[Libreoffice-commits] .: vcl/unx
Jan Holesovsky
kendy at kemper.freedesktop.org
Fri Apr 29 16:10:44 PDT 2011
vcl/unx/gtk/gdi/salnativewidgets-gtk.cxx | 16 ++++++++++++++++
1 file changed, 16 insertions(+)
New commits:
commit 65d99f6b6fcaa303986ae151a95a8ee76e22bf3e
Author: Christian Dywan <christian at lanedo.com>
Date: Sat Apr 30 01:09:53 2011 +0200
Set GTK+ native mouse behaviour settings
diff --git a/vcl/unx/gtk/gdi/salnativewidgets-gtk.cxx b/vcl/unx/gtk/gdi/salnativewidgets-gtk.cxx
index 162ffad..c37b366 100644
--- a/vcl/unx/gtk/gdi/salnativewidgets-gtk.cxx
+++ b/vcl/unx/gtk/gdi/salnativewidgets-gtk.cxx
@@ -3497,6 +3497,22 @@ void GtkSalGraphics::updateSettings( AllSettings& rSettings )
else
aStyleSet.SetCursorBlinkTime( STYLE_CURSOR_NOBLINKTIME );
+ MouseSettings aMouseSettings = rSettings.GetMouseSettings();
+ int iDoubleClickTime, iDoubleClickDistance, iDragThreshold, iMenuPopupDelay;
+ g_object_get( pSettings,
+ "gtk-double-click-time", &iDoubleClickTime,
+ "gtk-double-click-distance", &iDoubleClickDistance,
+ "gtk-dnd-drag-threshold", &iDragThreshold,
+ "gtk-menu-popup-delay", &iMenuPopupDelay,
+ (char *)NULL );
+ aMouseSettings.SetDoubleClickTime( iDoubleClickTime );
+ aMouseSettings.SetDoubleClickWidth( iDoubleClickDistance );
+ aMouseSettings.SetDoubleClickHeight( iDoubleClickDistance );
+ aMouseSettings.SetStartDragWidth( iDragThreshold );
+ aMouseSettings.SetStartDragHeight( iDragThreshold );
+ aMouseSettings.SetMenuDelay( iMenuPopupDelay );
+ rSettings.SetMouseSettings( aMouseSettings );
+
gboolean showmenuicons = true;
g_object_get( pSettings, "gtk-menu-images", &showmenuicons, (char *)NULL );
aStyleSet.SetPreferredUseImagesInMenus( showmenuicons );
More information about the Libreoffice-commits
mailing list