Back to index

libunity  5.92.0
protocol-scope-interface.c
Go to the documentation of this file.
00001 /* protocol-scope-interface.c generated by valac 0.17.2, the Vala compiler
00002  * generated from protocol-scope-interface.vala, do not modify */
00003 
00004 /*
00005  * Copyright (C) 2011 Canonical, Ltd.
00006  *
00007  * This library is free software; you can redistribute it and/or modify
00008  * it under the terms of the GNU Lesser General Public License
00009  * version 3.0 as published by the Free Software Foundation.
00010  *
00011  * This library is distributed in the hope that it will be useful,
00012  * but WITHOUT ANY WARRANTY; without even the implied warranty of
00013  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00014  * GNU Lesser General Public License version 3.0 for more details.
00015  *
00016  * You should have received a copy of the GNU Lesser General Public
00017  * License along with this library. If not, see
00018  * <http://www.gnu.org/licenses/>.
00019  *
00020  * Authored by Neil Jagdish Patel <neil.patel@canonical.com>
00021  *
00022  */
00023 
00024 #include <glib.h>
00025 #include <glib-object.h>
00026 #include <stdlib.h>
00027 #include <string.h>
00028 #include <gio/gio.h>
00029 
00030 
00031 #define UNITY_PROTOCOL_TYPE_SCOPE_INFO (unity_protocol_scope_info_get_type ())
00032 typedef struct _UnityProtocolScopeInfo UnityProtocolScopeInfo;
00033 #define _g_free0(var) (var = (g_free (var), NULL))
00034 #define _g_variant_unref0(var) ((var == NULL) ? NULL : (var = (g_variant_unref (var), NULL)))
00035 #define _g_hash_table_unref0(var) ((var == NULL) ? NULL : (var = (g_hash_table_unref (var), NULL)))
00036 
00037 #define UNITY_PROTOCOL_TYPE_ACTIVATION_REPLY_RAW (unity_protocol_activation_reply_raw_get_type ())
00038 typedef struct _UnityProtocolActivationReplyRaw UnityProtocolActivationReplyRaw;
00039 
00040 #define UNITY_PROTOCOL_TYPE_SCOPE_SERVICE (unity_protocol_scope_service_get_type ())
00041 #define UNITY_PROTOCOL_SCOPE_SERVICE(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), UNITY_PROTOCOL_TYPE_SCOPE_SERVICE, UnityProtocolScopeService))
00042 #define UNITY_PROTOCOL_IS_SCOPE_SERVICE(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), UNITY_PROTOCOL_TYPE_SCOPE_SERVICE))
00043 #define UNITY_PROTOCOL_SCOPE_SERVICE_GET_INTERFACE(obj) (G_TYPE_INSTANCE_GET_INTERFACE ((obj), UNITY_PROTOCOL_TYPE_SCOPE_SERVICE, UnityProtocolScopeServiceIface))
00044 
00045 typedef struct _UnityProtocolScopeService UnityProtocolScopeService;
00046 typedef struct _UnityProtocolScopeServiceIface UnityProtocolScopeServiceIface;
00047 
00048 #define UNITY_PROTOCOL_TYPE_SCOPE_SERVICE_PROXY (unity_protocol_scope_service_proxy_get_type ())
00049 typedef GDBusProxy UnityProtocolScopeServiceProxy;
00050 typedef GDBusProxyClass UnityProtocolScopeServiceProxyClass;
00051 
00052 struct _UnityProtocolScopeInfo {
00053        gchar* dbus_path;
00054        GVariant* sources;
00055        gboolean search_in_global;
00056        gchar* private_connection_name;
00057        gchar* results_model_name;
00058        gchar* global_results_model_name;
00059        gchar* filters_model_name;
00060        GHashTable* hints;
00061 };
00062 
00063 struct _UnityProtocolActivationReplyRaw {
00064        gchar* uri;
00065        guint handled;
00066        GHashTable* hints;
00067 };
00068 
00069 typedef enum  {
00070        UNITY_PROTOCOL_SCOPE_ERROR_SEARCH_CANCELLED,
00071        UNITY_PROTOCOL_SCOPE_ERROR_UNKNOWN
00072 } UnityProtocolScopeError;
00073 #define UNITY_PROTOCOL_SCOPE_ERROR unity_protocol_scope_error_quark ()
00074 struct _UnityProtocolScopeServiceIface {
00075        GTypeInterface parent_iface;
00076        void (*info_request) (UnityProtocolScopeService* self, GAsyncReadyCallback _callback_, gpointer _user_data_);
00077        void (*info_request_finish) (UnityProtocolScopeService* self, GAsyncResult* _res_, GError** error);
00078        void (*activate) (UnityProtocolScopeService* self, const gchar* uri, guint action_type, GAsyncReadyCallback _callback_, gpointer _user_data_);
00079        void (*activate_finish) (UnityProtocolScopeService* self, GAsyncResult* _res_, UnityProtocolActivationReplyRaw* result, GError** error);
00080        void (*update_preview_property) (UnityProtocolScopeService* self, const gchar* uri, GHashTable* values, GAsyncReadyCallback _callback_, gpointer _user_data_);
00081        GHashTable* (*update_preview_property_finish) (UnityProtocolScopeService* self, GAsyncResult* _res_, GError** error);
00082        void (*search) (UnityProtocolScopeService* self, const gchar* search_string, GHashTable* hints, GAsyncReadyCallback _callback_, gpointer _user_data_);
00083        GHashTable* (*search_finish) (UnityProtocolScopeService* self, GAsyncResult* _res_, GError** error);
00084        void (*global_search) (UnityProtocolScopeService* self, const gchar* search_string, GHashTable* hints, GAsyncReadyCallback _callback_, gpointer _user_data_);
00085        GHashTable* (*global_search_finish) (UnityProtocolScopeService* self, GAsyncResult* _res_, GError** error);
00086        void (*set_view_type) (UnityProtocolScopeService* self, guint view_type, GAsyncReadyCallback _callback_, gpointer _user_data_);
00087        void (*set_view_type_finish) (UnityProtocolScopeService* self, GAsyncResult* _res_, GError** error);
00088        void (*set_active_sources) (UnityProtocolScopeService* self, gchar** sources, int sources_length1, GAsyncReadyCallback _callback_, gpointer _user_data_);
00089        void (*set_active_sources_finish) (UnityProtocolScopeService* self, GAsyncResult* _res_, GError** error);
00090 };
00091 
00092 
00093 
00094 GType unity_protocol_scope_info_get_type (void) G_GNUC_CONST;
00095 UnityProtocolScopeInfo* unity_protocol_scope_info_dup (const UnityProtocolScopeInfo* self);
00096 void unity_protocol_scope_info_free (UnityProtocolScopeInfo* self);
00097 void unity_protocol_scope_info_copy (const UnityProtocolScopeInfo* self, UnityProtocolScopeInfo* dest);
00098 void unity_protocol_scope_info_destroy (UnityProtocolScopeInfo* self);
00099 GType unity_protocol_activation_reply_raw_get_type (void) G_GNUC_CONST;
00100 UnityProtocolActivationReplyRaw* unity_protocol_activation_reply_raw_dup (const UnityProtocolActivationReplyRaw* self);
00101 void unity_protocol_activation_reply_raw_free (UnityProtocolActivationReplyRaw* self);
00102 void unity_protocol_activation_reply_raw_copy (const UnityProtocolActivationReplyRaw* self, UnityProtocolActivationReplyRaw* dest);
00103 void unity_protocol_activation_reply_raw_destroy (UnityProtocolActivationReplyRaw* self);
00104 GQuark unity_protocol_scope_error_quark (void);
00105 GType unity_protocol_scope_service_proxy_get_type (void) G_GNUC_CONST;
00106 guint unity_protocol_scope_service_register_object (void* object, GDBusConnection* connection, const gchar* path, GError** error);
00107 GType unity_protocol_scope_service_get_type (void) G_GNUC_CONST;
00108 void unity_protocol_scope_service_info_request (UnityProtocolScopeService* self, GAsyncReadyCallback _callback_, gpointer _user_data_);
00109 void unity_protocol_scope_service_info_request_finish (UnityProtocolScopeService* self, GAsyncResult* _res_, GError** error);
00110 void unity_protocol_scope_service_activate (UnityProtocolScopeService* self, const gchar* uri, guint action_type, GAsyncReadyCallback _callback_, gpointer _user_data_);
00111 void unity_protocol_scope_service_activate_finish (UnityProtocolScopeService* self, GAsyncResult* _res_, UnityProtocolActivationReplyRaw* result, GError** error);
00112 void unity_protocol_scope_service_update_preview_property (UnityProtocolScopeService* self, const gchar* uri, GHashTable* values, GAsyncReadyCallback _callback_, gpointer _user_data_);
00113 GHashTable* unity_protocol_scope_service_update_preview_property_finish (UnityProtocolScopeService* self, GAsyncResult* _res_, GError** error);
00114 void unity_protocol_scope_service_search (UnityProtocolScopeService* self, const gchar* search_string, GHashTable* hints, GAsyncReadyCallback _callback_, gpointer _user_data_);
00115 GHashTable* unity_protocol_scope_service_search_finish (UnityProtocolScopeService* self, GAsyncResult* _res_, GError** error);
00116 void unity_protocol_scope_service_global_search (UnityProtocolScopeService* self, const gchar* search_string, GHashTable* hints, GAsyncReadyCallback _callback_, gpointer _user_data_);
00117 GHashTable* unity_protocol_scope_service_global_search_finish (UnityProtocolScopeService* self, GAsyncResult* _res_, GError** error);
00118 void unity_protocol_scope_service_set_view_type (UnityProtocolScopeService* self, guint view_type, GAsyncReadyCallback _callback_, gpointer _user_data_);
00119 void unity_protocol_scope_service_set_view_type_finish (UnityProtocolScopeService* self, GAsyncResult* _res_, GError** error);
00120 void unity_protocol_scope_service_set_active_sources (UnityProtocolScopeService* self, gchar** sources, int sources_length1, GAsyncReadyCallback _callback_, gpointer _user_data_);
00121 void unity_protocol_scope_service_set_active_sources_finish (UnityProtocolScopeService* self, GAsyncResult* _res_, GError** error);
00122 static void g_cclosure_user_marshal_VOID__BOXED (GClosure * closure, GValue * return_value, guint n_param_values, const GValue * param_values, gpointer invocation_hint, gpointer marshal_data);
00123 static void unity_protocol_scope_service_proxy_g_signal (GDBusProxy* proxy, const gchar* sender_name, const gchar* signal_name, GVariant* parameters);
00124 static void _dbus_handle_unity_protocol_scope_service_changed (UnityProtocolScopeService* self, GVariant* parameters);
00125 static void _vala_g_async_ready_callback (GObject *source_object, GAsyncResult *res, void *user_data);
00126 static void unity_protocol_scope_service_proxy_info_request_async (UnityProtocolScopeService* self, GAsyncReadyCallback _callback_, gpointer _user_data_);
00127 static void unity_protocol_scope_service_proxy_info_request_finish (UnityProtocolScopeService* self, GAsyncResult* _res_, GError** error);
00128 static void unity_protocol_scope_service_proxy_activate_async (UnityProtocolScopeService* self, const gchar* uri, guint action_type, GAsyncReadyCallback _callback_, gpointer _user_data_);
00129 static void unity_protocol_scope_service_proxy_activate_finish (UnityProtocolScopeService* self, GAsyncResult* _res_, UnityProtocolActivationReplyRaw* result, GError** error);
00130 static void unity_protocol_scope_service_proxy_update_preview_property_async (UnityProtocolScopeService* self, const gchar* uri, GHashTable* values, GAsyncReadyCallback _callback_, gpointer _user_data_);
00131 static GHashTable* unity_protocol_scope_service_proxy_update_preview_property_finish (UnityProtocolScopeService* self, GAsyncResult* _res_, GError** error);
00132 static void unity_protocol_scope_service_proxy_search_async (UnityProtocolScopeService* self, const gchar* search_string, GHashTable* hints, GAsyncReadyCallback _callback_, gpointer _user_data_);
00133 static GHashTable* unity_protocol_scope_service_proxy_search_finish (UnityProtocolScopeService* self, GAsyncResult* _res_, GError** error);
00134 static void unity_protocol_scope_service_proxy_global_search_async (UnityProtocolScopeService* self, const gchar* search_string, GHashTable* hints, GAsyncReadyCallback _callback_, gpointer _user_data_);
00135 static GHashTable* unity_protocol_scope_service_proxy_global_search_finish (UnityProtocolScopeService* self, GAsyncResult* _res_, GError** error);
00136 static void unity_protocol_scope_service_proxy_set_view_type_async (UnityProtocolScopeService* self, guint view_type, GAsyncReadyCallback _callback_, gpointer _user_data_);
00137 static void unity_protocol_scope_service_proxy_set_view_type_finish (UnityProtocolScopeService* self, GAsyncResult* _res_, GError** error);
00138 static void unity_protocol_scope_service_proxy_set_active_sources_async (UnityProtocolScopeService* self, gchar** sources, int sources_length1, GAsyncReadyCallback _callback_, gpointer _user_data_);
00139 static void unity_protocol_scope_service_proxy_set_active_sources_finish (UnityProtocolScopeService* self, GAsyncResult* _res_, GError** error);
00140 static void unity_protocol_scope_service_proxy_unity_protocol_scope_service_interface_init (UnityProtocolScopeServiceIface* iface);
00141 static void _dbus_unity_protocol_scope_service_info_request (UnityProtocolScopeService* self, GVariant* parameters, GDBusMethodInvocation* invocation);
00142 static void _dbus_unity_protocol_scope_service_info_request_ready (GObject * source_object, GAsyncResult * _res_, gpointer _user_data_);
00143 static void _dbus_unity_protocol_scope_service_activate (UnityProtocolScopeService* self, GVariant* parameters, GDBusMethodInvocation* invocation);
00144 static void _dbus_unity_protocol_scope_service_activate_ready (GObject * source_object, GAsyncResult * _res_, gpointer _user_data_);
00145 static void _dbus_unity_protocol_scope_service_update_preview_property (UnityProtocolScopeService* self, GVariant* parameters, GDBusMethodInvocation* invocation);
00146 static void _dbus_unity_protocol_scope_service_update_preview_property_ready (GObject * source_object, GAsyncResult * _res_, gpointer _user_data_);
00147 static void _dbus_unity_protocol_scope_service_search (UnityProtocolScopeService* self, GVariant* parameters, GDBusMethodInvocation* invocation);
00148 static void _dbus_unity_protocol_scope_service_search_ready (GObject * source_object, GAsyncResult * _res_, gpointer _user_data_);
00149 static void _dbus_unity_protocol_scope_service_global_search (UnityProtocolScopeService* self, GVariant* parameters, GDBusMethodInvocation* invocation);
00150 static void _dbus_unity_protocol_scope_service_global_search_ready (GObject * source_object, GAsyncResult * _res_, gpointer _user_data_);
00151 static void _dbus_unity_protocol_scope_service_set_view_type (UnityProtocolScopeService* self, GVariant* parameters, GDBusMethodInvocation* invocation);
00152 static void _dbus_unity_protocol_scope_service_set_view_type_ready (GObject * source_object, GAsyncResult * _res_, gpointer _user_data_);
00153 static void _dbus_unity_protocol_scope_service_set_active_sources (UnityProtocolScopeService* self, GVariant* parameters, GDBusMethodInvocation* invocation);
00154 static void _dbus_unity_protocol_scope_service_set_active_sources_ready (GObject * source_object, GAsyncResult * _res_, gpointer _user_data_);
00155 static void unity_protocol_scope_service_dbus_interface_method_call (GDBusConnection* connection, const gchar* sender, const gchar* object_path, const gchar* interface_name, const gchar* method_name, GVariant* parameters, GDBusMethodInvocation* invocation, gpointer user_data);
00156 static GVariant* unity_protocol_scope_service_dbus_interface_get_property (GDBusConnection* connection, const gchar* sender, const gchar* object_path, const gchar* interface_name, const gchar* property_name, GError** error, gpointer user_data);
00157 static gboolean unity_protocol_scope_service_dbus_interface_set_property (GDBusConnection* connection, const gchar* sender, const gchar* object_path, const gchar* interface_name, const gchar* property_name, GVariant* value, GError** error, gpointer user_data);
00158 static void _dbus_unity_protocol_scope_service_changed (GObject* _sender, UnityProtocolScopeInfo* lens_info, gpointer* _data);
00159 static void _unity_protocol_scope_service_unregister_object (gpointer user_data);
00160 static void _vala_array_destroy (gpointer array, gint array_length, GDestroyNotify destroy_func);
00161 static void _vala_array_free (gpointer array, gint array_length, GDestroyNotify destroy_func);
00162 
00163 static const GDBusErrorEntry unity_protocol_scope_error_entries[] = {{UNITY_PROTOCOL_SCOPE_ERROR_SEARCH_CANCELLED, "com.canonical.Unity.ScopeError.SearchCancelled"}, {UNITY_PROTOCOL_SCOPE_ERROR_UNKNOWN, "com.canonical.Unity.ScopeError.Unknown"}};
00164 static const GDBusArgInfo * const _unity_protocol_scope_service_dbus_arg_info_info_request_in[] = {NULL};
00165 static const GDBusArgInfo * const _unity_protocol_scope_service_dbus_arg_info_info_request_out[] = {NULL};
00166 static const GDBusMethodInfo _unity_protocol_scope_service_dbus_method_info_info_request = {-1, "InfoRequest", (GDBusArgInfo **) (&_unity_protocol_scope_service_dbus_arg_info_info_request_in), (GDBusArgInfo **) (&_unity_protocol_scope_service_dbus_arg_info_info_request_out)};
00167 static const GDBusArgInfo _unity_protocol_scope_service_dbus_arg_info_activate_uri = {-1, "uri", "s"};
00168 static const GDBusArgInfo _unity_protocol_scope_service_dbus_arg_info_activate_action_type = {-1, "action_type", "u"};
00169 static const GDBusArgInfo _unity_protocol_scope_service_dbus_arg_info_activate_result = {-1, "result", "(sua{sv})"};
00170 static const GDBusArgInfo * const _unity_protocol_scope_service_dbus_arg_info_activate_in[] = {&_unity_protocol_scope_service_dbus_arg_info_activate_uri, &_unity_protocol_scope_service_dbus_arg_info_activate_action_type, NULL};
00171 static const GDBusArgInfo * const _unity_protocol_scope_service_dbus_arg_info_activate_out[] = {&_unity_protocol_scope_service_dbus_arg_info_activate_result, NULL};
00172 static const GDBusMethodInfo _unity_protocol_scope_service_dbus_method_info_activate = {-1, "Activate", (GDBusArgInfo **) (&_unity_protocol_scope_service_dbus_arg_info_activate_in), (GDBusArgInfo **) (&_unity_protocol_scope_service_dbus_arg_info_activate_out)};
00173 static const GDBusArgInfo _unity_protocol_scope_service_dbus_arg_info_update_preview_property_uri = {-1, "uri", "s"};
00174 static const GDBusArgInfo _unity_protocol_scope_service_dbus_arg_info_update_preview_property_values = {-1, "values", "a{sv}"};
00175 static const GDBusArgInfo _unity_protocol_scope_service_dbus_arg_info_update_preview_property_result = {-1, "result", "a{sv}"};
00176 static const GDBusArgInfo * const _unity_protocol_scope_service_dbus_arg_info_update_preview_property_in[] = {&_unity_protocol_scope_service_dbus_arg_info_update_preview_property_uri, &_unity_protocol_scope_service_dbus_arg_info_update_preview_property_values, NULL};
00177 static const GDBusArgInfo * const _unity_protocol_scope_service_dbus_arg_info_update_preview_property_out[] = {&_unity_protocol_scope_service_dbus_arg_info_update_preview_property_result, NULL};
00178 static const GDBusMethodInfo _unity_protocol_scope_service_dbus_method_info_update_preview_property = {-1, "UpdatePreviewProperty", (GDBusArgInfo **) (&_unity_protocol_scope_service_dbus_arg_info_update_preview_property_in), (GDBusArgInfo **) (&_unity_protocol_scope_service_dbus_arg_info_update_preview_property_out)};
00179 static const GDBusArgInfo _unity_protocol_scope_service_dbus_arg_info_search_search_string = {-1, "search_string", "s"};
00180 static const GDBusArgInfo _unity_protocol_scope_service_dbus_arg_info_search_hints = {-1, "hints", "a{sv}"};
00181 static const GDBusArgInfo _unity_protocol_scope_service_dbus_arg_info_search_result = {-1, "result", "a{sv}"};
00182 static const GDBusArgInfo * const _unity_protocol_scope_service_dbus_arg_info_search_in[] = {&_unity_protocol_scope_service_dbus_arg_info_search_search_string, &_unity_protocol_scope_service_dbus_arg_info_search_hints, NULL};
00183 static const GDBusArgInfo * const _unity_protocol_scope_service_dbus_arg_info_search_out[] = {&_unity_protocol_scope_service_dbus_arg_info_search_result, NULL};
00184 static const GDBusMethodInfo _unity_protocol_scope_service_dbus_method_info_search = {-1, "Search", (GDBusArgInfo **) (&_unity_protocol_scope_service_dbus_arg_info_search_in), (GDBusArgInfo **) (&_unity_protocol_scope_service_dbus_arg_info_search_out)};
00185 static const GDBusArgInfo _unity_protocol_scope_service_dbus_arg_info_global_search_search_string = {-1, "search_string", "s"};
00186 static const GDBusArgInfo _unity_protocol_scope_service_dbus_arg_info_global_search_hints = {-1, "hints", "a{sv}"};
00187 static const GDBusArgInfo _unity_protocol_scope_service_dbus_arg_info_global_search_result = {-1, "result", "a{sv}"};
00188 static const GDBusArgInfo * const _unity_protocol_scope_service_dbus_arg_info_global_search_in[] = {&_unity_protocol_scope_service_dbus_arg_info_global_search_search_string, &_unity_protocol_scope_service_dbus_arg_info_global_search_hints, NULL};
00189 static const GDBusArgInfo * const _unity_protocol_scope_service_dbus_arg_info_global_search_out[] = {&_unity_protocol_scope_service_dbus_arg_info_global_search_result, NULL};
00190 static const GDBusMethodInfo _unity_protocol_scope_service_dbus_method_info_global_search = {-1, "GlobalSearch", (GDBusArgInfo **) (&_unity_protocol_scope_service_dbus_arg_info_global_search_in), (GDBusArgInfo **) (&_unity_protocol_scope_service_dbus_arg_info_global_search_out)};
00191 static const GDBusArgInfo _unity_protocol_scope_service_dbus_arg_info_set_view_type_view_type = {-1, "view_type", "u"};
00192 static const GDBusArgInfo * const _unity_protocol_scope_service_dbus_arg_info_set_view_type_in[] = {&_unity_protocol_scope_service_dbus_arg_info_set_view_type_view_type, NULL};
00193 static const GDBusArgInfo * const _unity_protocol_scope_service_dbus_arg_info_set_view_type_out[] = {NULL};
00194 static const GDBusMethodInfo _unity_protocol_scope_service_dbus_method_info_set_view_type = {-1, "SetViewType", (GDBusArgInfo **) (&_unity_protocol_scope_service_dbus_arg_info_set_view_type_in), (GDBusArgInfo **) (&_unity_protocol_scope_service_dbus_arg_info_set_view_type_out)};
00195 static const GDBusArgInfo _unity_protocol_scope_service_dbus_arg_info_set_active_sources_sources = {-1, "sources", "as"};
00196 static const GDBusArgInfo * const _unity_protocol_scope_service_dbus_arg_info_set_active_sources_in[] = {&_unity_protocol_scope_service_dbus_arg_info_set_active_sources_sources, NULL};
00197 static const GDBusArgInfo * const _unity_protocol_scope_service_dbus_arg_info_set_active_sources_out[] = {NULL};
00198 static const GDBusMethodInfo _unity_protocol_scope_service_dbus_method_info_set_active_sources = {-1, "SetActiveSources", (GDBusArgInfo **) (&_unity_protocol_scope_service_dbus_arg_info_set_active_sources_in), (GDBusArgInfo **) (&_unity_protocol_scope_service_dbus_arg_info_set_active_sources_out)};
00199 static const GDBusMethodInfo * const _unity_protocol_scope_service_dbus_method_info[] = {&_unity_protocol_scope_service_dbus_method_info_info_request, &_unity_protocol_scope_service_dbus_method_info_activate, &_unity_protocol_scope_service_dbus_method_info_update_preview_property, &_unity_protocol_scope_service_dbus_method_info_search, &_unity_protocol_scope_service_dbus_method_info_global_search, &_unity_protocol_scope_service_dbus_method_info_set_view_type, &_unity_protocol_scope_service_dbus_method_info_set_active_sources, NULL};
00200 static const GDBusArgInfo _unity_protocol_scope_service_dbus_arg_info_changed_lens_info = {-1, "lens_info", "(svbssssa{sv})"};
00201 static const GDBusArgInfo * const _unity_protocol_scope_service_dbus_arg_info_changed[] = {&_unity_protocol_scope_service_dbus_arg_info_changed_lens_info, NULL};
00202 static const GDBusSignalInfo _unity_protocol_scope_service_dbus_signal_info_changed = {-1, "Changed", (GDBusArgInfo **) (&_unity_protocol_scope_service_dbus_arg_info_changed)};
00203 static const GDBusSignalInfo * const _unity_protocol_scope_service_dbus_signal_info[] = {&_unity_protocol_scope_service_dbus_signal_info_changed, NULL};
00204 static const GDBusPropertyInfo * const _unity_protocol_scope_service_dbus_property_info[] = {NULL};
00205 static const GDBusInterfaceInfo _unity_protocol_scope_service_dbus_interface_info = {-1, "com.canonical.Unity.Scope", (GDBusMethodInfo **) (&_unity_protocol_scope_service_dbus_method_info), (GDBusSignalInfo **) (&_unity_protocol_scope_service_dbus_signal_info), (GDBusPropertyInfo **) (&_unity_protocol_scope_service_dbus_property_info)};
00206 static const GDBusInterfaceVTable _unity_protocol_scope_service_dbus_interface_vtable = {unity_protocol_scope_service_dbus_interface_method_call, unity_protocol_scope_service_dbus_interface_get_property, unity_protocol_scope_service_dbus_interface_set_property};
00207 
00208 static gpointer _g_variant_ref0 (gpointer self) {
00209        return self ? g_variant_ref (self) : NULL;
00210 }
00211 
00212 
00213 static gpointer _g_hash_table_ref0 (gpointer self) {
00214        return self ? g_hash_table_ref (self) : NULL;
00215 }
00216 
00217 
00218 void unity_protocol_scope_info_copy (const UnityProtocolScopeInfo* self, UnityProtocolScopeInfo* dest) {
00219        const gchar* _tmp0_;
00220        gchar* _tmp1_;
00221        GVariant* _tmp2_;
00222        GVariant* _tmp3_;
00223        gboolean _tmp4_;
00224        const gchar* _tmp5_;
00225        gchar* _tmp6_;
00226        const gchar* _tmp7_;
00227        gchar* _tmp8_;
00228        const gchar* _tmp9_;
00229        gchar* _tmp10_;
00230        const gchar* _tmp11_;
00231        gchar* _tmp12_;
00232        GHashTable* _tmp13_;
00233        GHashTable* _tmp14_;
00234        _tmp0_ = (*self).dbus_path;
00235        _tmp1_ = g_strdup (_tmp0_);
00236        _g_free0 ((*dest).dbus_path);
00237        (*dest).dbus_path = _tmp1_;
00238        _tmp2_ = (*self).sources;
00239        _tmp3_ = _g_variant_ref0 (_tmp2_);
00240        _g_variant_unref0 ((*dest).sources);
00241        (*dest).sources = _tmp3_;
00242        _tmp4_ = (*self).search_in_global;
00243        (*dest).search_in_global = _tmp4_;
00244        _tmp5_ = (*self).private_connection_name;
00245        _tmp6_ = g_strdup (_tmp5_);
00246        _g_free0 ((*dest).private_connection_name);
00247        (*dest).private_connection_name = _tmp6_;
00248        _tmp7_ = (*self).results_model_name;
00249        _tmp8_ = g_strdup (_tmp7_);
00250        _g_free0 ((*dest).results_model_name);
00251        (*dest).results_model_name = _tmp8_;
00252        _tmp9_ = (*self).global_results_model_name;
00253        _tmp10_ = g_strdup (_tmp9_);
00254        _g_free0 ((*dest).global_results_model_name);
00255        (*dest).global_results_model_name = _tmp10_;
00256        _tmp11_ = (*self).filters_model_name;
00257        _tmp12_ = g_strdup (_tmp11_);
00258        _g_free0 ((*dest).filters_model_name);
00259        (*dest).filters_model_name = _tmp12_;
00260        _tmp13_ = (*self).hints;
00261        _tmp14_ = _g_hash_table_ref0 (_tmp13_);
00262        _g_hash_table_unref0 ((*dest).hints);
00263        (*dest).hints = _tmp14_;
00264 }
00265 
00266 
00267 void unity_protocol_scope_info_destroy (UnityProtocolScopeInfo* self) {
00268        _g_free0 ((*self).dbus_path);
00269        _g_variant_unref0 ((*self).sources);
00270        _g_free0 ((*self).private_connection_name);
00271        _g_free0 ((*self).results_model_name);
00272        _g_free0 ((*self).global_results_model_name);
00273        _g_free0 ((*self).filters_model_name);
00274        _g_hash_table_unref0 ((*self).hints);
00275 }
00276 
00277 
00278 UnityProtocolScopeInfo* unity_protocol_scope_info_dup (const UnityProtocolScopeInfo* self) {
00279        UnityProtocolScopeInfo* dup;
00280        dup = g_new0 (UnityProtocolScopeInfo, 1);
00281        unity_protocol_scope_info_copy (self, dup);
00282        return dup;
00283 }
00284 
00285 
00286 void unity_protocol_scope_info_free (UnityProtocolScopeInfo* self) {
00287        unity_protocol_scope_info_destroy (self);
00288        g_free (self);
00289 }
00290 
00291 
00292 GType unity_protocol_scope_info_get_type (void) {
00293        static volatile gsize unity_protocol_scope_info_type_id__volatile = 0;
00294        if (g_once_init_enter (&unity_protocol_scope_info_type_id__volatile)) {
00295               GType unity_protocol_scope_info_type_id;
00296               unity_protocol_scope_info_type_id = g_boxed_type_register_static ("UnityProtocolScopeInfo", (GBoxedCopyFunc) unity_protocol_scope_info_dup, (GBoxedFreeFunc) unity_protocol_scope_info_free);
00297               g_once_init_leave (&unity_protocol_scope_info_type_id__volatile, unity_protocol_scope_info_type_id);
00298        }
00299        return unity_protocol_scope_info_type_id__volatile;
00300 }
00301 
00302 
00303 void unity_protocol_activation_reply_raw_copy (const UnityProtocolActivationReplyRaw* self, UnityProtocolActivationReplyRaw* dest) {
00304        const gchar* _tmp0_;
00305        gchar* _tmp1_;
00306        guint _tmp2_;
00307        GHashTable* _tmp3_;
00308        GHashTable* _tmp4_;
00309        _tmp0_ = (*self).uri;
00310        _tmp1_ = g_strdup (_tmp0_);
00311        _g_free0 ((*dest).uri);
00312        (*dest).uri = _tmp1_;
00313        _tmp2_ = (*self).handled;
00314        (*dest).handled = _tmp2_;
00315        _tmp3_ = (*self).hints;
00316        _tmp4_ = _g_hash_table_ref0 (_tmp3_);
00317        _g_hash_table_unref0 ((*dest).hints);
00318        (*dest).hints = _tmp4_;
00319 }
00320 
00321 
00322 void unity_protocol_activation_reply_raw_destroy (UnityProtocolActivationReplyRaw* self) {
00323        _g_free0 ((*self).uri);
00324        _g_hash_table_unref0 ((*self).hints);
00325 }
00326 
00327 
00328 UnityProtocolActivationReplyRaw* unity_protocol_activation_reply_raw_dup (const UnityProtocolActivationReplyRaw* self) {
00329        UnityProtocolActivationReplyRaw* dup;
00330        dup = g_new0 (UnityProtocolActivationReplyRaw, 1);
00331        unity_protocol_activation_reply_raw_copy (self, dup);
00332        return dup;
00333 }
00334 
00335 
00336 void unity_protocol_activation_reply_raw_free (UnityProtocolActivationReplyRaw* self) {
00337        unity_protocol_activation_reply_raw_destroy (self);
00338        g_free (self);
00339 }
00340 
00341 
00342 GType unity_protocol_activation_reply_raw_get_type (void) {
00343        static volatile gsize unity_protocol_activation_reply_raw_type_id__volatile = 0;
00344        if (g_once_init_enter (&unity_protocol_activation_reply_raw_type_id__volatile)) {
00345               GType unity_protocol_activation_reply_raw_type_id;
00346               unity_protocol_activation_reply_raw_type_id = g_boxed_type_register_static ("UnityProtocolActivationReplyRaw", (GBoxedCopyFunc) unity_protocol_activation_reply_raw_dup, (GBoxedFreeFunc) unity_protocol_activation_reply_raw_free);
00347               g_once_init_leave (&unity_protocol_activation_reply_raw_type_id__volatile, unity_protocol_activation_reply_raw_type_id);
00348        }
00349        return unity_protocol_activation_reply_raw_type_id__volatile;
00350 }
00351 
00352 
00353 GQuark unity_protocol_scope_error_quark (void) {
00354        static volatile gsize unity_protocol_scope_error_quark_volatile = 0;
00355        g_dbus_error_register_error_domain ("unity_protocol_scope_error-quark", &unity_protocol_scope_error_quark_volatile, unity_protocol_scope_error_entries, G_N_ELEMENTS (unity_protocol_scope_error_entries));
00356        return (GQuark) unity_protocol_scope_error_quark_volatile;
00357 }
00358 
00359 
00360 void unity_protocol_scope_service_info_request (UnityProtocolScopeService* self, GAsyncReadyCallback _callback_, gpointer _user_data_) {
00361        UNITY_PROTOCOL_SCOPE_SERVICE_GET_INTERFACE (self)->info_request (self, _callback_, _user_data_);
00362 }
00363 
00364 
00365 void unity_protocol_scope_service_info_request_finish (UnityProtocolScopeService* self, GAsyncResult* _res_, GError** error) {
00366        UNITY_PROTOCOL_SCOPE_SERVICE_GET_INTERFACE (self)->info_request_finish (self, _res_, error);
00367 }
00368 
00369 
00370 void unity_protocol_scope_service_activate (UnityProtocolScopeService* self, const gchar* uri, guint action_type, GAsyncReadyCallback _callback_, gpointer _user_data_) {
00371        UNITY_PROTOCOL_SCOPE_SERVICE_GET_INTERFACE (self)->activate (self, uri, action_type, _callback_, _user_data_);
00372 }
00373 
00374 
00375 void unity_protocol_scope_service_activate_finish (UnityProtocolScopeService* self, GAsyncResult* _res_, UnityProtocolActivationReplyRaw* result, GError** error) {
00376        UNITY_PROTOCOL_SCOPE_SERVICE_GET_INTERFACE (self)->activate_finish (self, _res_, result, error);
00377 }
00378 
00379 
00380 void unity_protocol_scope_service_update_preview_property (UnityProtocolScopeService* self, const gchar* uri, GHashTable* values, GAsyncReadyCallback _callback_, gpointer _user_data_) {
00381        UNITY_PROTOCOL_SCOPE_SERVICE_GET_INTERFACE (self)->update_preview_property (self, uri, values, _callback_, _user_data_);
00382 }
00383 
00384 
00385 GHashTable* unity_protocol_scope_service_update_preview_property_finish (UnityProtocolScopeService* self, GAsyncResult* _res_, GError** error) {
00386        return UNITY_PROTOCOL_SCOPE_SERVICE_GET_INTERFACE (self)->update_preview_property_finish (self, _res_, error);
00387 }
00388 
00389 
00390 void unity_protocol_scope_service_search (UnityProtocolScopeService* self, const gchar* search_string, GHashTable* hints, GAsyncReadyCallback _callback_, gpointer _user_data_) {
00391        UNITY_PROTOCOL_SCOPE_SERVICE_GET_INTERFACE (self)->search (self, search_string, hints, _callback_, _user_data_);
00392 }
00393 
00394 
00395 GHashTable* unity_protocol_scope_service_search_finish (UnityProtocolScopeService* self, GAsyncResult* _res_, GError** error) {
00396        return UNITY_PROTOCOL_SCOPE_SERVICE_GET_INTERFACE (self)->search_finish (self, _res_, error);
00397 }
00398 
00399 
00400 void unity_protocol_scope_service_global_search (UnityProtocolScopeService* self, const gchar* search_string, GHashTable* hints, GAsyncReadyCallback _callback_, gpointer _user_data_) {
00401        UNITY_PROTOCOL_SCOPE_SERVICE_GET_INTERFACE (self)->global_search (self, search_string, hints, _callback_, _user_data_);
00402 }
00403 
00404 
00405 GHashTable* unity_protocol_scope_service_global_search_finish (UnityProtocolScopeService* self, GAsyncResult* _res_, GError** error) {
00406        return UNITY_PROTOCOL_SCOPE_SERVICE_GET_INTERFACE (self)->global_search_finish (self, _res_, error);
00407 }
00408 
00409 
00410 void unity_protocol_scope_service_set_view_type (UnityProtocolScopeService* self, guint view_type, GAsyncReadyCallback _callback_, gpointer _user_data_) {
00411        UNITY_PROTOCOL_SCOPE_SERVICE_GET_INTERFACE (self)->set_view_type (self, view_type, _callback_, _user_data_);
00412 }
00413 
00414 
00415 void unity_protocol_scope_service_set_view_type_finish (UnityProtocolScopeService* self, GAsyncResult* _res_, GError** error) {
00416        UNITY_PROTOCOL_SCOPE_SERVICE_GET_INTERFACE (self)->set_view_type_finish (self, _res_, error);
00417 }
00418 
00419 
00420 void unity_protocol_scope_service_set_active_sources (UnityProtocolScopeService* self, gchar** sources, int sources_length1, GAsyncReadyCallback _callback_, gpointer _user_data_) {
00421        UNITY_PROTOCOL_SCOPE_SERVICE_GET_INTERFACE (self)->set_active_sources (self, sources, sources_length1, _callback_, _user_data_);
00422 }
00423 
00424 
00425 void unity_protocol_scope_service_set_active_sources_finish (UnityProtocolScopeService* self, GAsyncResult* _res_, GError** error) {
00426        UNITY_PROTOCOL_SCOPE_SERVICE_GET_INTERFACE (self)->set_active_sources_finish (self, _res_, error);
00427 }
00428 
00429 
00430 static void g_cclosure_user_marshal_VOID__BOXED (GClosure * closure, GValue * return_value, guint n_param_values, const GValue * param_values, gpointer invocation_hint, gpointer marshal_data) {
00431        typedef void (*GMarshalFunc_VOID__BOXED) (gpointer data1, gpointer arg_1, gpointer data2);
00432        register GMarshalFunc_VOID__BOXED callback;
00433        register GCClosure * cc;
00434        register gpointer data1;
00435        register gpointer data2;
00436        cc = (GCClosure *) closure;
00437        g_return_if_fail (n_param_values == 2);
00438        if (G_CCLOSURE_SWAP_DATA (closure)) {
00439               data1 = closure->data;
00440               data2 = param_values->data[0].v_pointer;
00441        } else {
00442               data1 = param_values->data[0].v_pointer;
00443               data2 = closure->data;
00444        }
00445        callback = (GMarshalFunc_VOID__BOXED) (marshal_data ? marshal_data : cc->callback);
00446        callback (data1, g_value_get_boxed (param_values + 1), data2);
00447 }
00448 
00449 
00450 static void unity_protocol_scope_service_base_init (UnityProtocolScopeServiceIface * iface) {
00451        static gboolean initialized = FALSE;
00452        if (!initialized) {
00453               initialized = TRUE;
00454               g_signal_new ("changed", UNITY_PROTOCOL_TYPE_SCOPE_SERVICE, G_SIGNAL_RUN_LAST, 0, NULL, NULL, g_cclosure_user_marshal_VOID__BOXED, G_TYPE_NONE, 1, UNITY_PROTOCOL_TYPE_SCOPE_INFO);
00455        }
00456 }
00457 
00458 
00464 GType unity_protocol_scope_service_get_type (void) {
00465        static volatile gsize unity_protocol_scope_service_type_id__volatile = 0;
00466        if (g_once_init_enter (&unity_protocol_scope_service_type_id__volatile)) {
00467               static const GTypeInfo g_define_type_info = { sizeof (UnityProtocolScopeServiceIface), (GBaseInitFunc) unity_protocol_scope_service_base_init, (GBaseFinalizeFunc) NULL, (GClassInitFunc) NULL, (GClassFinalizeFunc) NULL, NULL, 0, 0, (GInstanceInitFunc) NULL, NULL };
00468               GType unity_protocol_scope_service_type_id;
00469               unity_protocol_scope_service_type_id = g_type_register_static (G_TYPE_INTERFACE, "UnityProtocolScopeService", &g_define_type_info, 0);
00470               g_type_interface_add_prerequisite (unity_protocol_scope_service_type_id, G_TYPE_OBJECT);
00471               g_type_set_qdata (unity_protocol_scope_service_type_id, g_quark_from_static_string ("vala-dbus-proxy-type"), (void*) unity_protocol_scope_service_proxy_get_type);
00472               g_type_set_qdata (unity_protocol_scope_service_type_id, g_quark_from_static_string ("vala-dbus-interface-name"), "com.canonical.Unity.Scope");
00473               g_type_set_qdata (unity_protocol_scope_service_type_id, g_quark_from_static_string ("vala-dbus-register-object"), (void*) unity_protocol_scope_service_register_object);
00474               g_once_init_leave (&unity_protocol_scope_service_type_id__volatile, unity_protocol_scope_service_type_id);
00475        }
00476        return unity_protocol_scope_service_type_id__volatile;
00477 }
00478 
00479 
00480 G_DEFINE_TYPE_EXTENDED (UnityProtocolScopeServiceProxy, unity_protocol_scope_service_proxy, G_TYPE_DBUS_PROXY, 0, G_IMPLEMENT_INTERFACE (UNITY_PROTOCOL_TYPE_SCOPE_SERVICE, unity_protocol_scope_service_proxy_unity_protocol_scope_service_interface_init) )
00481 static void unity_protocol_scope_service_proxy_class_init (UnityProtocolScopeServiceProxyClass* klass) {
00482        G_DBUS_PROXY_CLASS (klass)->g_signal = unity_protocol_scope_service_proxy_g_signal;
00483 }
00484 
00485 
00486 static void _dbus_handle_unity_protocol_scope_service_changed (UnityProtocolScopeService* self, GVariant* parameters) {
00487        GVariantIter _arguments_iter;
00488        UnityProtocolScopeInfo lens_info = {0};
00489        GVariant* _tmp107_;
00490        UnityProtocolScopeInfo _tmp108_;
00491        GVariantIter _tmp109_;
00492        GVariant* _tmp110_;
00493        GVariant* _tmp111_;
00494        GVariant* _tmp112_;
00495        GVariant* _tmp113_;
00496        GVariant* _tmp114_;
00497        GVariant* _tmp115_;
00498        GVariant* _tmp116_;
00499        GVariant* _tmp117_;
00500        GHashTable* _tmp118_;
00501        GVariantIter _tmp119_;
00502        GVariant* _tmp120_;
00503        GVariant* _tmp121_;
00504        g_variant_iter_init (&_arguments_iter, parameters);
00505        _tmp107_ = g_variant_iter_next_value (&_arguments_iter);
00506        g_variant_iter_init (&_tmp109_, _tmp107_);
00507        _tmp110_ = g_variant_iter_next_value (&_tmp109_);
00508        _tmp108_.dbus_path = g_variant_dup_string (_tmp110_, NULL);
00509        g_variant_unref (_tmp110_);
00510        _tmp111_ = g_variant_iter_next_value (&_tmp109_);
00511        _tmp108_.sources = g_variant_get_variant (_tmp111_);
00512        g_variant_unref (_tmp111_);
00513        _tmp112_ = g_variant_iter_next_value (&_tmp109_);
00514        _tmp108_.search_in_global = g_variant_get_boolean (_tmp112_);
00515        g_variant_unref (_tmp112_);
00516        _tmp113_ = g_variant_iter_next_value (&_tmp109_);
00517        _tmp108_.private_connection_name = g_variant_dup_string (_tmp113_, NULL);
00518        g_variant_unref (_tmp113_);
00519        _tmp114_ = g_variant_iter_next_value (&_tmp109_);
00520        _tmp108_.results_model_name = g_variant_dup_string (_tmp114_, NULL);
00521        g_variant_unref (_tmp114_);
00522        _tmp115_ = g_variant_iter_next_value (&_tmp109_);
00523        _tmp108_.global_results_model_name = g_variant_dup_string (_tmp115_, NULL);
00524        g_variant_unref (_tmp115_);
00525        _tmp116_ = g_variant_iter_next_value (&_tmp109_);
00526        _tmp108_.filters_model_name = g_variant_dup_string (_tmp116_, NULL);
00527        g_variant_unref (_tmp116_);
00528        _tmp117_ = g_variant_iter_next_value (&_tmp109_);
00529        _tmp118_ = g_hash_table_new_full (g_str_hash, g_str_equal, g_free, NULL);
00530        g_variant_iter_init (&_tmp119_, _tmp117_);
00531        while (g_variant_iter_loop (&_tmp119_, "{?*}", &_tmp120_, &_tmp121_)) {
00532               g_hash_table_insert (_tmp118_, g_variant_dup_string (_tmp120_, NULL), g_variant_get_variant (_tmp121_));
00533        }
00534        _tmp108_.hints = _tmp118_;
00535        g_variant_unref (_tmp117_);
00536        lens_info = _tmp108_;
00537        g_variant_unref (_tmp107_);
00538        g_signal_emit_by_name (self, "changed", &lens_info);
00539        unity_protocol_scope_info_destroy (&lens_info);
00540 }
00541 
00542 
00543 static void unity_protocol_scope_service_proxy_g_signal (GDBusProxy* proxy, const gchar* sender_name, const gchar* signal_name, GVariant* parameters) {
00544        if (strcmp (signal_name, "Changed") == 0) {
00545               _dbus_handle_unity_protocol_scope_service_changed ((UnityProtocolScopeService*) proxy, parameters);
00546        }
00547 }
00548 
00549 
00550 static void unity_protocol_scope_service_proxy_init (UnityProtocolScopeServiceProxy* self) {
00551 }
00552 
00553 
00554 static void _vala_g_async_ready_callback (GObject *source_object, GAsyncResult *res, void *user_data) {
00555        g_simple_async_result_set_op_res_gpointer (user_data, g_object_ref (res), g_object_unref);
00556        g_simple_async_result_complete (user_data);
00557        g_object_unref (user_data);
00558 }
00559 
00560 
00561 static void unity_protocol_scope_service_proxy_info_request_async (UnityProtocolScopeService* self, GAsyncReadyCallback _callback_, gpointer _user_data_) {
00562        GDBusMessage *_message;
00563        GVariant *_arguments;
00564        GVariantBuilder _arguments_builder;
00565        G_IO_ERROR;
00566        _message = g_dbus_message_new_method_call (g_dbus_proxy_get_name ((GDBusProxy *) self), g_dbus_proxy_get_object_path ((GDBusProxy *) self), "com.canonical.Unity.Scope", "InfoRequest");
00567        g_variant_builder_init (&_arguments_builder, G_VARIANT_TYPE_TUPLE);
00568        _arguments = g_variant_builder_end (&_arguments_builder);
00569        g_dbus_message_set_body (_message, _arguments);
00570        g_dbus_connection_send_message_with_reply (g_dbus_proxy_get_connection ((GDBusProxy *) self), _message, G_DBUS_SEND_MESSAGE_FLAGS_NONE, g_dbus_proxy_get_default_timeout ((GDBusProxy *) self), NULL, NULL, _vala_g_async_ready_callback, g_simple_async_result_new ((GObject *) self, _callback_, _user_data_, NULL));
00571        g_object_unref (_message);
00572 }
00573 
00574 
00575 static void unity_protocol_scope_service_proxy_info_request_finish (UnityProtocolScopeService* self, GAsyncResult* _res_, GError** error) {
00576        GDBusMessage *_reply_message;
00577        _reply_message = g_dbus_connection_send_message_with_reply_finish (g_dbus_proxy_get_connection ((GDBusProxy *) self), g_simple_async_result_get_op_res_gpointer ((GSimpleAsyncResult *) _res_), error);
00578        if (!_reply_message) {
00579               return;
00580        }
00581        if (g_dbus_message_to_gerror (_reply_message, error)) {
00582               g_object_unref (_reply_message);
00583               return;
00584        }
00585        g_object_unref (_reply_message);
00586 }
00587 
00588 
00589 static void unity_protocol_scope_service_proxy_activate_async (UnityProtocolScopeService* self, const gchar* uri, guint action_type, GAsyncReadyCallback _callback_, gpointer _user_data_) {
00590        GDBusMessage *_message;
00591        GVariant *_arguments;
00592        GVariantBuilder _arguments_builder;
00593        G_IO_ERROR;
00594        _message = g_dbus_message_new_method_call (g_dbus_proxy_get_name ((GDBusProxy *) self), g_dbus_proxy_get_object_path ((GDBusProxy *) self), "com.canonical.Unity.Scope", "Activate");
00595        g_variant_builder_init (&_arguments_builder, G_VARIANT_TYPE_TUPLE);
00596        g_variant_builder_add_value (&_arguments_builder, g_variant_new_string (uri));
00597        g_variant_builder_add_value (&_arguments_builder, g_variant_new_uint32 (action_type));
00598        _arguments = g_variant_builder_end (&_arguments_builder);
00599        g_dbus_message_set_body (_message, _arguments);
00600        g_dbus_connection_send_message_with_reply (g_dbus_proxy_get_connection ((GDBusProxy *) self), _message, G_DBUS_SEND_MESSAGE_FLAGS_NONE, g_dbus_proxy_get_default_timeout ((GDBusProxy *) self), NULL, NULL, _vala_g_async_ready_callback, g_simple_async_result_new ((GObject *) self, _callback_, _user_data_, NULL));
00601        g_object_unref (_message);
00602 }
00603 
00604 
00605 static void unity_protocol_scope_service_proxy_activate_finish (UnityProtocolScopeService* self, GAsyncResult* _res_, UnityProtocolActivationReplyRaw* result, GError** error) {
00606        GDBusMessage *_reply_message;
00607        GVariant *_reply;
00608        GVariantIter _reply_iter;
00609        GVariant* _tmp122_;
00610        UnityProtocolActivationReplyRaw _tmp123_;
00611        GVariantIter _tmp124_;
00612        GVariant* _tmp125_;
00613        GVariant* _tmp126_;
00614        GVariant* _tmp127_;
00615        GHashTable* _tmp128_;
00616        GVariantIter _tmp129_;
00617        GVariant* _tmp130_;
00618        GVariant* _tmp131_;
00619        _reply_message = g_dbus_connection_send_message_with_reply_finish (g_dbus_proxy_get_connection ((GDBusProxy *) self), g_simple_async_result_get_op_res_gpointer ((GSimpleAsyncResult *) _res_), error);
00620        if (!_reply_message) {
00621               return;
00622        }
00623        if (g_dbus_message_to_gerror (_reply_message, error)) {
00624               g_object_unref (_reply_message);
00625               return;
00626        }
00627        _reply = g_dbus_message_get_body (_reply_message);
00628        g_variant_iter_init (&_reply_iter, _reply);
00629        _tmp122_ = g_variant_iter_next_value (&_reply_iter);
00630        g_variant_iter_init (&_tmp124_, _tmp122_);
00631        _tmp125_ = g_variant_iter_next_value (&_tmp124_);
00632        _tmp123_.uri = g_variant_dup_string (_tmp125_, NULL);
00633        g_variant_unref (_tmp125_);
00634        _tmp126_ = g_variant_iter_next_value (&_tmp124_);
00635        _tmp123_.handled = g_variant_get_uint32 (_tmp126_);
00636        g_variant_unref (_tmp126_);
00637        _tmp127_ = g_variant_iter_next_value (&_tmp124_);
00638        _tmp128_ = g_hash_table_new_full (g_str_hash, g_str_equal, g_free, NULL);
00639        g_variant_iter_init (&_tmp129_, _tmp127_);
00640        while (g_variant_iter_loop (&_tmp129_, "{?*}", &_tmp130_, &_tmp131_)) {
00641               g_hash_table_insert (_tmp128_, g_variant_dup_string (_tmp130_, NULL), g_variant_get_variant (_tmp131_));
00642        }
00643        _tmp123_.hints = _tmp128_;
00644        g_variant_unref (_tmp127_);
00645        *result = _tmp123_;
00646        g_variant_unref (_tmp122_);
00647        g_object_unref (_reply_message);
00648 }
00649 
00650 
00651 static void unity_protocol_scope_service_proxy_update_preview_property_async (UnityProtocolScopeService* self, const gchar* uri, GHashTable* values, GAsyncReadyCallback _callback_, gpointer _user_data_) {
00652        GDBusMessage *_message;
00653        GVariant *_arguments;
00654        GVariantBuilder _arguments_builder;
00655        GVariantBuilder _tmp132_;
00656        GHashTableIter _tmp133_;
00657        gpointer _tmp134_;
00658        gpointer _tmp135_;
00659        G_IO_ERROR;
00660        _message = g_dbus_message_new_method_call (g_dbus_proxy_get_name ((GDBusProxy *) self), g_dbus_proxy_get_object_path ((GDBusProxy *) self), "com.canonical.Unity.Scope", "UpdatePreviewProperty");
00661        g_variant_builder_init (&_arguments_builder, G_VARIANT_TYPE_TUPLE);
00662        g_variant_builder_add_value (&_arguments_builder, g_variant_new_string (uri));
00663        g_hash_table_iter_init (&_tmp133_, values);
00664        g_variant_builder_init (&_tmp132_, G_VARIANT_TYPE ("a{sv}"));
00665        while (g_hash_table_iter_next (&_tmp133_, &_tmp134_, &_tmp135_)) {
00666               gchar* _key;
00667               GVariant* _value;
00668               _key = (gchar*) _tmp134_;
00669               _value = (GVariant*) _tmp135_;
00670               g_variant_builder_add (&_tmp132_, "{?*}", g_variant_new_string (_key), g_variant_new_variant (_value));
00671        }
00672        g_variant_builder_add_value (&_arguments_builder, g_variant_builder_end (&_tmp132_));
00673        _arguments = g_variant_builder_end (&_arguments_builder);
00674        g_dbus_message_set_body (_message, _arguments);
00675        g_dbus_connection_send_message_with_reply (g_dbus_proxy_get_connection ((GDBusProxy *) self), _message, G_DBUS_SEND_MESSAGE_FLAGS_NONE, g_dbus_proxy_get_default_timeout ((GDBusProxy *) self), NULL, NULL, _vala_g_async_ready_callback, g_simple_async_result_new ((GObject *) self, _callback_, _user_data_, NULL));
00676        g_object_unref (_message);
00677 }
00678 
00679 
00680 static GHashTable* unity_protocol_scope_service_proxy_update_preview_property_finish (UnityProtocolScopeService* self, GAsyncResult* _res_, GError** error) {
00681        GDBusMessage *_reply_message;
00682        GVariant *_reply;
00683        GVariantIter _reply_iter;
00684        GHashTable* _result;
00685        GVariant* _tmp136_;
00686        GHashTable* _tmp137_;
00687        GVariantIter _tmp138_;
00688        GVariant* _tmp139_;
00689        GVariant* _tmp140_;
00690        _reply_message = g_dbus_connection_send_message_with_reply_finish (g_dbus_proxy_get_connection ((GDBusProxy *) self), g_simple_async_result_get_op_res_gpointer ((GSimpleAsyncResult *) _res_), error);
00691        if (!_reply_message) {
00692               return NULL;
00693        }
00694        if (g_dbus_message_to_gerror (_reply_message, error)) {
00695               g_object_unref (_reply_message);
00696               return NULL;
00697        }
00698        _reply = g_dbus_message_get_body (_reply_message);
00699        g_variant_iter_init (&_reply_iter, _reply);
00700        _tmp136_ = g_variant_iter_next_value (&_reply_iter);
00701        _tmp137_ = g_hash_table_new_full (g_str_hash, g_str_equal, g_free, NULL);
00702        g_variant_iter_init (&_tmp138_, _tmp136_);
00703        while (g_variant_iter_loop (&_tmp138_, "{?*}", &_tmp139_, &_tmp140_)) {
00704               g_hash_table_insert (_tmp137_, g_variant_dup_string (_tmp139_, NULL), g_variant_get_variant (_tmp140_));
00705        }
00706        _result = _tmp137_;
00707        g_variant_unref (_tmp136_);
00708        g_object_unref (_reply_message);
00709        return _result;
00710 }
00711 
00712 
00713 static void unity_protocol_scope_service_proxy_search_async (UnityProtocolScopeService* self, const gchar* search_string, GHashTable* hints, GAsyncReadyCallback _callback_, gpointer _user_data_) {
00714        GDBusMessage *_message;
00715        GVariant *_arguments;
00716        GVariantBuilder _arguments_builder;
00717        GVariantBuilder _tmp141_;
00718        GHashTableIter _tmp142_;
00719        gpointer _tmp143_;
00720        gpointer _tmp144_;
00721        G_IO_ERROR;
00722        UNITY_PROTOCOL_SCOPE_ERROR;
00723        _message = g_dbus_message_new_method_call (g_dbus_proxy_get_name ((GDBusProxy *) self), g_dbus_proxy_get_object_path ((GDBusProxy *) self), "com.canonical.Unity.Scope", "Search");
00724        g_variant_builder_init (&_arguments_builder, G_VARIANT_TYPE_TUPLE);
00725        g_variant_builder_add_value (&_arguments_builder, g_variant_new_string (search_string));
00726        g_hash_table_iter_init (&_tmp142_, hints);
00727        g_variant_builder_init (&_tmp141_, G_VARIANT_TYPE ("a{sv}"));
00728        while (g_hash_table_iter_next (&_tmp142_, &_tmp143_, &_tmp144_)) {
00729               gchar* _key;
00730               GVariant* _value;
00731               _key = (gchar*) _tmp143_;
00732               _value = (GVariant*) _tmp144_;
00733               g_variant_builder_add (&_tmp141_, "{?*}", g_variant_new_string (_key), g_variant_new_variant (_value));
00734        }
00735        g_variant_builder_add_value (&_arguments_builder, g_variant_builder_end (&_tmp141_));
00736        _arguments = g_variant_builder_end (&_arguments_builder);
00737        g_dbus_message_set_body (_message, _arguments);
00738        g_dbus_connection_send_message_with_reply (g_dbus_proxy_get_connection ((GDBusProxy *) self), _message, G_DBUS_SEND_MESSAGE_FLAGS_NONE, g_dbus_proxy_get_default_timeout ((GDBusProxy *) self), NULL, NULL, _vala_g_async_ready_callback, g_simple_async_result_new ((GObject *) self, _callback_, _user_data_, NULL));
00739        g_object_unref (_message);
00740 }
00741 
00742 
00743 static GHashTable* unity_protocol_scope_service_proxy_search_finish (UnityProtocolScopeService* self, GAsyncResult* _res_, GError** error) {
00744        GDBusMessage *_reply_message;
00745        GVariant *_reply;
00746        GVariantIter _reply_iter;
00747        GHashTable* _result;
00748        GVariant* _tmp145_;
00749        GHashTable* _tmp146_;
00750        GVariantIter _tmp147_;
00751        GVariant* _tmp148_;
00752        GVariant* _tmp149_;
00753        _reply_message = g_dbus_connection_send_message_with_reply_finish (g_dbus_proxy_get_connection ((GDBusProxy *) self), g_simple_async_result_get_op_res_gpointer ((GSimpleAsyncResult *) _res_), error);
00754        if (!_reply_message) {
00755               return NULL;
00756        }
00757        if (g_dbus_message_to_gerror (_reply_message, error)) {
00758               g_object_unref (_reply_message);
00759               return NULL;
00760        }
00761        _reply = g_dbus_message_get_body (_reply_message);
00762        g_variant_iter_init (&_reply_iter, _reply);
00763        _tmp145_ = g_variant_iter_next_value (&_reply_iter);
00764        _tmp146_ = g_hash_table_new_full (g_str_hash, g_str_equal, g_free, NULL);
00765        g_variant_iter_init (&_tmp147_, _tmp145_);
00766        while (g_variant_iter_loop (&_tmp147_, "{?*}", &_tmp148_, &_tmp149_)) {
00767               g_hash_table_insert (_tmp146_, g_variant_dup_string (_tmp148_, NULL), g_variant_get_variant (_tmp149_));
00768        }
00769        _result = _tmp146_;
00770        g_variant_unref (_tmp145_);
00771        g_object_unref (_reply_message);
00772        return _result;
00773 }
00774 
00775 
00776 static void unity_protocol_scope_service_proxy_global_search_async (UnityProtocolScopeService* self, const gchar* search_string, GHashTable* hints, GAsyncReadyCallback _callback_, gpointer _user_data_) {
00777        GDBusMessage *_message;
00778        GVariant *_arguments;
00779        GVariantBuilder _arguments_builder;
00780        GVariantBuilder _tmp150_;
00781        GHashTableIter _tmp151_;
00782        gpointer _tmp152_;
00783        gpointer _tmp153_;
00784        G_IO_ERROR;
00785        UNITY_PROTOCOL_SCOPE_ERROR;
00786        _message = g_dbus_message_new_method_call (g_dbus_proxy_get_name ((GDBusProxy *) self), g_dbus_proxy_get_object_path ((GDBusProxy *) self), "com.canonical.Unity.Scope", "GlobalSearch");
00787        g_variant_builder_init (&_arguments_builder, G_VARIANT_TYPE_TUPLE);
00788        g_variant_builder_add_value (&_arguments_builder, g_variant_new_string (search_string));
00789        g_hash_table_iter_init (&_tmp151_, hints);
00790        g_variant_builder_init (&_tmp150_, G_VARIANT_TYPE ("a{sv}"));
00791        while (g_hash_table_iter_next (&_tmp151_, &_tmp152_, &_tmp153_)) {
00792               gchar* _key;
00793               GVariant* _value;
00794               _key = (gchar*) _tmp152_;
00795               _value = (GVariant*) _tmp153_;
00796               g_variant_builder_add (&_tmp150_, "{?*}", g_variant_new_string (_key), g_variant_new_variant (_value));
00797        }
00798        g_variant_builder_add_value (&_arguments_builder, g_variant_builder_end (&_tmp150_));
00799        _arguments = g_variant_builder_end (&_arguments_builder);
00800        g_dbus_message_set_body (_message, _arguments);
00801        g_dbus_connection_send_message_with_reply (g_dbus_proxy_get_connection ((GDBusProxy *) self), _message, G_DBUS_SEND_MESSAGE_FLAGS_NONE, g_dbus_proxy_get_default_timeout ((GDBusProxy *) self), NULL, NULL, _vala_g_async_ready_callback, g_simple_async_result_new ((GObject *) self, _callback_, _user_data_, NULL));
00802        g_object_unref (_message);
00803 }
00804 
00805 
00806 static GHashTable* unity_protocol_scope_service_proxy_global_search_finish (UnityProtocolScopeService* self, GAsyncResult* _res_, GError** error) {
00807        GDBusMessage *_reply_message;
00808        GVariant *_reply;
00809        GVariantIter _reply_iter;
00810        GHashTable* _result;
00811        GVariant* _tmp154_;
00812        GHashTable* _tmp155_;
00813        GVariantIter _tmp156_;
00814        GVariant* _tmp157_;
00815        GVariant* _tmp158_;
00816        _reply_message = g_dbus_connection_send_message_with_reply_finish (g_dbus_proxy_get_connection ((GDBusProxy *) self), g_simple_async_result_get_op_res_gpointer ((GSimpleAsyncResult *) _res_), error);
00817        if (!_reply_message) {
00818               return NULL;
00819        }
00820        if (g_dbus_message_to_gerror (_reply_message, error)) {
00821               g_object_unref (_reply_message);
00822               return NULL;
00823        }
00824        _reply = g_dbus_message_get_body (_reply_message);
00825        g_variant_iter_init (&_reply_iter, _reply);
00826        _tmp154_ = g_variant_iter_next_value (&_reply_iter);
00827        _tmp155_ = g_hash_table_new_full (g_str_hash, g_str_equal, g_free, NULL);
00828        g_variant_iter_init (&_tmp156_, _tmp154_);
00829        while (g_variant_iter_loop (&_tmp156_, "{?*}", &_tmp157_, &_tmp158_)) {
00830               g_hash_table_insert (_tmp155_, g_variant_dup_string (_tmp157_, NULL), g_variant_get_variant (_tmp158_));
00831        }
00832        _result = _tmp155_;
00833        g_variant_unref (_tmp154_);
00834        g_object_unref (_reply_message);
00835        return _result;
00836 }
00837 
00838 
00839 static void unity_protocol_scope_service_proxy_set_view_type_async (UnityProtocolScopeService* self, guint view_type, GAsyncReadyCallback _callback_, gpointer _user_data_) {
00840        GDBusMessage *_message;
00841        GVariant *_arguments;
00842        GVariantBuilder _arguments_builder;
00843        G_IO_ERROR;
00844        _message = g_dbus_message_new_method_call (g_dbus_proxy_get_name ((GDBusProxy *) self), g_dbus_proxy_get_object_path ((GDBusProxy *) self), "com.canonical.Unity.Scope", "SetViewType");
00845        g_variant_builder_init (&_arguments_builder, G_VARIANT_TYPE_TUPLE);
00846        g_variant_builder_add_value (&_arguments_builder, g_variant_new_uint32 (view_type));
00847        _arguments = g_variant_builder_end (&_arguments_builder);
00848        g_dbus_message_set_body (_message, _arguments);
00849        g_dbus_connection_send_message_with_reply (g_dbus_proxy_get_connection ((GDBusProxy *) self), _message, G_DBUS_SEND_MESSAGE_FLAGS_NONE, g_dbus_proxy_get_default_timeout ((GDBusProxy *) self), NULL, NULL, _vala_g_async_ready_callback, g_simple_async_result_new ((GObject *) self, _callback_, _user_data_, NULL));
00850        g_object_unref (_message);
00851 }
00852 
00853 
00854 static void unity_protocol_scope_service_proxy_set_view_type_finish (UnityProtocolScopeService* self, GAsyncResult* _res_, GError** error) {
00855        GDBusMessage *_reply_message;
00856        _reply_message = g_dbus_connection_send_message_with_reply_finish (g_dbus_proxy_get_connection ((GDBusProxy *) self), g_simple_async_result_get_op_res_gpointer ((GSimpleAsyncResult *) _res_), error);
00857        if (!_reply_message) {
00858               return;
00859        }
00860        if (g_dbus_message_to_gerror (_reply_message, error)) {
00861               g_object_unref (_reply_message);
00862               return;
00863        }
00864        g_object_unref (_reply_message);
00865 }
00866 
00867 
00868 static void unity_protocol_scope_service_proxy_set_active_sources_async (UnityProtocolScopeService* self, gchar** sources, int sources_length1, GAsyncReadyCallback _callback_, gpointer _user_data_) {
00869        GDBusMessage *_message;
00870        GVariant *_arguments;
00871        GVariantBuilder _arguments_builder;
00872        gchar** _tmp159_;
00873        GVariantBuilder _tmp160_;
00874        int _tmp161_;
00875        G_IO_ERROR;
00876        _message = g_dbus_message_new_method_call (g_dbus_proxy_get_name ((GDBusProxy *) self), g_dbus_proxy_get_object_path ((GDBusProxy *) self), "com.canonical.Unity.Scope", "SetActiveSources");
00877        g_variant_builder_init (&_arguments_builder, G_VARIANT_TYPE_TUPLE);
00878        _tmp159_ = sources;
00879        g_variant_builder_init (&_tmp160_, G_VARIANT_TYPE ("as"));
00880        for (_tmp161_ = 0; _tmp161_ < sources_length1; _tmp161_++) {
00881               g_variant_builder_add_value (&_tmp160_, g_variant_new_string (*_tmp159_));
00882               _tmp159_++;
00883        }
00884        g_variant_builder_add_value (&_arguments_builder, g_variant_builder_end (&_tmp160_));
00885        _arguments = g_variant_builder_end (&_arguments_builder);
00886        g_dbus_message_set_body (_message, _arguments);
00887        g_dbus_connection_send_message_with_reply (g_dbus_proxy_get_connection ((GDBusProxy *) self), _message, G_DBUS_SEND_MESSAGE_FLAGS_NONE, g_dbus_proxy_get_default_timeout ((GDBusProxy *) self), NULL, NULL, _vala_g_async_ready_callback, g_simple_async_result_new ((GObject *) self, _callback_, _user_data_, NULL));
00888        g_object_unref (_message);
00889 }
00890 
00891 
00892 static void unity_protocol_scope_service_proxy_set_active_sources_finish (UnityProtocolScopeService* self, GAsyncResult* _res_, GError** error) {
00893        GDBusMessage *_reply_message;
00894        _reply_message = g_dbus_connection_send_message_with_reply_finish (g_dbus_proxy_get_connection ((GDBusProxy *) self), g_simple_async_result_get_op_res_gpointer ((GSimpleAsyncResult *) _res_), error);
00895        if (!_reply_message) {
00896               return;
00897        }
00898        if (g_dbus_message_to_gerror (_reply_message, error)) {
00899               g_object_unref (_reply_message);
00900               return;
00901        }
00902        g_object_unref (_reply_message);
00903 }
00904 
00905 
00906 static void unity_protocol_scope_service_proxy_unity_protocol_scope_service_interface_init (UnityProtocolScopeServiceIface* iface) {
00907        iface->info_request = unity_protocol_scope_service_proxy_info_request_async;
00908        iface->info_request_finish = unity_protocol_scope_service_proxy_info_request_finish;
00909        iface->activate = unity_protocol_scope_service_proxy_activate_async;
00910        iface->activate_finish = unity_protocol_scope_service_proxy_activate_finish;
00911        iface->update_preview_property = unity_protocol_scope_service_proxy_update_preview_property_async;
00912        iface->update_preview_property_finish = unity_protocol_scope_service_proxy_update_preview_property_finish;
00913        iface->search = unity_protocol_scope_service_proxy_search_async;
00914        iface->search_finish = unity_protocol_scope_service_proxy_search_finish;
00915        iface->global_search = unity_protocol_scope_service_proxy_global_search_async;
00916        iface->global_search_finish = unity_protocol_scope_service_proxy_global_search_finish;
00917        iface->set_view_type = unity_protocol_scope_service_proxy_set_view_type_async;
00918        iface->set_view_type_finish = unity_protocol_scope_service_proxy_set_view_type_finish;
00919        iface->set_active_sources = unity_protocol_scope_service_proxy_set_active_sources_async;
00920        iface->set_active_sources_finish = unity_protocol_scope_service_proxy_set_active_sources_finish;
00921 }
00922 
00923 
00924 static void _dbus_unity_protocol_scope_service_info_request (UnityProtocolScopeService* self, GVariant* parameters, GDBusMethodInvocation* invocation) {
00925        GVariantIter _arguments_iter;
00926        g_variant_iter_init (&_arguments_iter, parameters);
00927        unity_protocol_scope_service_info_request (self, (GAsyncReadyCallback) _dbus_unity_protocol_scope_service_info_request_ready, invocation);
00928 }
00929 
00930 
00931 static void _dbus_unity_protocol_scope_service_info_request_ready (GObject * source_object, GAsyncResult * _res_, gpointer _user_data_) {
00932        GDBusMethodInvocation * invocation;
00933        GError* error = NULL;
00934        GDBusMessage* _reply_message;
00935        GVariant* _reply;
00936        GVariantBuilder _reply_builder;
00937        invocation = _user_data_;
00938        unity_protocol_scope_service_info_request_finish ((UnityProtocolScopeService*) source_object, _res_, &error);
00939        if (error) {
00940               g_dbus_method_invocation_return_gerror (invocation, error);
00941               return;
00942        }
00943        _reply_message = g_dbus_message_new_method_reply (g_dbus_method_invocation_get_message (invocation));
00944        g_variant_builder_init (&_reply_builder, G_VARIANT_TYPE_TUPLE);
00945        _reply = g_variant_builder_end (&_reply_builder);
00946        g_dbus_message_set_body (_reply_message, _reply);
00947        g_dbus_connection_send_message (g_dbus_method_invocation_get_connection (invocation), _reply_message, G_DBUS_SEND_MESSAGE_FLAGS_NONE, NULL, NULL);
00948        g_object_unref (invocation);
00949        g_object_unref (_reply_message);
00950 }
00951 
00952 
00953 static void _dbus_unity_protocol_scope_service_activate (UnityProtocolScopeService* self, GVariant* parameters, GDBusMethodInvocation* invocation) {
00954        GVariantIter _arguments_iter;
00955        gchar* uri = NULL;
00956        GVariant* _tmp162_;
00957        guint action_type = 0U;
00958        GVariant* _tmp163_;
00959        g_variant_iter_init (&_arguments_iter, parameters);
00960        _tmp162_ = g_variant_iter_next_value (&_arguments_iter);
00961        uri = g_variant_dup_string (_tmp162_, NULL);
00962        g_variant_unref (_tmp162_);
00963        _tmp163_ = g_variant_iter_next_value (&_arguments_iter);
00964        action_type = g_variant_get_uint32 (_tmp163_);
00965        g_variant_unref (_tmp163_);
00966        unity_protocol_scope_service_activate (self, uri, action_type, (GAsyncReadyCallback) _dbus_unity_protocol_scope_service_activate_ready, invocation);
00967        _g_free0 (uri);
00968 }
00969 
00970 
00971 static void _dbus_unity_protocol_scope_service_activate_ready (GObject * source_object, GAsyncResult * _res_, gpointer _user_data_) {
00972        GDBusMethodInvocation * invocation;
00973        GError* error = NULL;
00974        GDBusMessage* _reply_message;
00975        GVariant* _reply;
00976        GVariantBuilder _reply_builder;
00977        UnityProtocolActivationReplyRaw result = {0};
00978        GVariantBuilder _tmp164_;
00979        GVariantBuilder _tmp165_;
00980        GHashTableIter _tmp166_;
00981        gpointer _tmp167_;
00982        gpointer _tmp168_;
00983        invocation = _user_data_;
00984        unity_protocol_scope_service_activate_finish ((UnityProtocolScopeService*) source_object, _res_, &result, &error);
00985        if (error) {
00986               g_dbus_method_invocation_return_gerror (invocation, error);
00987               return;
00988        }
00989        _reply_message = g_dbus_message_new_method_reply (g_dbus_method_invocation_get_message (invocation));
00990        g_variant_builder_init (&_reply_builder, G_VARIANT_TYPE_TUPLE);
00991        g_variant_builder_init (&_tmp164_, G_VARIANT_TYPE_TUPLE);
00992        g_variant_builder_add_value (&_tmp164_, g_variant_new_string (result.uri));
00993        g_variant_builder_add_value (&_tmp164_, g_variant_new_uint32 (result.handled));
00994        g_hash_table_iter_init (&_tmp166_, result.hints);
00995        g_variant_builder_init (&_tmp165_, G_VARIANT_TYPE ("a{sv}"));
00996        while (g_hash_table_iter_next (&_tmp166_, &_tmp167_, &_tmp168_)) {
00997               gchar* _key;
00998               GVariant* _value;
00999               _key = (gchar*) _tmp167_;
01000               _value = (GVariant*) _tmp168_;
01001               g_variant_builder_add (&_tmp165_, "{?*}", g_variant_new_string (_key), g_variant_new_variant (_value));
01002        }
01003        g_variant_builder_add_value (&_tmp164_, g_variant_builder_end (&_tmp165_));
01004        g_variant_builder_add_value (&_reply_builder, g_variant_builder_end (&_tmp164_));
01005        unity_protocol_activation_reply_raw_destroy (&result);
01006        _reply = g_variant_builder_end (&_reply_builder);
01007        g_dbus_message_set_body (_reply_message, _reply);
01008        g_dbus_connection_send_message (g_dbus_method_invocation_get_connection (invocation), _reply_message, G_DBUS_SEND_MESSAGE_FLAGS_NONE, NULL, NULL);
01009        g_object_unref (invocation);
01010        g_object_unref (_reply_message);
01011 }
01012 
01013 
01014 static void _dbus_unity_protocol_scope_service_update_preview_property (UnityProtocolScopeService* self, GVariant* parameters, GDBusMethodInvocation* invocation) {
01015        GVariantIter _arguments_iter;
01016        gchar* uri = NULL;
01017        GVariant* _tmp169_;
01018        GHashTable* values = NULL;
01019        GVariant* _tmp170_;
01020        GHashTable* _tmp171_;
01021        GVariantIter _tmp172_;
01022        GVariant* _tmp173_;
01023        GVariant* _tmp174_;
01024        g_variant_iter_init (&_arguments_iter, parameters);
01025        _tmp169_ = g_variant_iter_next_value (&_arguments_iter);
01026        uri = g_variant_dup_string (_tmp169_, NULL);
01027        g_variant_unref (_tmp169_);
01028        _tmp170_ = g_variant_iter_next_value (&_arguments_iter);
01029        _tmp171_ = g_hash_table_new_full (g_str_hash, g_str_equal, g_free, NULL);
01030        g_variant_iter_init (&_tmp172_, _tmp170_);
01031        while (g_variant_iter_loop (&_tmp172_, "{?*}", &_tmp173_, &_tmp174_)) {
01032               g_hash_table_insert (_tmp171_, g_variant_dup_string (_tmp173_, NULL), g_variant_get_variant (_tmp174_));
01033        }
01034        values = _tmp171_;
01035        g_variant_unref (_tmp170_);
01036        unity_protocol_scope_service_update_preview_property (self, uri, values, (GAsyncReadyCallback) _dbus_unity_protocol_scope_service_update_preview_property_ready, invocation);
01037        _g_free0 (uri);
01038        _g_hash_table_unref0 (values);
01039 }
01040 
01041 
01042 static void _dbus_unity_protocol_scope_service_update_preview_property_ready (GObject * source_object, GAsyncResult * _res_, gpointer _user_data_) {
01043        GDBusMethodInvocation * invocation;
01044        GError* error = NULL;
01045        GDBusMessage* _reply_message;
01046        GVariant* _reply;
01047        GVariantBuilder _reply_builder;
01048        GHashTable* result;
01049        GVariantBuilder _tmp175_;
01050        GHashTableIter _tmp176_;
01051        gpointer _tmp177_;
01052        gpointer _tmp178_;
01053        invocation = _user_data_;
01054        result = unity_protocol_scope_service_update_preview_property_finish ((UnityProtocolScopeService*) source_object, _res_, &error);
01055        if (error) {
01056               g_dbus_method_invocation_return_gerror (invocation, error);
01057               return;
01058        }
01059        _reply_message = g_dbus_message_new_method_reply (g_dbus_method_invocation_get_message (invocation));
01060        g_variant_builder_init (&_reply_builder, G_VARIANT_TYPE_TUPLE);
01061        g_hash_table_iter_init (&_tmp176_, result);
01062        g_variant_builder_init (&_tmp175_, G_VARIANT_TYPE ("a{sv}"));
01063        while (g_hash_table_iter_next (&_tmp176_, &_tmp177_, &_tmp178_)) {
01064               gchar* _key;
01065               GVariant* _value;
01066               _key = (gchar*) _tmp177_;
01067               _value = (GVariant*) _tmp178_;
01068               g_variant_builder_add (&_tmp175_, "{?*}", g_variant_new_string (_key), g_variant_new_variant (_value));
01069        }
01070        g_variant_builder_add_value (&_reply_builder, g_variant_builder_end (&_tmp175_));
01071        _g_hash_table_unref0 (result);
01072        _reply = g_variant_builder_end (&_reply_builder);
01073        g_dbus_message_set_body (_reply_message, _reply);
01074        g_dbus_connection_send_message (g_dbus_method_invocation_get_connection (invocation), _reply_message, G_DBUS_SEND_MESSAGE_FLAGS_NONE, NULL, NULL);
01075        g_object_unref (invocation);
01076        g_object_unref (_reply_message);
01077 }
01078 
01079 
01080 static void _dbus_unity_protocol_scope_service_search (UnityProtocolScopeService* self, GVariant* parameters, GDBusMethodInvocation* invocation) {
01081        GVariantIter _arguments_iter;
01082        gchar* search_string = NULL;
01083        GVariant* _tmp179_;
01084        GHashTable* hints = NULL;
01085        GVariant* _tmp180_;
01086        GHashTable* _tmp181_;
01087        GVariantIter _tmp182_;
01088        GVariant* _tmp183_;
01089        GVariant* _tmp184_;
01090        g_variant_iter_init (&_arguments_iter, parameters);
01091        _tmp179_ = g_variant_iter_next_value (&_arguments_iter);
01092        search_string = g_variant_dup_string (_tmp179_, NULL);
01093        g_variant_unref (_tmp179_);
01094        _tmp180_ = g_variant_iter_next_value (&_arguments_iter);
01095        _tmp181_ = g_hash_table_new_full (g_str_hash, g_str_equal, g_free, NULL);
01096        g_variant_iter_init (&_tmp182_, _tmp180_);
01097        while (g_variant_iter_loop (&_tmp182_, "{?*}", &_tmp183_, &_tmp184_)) {
01098               g_hash_table_insert (_tmp181_, g_variant_dup_string (_tmp183_, NULL), g_variant_get_variant (_tmp184_));
01099        }
01100        hints = _tmp181_;
01101        g_variant_unref (_tmp180_);
01102        unity_protocol_scope_service_search (self, search_string, hints, (GAsyncReadyCallback) _dbus_unity_protocol_scope_service_search_ready, invocation);
01103        _g_free0 (search_string);
01104        _g_hash_table_unref0 (hints);
01105 }
01106 
01107 
01108 static void _dbus_unity_protocol_scope_service_search_ready (GObject * source_object, GAsyncResult * _res_, gpointer _user_data_) {
01109        GDBusMethodInvocation * invocation;
01110        GError* error = NULL;
01111        GDBusMessage* _reply_message;
01112        GVariant* _reply;
01113        GVariantBuilder _reply_builder;
01114        GHashTable* result;
01115        GVariantBuilder _tmp185_;
01116        GHashTableIter _tmp186_;
01117        gpointer _tmp187_;
01118        gpointer _tmp188_;
01119        invocation = _user_data_;
01120        result = unity_protocol_scope_service_search_finish ((UnityProtocolScopeService*) source_object, _res_, &error);
01121        if (error) {
01122               g_dbus_method_invocation_return_gerror (invocation, error);
01123               return;
01124        }
01125        _reply_message = g_dbus_message_new_method_reply (g_dbus_method_invocation_get_message (invocation));
01126        g_variant_builder_init (&_reply_builder, G_VARIANT_TYPE_TUPLE);
01127        g_hash_table_iter_init (&_tmp186_, result);
01128        g_variant_builder_init (&_tmp185_, G_VARIANT_TYPE ("a{sv}"));
01129        while (g_hash_table_iter_next (&_tmp186_, &_tmp187_, &_tmp188_)) {
01130               gchar* _key;
01131               GVariant* _value;
01132               _key = (gchar*) _tmp187_;
01133               _value = (GVariant*) _tmp188_;
01134               g_variant_builder_add (&_tmp185_, "{?*}", g_variant_new_string (_key), g_variant_new_variant (_value));
01135        }
01136        g_variant_builder_add_value (&_reply_builder, g_variant_builder_end (&_tmp185_));
01137        _g_hash_table_unref0 (result);
01138        _reply = g_variant_builder_end (&_reply_builder);
01139        g_dbus_message_set_body (_reply_message, _reply);
01140        g_dbus_connection_send_message (g_dbus_method_invocation_get_connection (invocation), _reply_message, G_DBUS_SEND_MESSAGE_FLAGS_NONE, NULL, NULL);
01141        g_object_unref (invocation);
01142        g_object_unref (_reply_message);
01143 }
01144 
01145 
01146 static void _dbus_unity_protocol_scope_service_global_search (UnityProtocolScopeService* self, GVariant* parameters, GDBusMethodInvocation* invocation) {
01147        GVariantIter _arguments_iter;
01148        gchar* search_string = NULL;
01149        GVariant* _tmp189_;
01150        GHashTable* hints = NULL;
01151        GVariant* _tmp190_;
01152        GHashTable* _tmp191_;
01153        GVariantIter _tmp192_;
01154        GVariant* _tmp193_;
01155        GVariant* _tmp194_;
01156        g_variant_iter_init (&_arguments_iter, parameters);
01157        _tmp189_ = g_variant_iter_next_value (&_arguments_iter);
01158        search_string = g_variant_dup_string (_tmp189_, NULL);
01159        g_variant_unref (_tmp189_);
01160        _tmp190_ = g_variant_iter_next_value (&_arguments_iter);
01161        _tmp191_ = g_hash_table_new_full (g_str_hash, g_str_equal, g_free, NULL);
01162        g_variant_iter_init (&_tmp192_, _tmp190_);
01163        while (g_variant_iter_loop (&_tmp192_, "{?*}", &_tmp193_, &_tmp194_)) {
01164               g_hash_table_insert (_tmp191_, g_variant_dup_string (_tmp193_, NULL), g_variant_get_variant (_tmp194_));
01165        }
01166        hints = _tmp191_;
01167        g_variant_unref (_tmp190_);
01168        unity_protocol_scope_service_global_search (self, search_string, hints, (GAsyncReadyCallback) _dbus_unity_protocol_scope_service_global_search_ready, invocation);
01169        _g_free0 (search_string);
01170        _g_hash_table_unref0 (hints);
01171 }
01172 
01173 
01174 static void _dbus_unity_protocol_scope_service_global_search_ready (GObject * source_object, GAsyncResult * _res_, gpointer _user_data_) {
01175        GDBusMethodInvocation * invocation;
01176        GError* error = NULL;
01177        GDBusMessage* _reply_message;
01178        GVariant* _reply;
01179        GVariantBuilder _reply_builder;
01180        GHashTable* result;
01181        GVariantBuilder _tmp195_;
01182        GHashTableIter _tmp196_;
01183        gpointer _tmp197_;
01184        gpointer _tmp198_;
01185        invocation = _user_data_;
01186        result = unity_protocol_scope_service_global_search_finish ((UnityProtocolScopeService*) source_object, _res_, &error);
01187        if (error) {
01188               g_dbus_method_invocation_return_gerror (invocation, error);
01189               return;
01190        }
01191        _reply_message = g_dbus_message_new_method_reply (g_dbus_method_invocation_get_message (invocation));
01192        g_variant_builder_init (&_reply_builder, G_VARIANT_TYPE_TUPLE);
01193        g_hash_table_iter_init (&_tmp196_, result);
01194        g_variant_builder_init (&_tmp195_, G_VARIANT_TYPE ("a{sv}"));
01195        while (g_hash_table_iter_next (&_tmp196_, &_tmp197_, &_tmp198_)) {
01196               gchar* _key;
01197               GVariant* _value;
01198               _key = (gchar*) _tmp197_;
01199               _value = (GVariant*) _tmp198_;
01200               g_variant_builder_add (&_tmp195_, "{?*}", g_variant_new_string (_key), g_variant_new_variant (_value));
01201        }
01202        g_variant_builder_add_value (&_reply_builder, g_variant_builder_end (&_tmp195_));
01203        _g_hash_table_unref0 (result);
01204        _reply = g_variant_builder_end (&_reply_builder);
01205        g_dbus_message_set_body (_reply_message, _reply);
01206        g_dbus_connection_send_message (g_dbus_method_invocation_get_connection (invocation), _reply_message, G_DBUS_SEND_MESSAGE_FLAGS_NONE, NULL, NULL);
01207        g_object_unref (invocation);
01208        g_object_unref (_reply_message);
01209 }
01210 
01211 
01212 static void _dbus_unity_protocol_scope_service_set_view_type (UnityProtocolScopeService* self, GVariant* parameters, GDBusMethodInvocation* invocation) {
01213        GVariantIter _arguments_iter;
01214        guint view_type = 0U;
01215        GVariant* _tmp199_;
01216        g_variant_iter_init (&_arguments_iter, parameters);
01217        _tmp199_ = g_variant_iter_next_value (&_arguments_iter);
01218        view_type = g_variant_get_uint32 (_tmp199_);
01219        g_variant_unref (_tmp199_);
01220        unity_protocol_scope_service_set_view_type (self, view_type, (GAsyncReadyCallback) _dbus_unity_protocol_scope_service_set_view_type_ready, invocation);
01221 }
01222 
01223 
01224 static void _dbus_unity_protocol_scope_service_set_view_type_ready (GObject * source_object, GAsyncResult * _res_, gpointer _user_data_) {
01225        GDBusMethodInvocation * invocation;
01226        GError* error = NULL;
01227        GDBusMessage* _reply_message;
01228        GVariant* _reply;
01229        GVariantBuilder _reply_builder;
01230        invocation = _user_data_;
01231        unity_protocol_scope_service_set_view_type_finish ((UnityProtocolScopeService*) source_object, _res_, &error);
01232        if (error) {
01233               g_dbus_method_invocation_return_gerror (invocation, error);
01234               return;
01235        }
01236        _reply_message = g_dbus_message_new_method_reply (g_dbus_method_invocation_get_message (invocation));
01237        g_variant_builder_init (&_reply_builder, G_VARIANT_TYPE_TUPLE);
01238        _reply = g_variant_builder_end (&_reply_builder);
01239        g_dbus_message_set_body (_reply_message, _reply);
01240        g_dbus_connection_send_message (g_dbus_method_invocation_get_connection (invocation), _reply_message, G_DBUS_SEND_MESSAGE_FLAGS_NONE, NULL, NULL);
01241        g_object_unref (invocation);
01242        g_object_unref (_reply_message);
01243 }
01244 
01245 
01246 static void _dbus_unity_protocol_scope_service_set_active_sources (UnityProtocolScopeService* self, GVariant* parameters, GDBusMethodInvocation* invocation) {
01247        GVariantIter _arguments_iter;
01248        gchar** sources = NULL;
01249        int sources_length1 = 0;
01250        GVariant* _tmp200_;
01251        gchar** _tmp201_;
01252        int _tmp201__length;
01253        int _tmp201__size;
01254        int _tmp201__length1;
01255        GVariantIter _tmp202_;
01256        GVariant* _tmp203_;
01257        g_variant_iter_init (&_arguments_iter, parameters);
01258        _tmp200_ = g_variant_iter_next_value (&_arguments_iter);
01259        _tmp201_ = g_new (gchar*, 5);
01260        _tmp201__length = 0;
01261        _tmp201__size = 4;
01262        _tmp201__length1 = 0;
01263        g_variant_iter_init (&_tmp202_, _tmp200_);
01264        for (; (_tmp203_ = g_variant_iter_next_value (&_tmp202_)) != NULL; _tmp201__length1++) {
01265               if (_tmp201__size == _tmp201__length) {
01266                      _tmp201__size = 2 * _tmp201__size;
01267                      _tmp201_ = g_renew (gchar*, _tmp201_, _tmp201__size + 1);
01268               }
01269               _tmp201_[_tmp201__length++] = g_variant_dup_string (_tmp203_, NULL);
01270               g_variant_unref (_tmp203_);
01271        }
01272        sources_length1 = _tmp201__length1;
01273        _tmp201_[_tmp201__length] = NULL;
01274        sources = _tmp201_;
01275        g_variant_unref (_tmp200_);
01276        unity_protocol_scope_service_set_active_sources (self, sources, sources_length1, (GAsyncReadyCallback) _dbus_unity_protocol_scope_service_set_active_sources_ready, invocation);
01277        sources = (_vala_array_free (sources, sources_length1, (GDestroyNotify) g_free), NULL);
01278 }
01279 
01280 
01281 static void _dbus_unity_protocol_scope_service_set_active_sources_ready (GObject * source_object, GAsyncResult * _res_, gpointer _user_data_) {
01282        GDBusMethodInvocation * invocation;
01283        GError* error = NULL;
01284        GDBusMessage* _reply_message;
01285        GVariant* _reply;
01286        GVariantBuilder _reply_builder;
01287        invocation = _user_data_;
01288        unity_protocol_scope_service_set_active_sources_finish ((UnityProtocolScopeService*) source_object, _res_, &error);
01289        if (error) {
01290               g_dbus_method_invocation_return_gerror (invocation, error);
01291               return;
01292        }
01293        _reply_message = g_dbus_message_new_method_reply (g_dbus_method_invocation_get_message (invocation));
01294        g_variant_builder_init (&_reply_builder, G_VARIANT_TYPE_TUPLE);
01295        _reply = g_variant_builder_end (&_reply_builder);
01296        g_dbus_message_set_body (_reply_message, _reply);
01297        g_dbus_connection_send_message (g_dbus_method_invocation_get_connection (invocation), _reply_message, G_DBUS_SEND_MESSAGE_FLAGS_NONE, NULL, NULL);
01298        g_object_unref (invocation);
01299        g_object_unref (_reply_message);
01300 }
01301 
01302 
01303 static void unity_protocol_scope_service_dbus_interface_method_call (GDBusConnection* connection, const gchar* sender, const gchar* object_path, const gchar* interface_name, const gchar* method_name, GVariant* parameters, GDBusMethodInvocation* invocation, gpointer user_data) {
01304        gpointer* data;
01305        gpointer object;
01306        data = user_data;
01307        object = data[0];
01308        if (strcmp (method_name, "InfoRequest") == 0) {
01309               _dbus_unity_protocol_scope_service_info_request (object, parameters, invocation);
01310        } else if (strcmp (method_name, "Activate") == 0) {
01311               _dbus_unity_protocol_scope_service_activate (object, parameters, invocation);
01312        } else if (strcmp (method_name, "UpdatePreviewProperty") == 0) {
01313               _dbus_unity_protocol_scope_service_update_preview_property (object, parameters, invocation);
01314        } else if (strcmp (method_name, "Search") == 0) {
01315               _dbus_unity_protocol_scope_service_search (object, parameters, invocation);
01316        } else if (strcmp (method_name, "GlobalSearch") == 0) {
01317               _dbus_unity_protocol_scope_service_global_search (object, parameters, invocation);
01318        } else if (strcmp (method_name, "SetViewType") == 0) {
01319               _dbus_unity_protocol_scope_service_set_view_type (object, parameters, invocation);
01320        } else if (strcmp (method_name, "SetActiveSources") == 0) {
01321               _dbus_unity_protocol_scope_service_set_active_sources (object, parameters, invocation);
01322        } else {
01323               g_object_unref (invocation);
01324        }
01325 }
01326 
01327 
01328 static GVariant* unity_protocol_scope_service_dbus_interface_get_property (GDBusConnection* connection, const gchar* sender, const gchar* object_path, const gchar* interface_name, const gchar* property_name, GError** error, gpointer user_data) {
01329        gpointer* data;
01330        gpointer object;
01331        data = user_data;
01332        object = data[0];
01333        return NULL;
01334 }
01335 
01336 
01337 static gboolean unity_protocol_scope_service_dbus_interface_set_property (GDBusConnection* connection, const gchar* sender, const gchar* object_path, const gchar* interface_name, const gchar* property_name, GVariant* value, GError** error, gpointer user_data) {
01338        gpointer* data;
01339        gpointer object;
01340        data = user_data;
01341        object = data[0];
01342        return FALSE;
01343 }
01344 
01345 
01346 static void _dbus_unity_protocol_scope_service_changed (GObject* _sender, UnityProtocolScopeInfo* lens_info, gpointer* _data) {
01347        GDBusConnection * _connection;
01348        const gchar * _path;
01349        GVariant *_arguments;
01350        GVariantBuilder _arguments_builder;
01351        GVariantBuilder _tmp204_;
01352        GVariantBuilder _tmp205_;
01353        GHashTableIter _tmp206_;
01354        gpointer _tmp207_;
01355        gpointer _tmp208_;
01356        _connection = _data[1];
01357        _path = _data[2];
01358        g_variant_builder_init (&_arguments_builder, G_VARIANT_TYPE_TUPLE);
01359        g_variant_builder_init (&_tmp204_, G_VARIANT_TYPE_TUPLE);
01360        g_variant_builder_add_value (&_tmp204_, g_variant_new_string ((*lens_info).dbus_path));
01361        g_variant_builder_add_value (&_tmp204_, g_variant_new_variant ((*lens_info).sources));
01362        g_variant_builder_add_value (&_tmp204_, g_variant_new_boolean ((*lens_info).search_in_global));
01363        g_variant_builder_add_value (&_tmp204_, g_variant_new_string ((*lens_info).private_connection_name));
01364        g_variant_builder_add_value (&_tmp204_, g_variant_new_string ((*lens_info).results_model_name));
01365        g_variant_builder_add_value (&_tmp204_, g_variant_new_string ((*lens_info).global_results_model_name));
01366        g_variant_builder_add_value (&_tmp204_, g_variant_new_string ((*lens_info).filters_model_name));
01367        g_hash_table_iter_init (&_tmp206_, (*lens_info).hints);
01368        g_variant_builder_init (&_tmp205_, G_VARIANT_TYPE ("a{sv}"));
01369        while (g_hash_table_iter_next (&_tmp206_, &_tmp207_, &_tmp208_)) {
01370               gchar* _key;
01371               GVariant* _value;
01372               _key = (gchar*) _tmp207_;
01373               _value = (GVariant*) _tmp208_;
01374               g_variant_builder_add (&_tmp205_, "{?*}", g_variant_new_string (_key), g_variant_new_variant (_value));
01375        }
01376        g_variant_builder_add_value (&_tmp204_, g_variant_builder_end (&_tmp205_));
01377        g_variant_builder_add_value (&_arguments_builder, g_variant_builder_end (&_tmp204_));
01378        _arguments = g_variant_builder_end (&_arguments_builder);
01379        g_dbus_connection_emit_signal (_connection, NULL, _path, "com.canonical.Unity.Scope", "Changed", _arguments, NULL);
01380 }
01381 
01382 
01383 guint unity_protocol_scope_service_register_object (gpointer object, GDBusConnection* connection, const gchar* path, GError** error) {
01384        guint result;
01385        gpointer *data;
01386        data = g_new (gpointer, 3);
01387        data[0] = g_object_ref (object);
01388        data[1] = g_object_ref (connection);
01389        data[2] = g_strdup (path);
01390        result = g_dbus_connection_register_object (connection, path, (GDBusInterfaceInfo *) (&_unity_protocol_scope_service_dbus_interface_info), &_unity_protocol_scope_service_dbus_interface_vtable, data, _unity_protocol_scope_service_unregister_object, error);
01391        if (!result) {
01392               return 0;
01393        }
01394        g_signal_connect (object, "changed", (GCallback) _dbus_unity_protocol_scope_service_changed, data);
01395        return result;
01396 }
01397 
01398 
01399 static void _unity_protocol_scope_service_unregister_object (gpointer user_data) {
01400        gpointer* data;
01401        data = user_data;
01402        g_signal_handlers_disconnect_by_func (data[0], _dbus_unity_protocol_scope_service_changed, data);
01403        g_object_unref (data[0]);
01404        g_object_unref (data[1]);
01405        g_free (data[2]);
01406        g_free (data);
01407 }
01408 
01409 
01410 static void _vala_array_destroy (gpointer array, gint array_length, GDestroyNotify destroy_func) {
01411        if ((array != NULL) && (destroy_func != NULL)) {
01412               int i;
01413               for (i = 0; i < array_length; i = i + 1) {
01414                      if (((gpointer*) array)[i] != NULL) {
01415                             destroy_func (((gpointer*) array)[i]);
01416                      }
01417               }
01418        }
01419 }
01420 
01421 
01422 static void _vala_array_free (gpointer array, gint array_length, GDestroyNotify destroy_func) {
01423        _vala_array_destroy (array, array_length, destroy_func);
01424        g_free (array);
01425 }
01426 
01427 
01428