ayatana-commits team mailing list archive
-
ayatana-commits team
-
Mailing list archive
-
Message #00805
[Merge] lp:~ted/libindicate/ayatanize into lp:libindicate
Ted Gould has proposed merging lp:~ted/libindicate/ayatanize into lp:libindicate with lp:~ted/libindicate/discovery-and-love as a prerequisite.
Requested reviews:
Indicator Applet Developers (indicator-applet-developers)
Changing to the org.ayatana namespace
--
https://code.launchpad.net/~ted/libindicate/ayatanize/+merge/18575
Your team ayatana-commits is subscribed to branch lp:libindicate.
=== modified file '.bzrignore'
--- .bzrignore 2009-10-11 16:09:33 +0000
+++ .bzrignore 2010-02-03 23:01:11 +0000
@@ -154,3 +154,14 @@
libindicate-gtk/Indicate-Gtk-0.2.typelib
libindicate-[0-9].[0-9].[0-9].tar.gz
libindicate-[0-9].[0-9].[0-9].tar.gz.asc
+tests/test-indicator-display
+tests/test-indicator-display-half
+tests/test-interests
+tests/test-interests-multi
+tests/test-max-indicators
+tests/test-max-indicators-repeat
+tests/test-menu
+tests/test-menu-client
+tests/test-menu-server
+tests/test-simple
+tests/test-thousand-indicators
=== modified file 'libindicate-gtk/Makefile.am'
--- libindicate-gtk/Makefile.am 2009-10-11 16:04:14 +0000
+++ libindicate-gtk/Makefile.am 2010-02-03 23:01:11 +0000
@@ -29,6 +29,7 @@
libindicate_gtk_la_CFLAGS = \
-I $(srcdir)/.. \
+ -Wall -Werror \
$(LIBINDICATEGTK_CFLAGS)
libindicate_gtk_la_LIBADD = \
=== modified file 'libindicate-gtk/listener.c'
--- libindicate-gtk/listener.c 2009-09-08 20:59:59 +0000
+++ libindicate-gtk/listener.c 2010-02-03 23:01:11 +0000
@@ -136,7 +136,7 @@
get_property_data->property = g_strdup(property);
get_property_data->type = prop_type;
- org_freedesktop_indicator_get_indicator_property_async (server->proxy , INDICATE_LISTENER_INDICATOR_ID(indicator), property, get_property_cb, get_property_data);
+ org_ayatana_indicate_get_indicator_property_async (server->proxy , INDICATE_LISTENER_INDICATOR_ID(indicator), property, get_property_cb, get_property_data);
return;
}
=== modified file 'libindicate/Makefile.am'
--- libindicate/Makefile.am 2009-10-11 16:04:14 +0000
+++ libindicate/Makefile.am 2010-02-03 23:01:11 +0000
@@ -46,6 +46,7 @@
dbus-indicate-client.h \
dbus-listener-server.h \
dbus-listener-client.h \
+ dbus-shared.h \
indicate-enum-types.c \
server.c \
server-marshal.c \
=== added file 'libindicate/dbus-shared.h'
--- libindicate/dbus-shared.h 1970-01-01 00:00:00 +0000
+++ libindicate/dbus-shared.h 2010-02-03 23:01:11 +0000
@@ -0,0 +1,34 @@
+/*
+Some common interfaces that get used all over.
+
+Copyright 2010 Canonical Ltd.
+
+Authors:
+ Ted Gould <ted@xxxxxxxxxxxxx>
+
+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 INDICATE_DBUS_SHARED
+#define INDICATE_DBUS_SHARED
+
+#define INDICATE_DBUS_IFACE "org.ayatana.indicate"
+#define INDICATE_LISTENER_DBUS_IFACE "org.ayatana.indicate.listener"
+
+#endif /* INDICATE_DBUS_SHARED */
=== modified file 'libindicate/indicate-interface.xml'
--- libindicate/indicate-interface.xml 2010-02-01 01:45:54 +0000
+++ libindicate/indicate-interface.xml 2010-02-03 23:01:11 +0000
@@ -28,7 +28,7 @@
<http://www.gnu.org/licenses/>
-->
<node name="/">
- <interface name="org.freedesktop.indicator">
+ <interface name="org.ayatana.indicate">
<!-- Properties -->
<property name="desktop" type="s" access="read" />
=== modified file 'libindicate/indicate-listener.xml'
--- libindicate/indicate-listener.xml 2010-02-03 23:01:11 +0000
+++ libindicate/indicate-listener.xml 2010-02-03 23:01:11 +0000
@@ -28,7 +28,7 @@
<http://www.gnu.org/licenses/>
-->
<node name="/">
- <interface name="org.freedesktop.indicator.listener">
+ <interface name="org.ayatana.indicate.listener">
<!-- Functions -->
<method name="GetIndicatorServers">
=== modified file 'libindicate/listener.c'
--- libindicate/listener.c 2010-02-03 23:01:11 +0000
+++ libindicate/listener.c 2010-02-03 23:01:11 +0000
@@ -35,6 +35,7 @@
#include "dbus-indicate-client.h"
#include "dbus-listener-client.h"
#include "interests-priv.h"
+#include "dbus-shared.h"
/* Errors */
enum {
@@ -214,17 +215,16 @@
priv->max_indicators = -1;
+ dbus_g_connection_register_g_object(priv->session_bus,
+ "/org/ayatana/indicate/listener",
+ G_OBJECT(listener));
+
/* WARNING */
/* Starting massive asynchronisity */
/* */
dbus_connection_add_filter(dbus_g_connection_get_connection(priv->session_bus), dbus_filter_show_server, listener, NULL);
- dbus_bus_add_match(dbus_g_connection_get_connection(priv->session_bus), "type='signal',interface='org.freedesktop.indicator',member='ServerShow'", NULL);
-
- dbus_g_connection_register_g_object(priv->session_bus,
- "/org/freedesktop/indicator/listener",
-// dbus_bus_get_unique_name(dbus_g_connection_get_connection(priv->session_bus)),
- G_OBJECT(listener));
+ dbus_bus_add_match(dbus_g_connection_get_connection(priv->session_bus), "type='signal',interface='" INDICATE_DBUS_IFACE "',member='ServerShow'", NULL);
g_signal_emit(G_OBJECT(listener), signals[INDICATOR_SERVERS_REPORT], 0, TRUE);
@@ -302,7 +302,7 @@
static DBusHandlerResult
dbus_filter_show_server (DBusConnection * connection, DBusMessage * message, void * user_data)
{
- if (!dbus_message_is_signal(message, "org.freedesktop.indicator", "ServerShow")) {
+ if (!dbus_message_is_signal(message, INDICATE_DBUS_IFACE, "ServerShow")) {
return DBUS_HANDLER_RESULT_NOT_YET_HANDLED;
}
@@ -459,7 +459,7 @@
proxyt->proxy = dbus_g_proxy_new_for_name_owner(todo->bus,
proxyt->name,
todo->path,
- "org.freedesktop.indicator",
+ INDICATE_DBUS_IFACE,
&error);
g_free(todo);
@@ -510,11 +510,11 @@
first couple. */
proxyt->server.max_indicators = priv->max_indicators;
if (proxyt->server.max_indicators != -1) {
- org_freedesktop_indicator_set_max_indicators_async(proxyt->proxy, proxyt->server.max_indicators, set_max_indicators_cb, proxyt->name);
+ org_ayatana_indicate_set_max_indicators_async(proxyt->proxy, proxyt->server.max_indicators, set_max_indicators_cb, proxyt->name);
}
indicate_listener_server_get_type(proxyt->listener, &proxyt->server, get_type_initial_cb, proxyt);
- org_freedesktop_indicator_get_indicator_list_async(proxyt->proxy, proxy_get_indicator_list, proxyt);
+ org_ayatana_indicate_get_indicator_list_async(proxyt->proxy, proxy_get_indicator_list, proxyt);
return TRUE;
}
@@ -790,7 +790,7 @@
get_property_data->property = g_strdup(property);
get_property_data->type = prop_type;
- org_freedesktop_indicator_get_indicator_property_async (server->proxy , INDICATE_LISTENER_INDICATOR_ID(indicator), property, get_property_cb, get_property_data);
+ org_ayatana_indicate_get_indicator_property_async (server->proxy , INDICATE_LISTENER_INDICATOR_ID(indicator), property, get_property_cb, get_property_data);
return;
}
@@ -904,7 +904,7 @@
void
indicate_listener_display (IndicateListener * listener, IndicateListenerServer * server, IndicateListenerIndicator * indicator)
{
- org_freedesktop_indicator_show_indicator_to_user_async (server->proxy, INDICATE_LISTENER_INDICATOR_ID(indicator), listener_display_cb, NULL);
+ org_ayatana_indicate_show_indicator_to_user_async (server->proxy, INDICATE_LISTENER_INDICATOR_ID(indicator), listener_display_cb, NULL);
return;
}
@@ -935,7 +935,7 @@
void
indicate_listener_displayed (IndicateListener * listener, IndicateListenerServer * server, IndicateListenerIndicator * indicator, gboolean displayed)
{
- org_freedesktop_indicator_indicator_displayed_async (server->proxy,
+ org_ayatana_indicate_indicator_displayed_async (server->proxy,
INDICATE_LISTENER_INDICATOR_ID(indicator),
displayed,
listener_displayed_cb,
@@ -1055,7 +1055,7 @@
property_cb,
localdata,
NULL,
- G_TYPE_STRING, "org.freedesktop.indicator",
+ G_TYPE_STRING, INDICATE_DBUS_IFACE,
G_TYPE_STRING, property_name,
G_TYPE_INVALID, G_TYPE_VALUE, G_TYPE_INVALID);
@@ -1137,7 +1137,7 @@
}
if (!server->interests[interest]) {
- org_freedesktop_indicator_show_interest_async (server->proxy, interest_to_string(interest), interest_cb, server);
+ org_ayatana_indicate_show_interest_async (server->proxy, interest_to_string(interest), interest_cb, server);
server->interests[interest] = TRUE;
}
return;
@@ -1147,7 +1147,7 @@
indicate_listener_server_remove_interest (IndicateListener * listener, IndicateListenerServer * server, IndicateInterests interest)
{
if (server->interests[interest]) {
- org_freedesktop_indicator_remove_interest_async (server->proxy, interest_to_string(interest), interest_cb, server);
+ org_ayatana_indicate_remove_interest_async (server->proxy, interest_to_string(interest), interest_cb, server);
server->interests[interest] = FALSE;
}
return;
@@ -1222,7 +1222,7 @@
if (server->max_indicators != max) {
server->max_indicators = max;
- org_freedesktop_indicator_set_max_indicators_async(server->proxy, server->max_indicators, set_max_indicators_cb, server->name);
+ org_ayatana_indicate_set_max_indicators_async(server->proxy, server->max_indicators, set_max_indicators_cb, server->name);
}
return;
=== modified file 'libindicate/server.c'
--- libindicate/server.c 2010-02-03 23:01:11 +0000
+++ libindicate/server.c 2010-02-03 23:01:11 +0000
@@ -33,6 +33,7 @@
#include <dbus/dbus-glib.h>
#include <dbus/dbus-glib-lowlevel.h>
#include <libdbusmenu-glib/server.h>
+#include "dbus-shared.h"
/* Errors */
enum {
@@ -391,7 +392,7 @@
IndicateServerPrivate * priv = INDICATE_SERVER_GET_PRIVATE(server);
- priv->path = g_strdup("/org/freedesktop/indicate");
+ priv->path = g_strdup("/org/ayatana/indicate");
priv->indicators = NULL;
priv->num_hidden = 0;
priv->visible = FALSE;
@@ -412,7 +413,7 @@
priv->connection = dbus_g_bus_get(DBUS_BUS_SESSION, NULL);
dbus_connection_add_filter(dbus_g_connection_get_connection(priv->connection), dbus_filter_new_listener, server, NULL);
- dbus_bus_add_match(dbus_g_connection_get_connection(priv->connection), "type='signal',interface='org.freedesktop.indicator.listener',member='IndicatorServersReport'", NULL);
+ dbus_bus_add_match(dbus_g_connection_get_connection(priv->connection), "type='signal',interface='" INDICATE_LISTENER_DBUS_IFACE "',member='IndicatorServersReport'", NULL);
return;
}
@@ -537,7 +538,7 @@
static DBusHandlerResult
dbus_filter_new_listener (DBusConnection * connection, DBusMessage * message, void * user_data)
{
- if (!dbus_message_is_signal(message, "org.freedesktop.indicator.listener", "IndicatorServersReport")) {
+ if (!dbus_message_is_signal(message, INDICATE_LISTENER_DBUS_IFACE, "IndicatorServersReport")) {
return DBUS_HANDLER_RESULT_NOT_YET_HANDLED;
}
Follow ups