[gnome-panel/wip/user-menu: 8/11] panel: Remove user menu from PanelMenuBar



commit 6cafe316bd2e32b5abf2ba8010e916bb9495dd86
Author: Vincent Untz <vuntz gnome org>
Date:   Thu Mar 31 17:32:24 2011 +0530

    panel: Remove user menu from PanelMenuBar
    
    It's not needed anymore now that we have a specific object for that.

 gnome-panel/panel-menu-bar.c |   17 -----------------
 1 files changed, 0 insertions(+), 17 deletions(-)
---
diff --git a/gnome-panel/panel-menu-bar.c b/gnome-panel/panel-menu-bar.c
index 76be70b..deccdfc 100644
--- a/gnome-panel/panel-menu-bar.c
+++ b/gnome-panel/panel-menu-bar.c
@@ -56,7 +56,6 @@ struct _PanelMenuBarPrivate {
 	GtkWidget   *applications_menu;
 	GtkWidget   *applications_item;
 	GtkWidget   *places_item;
-	GtkWidget   *desktop_item;
 };
 
 /* themeable size - "panel-foobar" -- This is only used for the icon of the
@@ -79,8 +78,6 @@ panel_menu_bar_reinit_tooltip (GtkWidget    *widget,
 		      "has-tooltip", TRUE, NULL);
 	g_object_set (menubar->priv->places_item,
 		      "has-tooltip", TRUE, NULL);
-	g_object_set (menubar->priv->desktop_item,
-		      "has-tooltip", TRUE, NULL);
 
 	return FALSE;
 }
@@ -106,8 +103,6 @@ panel_menu_bar_setup_tooltip (PanelMenuBar *menubar)
 				     _("Browse and run installed applications"));
 	panel_util_set_tooltip_text (menubar->priv->places_item,
 				     _("Access documents, folders and network places"));
-	panel_util_set_tooltip_text (menubar->priv->desktop_item,
-				     _("Change desktop appearance and behavior, get help, or log out"));
 
 	//FIXME: this doesn't handle the right-click case. Sigh.
 	/* Hide tooltip if a menu is activated */
@@ -119,10 +114,6 @@ panel_menu_bar_setup_tooltip (PanelMenuBar *menubar)
 			  "activate",
 			  G_CALLBACK (panel_menu_bar_hide_tooltip_and_focus),
 			  menubar);
-	g_signal_connect (menubar->priv->desktop_item,
-			  "activate",
-			  G_CALLBACK (panel_menu_bar_hide_tooltip_and_focus),
-			  menubar);
 
 	/* Reset tooltip when the menu bar is not used */
 	g_signal_connect (GTK_MENU_SHELL (menubar),
@@ -157,11 +148,6 @@ panel_menu_bar_init (PanelMenuBar *menubar)
 			       menubar->priv->places_item);
 	gtk_widget_show (menubar->priv->places_item);
 
-	menubar->priv->desktop_item = panel_desktop_menu_item_new (FALSE, TRUE);
-	gtk_menu_shell_append (GTK_MENU_SHELL (menubar),
-			       menubar->priv->desktop_item);
-	gtk_widget_show (menubar->priv->desktop_item);
-
 	panel_menu_bar_setup_tooltip (menubar);
 }
 
@@ -184,9 +170,6 @@ panel_menu_bar_parent_set (GtkWidget *widget,
 	if (menubar->priv->places_item)
 		panel_place_menu_item_set_panel (menubar->priv->places_item,
 						 menubar->priv->panel);
-	if (menubar->priv->desktop_item)
-		panel_desktop_menu_item_set_panel (menubar->priv->desktop_item,
-						   menubar->priv->panel);
 }
 
 static void



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]