[gnome-power-manager] Do not handle the 'power' button key, it's moved to gnome-settings-daemon



commit b5c4c0652d2f3af8f7b3e7153c88fcb730f5b8fa
Author: Richard Hughes <richard hughsie com>
Date:   Mon Jul 4 12:23:55 2011 +0100

    Do not handle the 'power' button key, it's moved to gnome-settings-daemon

 configure.ac      |    7 -------
 src/gpm-button.c  |    3 ---
 src/gpm-manager.c |   10 ----------
 3 files changed, 0 insertions(+), 20 deletions(-)
---
diff --git a/configure.ac b/configure.ac
index 7329249..13588e1 100644
--- a/configure.ac
+++ b/configure.ac
@@ -129,13 +129,6 @@ PKG_CHECK_MODULES(UPOWER, upower-glib >= 0.9.1)
 dnl **** Check for NOTIFY ****
 PKG_CHECK_MODULES(NOTIFY, libnotify >= 0.7.0)
 
-dnl ---------------------------------------------------------------------------
-dnl - Check XF86XK_Keys
-dnl ---------------------------------------------------------------------------
-PKG_CHECK_EXISTS(
- [xproto >= 7.0.14],
- [AC_DEFINE(HAVE_XF86XK_BATTERY, 1, [Define if XF86XK_Battery is available])])
-
 PKG_CHECK_EXISTS(
  [xproto >= 7.0.15],
  [AC_DEFINE(HAVE_XF86XK_SUSPEND, 1, [Define if XF86XK_Suspend is available])
diff --git a/src/gpm-button.c b/src/gpm-button.c
index 2373a80..baf817a 100644
--- a/src/gpm-button.c
+++ b/src/gpm-button.c
@@ -333,9 +333,6 @@ gpm_button_init (GpmButton *button)
 	gpm_button_xevent_key (button, XF86XK_MonBrightnessUp, GPM_BUTTON_BRIGHT_UP);
 	gpm_button_xevent_key (button, XF86XK_MonBrightnessDown, GPM_BUTTON_BRIGHT_DOWN);
 	gpm_button_xevent_key (button, XF86XK_ScreenSaver, GPM_BUTTON_LOCK);
-#ifdef HAVE_XF86XK_BATTERY
-	gpm_button_xevent_key (button, XF86XK_Battery, GPM_BUTTON_BATTERY);
-#endif
 
 	/* use global filter */
 	gdk_window_add_filter (button->priv->window,
diff --git a/src/gpm-manager.c b/src/gpm-manager.c
index 68118db..15d3206 100644
--- a/src/gpm-manager.c
+++ b/src/gpm-manager.c
@@ -978,7 +978,6 @@ gpm_manager_update_lid_throttle (GpmManager *manager, gboolean lid_is_closed)
 static void
 gpm_manager_button_pressed_cb (GpmButton *button, const gchar *type, GpmManager *manager)
 {
-	gchar *message;
 	g_debug ("Button press event type=%s", type);
 
 	/* ConsoleKit says we are not on active console */
@@ -999,15 +998,6 @@ gpm_manager_button_pressed_cb (GpmButton *button, const gchar *type, GpmManager
 		gpm_manager_lid_button_pressed (manager, FALSE);
 	} else if (g_strcmp0 (type, GPM_BUTTON_LID_CLOSED) == 0) {
 		gpm_manager_lid_button_pressed (manager, TRUE);
-	} else if (g_strcmp0 (type, GPM_BUTTON_BATTERY) == 0) {
-		message = gpm_engine_get_summary (manager->priv->engine);
-		gpm_manager_notify (manager, &manager->priv->notification_general,
-				    _("Power Information"),
-				    message,
-				    GPM_MANAGER_NOTIFY_TIMEOUT_LONG,
-				    GTK_STOCK_DIALOG_INFO,
-				    NOTIFY_URGENCY_NORMAL);
-		g_free (message);
 	}
 
 	/* really belongs in gnome-screensaver */



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]