Codejock Forums Homepage
Forum Home Forum Home > Codejock Products > Visual C++ MFC > Command Bars
  New Posts New Posts RSS Feed - Adding to toolbars and separator
  FAQ FAQ  Forum Search   Events   Register Register  Login Login

Adding to toolbars and separator

 Post Reply Post Reply
Author
Message
Graham View Drop Down
Groupie
Groupie


Joined: 12 May 2003
Location: United Kingdom
Status: Offline
Points: 23
Post Options Post Options   Thanks (0) Thanks(0)   Quote Graham Quote  Post ReplyReply Direct Link To This Post Topic: Adding to toolbars and separator
    Posted: 29 May 2003 at 6:29am

Not sure if this is a bug, but when I add a combo box to a toolbar using the following code

(CXTPControlComboBox*)pCommandBar->GetControls()->Add(xtpControlComboBox, ID_PRESETBAR_MODEPATCH,_T(""), 3)

and there is a separator before the item on the toolbar which I'm inserting before (index 3 in this example), then the inserted combo box is inserted before the separator as well, so I can't insert after the separator and before the item with index 3.

I suppose I could get around it by having a dummy button on the toolbar after the separator and then remove that button once I've inserted the combox box after it.

Graham

Back to Top
Oleg View Drop Down
Admin Group
Admin Group
Avatar

Joined: 21 May 2003
Location: United States
Status: Offline
Points: 11234
Post Options Post Options   Thanks (0) Thanks(0)   Quote Oleg Quote  Post ReplyReply Direct Link To This Post Posted: 29 May 2003 at 8:40am

Separator in Xtreme Command Bars is linked with Control.

You must call SetBeginGroup(TRUE) member of ComboBox  object. 

 

 

CXTPControl* pControl = pCommandBar->GetControls()->Add(xtpControlComboBox, ID_PRESETBAR_MODEPATCH,_T(""), 3)

pControl ->SetBeginGroup(TRUE)

Back to Top
Graham View Drop Down
Groupie
Groupie


Joined: 12 May 2003
Location: United Kingdom
Status: Offline
Points: 23
Post Options Post Options   Thanks (0) Thanks(0)   Quote Graham Quote  Post ReplyReply Direct Link To This Post Posted: 29 May 2003 at 10:57am

Thanks for that.

Graham

Back to Top
 Post Reply Post Reply
  Share Topic   

Forum Jump Forum Permissions View Drop Down



This page was generated in 0.094 seconds.