summaryrefslogtreecommitdiff
path: root/src/gpm-manager.c
diff options
context:
space:
mode:
authorWilliam Brown <[email protected]>2012-11-11 20:02:11 +1030
committerWilliam Brown <[email protected]>2012-11-11 20:02:11 +1030
commit9361bbfbb5f7fda96f147310125fc709f4da2200 (patch)
tree7b096d440129278db391c2611133caad51c43f39 /src/gpm-manager.c
parentfbf40ff748a675bdba451168c30aab7abeb5afa2 (diff)
downloadmate-power-manager-9361bbfbb5f7fda96f147310125fc709f4da2200.tar.bz2
mate-power-manager-9361bbfbb5f7fda96f147310125fc709f4da2200.tar.xz
Keyboard backlight patches, tested as working against 1.5.0 on F18
Diffstat (limited to 'src/gpm-manager.c')
-rw-r--r--src/gpm-manager.c10
1 files changed, 10 insertions, 0 deletions
diff --git a/src/gpm-manager.c b/src/gpm-manager.c
index 68ff788..13b0b8d 100644
--- a/src/gpm-manager.c
+++ b/src/gpm-manager.c
@@ -53,6 +53,7 @@
#include "gpm-manager.h"
#include "gpm-screensaver.h"
#include "gpm-backlight.h"
+#include "gpm-kbd-backlight.h"
#include "gpm-session.h"
#include "gpm-stock-icons.h"
#include "gpm-tray-icon.h"
@@ -84,6 +85,7 @@ struct GpmManagerPrivate
GpmTrayIcon *tray_icon;
GpmEngine *engine;
GpmBacklight *backlight;
+ GpmKbdBacklight *kbd_backlight;
EggConsoleKit *console;
guint32 screensaver_ac_throttle_id;
guint32 screensaver_dpms_throttle_id;
@@ -1904,6 +1906,13 @@ gpm_manager_init (GpmManager *manager)
G_OBJECT (manager->priv->backlight));
}
+ manager->priv->kbd_backlight = gpm_kbd_backlight_new ();
+ if (manager->priv->kbd_backlight != NULL) {
+ gpm_kbd_backlight_register_dbus (manager->priv->kbd_backlight,
+ connection,
+ NULL);
+ }
+
manager->priv->idle = gpm_idle_new ();
g_signal_connect (manager->priv->idle, "idle-changed",
G_CALLBACK (gpm_manager_idle_changed_cb), manager);
@@ -1998,6 +2007,7 @@ gpm_manager_finalize (GObject *object)
g_object_unref (manager->priv->control);
g_object_unref (manager->priv->button);
g_object_unref (manager->priv->backlight);
+ g_object_unref (manager->priv->kbd_backlight);
g_object_unref (manager->priv->console);
g_object_unref (manager->priv->client);
g_object_unref (manager->priv->status_icon);