diff options
author | Sebastien Bacher <seb128@ubuntu.com> | 2012-08-24 16:15:40 +0200 |
---|---|---|
committer | Sebastien Bacher <seb128@ubuntu.com> | 2012-08-24 16:15:40 +0200 |
commit | ddf5e5f9018fca86d24f8ab65adaa5ffedd4062f (patch) | |
tree | 3b35cbc606260d5a3aaec9b0e05aedaefa931231 | |
parent | 1e2a94c141361b6b2269cb030a72bee068442942 (diff) | |
parent | 28c6d543fc310d5098edb61d506aa8383a96de6f (diff) | |
download | ayatana-indicator-messages-ddf5e5f9018fca86d24f8ab65adaa5ffedd4062f.tar.gz ayatana-indicator-messages-ddf5e5f9018fca86d24f8ab65adaa5ffedd4062f.tar.bz2 ayatana-indicator-messages-ddf5e5f9018fca86d24f8ab65adaa5ffedd4062f.zip |
Backported fixes from trunk up to r288, some of those are needed for the
-rw-r--r-- | debian/changelog | 2 | ||||
-rw-r--r-- | libmessaging-menu/Makefile.am | 4 | ||||
-rw-r--r-- | libmessaging-menu/messaging-menu.c | 22 |
3 files changed, 15 insertions, 13 deletions
diff --git a/debian/changelog b/debian/changelog index 4e46ba1..341d83e 100644 --- a/debian/changelog +++ b/debian/changelog @@ -12,7 +12,7 @@ indicator-messages (12.10.0-0ubuntu1) UNRELEASED; urgency=low * Updated packaging to dh9, current standards * Drop gtk2 build from the packaging since support for it was dropped in trunk, thanks Lars Uebernickel - * Backported fixes from trunk up to r286, some of those are needed for the + * Backported fixes from trunk up to r288, some of those are needed for the bindings to work -- Sebastien Bacher <seb128@ubuntu.com> Tue, 21 Aug 2012 18:17:34 +0200 diff --git a/libmessaging-menu/Makefile.am b/libmessaging-menu/Makefile.am index d0f941f..ef37700 100644 --- a/libmessaging-menu/Makefile.am +++ b/libmessaging-menu/Makefile.am @@ -41,7 +41,7 @@ pkgconfig_DATA = messaging-menu.pc -include $(INTROSPECTION_MAKEFILE) INTROSPECTION_GIRS = -INTROSPECTION_SCANNER_ARGS = --add-include-path=$(srcdir) +INTROSPECTION_SCANNER_ARGS = --add-include-path=$(srcdir) --warn-all INTROSPECTION_COMPILER_ARGS = --includedir=$(srcdir) if HAVE_INTROSPECTION @@ -51,7 +51,7 @@ MessagingMenu_1_0_gir_NAMESPACE = MessagingMenu MessagingMenu_1_0_gir_INCLUDES = GObject-2.0 Gio-2.0 MessagingMenu_1_0_gir_CFLAGS = $(INCLUDES) $(GIO_CFLAGS) MessagingMenu_1_0_gir_LIBS = libmessaging-menu.la -MessagingMenu_1_0_gir_FILES = $(libmessaging_menu_la_SOURCES) $(libmessaging_menu_la_HEADERS) +MessagingMenu_1_0_gir_FILES = messaging-menu.c messaging-menu.h INTROSPECTION_GIRS += MessagingMenu-1.0.gir girdir = $(datadir)/gir-1.0 diff --git a/libmessaging-menu/messaging-menu.c b/libmessaging-menu/messaging-menu.c index 387412e..b090352 100644 --- a/libmessaging-menu/messaging-menu.c +++ b/libmessaging-menu/messaging-menu.c @@ -327,7 +327,7 @@ messaging_menu_app_init (MessagingMenuApp *app) * The messaging menu will return to marking the application as not running as * soon as the returned #MessagingMenuApp is destroyed. * - * Returns: (transfer-full): a new #MessagingMenuApp + * Returns: (transfer full): a new #MessagingMenuApp */ MessagingMenuApp * messaging_menu_app_new (const gchar *desktop_id) @@ -658,7 +658,6 @@ messaging_menu_app_insert_source_with_time (MessagingMenuApp *app, /** * messaging_menu_app_append_source_with_time: * @app: a #MessagingMenuApp - * @position: the position at which to insert the source * @id: a unique identifier for the source to be added * @icon: (allow-none): the icon associated with the source * @label: a user-visible string best describing the source @@ -714,7 +713,6 @@ messaging_menu_app_insert_source_with_string (MessagingMenuApp *app, /** * messaging_menu_app_append_source_with_string: * @app: a #MessagingMenuApp - * @position: the position at which to insert the source * @id: a unique identifier for the source to be added * @icon: (allow-none): the icon associated with the source * @label: a user-visible string best describing the source @@ -761,14 +759,18 @@ messaging_menu_app_remove_source (MessagingMenuApp *app, n_items = g_menu_model_get_n_items (G_MENU_MODEL (app->menu)); for (i = 0; i < n_items; i++) { - const gchar *action = NULL; + gchar *action; - g_menu_model_get_item_attribute (G_MENU_MODEL (app->menu), i, - "action", "&s", &action); - if (!g_strcmp0 (action, source_id)) + if (g_menu_model_get_item_attribute (G_MENU_MODEL (app->menu), i, + "action", "s", &action)) { - g_menu_remove (app->menu, i); - break; + if (!g_strcmp0 (action, source_id)) + { + g_menu_remove (app->menu, i); + break; + } + + g_free (action); } } @@ -832,7 +834,7 @@ messaging_menu_app_set_source_time (MessagingMenuApp *app, * messaging_menu_app_set_source_string: * @app: a #MessagingMenuApp * @source_id: a source id - * @string: the new string for the source + * @str: the new string for the source * * Updates the string displayed next to @source_id to @str. * |