|
-
May 10th, 2003, 08:40 PM
#1
how to check where the CToolBar is docked
how can i check where the toolbar is docked ?
i want to see where the toolbar is docked (top, bottom, right or left) when i am leaving the program for saving/restore purposes...
i loose myself in that MFC sources so i need help...
thanx
-
May 11th, 2003, 12:44 AM
#2
Get the toolbar's style and check for the CBRS_ALIGN_ bit settings
Code:
if (!this->m_wndToolBar.IsFloating()) {
switch (this->m_wndToolBar.GetBarStyle() & CBRS_ALIGN_ANY) {
case CBRS_ALIGN_TOP:
MessageBox("Docking = Top");
break;
case CBRS_ALIGN_BOTTOM:
MessageBox("Docking = Bottom");
break;
case CBRS_ALIGN_LEFT:
MessageBox("Docking = Left");
break;
case CBRS_ALIGN_RIGHT:
MessageBox("Docking = Right");
break;
default:
MessageBox("Docking = Unknown");
}
}
else MessageBox("Not docked");
Hope it will help you
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
|