diff options
Diffstat (limited to 'src/gpm-manager.c')
-rw-r--r-- | src/gpm-manager.c | 34 |
1 files changed, 0 insertions, 34 deletions
diff --git a/src/gpm-manager.c b/src/gpm-manager.c index b63ccb7..f6c498e 100644 --- a/src/gpm-manager.c +++ b/src/gpm-manager.c @@ -60,7 +60,6 @@ #include "gpm-tray-icon.h" #include "gpm-engine.h" #include "gpm-upower.h" -#include "gpm-disks.h" #include "org.mate.PowerManager.Backlight.h" #include "org.mate.PowerManager.KbdBacklight.h" @@ -78,7 +77,6 @@ struct GpmManagerPrivate { GpmButton *button; GSettings *settings; - GpmDisks *disks; GpmDpms *dpms; GpmIdle *idle; GpmControl *control; @@ -946,28 +944,6 @@ gpm_manager_button_pressed_cb (GpmButton *button, const gchar *type, GpmManager } /** - * gpm_manager_get_spindown_timeout: - **/ -static gint -gpm_manager_get_spindown_timeout (GpmManager *manager) -{ - gboolean enabled; - gint timeout; - - /* get policy */ - if (!manager->priv->on_battery) { - enabled = g_settings_get_boolean (manager->priv->settings, GPM_SETTINGS_SPINDOWN_ENABLE_AC); - timeout = g_settings_get_int (manager->priv->settings, GPM_SETTINGS_SPINDOWN_TIMEOUT_AC); - } else { - enabled = g_settings_get_boolean (manager->priv->settings, GPM_SETTINGS_SPINDOWN_ENABLE_BATT); - timeout = g_settings_get_int (manager->priv->settings, GPM_SETTINGS_SPINDOWN_TIMEOUT_BATT); - } - if (!enabled) - timeout = 0; - return timeout; -} - -/** * gpm_manager_client_changed_cb: **/ static void @@ -1016,10 +992,6 @@ gpm_manager_client_changed_cb (UpClient *client, GpmManager *manager) egg_debug ("on_battery: %d", on_battery); - /* set disk spindown threshold */ - timeout = gpm_manager_get_spindown_timeout (manager); - gpm_disks_set_spindown_timeout (manager->priv->disks, timeout); - gpm_manager_sync_policy_sleep (manager); gpm_manager_update_ac_throttle (manager); @@ -1850,7 +1822,6 @@ gpm_manager_init (GpmManager *manager) manager->priv->notification_warning_low = NULL; manager->priv->notification_discharging = NULL; manager->priv->notification_fully_charged = NULL; - manager->priv->disks = gpm_disks_new (); manager->priv->settings = g_settings_new (GPM_SETTINGS_SCHEMA); g_signal_connect (manager->priv->settings, "changed", G_CALLBACK (gpm_manager_settings_changed_cb), manager); @@ -1943,10 +1914,6 @@ gpm_manager_init (GpmManager *manager) g_signal_connect (manager->priv->engine, "charge-action", G_CALLBACK (gpm_manager_engine_charge_action_cb), manager); - /* set disk spindown threshold */ - timeout = gpm_manager_get_spindown_timeout (manager); - gpm_disks_set_spindown_timeout (manager->priv->disks, timeout); - /* update ac throttle */ gpm_manager_update_ac_throttle (manager); } @@ -1982,7 +1949,6 @@ gpm_manager_finalize (GObject *object) g_source_remove (manager->priv->critical_alert_timeout_id); g_object_unref (manager->priv->settings); - g_object_unref (manager->priv->disks); g_object_unref (manager->priv->dpms); g_object_unref (manager->priv->idle); g_object_unref (manager->priv->engine); |