diff options
author | Ted Gould <ted@gould.cx> | 2011-01-21 11:56:15 -0600 |
---|---|---|
committer | Ted Gould <ted@gould.cx> | 2011-01-21 11:56:15 -0600 |
commit | 7cddccbdd648ea01f9184bc975bb762b7a032c45 (patch) | |
tree | 38d96fd5174b1573ef3c70805b7663b8f1157dcb /libdbusmenu-gtk | |
parent | aea42d14c645517cc32611ab0e8580223948aad3 (diff) | |
parent | 4bb9903a560f83b1b8a19c7801efab80d677ab46 (diff) | |
download | libdbusmenu-7cddccbdd648ea01f9184bc975bb762b7a032c45.tar.gz libdbusmenu-7cddccbdd648ea01f9184bc975bb762b7a032c45.tar.bz2 libdbusmenu-7cddccbdd648ea01f9184bc975bb762b7a032c45.zip |
Updating to trunk
Diffstat (limited to 'libdbusmenu-gtk')
-rw-r--r-- | libdbusmenu-gtk/Makefile.am | 3 | ||||
-rw-r--r-- | libdbusmenu-gtk/client.c | 2 | ||||
-rw-r--r-- | libdbusmenu-gtk/dbusmenu-gtk.h | 40 |
3 files changed, 45 insertions, 0 deletions
diff --git a/libdbusmenu-gtk/Makefile.am b/libdbusmenu-gtk/Makefile.am index a424d4a..754ed3e 100644 --- a/libdbusmenu-gtk/Makefile.am +++ b/libdbusmenu-gtk/Makefile.am @@ -20,6 +20,7 @@ EXTRA_DIST = \ libdbusmenu_gtkincludedir=$(includedir)/libdbusmenu-0.4/libdbusmenu-gtk$(VER)/ libdbusmenu_gtkinclude_HEADERS = \ + dbusmenu-gtk.h \ client.h \ menu.h \ menuitem.h \ @@ -72,12 +73,14 @@ INTROSPECTION_GIRS = if INTROSPECTION_TEN INTROSPECTION_SCANNER_ARGS = --add-include-path=$(srcdir) \ + --warn-all \ --add-include-path=$(top_builddir)/libdbusmenu-glib \ $(addprefix --c-include=libdbusmenu-gtk/, $(introspection_sources)) \ --symbol-prefix=dbusmenu \ --identifier-prefix=DbusmenuGtk else INTROSPECTION_SCANNER_ARGS = --add-include-path=$(srcdir) \ + --warn-all \ --add-include-path=$(top_builddir)/libdbusmenu-glib \ $(addprefix --c-include=libdbusmenu-gtk/, $(introspection_sources)) endif diff --git a/libdbusmenu-gtk/client.c b/libdbusmenu-gtk/client.c index af7768a..d957f25 100644 --- a/libdbusmenu-gtk/client.c +++ b/libdbusmenu-gtk/client.c @@ -789,6 +789,7 @@ image_property_handle (DbusmenuMenuitem * item, const gchar * property, GVariant gtkimage = NULL; } else if (g_strcmp0(iconname, DBUSMENU_MENUITEM_ICON_NAME_BLANK) == 0) { gtkimage = gtk_image_new(); + g_object_set(G_OBJECT(gtkimage), "use-fallback", TRUE, NULL); } else { /* Look to see if we want to have an icon with the 'ltr' or 'rtl' depending on what we're doing. */ @@ -807,6 +808,7 @@ image_property_handle (DbusmenuMenuitem * item, const gchar * property, GVariant can just convert it to this name. */ if (gtkimage == NULL) { gtkimage = gtk_image_new_from_icon_name(finaliconname, GTK_ICON_SIZE_MENU); + g_object_set(G_OBJECT(gtkimage), "use-fallback", TRUE, NULL); } else { gtk_image_set_from_icon_name(GTK_IMAGE(gtkimage), finaliconname, GTK_ICON_SIZE_MENU); } diff --git a/libdbusmenu-gtk/dbusmenu-gtk.h b/libdbusmenu-gtk/dbusmenu-gtk.h new file mode 100644 index 0000000..de63c61 --- /dev/null +++ b/libdbusmenu-gtk/dbusmenu-gtk.h @@ -0,0 +1,40 @@ +/* +A library to communicate a menu object set accross DBus and +track updates and maintain consistency. + +Copyright 2011 Canonical Ltd. + +Authors: + Ted Gould <ted@canonical.com> + +This program is free software: you can redistribute it and/or modify it +under the terms of either or both of the following licenses: + +1) the GNU Lesser General Public License version 3, as published by the +Free Software Foundation; and/or +2) the GNU Lesser General Public License version 2.1, as published by +the Free Software Foundation. + +This program is distributed in the hope that it will be useful, but +WITHOUT ANY WARRANTY; without even the implied warranties of +MERCHANTABILITY, SATISFACTORY QUALITY or FITNESS FOR A PARTICULAR +PURPOSE. See the applicable version of the GNU Lesser General Public +License for more details. + +You should have received a copy of both the GNU Lesser General Public +License version 3 and version 2.1 along with this program. If not, see +<http://www.gnu.org/licenses/> +*/ + +#ifndef __DBUSMENU_GTK_H__ +#define __DBUSMENU_GTK_H__ + +/* Start with the glib stuff */ +#include <libdbusmenu-glib/dbusmenu-glib.h> + +/* Now get the GTK stuff */ +#include <libdbusmenu-gtk/client.h> +#include <libdbusmenu-gtk/menu.h> +#include <libdbusmenu-gtk/menuitem.h> + +#endif /* __DBUSMENU_GLIB_H__ */ |