Professional UI Solutions
Site Map   /  Register
 
 

Forum

Please Log In to post a new message or reply to an existing one. If you are not registered, please register.

NOTE: Some forums may be read-only if you are not currently subscribed to our technical support services.

Forums » Prof-UIS General Discussion » CExtColorButton problem Collapse All
Subject Author Date
Tobias Billas Feb 8, 2008 - 3:20 AM

I’m creating a CExtColorButton control and setting the default color and selected color. Compiles it with latest 2.8.2.0 lib on a Vista machine.

When running the application under Vista all works fine, but when running same application under Win XP the control doesn’t work as expected. When selecting a new color the color on the button control don’t change and the value of m_clrSelected remains at the value it got at initialization.

Technical Support Feb 21, 2008 - 10:18 AM

We think you may simply have forgotten to invoke m_btnQueueColor.Invalidate(); finally after changing the color. The difference between XP and Vista may be caused by some third party conditions specific for each OS.

Tobias Billas Feb 21, 2008 - 3:57 AM

I have a dialog derived from CExtResizableDialog where I have a CExtColorButton and some CExtCheckBox’s.
In the OnInitDialog()
m_btnQueueColor.m_bEnableBtnColorDefault = true;
m_btnQueueColor.m_clrDefault = RGB(255,255,255);
m_btnQueueColor.m_bUseStdColorDlg = false;
SubclassAllControlsDynamically(GetSafeHwnd());

I have a OnLoad() function that will load some initial values to the controls when the dialog is shown.
OnLoad()
//Doin some .SetCheck(true/false) on the check boxes
m_btnQueueColor.m_clrSelected = settings.GetMainListBkColor(); //This value will not change whatever I select when running on XP.

And when running this on a Vista machine all works fine, but not on a XP. Also notice that I didn’t have this problem before I upgraded to 2.82.

Technical Support Feb 11, 2008 - 6:40 AM

We cannot reproduce this problem with color buttons displayed on the Buttons page in the ProfUIS_Controls sample. We suspect the problem in your project may have to do with some specific code in scope of your project only. Please provide us with more details or a test project.