|
-
July 20th, 2005, 11:58 AM
#1
Toolbar that can't be resized by user
Hi,
I have a toolbar created as follows.
Code:
if (!m_wndDynamicRuntimeToolBar.CreateEx(this, TBSTYLE_FLAT, WS_CHILD | CBRS_TOP
| CBRS_TOOLTIPS | CBRS_FLYBY | CBRS_SIZE_DYNAMIC | WS_DLGFRAME, CRect(0, 0, 0, 0), IDR_DYNAMICRUNTIMETOOLBAR) ||
!m_wndDynamicRuntimeToolBar.LoadToolBar(IDR_DYNAMICRUNTIMETOOLBAR))
{
TRACE0("Failed to create toolbar\n");
return -1; // fail to create
}
m_wndDynamicRuntimeToolBar.EnableDocking(0);
It has no gripper and shows only the buttons.
The problem is that when you move the mouse on the edges of the toolbar you have the possibility to resize the toolbar.
Does someone know how to prevent the user to be able to resize the toolbar?
Thanks a lot!
-
July 20th, 2005, 12:34 PM
#2
Re: Toolbar that can't be resized by user
Your problem is most likly the CBRS_SIZE_DYNAMIC flag. It's purpose is to make the toolbar resizable. Removing it should fix the issue.
-
July 21st, 2005, 01:15 AM
#3
Re: Toolbar that can't be resized by user
Hi,
Firstly, Thanks for answering.
But it does not change anything.
I still have the possibility to click on the edges and resize the bar.
Any other ideas, perhaps SubClassing but SubClass what and override what???
Thanks a lot
-
July 21st, 2005, 03:50 AM
#4
Re: Toolbar that can't be resized by user
Hi,
removing this flag works thanks, it was somewhere else that there was a mistake.
Thanks it works now
-
July 21st, 2005, 03:11 PM
#5
Re: Toolbar that can't be resized by user
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|