aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorCharles Kerr <charles.kerr@canonical.com>2012-04-04 13:28:38 -0500
committerCharles Kerr <charles.kerr@canonical.com>2012-04-04 13:28:38 -0500
commit5779b63a5dd049d00a4fd500acecb27b169b6d82 (patch)
tree38f3c264a8f9419edb76000b9675d40a8ad53a85 /src
parent0a10a54cffe3e7f1cbc709461c1a8c32a66d4d70 (diff)
parentd0eae41a0c2f1d70e00eba6961020657fdaaa2a4 (diff)
downloadayatana-indicator-messages-5779b63a5dd049d00a4fd500acecb27b169b6d82.tar.gz
ayatana-indicator-messages-5779b63a5dd049d00a4fd500acecb27b169b6d82.tar.bz2
ayatana-indicator-messages-5779b63a5dd049d00a4fd500acecb27b169b6d82.zip
Merge lp:~larsu/indicator-messages/lp956147 to fix broken thunderbird message indicator icons.
This is a refinement to r254, which set an empty icon so that shortcut labels ("compose new message", "contacts", etc.) are horizontally aligned with the labels of the applications they belong to. Apparently gtk2 sets a "broken" icon onto a GtkImage if gtk_image_set_from_icon_name() is passed an empty string, which caused the behavior seen in bug #956147. Adding an #ifdef is a short-term fix for removing that "broken" icon in gtk2 for 12.04. Xref: http://bazaar.launchpad.net/~indicator-applet-developers/indicator-messages/trunk.0.6/revision/254 Xref: https://code.launchpad.net/~larsu/indicator-messages/lp956147/+merge/100836
Diffstat (limited to 'src')
-rw-r--r--src/messages-service.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/messages-service.c b/src/messages-service.c
index 981c286..98e84c7 100644
--- a/src/messages-service.c
+++ b/src/messages-service.c
@@ -29,6 +29,7 @@ with this program. If not, see <http://www.gnu.org/licenses/>.
#include <libindicator/indicator-service.h>
#include <gio/gio.h>
#include <glib/gi18n.h>
+#include <gtk/gtk.h>
#include <libdbusmenu-glib/client.h>
#include <libdbusmenu-glib/server.h>
@@ -664,7 +665,9 @@ server_shortcut_added (AppMenuItem * appitem, DbusmenuMenuitem * mi, gpointer da
g_debug("Application Shortcut added: %s", mi != NULL ? dbusmenu_menuitem_property_get(mi, DBUSMENU_MENUITEM_PROP_LABEL) : "none");
DbusmenuMenuitem * shell = DBUSMENU_MENUITEM(data);
if (mi != NULL) {
+#if GTK_CHECK_VERSION(3, 0, 0)
dbusmenu_menuitem_property_set (mi, DBUSMENU_MENUITEM_PROP_ICON_NAME, "");
+#endif
dbusmenu_menuitem_child_append(shell, mi);
}
resort_menu(shell);