diff options
-rw-r--r-- | include/vcl/menu.hxx | 2 | ||||
-rw-r--r-- | vcl/source/window/menu.cxx | 6 |
2 files changed, 4 insertions, 4 deletions
diff --git a/include/vcl/menu.hxx b/include/vcl/menu.hxx index 6fd25acf169c..2846fa78cf03 100644 --- a/include/vcl/menu.hxx +++ b/include/vcl/menu.hxx @@ -413,7 +413,7 @@ class VCL_DLLPUBLIC MenuBar : public Menu bool mbFloatBtnVisible : 1; bool mbHideBtnVisible : 1; bool mbDisplayable : 1; - SystemWindow* mpAssociatedSystemWindow; + VclPtr<SystemWindow> mxAssociatedSystemWindow; friend class Application; friend class Menu; diff --git a/vcl/source/window/menu.cxx b/vcl/source/window/menu.cxx index 373d94686887..c31887e2d013 100644 --- a/vcl/source/window/menu.cxx +++ b/vcl/source/window/menu.cxx @@ -2494,9 +2494,9 @@ MenuBar::MenuBar(SystemWindow* pAssociatedSystemWindow) mbFloatBtnVisible(false), mbHideBtnVisible(false), mbDisplayable(true), - mpAssociatedSystemWindow(pAssociatedSystemWindow) + mxAssociatedSystemWindow(pAssociatedSystemWindow) { - mpSalMenu = ImplGetSVData()->mpDefInst->CreateMenu(true, this, mpAssociatedSystemWindow); + mpSalMenu = ImplGetSVData()->mpDefInst->CreateMenu(true, this, mxAssociatedSystemWindow.get()); } MenuBar::MenuBar( const MenuBar& rMenu ) @@ -2506,7 +2506,7 @@ MenuBar::MenuBar( const MenuBar& rMenu ) mbHideBtnVisible(false), mbDisplayable(true) { - mpSalMenu = ImplGetSVData()->mpDefInst->CreateMenu(true, this, mpAssociatedSystemWindow); + mpSalMenu = ImplGetSVData()->mpDefInst->CreateMenu(true, this, mxAssociatedSystemWindow.get()); *this = rMenu; } |