Codejock Forums Homepage
Forum Home Forum Home > Codejock Products > Visual C++ MFC > Command Bars
  New Posts New Posts RSS Feed - SetDropDownListStyle changes behavior in Ribbon
  FAQ FAQ  Forum Search   Events   Register Register  Login Login

SetDropDownListStyle changes behavior in Ribbon

 Post Reply Post Reply
Author
Message
cpede View Drop Down
Senior Member
Senior Member


Joined: 13 August 2004
Location: Denmark
Status: Offline
Points: 668
Post Options Post Options   Thanks (0) Thanks(0)   Quote cpede Quote  Post ReplyReply Direct Link To This Post Topic: SetDropDownListStyle changes behavior in Ribbon
    Posted: 29 September 2010 at 4:38am

I found a strange difference in how a combo box gallery is working in a Ribbon. The behavior can be see in the examples by changing the pCombo->SetDropDownListStyle() to pCombo->SetDropDownListStyle(FALSE), e.g. for the Font Size control. The FALSE should according to the documentation make the combo box edit box read only.

 
The strange effect can be seen above. When the value is e.g. 36 and pCombo->SetDropDownListStyle()  is used we get a drop-down list with 36 selected (as expected) and seen in the samples. If I change it to pCombo->SetDropDownListStyle(FALSE) I get the behavior in the right most image. The selection is set to the first item in the list.
I believe this is a bug. Anyway to get the expected behavior?
 
Product: Xtreme ToolkitPro (24.0.0)
Platform: Windows 10 (x64)
Language: Visual Studio 2017 (C++)
Back to Top
cpede View Drop Down
Senior Member
Senior Member


Joined: 13 August 2004
Location: Denmark
Status: Offline
Points: 668
Post Options Post Options   Thanks (0) Thanks(0)   Quote cpede Quote  Post ReplyReply Direct Link To This Post Posted: 29 September 2010 at 4:43am
Ok found the answer myself :-)
 
Instead of using pCombo->SetDropDownListStyle(FALSE) I use the combination:
pCombo->SetDropDownListStyle() and pCombo->SetEditStyle(ES_READONLY);
 
Then I get the same effect. But I still think the other way should work also.
Product: Xtreme ToolkitPro (24.0.0)
Platform: Windows 10 (x64)
Language: Visual Studio 2017 (C++)
Back to Top
 Post Reply Post Reply
  Share Topic   

Forum Jump Forum Permissions View Drop Down

Forum Software by Web Wiz Forums® version 12.04
Copyright ©2001-2021 Web Wiz Ltd.

This page was generated in 0.125 seconds.