[gnome-settings-daemon] power: Better debug for screensaver blanking test
- From: Bastien Nocera <hadess src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-settings-daemon] power: Better debug for screensaver blanking test
- Date: Wed, 23 Jan 2013 15:27:24 +0000 (UTC)
commit 02cbbcc8374869048679c9d6c9873d29e659f4ba
Author: Bastien Nocera <hadess hadess net>
Date: Wed Jan 23 16:25:24 2013 +0100
power: Better debug for screensaver blanking test
plugins/power/gsd-power-manager.c | 13 +++++++------
1 files changed, 7 insertions(+), 6 deletions(-)
---
diff --git a/plugins/power/gsd-power-manager.c b/plugins/power/gsd-power-manager.c
index 8566f8e..668b93c 100644
--- a/plugins/power/gsd-power-manager.c
+++ b/plugins/power/gsd-power-manager.c
@@ -2373,13 +2373,14 @@ idle_set_mode (GsdPowerManager *manager, GsdPowerIdleMode mode)
GVariant *active_v;
gboolean is_active = FALSE;
- if (mode == manager->priv->current_idle_mode)
- return;
-
/* Ignore attempts to set "less idle" modes */
- if (mode < manager->priv->current_idle_mode &&
- mode != GSD_POWER_IDLE_MODE_NORMAL)
+ if (mode <= manager->priv->current_idle_mode &&
+ mode != GSD_POWER_IDLE_MODE_NORMAL) {
+ g_debug ("Not going to 'less idle' mode %s (current: %s)",
+ idle_mode_to_string (mode),
+ idle_mode_to_string (manager->priv->current_idle_mode));
return;
+ }
/* ensure we're still on an active console */
active_v = g_dbus_proxy_get_cached_property (manager->priv->session,
@@ -2809,7 +2810,7 @@ screensaver_signal_cb (GDBusProxy *proxy,
if (g_strcmp0 (signal_name, "ActiveChanged") == 0) {
g_variant_get (parameters, "(b)", &active);
- g_debug ("Received screensaver ActiveChanged signal: %d", active);
+ g_debug ("Received screensaver ActiveChanged signal: %d (old: %d)", active, manager->priv->screensaver_active);
if (manager->priv->screensaver_active != active) {
manager->priv->screensaver_active = active;
idle_configure (manager);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]