summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNoel Grandin <noel@peralex.com>2015-08-03 11:12:08 +0200
committerMiklos Vajna <vmiklos@collabora.co.uk>2015-08-05 09:41:43 +0000
commit1b556192d5cf43a2505755d98c96d48bf841e9da (patch)
tree8da26c02252e1bb4425cefc43f27104043abb4a8
parent7a479d44676b3a2f413c3a103ef5943b3562cbe3 (diff)
tdf#92788 - Middle Button on Mouse Paste Option Broken for X11
cherry-pick from master caused by commit 5333782d090a9e147c0c431f0f741863d1d8cf8e "convert SETTINGS_ #defines to 'enum class'" Change-Id: Id0c2738a61f73223f6c8716f04a619c8cb84c0a9 Reviewed-on: https://gerrit.libreoffice.org/17493 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk>
-rw-r--r--include/vcl/settings.hxx3
-rw-r--r--vcl/source/app/settings.cxx13
2 files changed, 14 insertions, 2 deletions
diff --git a/include/vcl/settings.hxx b/include/vcl/settings.hxx
index 965d47065d79..006e758be579 100644
--- a/include/vcl/settings.hxx
+++ b/include/vcl/settings.hxx
@@ -679,13 +679,14 @@ public:
enum class AllSettingsFlags {
NONE = 0x0000,
+ MOUSE = 0x0001,
STYLE = 0x0002,
MISC = 0x0004,
LOCALE = 0x0020,
};
namespace o3tl
{
- template<> struct typed_flags<AllSettingsFlags> : is_typed_flags<AllSettingsFlags, 0x026> {};
+ template<> struct typed_flags<AllSettingsFlags> : is_typed_flags<AllSettingsFlags, 0x0027> {};
}
class VCL_DLLPUBLIC AllSettings
diff --git a/vcl/source/app/settings.cxx b/vcl/source/app/settings.cxx
index 3d6f3c1a5781..638f9e8c1c94 100644
--- a/vcl/source/app/settings.cxx
+++ b/vcl/source/app/settings.cxx
@@ -2706,7 +2706,8 @@ ImplAllSettingsData::ImplAllSettingsData()
maLocale( LANGUAGE_SYSTEM ),
maUILocale( LANGUAGE_SYSTEM )
{
- mnWindowUpdate = AllSettingsFlags::STYLE | AllSettingsFlags::MISC | AllSettingsFlags::LOCALE;
+ mnWindowUpdate = AllSettingsFlags::MOUSE | AllSettingsFlags::STYLE |
+ AllSettingsFlags::MISC | AllSettingsFlags::LOCALE;
mpLocaleDataWrapper = NULL;
mpUILocaleDataWrapper = NULL;
mpI18nHelper = NULL;
@@ -2768,6 +2769,16 @@ AllSettingsFlags AllSettings::Update( AllSettingsFlags nFlags, const AllSettings
AllSettingsFlags nChangeFlags = AllSettingsFlags::NONE;
+ if ( nFlags & AllSettingsFlags::MOUSE )
+ {
+ if ( mxData->maMouseSettings != rSet.mxData->maMouseSettings )
+ {
+ CopyData();
+ mxData->maMouseSettings = rSet.mxData->maMouseSettings;
+ nChangeFlags |= AllSettingsFlags::MOUSE;
+ }
+ }
+
if ( nFlags & AllSettingsFlags::STYLE )
{
if ( mxData->maStyleSettings != rSet.mxData->maStyleSettings )