include/vcl/menu.hxx | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-)
New commits: commit ed6d0b6a2037fddcc5869c9cebf999cf4060e973 Author: Michael Weghorn <m.wegh...@posteo.de> AuthorDate: Mon Dec 2 13:00:41 2024 +0100 Commit: Michael Weghorn <m.wegh...@posteo.de> CommitDate: Mon Dec 2 19:27:07 2024 +0100 vcl MenuBar: Drop friend class Application Application doesn't need access to any private members. Change-Id: Ia69b64ecf8e380b0b8da7477e3a3c7d312629965 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/177693 Tested-by: Jenkins Reviewed-by: Michael Weghorn <m.wegh...@posteo.de> diff --git a/include/vcl/menu.hxx b/include/vcl/menu.hxx index 6a9e3141f219..0f6a0c414926 100644 --- a/include/vcl/menu.hxx +++ b/include/vcl/menu.hxx @@ -417,7 +417,6 @@ class VCL_DLLPUBLIC MenuBar final : public Menu bool mbHideBtnVisible : 1; bool mbDisplayable : 1; - friend class Application; friend class Menu; friend class MenuBarWindow; friend class SystemWindow; commit 09187a0208b9d531be75b780055002db620c4d96 Author: Michael Weghorn <m.wegh...@posteo.de> AuthorDate: Mon Dec 2 12:55:09 2024 +0100 Commit: Michael Weghorn <m.wegh...@posteo.de> CommitDate: Mon Dec 2 19:26:53 2024 +0100 vcl: No longer let MenuFloatingWindow be a friend of MenuBar MenuFloatingWindow is the window used of PopupMenu, while the window for MenuBar is MenuBarWindow. MenuFloatingWindow only needs access to the menu bar's MenuBarWindow, so make MenuBar::getMenuBarWindow public and no longer let MenuFloatingWindow be a friend of MenuBar, to make a little clearer who is able to access whose private members,... Change-Id: I7ee492e36d6e94884d1dba652d11f26cb8543a52 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/177692 Reviewed-by: Michael Weghorn <m.wegh...@posteo.de> Tested-by: Jenkins diff --git a/include/vcl/menu.hxx b/include/vcl/menu.hxx index bac335d305d9..6a9e3141f219 100644 --- a/include/vcl/menu.hxx +++ b/include/vcl/menu.hxx @@ -420,7 +420,6 @@ class VCL_DLLPUBLIC MenuBar final : public Menu friend class Application; friend class Menu; friend class MenuBarWindow; - friend class MenuFloatingWindow; friend class SystemWindow; SAL_DLLPRIVATE static VclPtr<vcl::Window> ImplCreate(vcl::Window* pParent, vcl::Window* pWindow, MenuBar* pMenu); @@ -428,9 +427,6 @@ class VCL_DLLPUBLIC MenuBar final : public Menu SAL_DLLPRIVATE bool ImplHandleKeyEvent(const KeyEvent& rKEvent); SAL_DLLPRIVATE bool ImplHandleCmdEvent(const CommandEvent& rCEvent); - /// Return the MenuBarWindow. - SAL_DLLPRIVATE MenuBarWindow* getMenuBarWindow(); - public: MenuBar(); SAL_DLLPRIVATE MenuBar( const MenuBar& rMenu ); @@ -441,6 +437,9 @@ public: virtual bool IsMenuBar() const override { return true; } + /// Return the MenuBarWindow. + SAL_DLLPRIVATE MenuBarWindow* getMenuBarWindow(); + /// Close the 'pStartedFrom' menu window. virtual void ClosePopup(Menu* pMenu) override;