[gnac/devel] Code cleanup
- From: Benoît Dupasquier <bdupasqu src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnac/devel] Code cleanup
- Date: Sun, 19 Sep 2010 21:15:16 +0000 (UTC)
commit c6a485ef999dc1c41c0a4cd0f3313021acfbc22b
Author: Benoît Dupasquier <bdupasqu src gnome org>
Date: Sun Sep 19 22:15:10 2010 +0100
Code cleanup
src/gnac-ui.c | 15 ++-------------
1 files changed, 2 insertions(+), 13 deletions(-)
---
diff --git a/src/gnac-ui.c b/src/gnac-ui.c
index b097f3c..25755d4 100644
--- a/src/gnac-ui.c
+++ b/src/gnac-ui.c
@@ -1076,6 +1076,8 @@ gnac_ui_hide_trayicon(void)
GtkWidget *main_window;
gboolean window_displayed;
+ if (!trayicon) return;
+
main_window = gnac_ui_get_widget("main_window");
g_object_get(main_window, "visible", &window_displayed, NULL);
@@ -1085,19 +1087,6 @@ gnac_ui_hide_trayicon(void)
gtk_window_move(GTK_WINDOW(main_window), root_x, root_y);
}
- if (!trayicon)
- {
- trayicon = gtk_status_icon_new_from_icon_name("gnac");
- gtk_status_icon_set_has_tooltip(trayicon, TRUE);
-
- g_signal_connect(G_OBJECT(trayicon), "query-tooltip",
- G_CALLBACK(gnac_ui_query_tooltip_cb), NULL);
- g_signal_connect(G_OBJECT(trayicon), "activate",
- G_CALLBACK(gnac_ui_on_trayicon), NULL);
- g_signal_connect(G_OBJECT(trayicon), "popup-menu",
- G_CALLBACK(gnac_ui_on_trayicon_popup), NULL);
- }
-
gtk_status_icon_set_visible(trayicon, FALSE);
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]