diff options
author | Caolán McNamara <caolanm@redhat.com> | 2021-11-17 16:31:07 +0000 |
---|---|---|
committer | Caolán McNamara <caolanm@redhat.com> | 2021-11-17 20:49:02 +0100 |
commit | 9f68cc110c16cc096f5549a4a0812cee56cb09db (patch) | |
tree | 316f2981038568ad87643af1c6b3542f63195406 | |
parent | 2b3cc82b88d0c6508e9c0c6ccc53e0f9bfb4069e (diff) |
drop unused PopupMenuFlags::NoHorzPlacement
Change-Id: Ic279160f96e5aa2a37690f987c2323b91b2ec49c
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125415
Tested-by: Caolán McNamara <caolanm@redhat.com>
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
-rw-r--r-- | compilerplugins/clang/unusedenumconstants.readonly.results | 2 | ||||
-rw-r--r-- | include/vcl/menu.hxx | 8 | ||||
-rw-r--r-- | vcl/source/window/menu.cxx | 3 |
3 files changed, 1 insertions, 12 deletions
diff --git a/compilerplugins/clang/unusedenumconstants.readonly.results b/compilerplugins/clang/unusedenumconstants.readonly.results index 935e74505021..02ec1e8a728f 100644 --- a/compilerplugins/clang/unusedenumconstants.readonly.results +++ b/compilerplugins/clang/unusedenumconstants.readonly.results @@ -512,8 +512,6 @@ include/vcl/keycodes.hxx:175 enum ModKeyFlags Mod2Msk include/vcl/menu.hxx:78 enum PopupMenuFlags ExecuteUp -include/vcl/menu.hxx:86 - enum PopupMenuFlags NoHorzPlacement include/vcl/pdf/PDFAnnotationSubType.hxx:17 enum vcl::pdf::PDFAnnotationSubType Unknown include/vcl/pdf/PDFAnnotationSubType.hxx:26 diff --git a/include/vcl/menu.hxx b/include/vcl/menu.hxx index c0a627a30f88..f96c775fa64d 100644 --- a/include/vcl/menu.hxx +++ b/include/vcl/menu.hxx @@ -77,17 +77,11 @@ enum class PopupMenuFlags ExecuteUp = 0x0002, ExecuteRight = 0x0008, NoMouseUpClose = 0x0010, -//If there isn't enough space to put the menu where it wants -//to go, then they will be autoplaced. Toggle this bit -//on to force menus to be placed either above or below -//the starting rectangle and shrunk to fit and then scroll rather than place -//the menu beside that rectangle - NoHorzPlacement = 0x0020, }; namespace o3tl { - template<> struct typed_flags<PopupMenuFlags> : is_typed_flags<PopupMenuFlags, 0x003b> {}; + template<> struct typed_flags<PopupMenuFlags> : is_typed_flags<PopupMenuFlags, 0x001b> {}; } enum class MenuFlags diff --git a/vcl/source/window/menu.cxx b/vcl/source/window/menu.cxx index 797740d127b8..53f5e28e6f53 100644 --- a/vcl/source/window/menu.cxx +++ b/vcl/source/window/menu.cxx @@ -2798,9 +2798,6 @@ sal_uInt16 PopupMenu::Execute( vcl::Window* pExecWindow, const tools::Rectangle& if (nFlags & PopupMenuFlags::NoMouseUpClose ) // allow popup menus to stay open on mouse button up nPopupModeFlags |= FloatWinPopupFlags::NoMouseUpClose; // useful if the menu was opened on mousebutton down (eg toolbox configuration) - if (nFlags & PopupMenuFlags::NoHorzPlacement) - nPopupModeFlags |= FloatWinPopupFlags::NoHorzPlacement; - return ImplExecute( pExecWindow, rRect, nPopupModeFlags, nullptr, false ); } |