gnome-power-manager: added patch for suspend, misc changes.

This commit is contained in:
Juan RP 2011-07-19 22:02:29 +02:00
parent f109e37daf
commit 043dbcd786
2 changed files with 36 additions and 6 deletions

View file

@ -0,0 +1,31 @@
From 44503c5bca065290ce73b0d064a1a0db7de2936d Mon Sep 17 00:00:00 2001
From: Matthias Clasen <mclasen@redhat.com>
Date: Mon, 02 May 2011 23:18:58 +0000
Subject: gpm-idle: manually update the status property
gnome-session doesn't emit PropertyChanged since it uses dbus-glib,
therefore we need to manually update the cached property when
receiving a SessionChanged signal.
https://bugzilla.redhat.com/show_bug.cgi?id=679083
Signed-off-by: Richard Hughes <richard@hughsie.com>
---
diff --git a/src/gpm-idle.c b/src/gpm-idle.c
index 04225fc..0f2f1ee 100644
--- src/gpm-idle.c
+++ src/gpm-idle.c
@@ -424,6 +424,11 @@ gpm_idle_dbus_signal_cb (GDBusProxy *proxy, const gchar *sender_name, const gcha
return;
}
if (g_strcmp0 (signal_name, "StatusChanged") == 0) {
+ guint status;
+
+ g_variant_get (parameters, "(u)", &status);
+ g_dbus_proxy_set_cached_property (proxy, "status",
+ g_variant_new ("u", status));
g_debug ("Received gnome session status change");
gpm_idle_evaluate (idle);
return;
--
cgit v0.9

View file

@ -1,11 +1,14 @@
# Template file for 'gnome-power-manager'
pkgname=gnome-power-manager
version=3.0.2
revision=1
distfiles="${GNOME_SITE}/$pkgname/3.0/$pkgname-$version.tar.bz2"
build_style=gnu_configure
configure_args="--disable-scrollkeeper --localstatedir=/var --disable-schemas-compile"
short_desc="GNOME power management tool"
maintainer="Juan RP <xtraeme@gmail.com>"
homepage="http://www.gnome.org/projects/gnome-power-manager/"
license="GPL-2"
checksum=d0e00fdcfbc3bfb709f9ed82a14de325c51cf0bb86eeacefcda2dd7fcf6cbc2b
long_desc="
GNOME Power Manager is a session daemon for the GNOME desktop that takes care
@ -19,7 +22,7 @@ long_desc="
components of the GNOME desktop."
triggers="gsettings-schemas"
gtk_iconcache_dirs="/usr/share/icons/hicolor"
gtk_iconcache_dirs="/usr/share/icons/hicolor /usr/share/icons/gnome"
Add_dependency run glibc
Add_dependency run glib
@ -38,12 +41,7 @@ Add_dependency run libgnome-keyring
Add_dependency build pkg-config
Add_dependency build intltool
Add_dependency build gnome-doc-utils
Add_dependency build glib-devel
Add_dependency build pango-devel
Add_dependency build cairo-devel
Add_dependency build gtk+3-devel
Add_dependency build libX11-devel
Add_dependency build libXext-devel
Add_dependency build libXrandr-devel
Add_dependency build libcanberra-devel
Add_dependency build libnotify-devel
@ -52,4 +50,5 @@ Add_dependency build GConf-devel
Add_dependency build libgnome-keyring-devel
Add_dependency full polkit-gnome
Add_dependency full gnome-icon-theme
Add_dependency full hicolor-icon-theme