[gnome-settings-daemon] mouse: Move set_mouse_settings() to avoid declaration
- From: Bastien Nocera <hadess src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-settings-daemon] mouse: Move set_mouse_settings() to avoid declaration
- Date: Sun, 26 Oct 2014 14:23:40 +0000 (UTC)
commit 6e22423362ffb36da0b576916b3bbcb0f26e3b74
Author: Bastien Nocera <hadess hadess net>
Date: Sun Oct 26 14:14:51 2014 +0100
mouse: Move set_mouse_settings() to avoid declaration
plugins/mouse/gsd-mouse-manager.c | 45 +++++++++++++++++-------------------
1 files changed, 21 insertions(+), 24 deletions(-)
---
diff --git a/plugins/mouse/gsd-mouse-manager.c b/plugins/mouse/gsd-mouse-manager.c
index 2cd4257..19698c6 100644
--- a/plugins/mouse/gsd-mouse-manager.c
+++ b/plugins/mouse/gsd-mouse-manager.c
@@ -99,9 +99,6 @@ static void gsd_mouse_manager_finalize (GObject *object);
static void set_tap_to_click (GdkDevice *device,
gboolean state,
gboolean left_handed);
-static void set_natural_scroll (GsdMouseManager *manager,
- GdkDevice *device,
- gboolean natural_scroll);
G_DEFINE_TYPE (GsdMouseManager, gsd_mouse_manager, G_TYPE_OBJECT)
@@ -930,27 +927,6 @@ get_touchpad_handedness (GsdMouseManager *manager, gboolean mouse_left_handed)
}
static void
-set_mouse_settings (GsdMouseManager *manager,
- GdkDevice *device)
-{
- gboolean mouse_left_handed, touchpad_left_handed;
-
- mouse_left_handed = g_settings_get_boolean (manager->priv->mouse_settings, KEY_LEFT_HANDED);
- touchpad_left_handed = get_touchpad_handedness (manager, mouse_left_handed);
- set_left_handed (manager, device, mouse_left_handed, touchpad_left_handed);
-
- set_motion (manager, device);
- set_middle_button (manager, device, g_settings_get_boolean (manager->priv->mouse_settings,
KEY_MIDDLE_BUTTON_EMULATION));
-
- set_tap_to_click (device, g_settings_get_boolean (manager->priv->touchpad_settings,
KEY_TAP_TO_CLICK), touchpad_left_handed);
- set_scroll_method (manager, device, g_settings_get_enum (manager->priv->touchpad_settings,
KEY_SCROLL_METHOD));
- set_horiz_scroll (device, g_settings_get_boolean (manager->priv->touchpad_settings,
KEY_PAD_HORIZ_SCROLL));
- set_natural_scroll (manager, device, g_settings_get_boolean (manager->priv->touchpad_settings,
KEY_NATURAL_SCROLL_ENABLED));
- if (g_settings_get_boolean (manager->priv->touchpad_settings, KEY_TOUCHPAD_ENABLED) == FALSE)
- set_touchpad_disabled (device);
-}
-
-static void
set_natural_scroll (GsdMouseManager *manager,
GdkDevice *device,
gboolean natural_scroll)
@@ -1012,6 +988,27 @@ set_natural_scroll (GsdMouseManager *manager,
}
static void
+set_mouse_settings (GsdMouseManager *manager,
+ GdkDevice *device)
+{
+ gboolean mouse_left_handed, touchpad_left_handed;
+
+ mouse_left_handed = g_settings_get_boolean (manager->priv->mouse_settings, KEY_LEFT_HANDED);
+ touchpad_left_handed = get_touchpad_handedness (manager, mouse_left_handed);
+ set_left_handed (manager, device, mouse_left_handed, touchpad_left_handed);
+
+ set_motion (manager, device);
+ set_middle_button (manager, device, g_settings_get_boolean (manager->priv->mouse_settings,
KEY_MIDDLE_BUTTON_EMULATION));
+
+ set_tap_to_click (device, g_settings_get_boolean (manager->priv->touchpad_settings,
KEY_TAP_TO_CLICK), touchpad_left_handed);
+ set_scroll_method (manager, device, g_settings_get_enum (manager->priv->touchpad_settings,
KEY_SCROLL_METHOD));
+ set_horiz_scroll (device, g_settings_get_boolean (manager->priv->touchpad_settings,
KEY_PAD_HORIZ_SCROLL));
+ set_natural_scroll (manager, device, g_settings_get_boolean (manager->priv->touchpad_settings,
KEY_NATURAL_SCROLL_ENABLED));
+ if (g_settings_get_boolean (manager->priv->touchpad_settings, KEY_TOUCHPAD_ENABLED) == FALSE)
+ set_touchpad_disabled (device);
+}
+
+static void
mouse_callback (GSettings *settings,
const gchar *key,
GsdMouseManager *manager)
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]