summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorSimon Long <simon@raspberrypi.org>2015-07-08 18:02:50 +0100
committerCaolán McNamara <caolanm@redhat.com>2015-07-09 15:07:24 +0000
commit74407aef94b6d8dfdd69891c4a6e578587ef3e71 (patch)
treecc8c8f9cde981f90760cb7fdaa02688713989f83 /include
parent40ade8d04380083e383d6a6e50e5c254fcde2b2f (diff)
tdf#92630 Enable auto-accelerator behaviour for gtk
Change-Id: I671177dd1f9e535c28a29bcbd6b74f1c789371ea Reviewed-on: https://gerrit.libreoffice.org/16883 Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
Diffstat (limited to 'include')
-rw-r--r--include/vcl/ctrl.hxx3
-rw-r--r--include/vcl/dialog.hxx1
-rw-r--r--include/vcl/layout.hxx1
-rw-r--r--include/vcl/menu.hxx2
-rw-r--r--include/vcl/outdev.hxx41
5 files changed, 27 insertions, 21 deletions
diff --git a/include/vcl/ctrl.hxx b/include/vcl/ctrl.hxx
index 69a3569a0b5e..b85f561ce254 100644
--- a/include/vcl/ctrl.hxx
+++ b/include/vcl/ctrl.hxx
@@ -43,6 +43,7 @@ private:
bool mbHasControlFocus;
bool mbFont;
bool mbForeground;
+ bool mbShowAccelerator;
Link<> maGetFocusHdl;
Link<> maLoseFocusHdl;
@@ -184,6 +185,8 @@ public:
OutputDevice* GetReferenceDevice() const;
vcl::Font GetUnzoomedControlPointFont() const;
+ void SetShowAccelerator (bool val);
+ bool GetShowAccelerator (void) const;
};
#endif // INCLUDED_VCL_CTRL_HXX
diff --git a/include/vcl/dialog.hxx b/include/vcl/dialog.hxx
index 8afe77480082..aae1dccbbda1 100644
--- a/include/vcl/dialog.hxx
+++ b/include/vcl/dialog.hxx
@@ -107,6 +107,7 @@ public:
private:
bool ImplStartExecuteModal();
static void ImplEndExecuteModal();
+ bool ImplHandleCmdEvent ( const CommandEvent& rCEvent );
public:
// Dialog::Execute replacement API
diff --git a/include/vcl/layout.hxx b/include/vcl/layout.hxx
index fc9eb56faa6a..7d67230ba363 100644
--- a/include/vcl/layout.hxx
+++ b/include/vcl/layout.hxx
@@ -786,6 +786,7 @@ inline bool isContainerWindow(const vcl::Window &rWindow)
{
WindowType eType = rWindow.GetType();
return eType == WINDOW_CONTAINER || eType == WINDOW_SCROLLWINDOW ||
+ eType == WINDOW_TABCONTROL || eType == WINDOW_TABPAGE ||
(eType == WINDOW_DOCKINGWINDOW && ::isLayoutEnabled(&rWindow));
}
diff --git a/include/vcl/menu.hxx b/include/vcl/menu.hxx
index 2a4abcf3052a..479849f608bc 100644
--- a/include/vcl/menu.hxx
+++ b/include/vcl/menu.hxx
@@ -44,6 +44,7 @@ class HelpEvent;
class Image;
class PopupMenu;
class KeyEvent;
+class CommandEvent;
class MenuFloatingWindow;
namespace vcl { class Window; }
class SalMenu;
@@ -440,6 +441,7 @@ class VCL_DLLPUBLIC MenuBar : public Menu
MenuBar* pMenu, const css::uno::Reference<css::frame::XFrame> &rFrame);
SAL_DLLPRIVATE static void ImplDestroy(MenuBar* pMenu, bool bDelete);
SAL_DLLPRIVATE bool ImplHandleKeyEvent(const KeyEvent& rKEvent, bool bFromMenu = true);
+ SAL_DLLPRIVATE bool ImplHandleCmdEvent(const CommandEvent& rCEvent);
protected:
diff --git a/include/vcl/outdev.hxx b/include/vcl/outdev.hxx
index 3e73b313c530..8f39b2febe13 100644
--- a/include/vcl/outdev.hxx
+++ b/include/vcl/outdev.hxx
@@ -160,30 +160,29 @@ typedef std::vector< Rectangle > MetricVector;
// Flags for DrawText()
enum class DrawTextFlags
{
- NONE = 0x0000,
- Disable = 0x0001,
- Mnemonic = 0x0002,
- Mono = 0x0004,
- Clip = 0x0008,
- Left = 0x0010,
- Center = 0x0020,
- Right = 0x0040,
- Top = 0x0080,
- VCenter = 0x0100,
- Bottom = 0x0200,
- EndEllipsis = 0x0400,
- PathEllipsis = 0x0800,
- MultiLine = 0x1000,
- WordBreak = 0x2000,
- NewsEllipsis = 0x4000,
- // in the long run we should make text style flags longer
- // but at the moment we can get away with this 2 bit field for ellipsis style
- CenterEllipsis = EndEllipsis | PathEllipsis,
- WordBreakHyphenation = 0x8000 | WordBreak,
+ NONE = 0x00000000,
+ Disable = 0x00000001,
+ Mnemonic = 0x00000002,
+ Mono = 0x00000004,
+ Clip = 0x00000008,
+ Left = 0x00000010,
+ Center = 0x00000020,
+ Right = 0x00000040,
+ Top = 0x00000080,
+ VCenter = 0x00000100,
+ Bottom = 0x00000200,
+ EndEllipsis = 0x00000400,
+ PathEllipsis = 0x00000800,
+ MultiLine = 0x00001000,
+ WordBreak = 0x00002000,
+ NewsEllipsis = 0x00004000,
+ WordBreakHyphenation = 0x00008000 | WordBreak,
+ CenterEllipsis = 0x00010000,
+ HideMnemonic = 0x00020000,
};
namespace o3tl
{
- template<> struct typed_flags<DrawTextFlags> : is_typed_flags<DrawTextFlags, 0xffff> {};
+ template<> struct typed_flags<DrawTextFlags> : is_typed_flags<DrawTextFlags, 0x3ffff> {};
}
// Flags for DrawImage(), these must match the definitions in css::awt::ImageDrawMode