summaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
authorCaolán McNamara <caolanm@redhat.com>2013-10-29 16:10:18 +0000
committerCaolán McNamara <caolanm@redhat.com>2013-10-29 16:11:08 +0000
commit0881ae68b0d7f977003e0798e52548caa2556f44 (patch)
tree0b6772d22c2ea8251520e5d0a24a44d239633428 /include
parentfdo#70998 Term Change: Picture/Graphic -> Image (diff)
downloadcore-0881ae68b0d7f977003e0798e52548caa2556f44.tar.gz
core-0881ae68b0d7f977003e0798e52548caa2556f44.zip
Resolves: rhbz#1021915 force menubar menus to be up/down only
If a menu won't fit in the desired location the default mode is to place it somewhere it will fit. e.g. above, left, right. For some cases, e.g. menubars, it's desirable to limit the options to above/below and force the menu to scroll if it won't fit Change-Id: I1998a842d25752389ec9032e54673408d1ed6cb5
Diffstat (limited to 'include')
-rw-r--r--include/vcl/floatwin.hxx1
-rw-r--r--include/vcl/menu.hxx17
2 files changed, 12 insertions, 6 deletions
diff --git a/include/vcl/floatwin.hxx b/include/vcl/floatwin.hxx
index 4e2f97cee243..9a9dbdcd11b1 100644
--- a/include/vcl/floatwin.hxx
+++ b/include/vcl/floatwin.hxx
@@ -48,6 +48,7 @@ class ToolBox;
#define FLOATWIN_POPUPMODE_NEWLEVEL ((sal_uLong)0x00008000)
#define FLOATWIN_POPUPMODE_NOMOUSEUPCLOSE ((sal_uLong)0x00010000)
#define FLOATWIN_POPUPMODE_GRABFOCUS ((sal_uLong)0x00020000)
+#define FLOATWIN_POPUPMODE_NOHORZPLACEMENT ((sal_uLong)0x00040000)
#define FLOATWIN_POPUPMODEEND_CANCEL ((sal_uInt16)0x0001)
#define FLOATWIN_POPUPMODEEND_TEAROFF ((sal_uInt16)0x0002)
diff --git a/include/vcl/menu.hxx b/include/vcl/menu.hxx
index 557914941e4f..637c701171e9 100644
--- a/include/vcl/menu.hxx
+++ b/include/vcl/menu.hxx
@@ -62,12 +62,17 @@ namespace vcl { struct MenuLayoutData; }
#define MENU_APPEND ((sal_uInt16)0xFFFF)
#define MENU_ITEM_NOTFOUND ((sal_uInt16)0xFFFF)
-#define POPUPMENU_EXECUTE_DOWN ((sal_uInt16)0x0001)
-#define POPUPMENU_EXECUTE_UP ((sal_uInt16)0x0002)
-#define POPUPMENU_EXECUTE_LEFT ((sal_uInt16)0x0004)
-#define POPUPMENU_EXECUTE_RIGHT ((sal_uInt16)0x0008)
-
-#define POPUPMENU_NOMOUSEUPCLOSE ((sal_uInt16)0x0010)
+#define POPUPMENU_EXECUTE_DOWN ((sal_uInt16)0x0001)
+#define POPUPMENU_EXECUTE_UP ((sal_uInt16)0x0002)
+#define POPUPMENU_EXECUTE_LEFT ((sal_uInt16)0x0004)
+#define POPUPMENU_EXECUTE_RIGHT ((sal_uInt16)0x0008)
+#define POPUPMENU_NOMOUSEUPCLOSE ((sal_uInt16)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
+#define POPUPMENU_NOHORZ_PLACEMENT ((sal_uInt16)0x0020)
#define MENU_FLAG_NOAUTOMNEMONICS 0x0001
#define MENU_FLAG_HIDEDISABLEDENTRIES 0x0002