Closed jkulawik closed 3 weeks ago
Fix from Luis:
Index: GuiPopUpColorPicker.cpp
===================================================================
--- GuiPopUpColorPicker.cpp (revision 166)
+++ GuiPopUpColorPicker.cpp (revision 167)
@@ -701,7 +701,7 @@
const cColor& cGuiPopUpColorPicker::GetOldColor()
{
- return mpFPreviousColor->GetBackGroundColor();
+ return mPrevColor;
}
//-------------------------------------------------------------------------------
@@ -909,7 +909,7 @@
if(pColor)
col = *pColor;
else
- col = mpFPreviousColor->GetBackGroundColor();
+ col = mPrevColor;
SetColor(col);
@@ -1394,7 +1394,7 @@
{
///////////////////////////////////////////////////////////////
// Compare old color to new and set up stuff if different
- if((mColor == mpFPreviousColor->GetBackGroundColor()) == false)
+ if (mColor != mPrevColor)
{
if(mpDestColor)
*mpDestColor = mColor;
I didn't expect this to work because mPrevColor is something we don't have so I just changed one of the conditions and it seems to have worked. Storing the previous color might be a better solution though because the current way of doing it is a hack, so this might need a solution in the future
See https://github.com/jkulawik/tdd-issues/issues/5