krb5 commit: Only create toolbar when not using ribbon UI
Benjamin Kaduk
kaduk at MIT.EDU
Fri Aug 24 12:24:11 EDT 2012
https://github.com/krb5/krb5/commit/7fc182b343517278ba7c8dd5b338068c74d032c6
commit 7fc182b343517278ba7c8dd5b338068c74d032c6
Author: Kevin Wasserman <kevin.wasserman at painless-security.com>
Date: Mon Apr 16 14:48:43 2012 -0400
Only create toolbar when not using ribbon UI
When we do create the toolbar, dock it.
Signed-off-by: Kevin Wasserman <kevin.wasserman at painless-security.com>
ticket: 7250 (new)
queue: kfw
target_version: 1.10.4
tags: pullup
src/windows/leash/MainFrm.cpp | 14 ++++++++------
1 files changed, 8 insertions(+), 6 deletions(-)
diff --git a/src/windows/leash/MainFrm.cpp b/src/windows/leash/MainFrm.cpp
index 15c0157..5346502 100644
--- a/src/windows/leash/MainFrm.cpp
+++ b/src/windows/leash/MainFrm.cpp
@@ -130,9 +130,9 @@ int CMainFrame::OnCreate(LPCREATESTRUCT lpCreateStruct)
#endif
*/
-
- if (!m_wndToolBar.Create(this) ||
- !m_wndToolBar.LoadToolBar(IDR_MAINFRAME))
+ if ((!CLeashApp::m_useRibbon) &&
+ (!m_wndToolBar.Create(this) ||
+ !m_wndToolBar.LoadToolBar(IDR_MAINFRAME)))
{
MessageBox("There is problem creating the Leash Toolbar!",
"Error", MB_OK);
@@ -154,11 +154,13 @@ int CMainFrame::OnCreate(LPCREATESTRUCT lpCreateStruct)
//m_wndToolBar.SetPaneStyle(m_wndToolBar.GetPaneStyle() |
// CBRS_TOOLTIPS | CBRS_FLYBY | CBRS_SIZE_DYNAMIC);
+ if (!CLeashApp::m_useRibbon) {
// TODO: Delete these three lines if you don't want the toolbar to
// be dockable
-// m_wndToolBar.EnableDocking(CBRS_ALIGN_ANY);
-// EnableDocking(CBRS_ALIGN_ANY);
- //DockControlBar(&m_wndToolBar);
+ m_wndToolBar.EnableDocking(CBRS_ALIGN_ANY);
+ EnableDocking(CBRS_ALIGN_ANY);
+ DockPane(&m_wndToolBar);
+ }
return 0;
}
More information about the cvs-krb5
mailing list