[gnome-power-manager] Remove GpmTrayIcon
- From: Richard Hughes <rhughes src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-power-manager] Remove GpmTrayIcon
- Date: Wed, 4 May 2011 13:16:15 +0000 (UTC)
commit baa2317cd326304ac785514f84b505df5a6f80ba
Author: Richard Hughes <richard hughsie com>
Date: Wed May 4 14:15:00 2011 +0100
Remove GpmTrayIcon
We no longer support showing our own status icon. GNOME Shell FTW.
data/org.gnome.power-manager.gschema.xml.in | 4 -
po/POTFILES.in | 1 -
src/Makefile.am | 2 -
src/gpm-manager.c | 33 --
src/gpm-tray-icon.c | 494 ---------------------------
src/gpm-tray-icon.h | 63 ----
6 files changed, 0 insertions(+), 597 deletions(-)
---
diff --git a/data/org.gnome.power-manager.gschema.xml.in b/data/org.gnome.power-manager.gschema.xml.in
index 937e89f..8611416 100644
--- a/data/org.gnome.power-manager.gschema.xml.in
+++ b/data/org.gnome.power-manager.gschema.xml.in
@@ -222,10 +222,6 @@
<_summary>If sounds should be used</_summary>
<_description>If sounds should be used when the power is critically low, or inhibit requests have stopped the policy action.</_description>
</key>
- <key name="show-actions" type="b">
- <default>true</default>
- <_summary>If preferences and statistics items should be shown in the context menu</_summary>
- </key>
<key name="icon-policy" enum="org.gnome.power-manager.IconPolicy">
<aliases>
<alias value='always' target='present'/>
diff --git a/po/POTFILES.in b/po/POTFILES.in
index 3e8739f..e0259f8 100644
--- a/po/POTFILES.in
+++ b/po/POTFILES.in
@@ -21,5 +21,4 @@ src/gpm-main.c
src/gpm-manager.c
src/gpm-screensaver.c
src/gpm-statistics.c
-src/gpm-tray-icon.c
src/gpm-upower.c
diff --git a/src/Makefile.am b/src/Makefile.am
index 807757b..820d410 100644
--- a/src/Makefile.am
+++ b/src/Makefile.am
@@ -107,8 +107,6 @@ gnome_power_manager_SOURCES = \
gpm-main.c \
gpm-manager.h \
gpm-manager.c \
- gpm-tray-icon.h \
- gpm-tray-icon.c \
gpm-screensaver.h \
gpm-screensaver.c \
gpm-stock-icons.h \
diff --git a/src/gpm-manager.c b/src/gpm-manager.c
index aa9f5cb..9bb0591 100644
--- a/src/gpm-manager.c
+++ b/src/gpm-manager.c
@@ -52,7 +52,6 @@
#include "gpm-backlight.h"
#include "gpm-kbd-backlight.h"
#include "gpm-stock-icons.h"
-#include "gpm-tray-icon.h"
#include "gpm-engine.h"
#include "gpm-upower.h"
#include "gpm-disks.h"
@@ -96,7 +95,6 @@ struct GpmManagerPrivate
GpmIdle *idle;
GpmControl *control;
GpmScreensaver *screensaver;
- GpmTrayIcon *tray_icon;
GpmEngine *engine;
GpmBacklight *backlight;
GpmKbdBacklight *kbd_backlight;
@@ -109,7 +107,6 @@ struct GpmManagerPrivate
UpClient *client;
gboolean on_battery;
gboolean just_resumed;
- GtkStatusIcon *status_icon;
NotifyNotification *notification_general;
NotifyNotification *notification_warning_low;
NotifyNotification *notification_discharging;
@@ -1357,24 +1354,6 @@ gpm_manager_engine_perhaps_recall_cb (GpmEngine *engine, UpDevice *device, gchar
}
/**
- * gpm_manager_engine_icon_changed_cb:
- */
-static void
-gpm_manager_engine_icon_changed_cb (GpmEngine *engine, GIcon *icon, GpmManager *manager)
-{
- gpm_tray_icon_set_icon (manager->priv->tray_icon, icon);
-}
-
-/**
- * gpm_manager_engine_summary_changed_cb:
- */
-static void
-gpm_manager_engine_summary_changed_cb (GpmEngine *engine, gchar *summary, GpmManager *manager)
-{
- gpm_tray_icon_set_tooltip (manager->priv->tray_icon, summary);
-}
-
-/**
* gpm_manager_engine_low_capacity_cb:
*/
static void
@@ -2340,12 +2319,6 @@ gpm_manager_init (GpmManager *manager)
g_signal_connect (manager->priv->control, "resume",
G_CALLBACK (gpm_manager_control_resume_cb), manager);
- g_debug ("creating new tray icon");
- manager->priv->tray_icon = gpm_tray_icon_new ();
-
- /* keep a reference for the notifications */
- manager->priv->status_icon = gpm_tray_icon_get_status_icon (manager->priv->tray_icon);
-
gpm_manager_sync_policy_sleep (manager);
manager->priv->engine = gpm_engine_new ();
@@ -2353,10 +2326,6 @@ gpm_manager_init (GpmManager *manager)
G_CALLBACK (gpm_manager_engine_perhaps_recall_cb), manager);
g_signal_connect (manager->priv->engine, "low-capacity",
G_CALLBACK (gpm_manager_engine_low_capacity_cb), manager);
- g_signal_connect (manager->priv->engine, "icon-changed",
- G_CALLBACK (gpm_manager_engine_icon_changed_cb), manager);
- g_signal_connect (manager->priv->engine, "summary-changed",
- G_CALLBACK (gpm_manager_engine_summary_changed_cb), manager);
g_signal_connect (manager->priv->engine, "fully-charged",
G_CALLBACK (gpm_manager_engine_fully_charged_cb), manager);
g_signal_connect (manager->priv->engine, "discharging",
@@ -2426,7 +2395,6 @@ gpm_manager_finalize (GObject *object)
g_object_unref (manager->priv->dpms);
g_object_unref (manager->priv->idle);
g_object_unref (manager->priv->engine);
- g_object_unref (manager->priv->tray_icon);
g_object_unref (manager->priv->screensaver);
g_object_unref (manager->priv->control);
g_object_unref (manager->priv->button);
@@ -2434,7 +2402,6 @@ gpm_manager_finalize (GObject *object)
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);
g_dbus_connection_unregister_object (manager->priv->bus_connection, manager->priv->bus_object_id);
g_object_unref (manager->priv->bus_connection);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]