diff options
author | Szymon Kłos <eszkadev@gmail.com> | 2016-03-18 13:55:24 +0100 |
---|---|---|
committer | Jan Holesovsky <kendy@collabora.com> | 2016-03-30 11:01:30 +0200 |
commit | 1fb314832ebd14cde6457feb2bf4f19e1bfcaa82 (patch) | |
tree | da734f97c69385c0864c42249de09f2d5a3754a6 /vcl/source/window/brdwin.cxx | |
parent | 2c29716d349353997bf7cdde63cd9f867c5baeb6 (diff) |
notebookbar: Instantiate the notebookbar via sfx2 infrastructure.
Change-Id: Iaed4596246245560e646d9086e717d5fb516897e
Diffstat (limited to 'vcl/source/window/brdwin.cxx')
-rw-r--r-- | vcl/source/window/brdwin.cxx | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/vcl/source/window/brdwin.cxx b/vcl/source/window/brdwin.cxx index ff246a5e3acd..31b968fa9f4c 100644 --- a/vcl/source/window/brdwin.cxx +++ b/vcl/source/window/brdwin.cxx @@ -2177,11 +2177,12 @@ void ImplBorderWindow::SetMenuBarMode( bool bHide ) UpdateMenuHeight(); } -void ImplBorderWindow::SetNotebookBarWindow(const OUString& rUIXMLDescription, const css::uno::Reference<css::frame::XFrame>& rFrame) +VclPtr<vcl::Window> ImplBorderWindow::CreateNotebookBarWindow(const OUString& rUIXMLDescription, const css::uno::Reference<css::frame::XFrame>& rFrame) { mpNotebookBarWindow = VclPtr<NotebookBarWindow>::Create(this, "NotebookBar", rUIXMLDescription, rFrame); Resize(); - mpNotebookBarWindow->Show(); + + return mpNotebookBarWindow; } void ImplBorderWindow::GetBorder( sal_Int32& rLeftBorder, sal_Int32& rTopBorder, @@ -2192,7 +2193,7 @@ void ImplBorderWindow::GetBorder( sal_Int32& rLeftBorder, sal_Int32& rTopBorder, if (mpMenuBarWindow && !mbMenuHide) rTopBorder += mpMenuBarWindow->GetSizePixel().Height(); - if (mpNotebookBarWindow) + if (mpNotebookBarWindow && mpNotebookBarWindow->IsVisible()) rTopBorder += mpNotebookBarWindow->GetSizePixel().Height(); } |