network-manager-applet r1167 - in trunk: . src



Author: dcbw
Date: Mon Feb 16 20:11:19 2009
New Revision: 1167
URL: http://svn.gnome.org/viewvc/network-manager-applet?rev=1167&view=rev

Log:
2009-02-16  Alexander Sack  <asac ubuntu com>

	* src/applet.c
		- (nma_menu_show_cb, nma_menu_deactivate_cb, applet_update_icon):
			use gtk_status_icon_set_tooltip_text() on GTK+ >= 2.15



Modified:
   trunk/ChangeLog
   trunk/src/applet.c

Modified: trunk/src/applet.c
==============================================================================
--- trunk/src/applet.c	(original)
+++ trunk/src/applet.c	Mon Feb 16 20:11:19 2009
@@ -1250,7 +1250,11 @@
 	g_return_if_fail (menu != NULL);
 	g_return_if_fail (applet != NULL);
 
+#if GTK_CHECK_VERSION(2, 15, 0)
+	gtk_status_icon_set_tooltip_text (applet->status_icon, NULL);
+#else
 	gtk_status_icon_set_tooltip (applet->status_icon, NULL);
+#endif
 
 	if (!nm_client_get_manager_running (applet->nm_client)) {
 		nma_menu_add_text_item (menu, _("NetworkManager is not running..."));
@@ -1290,7 +1294,11 @@
 	g_idle_add_full (G_PRIORITY_LOW, (GSourceFunc) nma_menu_clear, applet, NULL);
 
 	/* Re-set the tooltip */
+#if GTK_CHECK_VERSION(2, 15, 0)
+	gtk_status_icon_set_tooltip_text (applet->status_icon, applet->tip);
+#else
 	gtk_status_icon_set_tooltip (applet->status_icon, applet->tip);
+#endif
 }
 
 /*
@@ -2003,7 +2011,11 @@
 		g_string_free (tip, FALSE);
 	}
 
+#if GTK_CHECK_VERSION(2, 15, 0)
+	gtk_status_icon_set_tooltip_text (applet->status_icon, applet->tip);
+#else
 	gtk_status_icon_set_tooltip (applet->status_icon, applet->tip);
+#endif
 
 	return FALSE;
 }



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