Merge lp:~indicator-applet-developers/indicator-application/ubuntu into lp:~ubuntu-desktop/indicator-application/ubuntu

Proposed by Ted Gould
Status: Merged
Merged at revision: 116
Proposed branch: lp:~indicator-applet-developers/indicator-application/ubuntu
Merge into: lp:~ubuntu-desktop/indicator-application/ubuntu
Diff against target: 1478 lines (+650/-99)
23 files modified
ChangeLog (+128/-0)
configure (+10/-10)
configure.ac (+2/-2)
debian/changelog (+8/-0)
docs/reference/html/ch01.html (+1/-1)
docs/reference/html/index.html (+1/-1)
docs/reference/html/libappindicator-app-indicator.html (+55/-55)
docs/reference/html/object-tree.html (+1/-1)
docs/reference/libappindicator-docs.sgml (+1/-1)
docs/reference/tmpl/app-indicator.sgml (+0/-2)
docs/reference/version.xml (+1/-1)
docs/reference/xml/app-indicator.xml (+2/-2)
src/Makefile.am (+1/-0)
src/Makefile.in (+1/-0)
src/application-service-appstore.c (+115/-10)
src/application-service-appstore.h (+10/-4)
src/application-service-watcher.c (+14/-0)
src/dbus-shared.h (+2/-0)
src/notification-approver.xml (+22/-0)
src/notification-watcher.xml (+7/-0)
tests/Makefile.am (+28/-0)
tests/Makefile.in (+61/-9)
tests/test-approver.c (+179/-0)
To merge this branch: bzr merge lp:~indicator-applet-developers/indicator-application/ubuntu
Reviewer Review Type Date Requested Status
Ken VanDine Approve
Review via email: mp+30022@code.launchpad.net

Description of the change

Oops, right branch.

To post a comment you must log in.
Revision history for this message
Ken VanDine (ken-vandine) wrote :

Approve

review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'ChangeLog'
2--- ChangeLog 2010-07-08 15:22:02 +0000
3+++ ChangeLog 2010-07-15 15:45:53 +0000
4@@ -1,5 +1,133 @@
5 # Generated by Makefile. Do not edit.
6
7+2010-07-13 Ted Gould <ted@gould.cx>
8+
9+ Adjusting the tests so they can deal with slow systems better.
10+
11+2010-07-12 Ted Gould <ted@gould.cx>
12+
13+ Ignoring the tester script
14+
15+2010-07-12 Ted Gould <ted@gould.cx>
16+
17+ Add a fail timeout so this test can't block.
18+
19+2010-07-12 Ted Gould <ted@gould.cx>
20+
21+ Adding in setting the environment variable to adjust the timeout to be twice as long for slow systems.
22+
23+2010-07-12 Ted Gould <ted@gould.cx>
24+
25+ Putting in a basic approver API.
26+
27+2010-07-09 Ted Gould <ted@gould.cx>
28+
29+ Need the built headers too
30+
31+2010-07-09 Ted Gould <ted@gould.cx>
32+
33+ Oops, with a menu we're all GTK now.
34+
35+2010-07-09 Ted Gould <ted@gould.cx>
36+
37+ Building up to a formal test
38+
39+2010-07-09 Ted Gould <ted@gould.cx>
40+
41+ Filling out the approve function.
42+
43+2010-07-09 Ted Gould <ted@gould.cx>
44+
45+ Filling out the approver prototype
46+
47+2010-07-09 Ted Gould <ted@gould.cx>
48+
49+ Building an application indicator too!
50+
51+2010-07-09 Ted Gould <ted@gould.cx>
52+
53+ Making the registration async to clean things up, and async is better anyway.
54+
55+2010-07-09 Ted Gould <ted@gould.cx>
56+
57+ Some more error handling and better debug messages.
58+
59+2010-07-09 Ted Gould <ted@gould.cx>
60+
61+ Helpful debug info
62+
63+2010-07-09 Ted Gould <ted@gould.cx>
64+
65+ Okay, so now we're detecing when the watcher comes up, and registering ourselves as the approver.
66+
67+2010-07-09 Ted Gould <ted@gould.cx>
68+
69+ Adding a new sample approver
70+
71+2010-07-09 Ted Gould <ted@gould.cx>
72+
73+ When we have new apps we can ask the approver about them.
74+
75+2010-07-09 Ted Gould <ted@gould.cx>
76+
77+ Looking at all the applications when we get a new approver.
78+
79+2010-07-09 Ted Gould <ted@gould.cx>
80+
81+ Building the approver structure and putting it in the list.
82+
83+2010-07-09 Ted Gould <ted@gould.cx>
84+
85+ Comments
86+
87+2010-07-09 Ted Gould <ted@gould.cx>
88+
89+ Adding some structures for approvers and making them real.
90+
91+2010-07-09 Ted Gould <ted@gould.cx>
92+
93+ For DBus to real objects, the signal shall travel.
94+
95+2010-07-09 Ted Gould <ted@gould.cx>
96+
97+ Adding a function to bring in approvers
98+
99+2010-07-09 Ted Gould <ted@gould.cx>
100+
101+ Sync to trunk
102+
103+2010-07-01 Ted Gould <ted@gould.cx>
104+
105+ Return a boolean
106+
107+2010-06-25 Ted Gould <ted@gould.cx>
108+
109+ Adding in a template function to register approvers.
110+
111+2010-06-25 Ted Gould <ted@gould.cx>
112+
113+ Adding a function to register an approver.
114+
115+2010-06-25 Ted Gould <ted@gould.cx>
116+
117+ Adding an approver interface.
118+
119+2010-07-08 Ted Gould <ted@gould.cx>
120+
121+ Use a private pointer instead of a lookup.
122+
123+2010-07-08 Sense Hofstede <qense@ubuntu.com>
124+
125+ Removed all but one calls to the APPLICATION_SERVICE_APPSTORE_GET_PRIVATE() macro
126+
127+ All references to the APPLICATION_SERVICE_APPSTORE_GET_PRIVATE() macro were removed
128+ from src/application-service-appstore.c. This makes this file comply with the
129+ recommended practise, which should reduce overhead.
130+
131+2010-07-08 Ted Gould <ted@gould.cx>
132+
133+ 0.2.2
134+
135 2010-07-07 Ted Gould <ted@gould.cx>
136
137 Merging this branch, but I think it's fixes must have gone in with another.
138
139=== modified file 'configure'
140--- configure 2010-07-08 15:23:57 +0000
141+++ configure 2010-07-15 15:45:53 +0000
142@@ -1,6 +1,6 @@
143 #! /bin/sh
144 # Guess values for system-dependent variables and create Makefiles.
145-# Generated by GNU Autoconf 2.65 for indicator-application 0.2.2.
146+# Generated by GNU Autoconf 2.65 for indicator-application 0.2.3.
147 #
148 # Report bugs to <ted@canonical.com>.
149 #
150@@ -703,8 +703,8 @@
151 # Identity of this package.
152 PACKAGE_NAME='indicator-application'
153 PACKAGE_TARNAME='indicator-application'
154-PACKAGE_VERSION='0.2.2'
155-PACKAGE_STRING='indicator-application 0.2.2'
156+PACKAGE_VERSION='0.2.3'
157+PACKAGE_STRING='indicator-application 0.2.3'
158 PACKAGE_BUGREPORT='ted@canonical.com'
159 PACKAGE_URL=''
160
161@@ -1505,7 +1505,7 @@
162 # Omit some internal or obsolete options to make the list less imposing.
163 # This message is too long to be a string in the A/UX 3.1 sh.
164 cat <<_ACEOF
165-\`configure' configures indicator-application 0.2.2 to adapt to many kinds of systems.
166+\`configure' configures indicator-application 0.2.3 to adapt to many kinds of systems.
167
168 Usage: $0 [OPTION]... [VAR=VALUE]...
169
170@@ -1576,7 +1576,7 @@
171
172 if test -n "$ac_init_help"; then
173 case $ac_init_help in
174- short | recursive ) echo "Configuration of indicator-application 0.2.2:";;
175+ short | recursive ) echo "Configuration of indicator-application 0.2.3:";;
176 esac
177 cat <<\_ACEOF
178
179@@ -1709,7 +1709,7 @@
180 test -n "$ac_init_help" && exit $ac_status
181 if $ac_init_version; then
182 cat <<\_ACEOF
183-indicator-application configure 0.2.2
184+indicator-application configure 0.2.3
185 generated by GNU Autoconf 2.65
186
187 Copyright (C) 2009 Free Software Foundation, Inc.
188@@ -1989,7 +1989,7 @@
189 This file contains any messages produced by compilers while
190 running configure, to aid debugging if configure makes a mistake.
191
192-It was created by indicator-application $as_me 0.2.2, which was
193+It was created by indicator-application $as_me 0.2.3, which was
194 generated by GNU Autoconf 2.65. Invocation command line was
195
196 $ $0 $@
197@@ -2803,7 +2803,7 @@
198
199 # Define the identity of the package.
200 PACKAGE=indicator-application
201- VERSION=0.2.2
202+ VERSION=0.2.3
203
204
205 cat >>confdefs.h <<_ACEOF
206@@ -13684,7 +13684,7 @@
207 # report actual input values of CONFIG_FILES etc. instead of their
208 # values after options handling.
209 ac_log="
210-This file was extended by indicator-application $as_me 0.2.2, which was
211+This file was extended by indicator-application $as_me 0.2.3, which was
212 generated by GNU Autoconf 2.65. Invocation command line was
213
214 CONFIG_FILES = $CONFIG_FILES
215@@ -13750,7 +13750,7 @@
216 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
217 ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
218 ac_cs_version="\\
219-indicator-application config.status 0.2.2
220+indicator-application config.status 0.2.3
221 configured by $0, generated by GNU Autoconf 2.65,
222 with options \\"\$ac_cs_config\\"
223
224
225=== modified file 'configure.ac'
226--- configure.ac 2010-07-08 15:08:02 +0000
227+++ configure.ac 2010-07-15 15:45:53 +0000
228@@ -1,11 +1,11 @@
229
230-AC_INIT(indicator-application, 0.2.2, ted@canonical.com)
231+AC_INIT(indicator-application, 0.2.3, ted@canonical.com)
232 AC_COPYRIGHT([Copyright 2009, 2010 Canonical])
233
234 AC_PREREQ(2.53)
235
236 AM_CONFIG_HEADER(config.h)
237-AM_INIT_AUTOMAKE(indicator-application, 0.2.2)
238+AM_INIT_AUTOMAKE(indicator-application, 0.2.3)
239
240 AM_MAINTAINER_MODE
241
242
243=== modified file 'debian/changelog'
244--- debian/changelog 2010-07-08 16:26:25 +0000
245+++ debian/changelog 2010-07-15 15:45:53 +0000
246@@ -1,3 +1,11 @@
247+indicator-application (0.2.3-0ubuntu1~ppa1) lucid; urgency=low
248+
249+ * New upstream release.
250+ * Fixing test for slower machines
251+ * Adding an Approver API to remove things from the AppIndicators.
252+
253+ -- Ted Gould <ted@ubuntu.com> Thu, 15 Jul 2010 10:22:33 -0500
254+
255 indicator-application (0.2.2-0ubuntu1) maverick; urgency=low
256
257 * debian/control, debian/rules:
258
259=== modified file 'docs/reference/html/ch01.html'
260--- docs/reference/html/ch01.html 2010-06-21 19:22:34 +0000
261+++ docs/reference/html/ch01.html 2010-07-15 15:45:53 +0000
262@@ -21,7 +21,7 @@
263 </tr></table>
264 <div class="chapter" title="Base Classes for Applications">
265 <div class="titlepage"><div><div><h2 class="title">
266-<a name="id460829"></a>Base Classes for Applications</h2></div></div></div>
267+<a name="id495610"></a>Base Classes for Applications</h2></div></div></div>
268 <div class="toc"><dl><dt>
269 <span class="refentrytitle"><a href="libappindicator-app-indicator.html">AppIndicator</a></span><span class="refpurpose"> — An object to put application information
270 into the panel.</span>
271
272=== modified file 'docs/reference/html/index.html'
273--- docs/reference/html/index.html 2010-06-03 19:00:39 +0000
274+++ docs/reference/html/index.html 2010-07-15 15:45:53 +0000
275@@ -15,7 +15,7 @@
276 <div>
277 <div><table class="navigation" id="top" width="100%" cellpadding="2" cellspacing="0"><tr><th valign="middle"><p class="title">libappindicator Reference Manual</p></th></tr></table></div>
278 <div><p class="releaseinfo">
279- for libappindicator 0.2.0
280+ for libappindicator 0.2.2
281 </p></div>
282 </div>
283 <hr>
284
285=== modified file 'docs/reference/html/libappindicator-app-indicator.html'
286--- docs/reference/html/libappindicator-app-indicator.html 2010-06-21 19:17:44 +0000
287+++ docs/reference/html/libappindicator-app-indicator.html 2010-07-15 15:45:53 +0000
288@@ -66,48 +66,48 @@
289 <a class="link" href="libappindicator-app-indicator.html#AppIndicatorPrivate" title="AppIndicatorPrivate">AppIndicatorPrivate</a>;
290 <a class="link" href="libappindicator-app-indicator.html#AppIndicator-struct" title="AppIndicator">AppIndicator</a>;
291 <a class="link" href="libappindicator-app-indicator.html#AppIndicatorClass" title="AppIndicatorClass">AppIndicatorClass</a>;
292-<a href="http://library.gnome.org/devel/gobject/unstable/gobject-Type-Information.html#GType"><span class="returnvalue">GType</span></a> <a class="link" href="libappindicator-app-indicator.html#app-indicator-get-type" title="app_indicator_get_type ()">app_indicator_get_type</a> (<em class="parameter"><code><span class="type">void</span></code></em>);
293-<a class="link" href="libappindicator-app-indicator.html#AppIndicator"><span class="returnvalue">AppIndicator</span></a> * <a class="link" href="libappindicator-app-indicator.html#app-indicator-new" title="app_indicator_new ()">app_indicator_new</a> (<em class="parameter"><code>const <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> *id</code></em>,
294- <em class="parameter"><code>const <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> *icon_name</code></em>,
295+<a href="/usr/share/gtk-doc/html/gobject/gobject-Type-Information.html#GType"><span class="returnvalue">GType</span></a> <a class="link" href="libappindicator-app-indicator.html#app-indicator-get-type" title="app_indicator_get_type ()">app_indicator_get_type</a> (<em class="parameter"><code><span class="type">void</span></code></em>);
296+<a class="link" href="libappindicator-app-indicator.html#AppIndicator"><span class="returnvalue">AppIndicator</span></a> * <a class="link" href="libappindicator-app-indicator.html#app-indicator-new" title="app_indicator_new ()">app_indicator_new</a> (<em class="parameter"><code>const <a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> *id</code></em>,
297+ <em class="parameter"><code>const <a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> *icon_name</code></em>,
298 <em class="parameter"><code><a class="link" href="libappindicator-app-indicator.html#AppIndicatorCategory" title="enum AppIndicatorCategory"><span class="type">AppIndicatorCategory</span></a> category</code></em>);
299-<a class="link" href="libappindicator-app-indicator.html#AppIndicator"><span class="returnvalue">AppIndicator</span></a> * <a class="link" href="libappindicator-app-indicator.html#app-indicator-new-with-path" title="app_indicator_new_with_path ()">app_indicator_new_with_path</a> (<em class="parameter"><code>const <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> *id</code></em>,
300- <em class="parameter"><code>const <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> *icon_name</code></em>,
301+<a class="link" href="libappindicator-app-indicator.html#AppIndicator"><span class="returnvalue">AppIndicator</span></a> * <a class="link" href="libappindicator-app-indicator.html#app-indicator-new-with-path" title="app_indicator_new_with_path ()">app_indicator_new_with_path</a> (<em class="parameter"><code>const <a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> *id</code></em>,
302+ <em class="parameter"><code>const <a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> *icon_name</code></em>,
303 <em class="parameter"><code><a class="link" href="libappindicator-app-indicator.html#AppIndicatorCategory" title="enum AppIndicatorCategory"><span class="type">AppIndicatorCategory</span></a> category</code></em>,
304- <em class="parameter"><code>const <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> *icon_path</code></em>);
305+ <em class="parameter"><code>const <a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> *icon_path</code></em>);
306 <span class="returnvalue">void</span> <a class="link" href="libappindicator-app-indicator.html#app-indicator-set-status" title="app_indicator_set_status ()">app_indicator_set_status</a> (<em class="parameter"><code><a class="link" href="libappindicator-app-indicator.html#AppIndicator"><span class="type">AppIndicator</span></a> *self</code></em>,
307 <em class="parameter"><code><a class="link" href="libappindicator-app-indicator.html#AppIndicatorStatus" title="enum AppIndicatorStatus"><span class="type">AppIndicatorStatus</span></a> status</code></em>);
308 <span class="returnvalue">void</span> <a class="link" href="libappindicator-app-indicator.html#app-indicator-set-attention-icon" title="app_indicator_set_attention_icon ()">app_indicator_set_attention_icon</a> (<em class="parameter"><code><a class="link" href="libappindicator-app-indicator.html#AppIndicator"><span class="type">AppIndicator</span></a> *self</code></em>,
309- <em class="parameter"><code>const <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> *icon_name</code></em>);
310+ <em class="parameter"><code>const <a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> *icon_name</code></em>);
311 <span class="returnvalue">void</span> <a class="link" href="libappindicator-app-indicator.html#app-indicator-set-menu" title="app_indicator_set_menu ()">app_indicator_set_menu</a> (<em class="parameter"><code><a class="link" href="libappindicator-app-indicator.html#AppIndicator"><span class="type">AppIndicator</span></a> *self</code></em>,
312 <em class="parameter"><code><a href="/usr/share/gtk-doc/html/gtk/GtkMenu.html"><span class="type">GtkMenu</span></a> *menu</code></em>);
313 <span class="returnvalue">void</span> <a class="link" href="libappindicator-app-indicator.html#app-indicator-set-icon" title="app_indicator_set_icon ()">app_indicator_set_icon</a> (<em class="parameter"><code><a class="link" href="libappindicator-app-indicator.html#AppIndicator"><span class="type">AppIndicator</span></a> *self</code></em>,
314- <em class="parameter"><code>const <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> *icon_name</code></em>);
315-const <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gchar"><span class="returnvalue">gchar</span></a> * <a class="link" href="libappindicator-app-indicator.html#app-indicator-get-id" title="app_indicator_get_id ()">app_indicator_get_id</a> (<em class="parameter"><code><a class="link" href="libappindicator-app-indicator.html#AppIndicator"><span class="type">AppIndicator</span></a> *self</code></em>);
316+ <em class="parameter"><code>const <a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> *icon_name</code></em>);
317+const <a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gchar"><span class="returnvalue">gchar</span></a> * <a class="link" href="libappindicator-app-indicator.html#app-indicator-get-id" title="app_indicator_get_id ()">app_indicator_get_id</a> (<em class="parameter"><code><a class="link" href="libappindicator-app-indicator.html#AppIndicator"><span class="type">AppIndicator</span></a> *self</code></em>);
318 <a class="link" href="libappindicator-app-indicator.html#AppIndicatorCategory" title="enum AppIndicatorCategory"><span class="returnvalue">AppIndicatorCategory</span></a> <a class="link" href="libappindicator-app-indicator.html#app-indicator-get-category" title="app_indicator_get_category ()">app_indicator_get_category</a> (<em class="parameter"><code><a class="link" href="libappindicator-app-indicator.html#AppIndicator"><span class="type">AppIndicator</span></a> *self</code></em>);
319 <a class="link" href="libappindicator-app-indicator.html#AppIndicatorStatus" title="enum AppIndicatorStatus"><span class="returnvalue">AppIndicatorStatus</span></a> <a class="link" href="libappindicator-app-indicator.html#app-indicator-get-status" title="app_indicator_get_status ()">app_indicator_get_status</a> (<em class="parameter"><code><a class="link" href="libappindicator-app-indicator.html#AppIndicator"><span class="type">AppIndicator</span></a> *self</code></em>);
320-const <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gchar"><span class="returnvalue">gchar</span></a> * <a class="link" href="libappindicator-app-indicator.html#app-indicator-get-icon" title="app_indicator_get_icon ()">app_indicator_get_icon</a> (<em class="parameter"><code><a class="link" href="libappindicator-app-indicator.html#AppIndicator"><span class="type">AppIndicator</span></a> *self</code></em>);
321-const <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gchar"><span class="returnvalue">gchar</span></a> * <a class="link" href="libappindicator-app-indicator.html#app-indicator-get-attention-icon" title="app_indicator_get_attention_icon ()">app_indicator_get_attention_icon</a> (<em class="parameter"><code><a class="link" href="libappindicator-app-indicator.html#AppIndicator"><span class="type">AppIndicator</span></a> *self</code></em>);
322+const <a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gchar"><span class="returnvalue">gchar</span></a> * <a class="link" href="libappindicator-app-indicator.html#app-indicator-get-icon" title="app_indicator_get_icon ()">app_indicator_get_icon</a> (<em class="parameter"><code><a class="link" href="libappindicator-app-indicator.html#AppIndicator"><span class="type">AppIndicator</span></a> *self</code></em>);
323+const <a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gchar"><span class="returnvalue">gchar</span></a> * <a class="link" href="libappindicator-app-indicator.html#app-indicator-get-attention-icon" title="app_indicator_get_attention_icon ()">app_indicator_get_attention_icon</a> (<em class="parameter"><code><a class="link" href="libappindicator-app-indicator.html#AppIndicator"><span class="type">AppIndicator</span></a> *self</code></em>);
324 <a href="/usr/share/gtk-doc/html/gtk/GtkMenu.html"><span class="returnvalue">GtkMenu</span></a> * <a class="link" href="libappindicator-app-indicator.html#app-indicator-get-menu" title="app_indicator_get_menu ()">app_indicator_get_menu</a> (<em class="parameter"><code><a class="link" href="libappindicator-app-indicator.html#AppIndicator"><span class="type">AppIndicator</span></a> *self</code></em>);
325 </pre>
326 </div>
327 <div class="refsect1" title="Object Hierarchy">
328 <a name="libappindicator-app-indicator.object-hierarchy"></a><h2>Object Hierarchy</h2>
329 <pre class="synopsis">
330- <a href="http://library.gnome.org/devel/gobject/unstable/gobject-The-Base-Object-Type.html#GObject">GObject</a>
331+ <a href="/usr/share/gtk-doc/html/gobject/gobject-The-Base-Object-Type.html#GObject">GObject</a>
332 +----AppIndicator
333 </pre>
334 </div>
335 <div class="refsect1" title="Properties">
336 <a name="libappindicator-app-indicator.properties"></a><h2>Properties</h2>
337 <pre class="synopsis">
338- "<a class="link" href="libappindicator-app-indicator.html#AppIndicator--attention-icon-name" title='The "attention-icon-name" property'>attention-icon-name</a>" <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a>* : Read / Write
339- "<a class="link" href="libappindicator-app-indicator.html#AppIndicator--category" title='The "category" property'>category</a>" <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a>* : Read / Write / Construct Only
340- "<a class="link" href="libappindicator-app-indicator.html#AppIndicator--connected" title='The "connected" property'>connected</a>" <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gboolean"><span class="type">gboolean</span></a> : Read
341- "<a class="link" href="libappindicator-app-indicator.html#AppIndicator--icon-name" title='The "icon-name" property'>icon-name</a>" <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a>* : Read / Write / Construct
342- "<a class="link" href="libappindicator-app-indicator.html#AppIndicator--icon-theme-path" title='The "icon-theme-path" property'>icon-theme-path</a>" <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a>* : Read / Write / Construct Only
343- "<a class="link" href="libappindicator-app-indicator.html#AppIndicator--id" title='The "id" property'>id</a>" <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a>* : Read / Write / Construct Only
344+ "<a class="link" href="libappindicator-app-indicator.html#AppIndicator--attention-icon-name" title='The "attention-icon-name" property'>attention-icon-name</a>" <a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a>* : Read / Write
345+ "<a class="link" href="libappindicator-app-indicator.html#AppIndicator--category" title='The "category" property'>category</a>" <a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a>* : Read / Write / Construct Only
346+ "<a class="link" href="libappindicator-app-indicator.html#AppIndicator--connected" title='The "connected" property'>connected</a>" <a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gboolean"><span class="type">gboolean</span></a> : Read
347+ "<a class="link" href="libappindicator-app-indicator.html#AppIndicator--icon-name" title='The "icon-name" property'>icon-name</a>" <a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a>* : Read / Write
348+ "<a class="link" href="libappindicator-app-indicator.html#AppIndicator--icon-theme-path" title='The "icon-theme-path" property'>icon-theme-path</a>" <a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a>* : Read / Write / Construct Only
349+ "<a class="link" href="libappindicator-app-indicator.html#AppIndicator--id" title='The "id" property'>id</a>" <a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a>* : Read / Write / Construct Only
350 "<a class="link" href="libappindicator-app-indicator.html#AppIndicator--menu" title='The "menu" property'>menu</a>" <span class="type">DBusGObjectPath</span>* : Read
351- "<a class="link" href="libappindicator-app-indicator.html#AppIndicator--status" title='The "status" property'>status</a>" <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a>* : Read / Write
352+ "<a class="link" href="libappindicator-app-indicator.html#AppIndicator--status" title='The "status" property'>status</a>" <a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a>* : Read / Write
353 </pre>
354 </div>
355 <div class="refsect1" title="Signals">
356@@ -139,7 +139,7 @@
357 <pre class="programlisting">#define APP_INDICATOR_TYPE (app_indicator_get_type ())
358 </pre>
359 <p>
360-Get the <a href="http://library.gnome.org/devel/gobject/unstable/gobject-Type-Information.html#GType"><span class="type">GType</span></a> for a <a class="link" href="libappindicator-app-indicator.html#AppIndicator"><span class="type">AppIndicator</span></a>.
361+Get the <a href="/usr/share/gtk-doc/html/gobject/gobject-Type-Information.html#GType"><span class="type">GType</span></a> for a <a class="link" href="libappindicator-app-indicator.html#AppIndicator"><span class="type">AppIndicator</span></a>.
362 </p>
363 </div>
364 <hr>
365@@ -148,7 +148,7 @@
366 <pre class="programlisting">#define APP_INDICATOR(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), APP_INDICATOR_TYPE, AppIndicator))
367 </pre>
368 <p>
369-Safely convert a <a href="http://library.gnome.org/devel/gobject/unstable/gobject-The-Base-Object-Type.html#GObject"><span class="type">GObject</span></a> into an <a class="link" href="libappindicator-app-indicator.html#AppIndicator"><span class="type">AppIndicator</span></a>.
370+Safely convert a <a href="/usr/share/gtk-doc/html/gobject/gobject-The-Base-Object-Type.html#GObject"><span class="type">GObject</span></a> into an <a class="link" href="libappindicator-app-indicator.html#AppIndicator"><span class="type">AppIndicator</span></a>.
371 </p>
372 <div class="variablelist"><table border="0">
373 <col align="left" valign="top">
374@@ -165,14 +165,14 @@
375 <pre class="programlisting">#define APP_INDICATOR_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), APP_INDICATOR_TYPE, AppIndicatorClass))
376 </pre>
377 <p>
378-Safely convert a <a href="http://library.gnome.org/devel/gobject/unstable/gobject-The-Base-Object-Type.html#GObjectClass"><span class="type">GObjectClass</span></a> into a <a class="link" href="libappindicator-app-indicator.html#AppIndicatorClass" title="AppIndicatorClass"><span class="type">AppIndicatorClass</span></a>.
379+Safely convert a <a href="/usr/share/gtk-doc/html/gobject/gobject-The-Base-Object-Type.html#GObjectClass"><span class="type">GObjectClass</span></a> into a <a class="link" href="libappindicator-app-indicator.html#AppIndicatorClass" title="AppIndicatorClass"><span class="type">AppIndicatorClass</span></a>.
380 </p>
381 <div class="variablelist"><table border="0">
382 <col align="left" valign="top">
383 <tbody><tr>
384 <td><p><span class="term"><em class="parameter"><code>klass</code></em> :</span></p></td>
385 <td>
386-<a href="http://library.gnome.org/devel/gobject/unstable/gobject-The-Base-Object-Type.html#GObjectClass"><span class="type">GObjectClass</span></a> based class to convert.
387+<a href="/usr/share/gtk-doc/html/gobject/gobject-The-Base-Object-Type.html#GObjectClass"><span class="type">GObjectClass</span></a> based class to convert.
388 </td>
389 </tr></tbody>
390 </table></div>
391@@ -189,7 +189,7 @@
392 <col align="left" valign="top">
393 <tbody><tr>
394 <td><p><span class="term"><em class="parameter"><code>obj</code></em> :</span></p></td>
395-<td>An <a href="http://library.gnome.org/devel/gobject/unstable/gobject-The-Base-Object-Type.html#GObject"><span class="type">GObject</span></a> to check
396+<td>An <a href="/usr/share/gtk-doc/html/gobject/gobject-The-Base-Object-Type.html#GObject"><span class="type">GObject</span></a> to check
397 </td>
398 </tr></tbody>
399 </table></div>
400@@ -206,7 +206,7 @@
401 <col align="left" valign="top">
402 <tbody><tr>
403 <td><p><span class="term"><em class="parameter"><code>klass</code></em> :</span></p></td>
404-<td>An <a href="http://library.gnome.org/devel/gobject/unstable/gobject-The-Base-Object-Type.html#GObjectClass"><span class="type">GObjectClass</span></a> to check
405+<td>An <a href="/usr/share/gtk-doc/html/gobject/gobject-The-Base-Object-Type.html#GObjectClass"><span class="type">GObjectClass</span></a> to check
406 </td>
407 </tr></tbody>
408 </table></div>
409@@ -223,7 +223,7 @@
410 <col align="left" valign="top">
411 <tbody><tr>
412 <td><p><span class="term"><em class="parameter"><code>obj</code></em> :</span></p></td>
413-<td>A <a href="http://library.gnome.org/devel/gobject/unstable/gobject-The-Base-Object-Type.html#GObject"><span class="type">GObject</span></a> in the class hierarchy of <a class="link" href="libappindicator-app-indicator.html#AppIndicator"><span class="type">AppIndicator</span></a>.
414+<td>A <a href="/usr/share/gtk-doc/html/gobject/gobject-The-Base-Object-Type.html#GObject"><span class="type">GObject</span></a> in the class hierarchy of <a class="link" href="libappindicator-app-indicator.html#AppIndicator"><span class="type">AppIndicator</span></a>.
415 </td>
416 </tr></tbody>
417 </table></div>
418@@ -405,7 +405,7 @@
419 <col align="left" valign="top">
420 <tbody>
421 <tr>
422-<td><p><span class="term"><a href="http://library.gnome.org/devel/gobject/unstable/gobject-The-Base-Object-Type.html#GObjectClass"><span class="type">GObjectClass</span></a> <em class="structfield"><code><a name="AppIndicatorClass.parent-class"></a>parent_class</code></em>;</span></p></td>
423+<td><p><span class="term"><a href="/usr/share/gtk-doc/html/gobject/gobject-The-Base-Object-Type.html#GObjectClass"><span class="type">GObjectClass</span></a> <em class="structfield"><code><a name="AppIndicatorClass.parent-class"></a>parent_class</code></em>;</span></p></td>
424 <td>Mia familia
425 </td>
426 </tr>
427@@ -457,15 +457,15 @@
428 <hr>
429 <div class="refsect2" title="app_indicator_get_type ()">
430 <a name="app-indicator-get-type"></a><h3>app_indicator_get_type ()</h3>
431-<pre class="programlisting"><a href="http://library.gnome.org/devel/gobject/unstable/gobject-Type-Information.html#GType"><span class="returnvalue">GType</span></a> app_indicator_get_type (<em class="parameter"><code><span class="type">void</span></code></em>);</pre>
432+<pre class="programlisting"><a href="/usr/share/gtk-doc/html/gobject/gobject-Type-Information.html#GType"><span class="returnvalue">GType</span></a> app_indicator_get_type (<em class="parameter"><code><span class="type">void</span></code></em>);</pre>
433 <p>
434-Generates or returns the unique <a href="http://library.gnome.org/devel/gobject/unstable/gobject-Type-Information.html#GType"><span class="type">GType</span></a> for <a class="link" href="libappindicator-app-indicator.html#AppIndicator"><span class="type">AppIndicator</span></a>.
435+Generates or returns the unique <a href="/usr/share/gtk-doc/html/gobject/gobject-Type-Information.html#GType"><span class="type">GType</span></a> for <a class="link" href="libappindicator-app-indicator.html#AppIndicator"><span class="type">AppIndicator</span></a>.
436 </p>
437 <div class="variablelist"><table border="0">
438 <col align="left" valign="top">
439 <tbody><tr>
440 <td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
441-<td> A unique <a href="http://library.gnome.org/devel/gobject/unstable/gobject-Type-Information.html#GType"><span class="type">GType</span></a> for <a class="link" href="libappindicator-app-indicator.html#AppIndicator"><span class="type">AppIndicator</span></a> objects.
442+<td> A unique <a href="/usr/share/gtk-doc/html/gobject/gobject-Type-Information.html#GType"><span class="type">GType</span></a> for <a class="link" href="libappindicator-app-indicator.html#AppIndicator"><span class="type">AppIndicator</span></a> objects.
443 </td>
444 </tr></tbody>
445 </table></div>
446@@ -473,8 +473,8 @@
447 <hr>
448 <div class="refsect2" title="app_indicator_new ()">
449 <a name="app-indicator-new"></a><h3>app_indicator_new ()</h3>
450-<pre class="programlisting"><a class="link" href="libappindicator-app-indicator.html#AppIndicator"><span class="returnvalue">AppIndicator</span></a> * app_indicator_new (<em class="parameter"><code>const <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> *id</code></em>,
451- <em class="parameter"><code>const <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> *icon_name</code></em>,
452+<pre class="programlisting"><a class="link" href="libappindicator-app-indicator.html#AppIndicator"><span class="returnvalue">AppIndicator</span></a> * app_indicator_new (<em class="parameter"><code>const <a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> *id</code></em>,
453+ <em class="parameter"><code>const <a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> *icon_name</code></em>,
454 <em class="parameter"><code><a class="link" href="libappindicator-app-indicator.html#AppIndicatorCategory" title="enum AppIndicatorCategory"><span class="type">AppIndicatorCategory</span></a> category</code></em>);</pre>
455 <p>
456 Creates a new <a class="link" href="libappindicator-app-indicator.html#AppIndicator"><span class="type">AppIndicator</span></a> setting the properties:
457@@ -511,10 +511,10 @@
458 <hr>
459 <div class="refsect2" title="app_indicator_new_with_path ()">
460 <a name="app-indicator-new-with-path"></a><h3>app_indicator_new_with_path ()</h3>
461-<pre class="programlisting"><a class="link" href="libappindicator-app-indicator.html#AppIndicator"><span class="returnvalue">AppIndicator</span></a> * app_indicator_new_with_path (<em class="parameter"><code>const <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> *id</code></em>,
462- <em class="parameter"><code>const <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> *icon_name</code></em>,
463+<pre class="programlisting"><a class="link" href="libappindicator-app-indicator.html#AppIndicator"><span class="returnvalue">AppIndicator</span></a> * app_indicator_new_with_path (<em class="parameter"><code>const <a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> *id</code></em>,
464+ <em class="parameter"><code>const <a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> *icon_name</code></em>,
465 <em class="parameter"><code><a class="link" href="libappindicator-app-indicator.html#AppIndicatorCategory" title="enum AppIndicatorCategory"><span class="type">AppIndicatorCategory</span></a> category</code></em>,
466- <em class="parameter"><code>const <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> *icon_path</code></em>);</pre>
467+ <em class="parameter"><code>const <a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> *icon_path</code></em>);</pre>
468 <p>
469 Creates a new <a class="link" href="libappindicator-app-indicator.html#AppIndicator"><span class="type">AppIndicator</span></a> setting the properties:
470 <a class="link" href="libappindicator-app-indicator.html#AppIndicator--id" title='The "id" property'><span class="type">"id"</span></a> with <em class="parameter"><code>id</code></em>, <a class="link" href="libappindicator-app-indicator.html#AppIndicator--category" title='The "category" property'><span class="type">"category"</span></a>
471@@ -580,7 +580,7 @@
472 <div class="refsect2" title="app_indicator_set_attention_icon ()">
473 <a name="app-indicator-set-attention-icon"></a><h3>app_indicator_set_attention_icon ()</h3>
474 <pre class="programlisting"><span class="returnvalue">void</span> app_indicator_set_attention_icon (<em class="parameter"><code><a class="link" href="libappindicator-app-indicator.html#AppIndicator"><span class="type">AppIndicator</span></a> *self</code></em>,
475- <em class="parameter"><code>const <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> *icon_name</code></em>);</pre>
476+ <em class="parameter"><code>const <a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> *icon_name</code></em>);</pre>
477 <p>
478 Wrapper function for property <a class="link" href="libappindicator-app-indicator.html#AppIndicator--attention-icon-name" title='The "attention-icon-name" property'><span class="type">"attention-icon-name"</span></a>.
479 </p>
480@@ -632,7 +632,7 @@
481 <div class="refsect2" title="app_indicator_set_icon ()">
482 <a name="app-indicator-set-icon"></a><h3>app_indicator_set_icon ()</h3>
483 <pre class="programlisting"><span class="returnvalue">void</span> app_indicator_set_icon (<em class="parameter"><code><a class="link" href="libappindicator-app-indicator.html#AppIndicator"><span class="type">AppIndicator</span></a> *self</code></em>,
484- <em class="parameter"><code>const <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> *icon_name</code></em>);</pre>
485+ <em class="parameter"><code>const <a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> *icon_name</code></em>);</pre>
486 <p>
487 Sets the default icon to use when the status is active but
488 not set to attention. In most cases, this should be the
489@@ -658,7 +658,7 @@
490 <hr>
491 <div class="refsect2" title="app_indicator_get_id ()">
492 <a name="app-indicator-get-id"></a><h3>app_indicator_get_id ()</h3>
493-<pre class="programlisting">const <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gchar"><span class="returnvalue">gchar</span></a> * app_indicator_get_id (<em class="parameter"><code><a class="link" href="libappindicator-app-indicator.html#AppIndicator"><span class="type">AppIndicator</span></a> *self</code></em>);</pre>
494+<pre class="programlisting">const <a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gchar"><span class="returnvalue">gchar</span></a> * app_indicator_get_id (<em class="parameter"><code><a class="link" href="libappindicator-app-indicator.html#AppIndicator"><span class="type">AppIndicator</span></a> *self</code></em>);</pre>
495 <p>
496 Wrapper function for property <a class="link" href="libappindicator-app-indicator.html#AppIndicator--id" title='The "id" property'><span class="type">"id"</span></a>.
497 </p>
498@@ -727,7 +727,7 @@
499 <hr>
500 <div class="refsect2" title="app_indicator_get_icon ()">
501 <a name="app-indicator-get-icon"></a><h3>app_indicator_get_icon ()</h3>
502-<pre class="programlisting">const <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gchar"><span class="returnvalue">gchar</span></a> * app_indicator_get_icon (<em class="parameter"><code><a class="link" href="libappindicator-app-indicator.html#AppIndicator"><span class="type">AppIndicator</span></a> *self</code></em>);</pre>
503+<pre class="programlisting">const <a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gchar"><span class="returnvalue">gchar</span></a> * app_indicator_get_icon (<em class="parameter"><code><a class="link" href="libappindicator-app-indicator.html#AppIndicator"><span class="type">AppIndicator</span></a> *self</code></em>);</pre>
504 <p>
505 Wrapper function for property <a class="link" href="libappindicator-app-indicator.html#AppIndicator--icon-name" title='The "icon-name" property'><span class="type">"icon-name"</span></a>.
506 </p>
507@@ -750,7 +750,7 @@
508 <hr>
509 <div class="refsect2" title="app_indicator_get_attention_icon ()">
510 <a name="app-indicator-get-attention-icon"></a><h3>app_indicator_get_attention_icon ()</h3>
511-<pre class="programlisting">const <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gchar"><span class="returnvalue">gchar</span></a> * app_indicator_get_attention_icon (<em class="parameter"><code><a class="link" href="libappindicator-app-indicator.html#AppIndicator"><span class="type">AppIndicator</span></a> *self</code></em>);</pre>
512+<pre class="programlisting">const <a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gchar"><span class="returnvalue">gchar</span></a> * app_indicator_get_attention_icon (<em class="parameter"><code><a class="link" href="libappindicator-app-indicator.html#AppIndicator"><span class="type">AppIndicator</span></a> *self</code></em>);</pre>
513 <p>
514 Wrapper function for property <a class="link" href="libappindicator-app-indicator.html#AppIndicator--attention-icon-name" title='The "attention-icon-name" property'><span class="type">"attention-icon-name"</span></a>.
515 </p>
516@@ -788,7 +788,7 @@
517 </tr>
518 <tr>
519 <td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
520-<td> A <a href="/usr/share/gtk-doc/html/gtk/GtkMenu.html"><span class="type">GtkMenu</span></a> object or <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a> if one hasn't been set.
521+<td> A <a href="/usr/share/gtk-doc/html/gtk/GtkMenu.html"><span class="type">GtkMenu</span></a> object or <a href="/usr/share/gtk-doc/html/glib/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a> if one hasn't been set.
522 </td>
523 </tr>
524 </tbody>
525@@ -799,7 +799,7 @@
526 <a name="libappindicator-app-indicator.property-details"></a><h2>Property Details</h2>
527 <div class="refsect2" title='The "attention-icon-name" property'>
528 <a name="AppIndicator--attention-icon-name"></a><h3>The <code class="literal">"attention-icon-name"</code> property</h3>
529-<pre class="programlisting"> "attention-icon-name" <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a>* : Read / Write</pre>
530+<pre class="programlisting"> "attention-icon-name" <a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a>* : Read / Write</pre>
531 <p>
532 If the indicator sets it's status to <a class="link" href="libappindicator-app-indicator.html#APP-INDICATOR-STATUS-ATTENTION:CAPS"><code class="literal">APP_INDICATOR_STATUS_ATTENTION</code></a>
533 then this icon is shown.
534@@ -809,7 +809,7 @@
535 <hr>
536 <div class="refsect2" title='The "category" property'>
537 <a name="AppIndicator--category"></a><h3>The <code class="literal">"category"</code> property</h3>
538-<pre class="programlisting"> "category" <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a>* : Read / Write / Construct Only</pre>
539+<pre class="programlisting"> "category" <a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a>* : Read / Write / Construct Only</pre>
540 <p>
541 The type of indicator that this represents. Please don't use 'Other'.
542 Defaults to 'ApplicationStatus'.
543@@ -819,9 +819,9 @@
544 <hr>
545 <div class="refsect2" title='The "connected" property'>
546 <a name="AppIndicator--connected"></a><h3>The <code class="literal">"connected"</code> property</h3>
547-<pre class="programlisting"> "connected" <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gboolean"><span class="type">gboolean</span></a> : Read</pre>
548+<pre class="programlisting"> "connected" <a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gboolean"><span class="type">gboolean</span></a> : Read</pre>
549 <p>
550-Pretty simple, <a href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#TRUE:CAPS"><code class="literal">TRUE</code></a> if we have a reasonable expectation of being
551+Pretty simple, <a href="/usr/share/gtk-doc/html/glib/glib-Standard-Macros.html#TRUE:CAPS"><code class="literal">TRUE</code></a> if we have a reasonable expectation of being
552 displayed through this object. You should hide your TrayIcon if so.
553 </p>
554 <p>Default value: FALSE</p>
555@@ -829,7 +829,7 @@
556 <hr>
557 <div class="refsect2" title='The "icon-name" property'>
558 <a name="AppIndicator--icon-name"></a><h3>The <code class="literal">"icon-name"</code> property</h3>
559-<pre class="programlisting"> "icon-name" <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a>* : Read / Write / Construct</pre>
560+<pre class="programlisting"> "icon-name" <a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a>* : Read / Write</pre>
561 <p>
562 The name of the regular icon that is shown for the indicator.
563 </p>
564@@ -838,7 +838,7 @@
565 <hr>
566 <div class="refsect2" title='The "icon-theme-path" property'>
567 <a name="AppIndicator--icon-theme-path"></a><h3>The <code class="literal">"icon-theme-path"</code> property</h3>
568-<pre class="programlisting"> "icon-theme-path" <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a>* : Read / Write / Construct Only</pre>
569+<pre class="programlisting"> "icon-theme-path" <a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a>* : Read / Write / Construct Only</pre>
570 <p>
571 An additional place to look for icon names that may be installed by the
572 application.
573@@ -848,7 +848,7 @@
574 <hr>
575 <div class="refsect2" title='The "id" property'>
576 <a name="AppIndicator--id"></a><h3>The <code class="literal">"id"</code> property</h3>
577-<pre class="programlisting"> "id" <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a>* : Read / Write / Construct Only</pre>
578+<pre class="programlisting"> "id" <a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a>* : Read / Write / Construct Only</pre>
579 <p>
580 The ID for this indicator, which should be unique, but used consistently
581 by this program and its indicator.
582@@ -866,7 +866,7 @@
583 <hr>
584 <div class="refsect2" title='The "status" property'>
585 <a name="AppIndicator--status"></a><h3>The <code class="literal">"status"</code> property</h3>
586-<pre class="programlisting"> "status" <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a>* : Read / Write</pre>
587+<pre class="programlisting"> "status" <a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a>* : Read / Write</pre>
588 <p>
589 Whether the indicator is shown or requests attention. Defaults to
590 'Passive'.
591@@ -879,8 +879,8 @@
592 <div class="refsect2" title='The "connection-changed" signal'>
593 <a name="AppIndicator-connection-changed"></a><h3>The <code class="literal">"connection-changed"</code> signal</h3>
594 <pre class="programlisting"><span class="returnvalue">void</span> user_function (<a class="link" href="libappindicator-app-indicator.html#AppIndicator"><span class="type">AppIndicator</span></a> *arg0,
595- <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gboolean"><span class="type">gboolean</span></a> arg1,
596- <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gpointer"><span class="type">gpointer</span></a> user_data) : Run Last</pre>
597+ <a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gboolean"><span class="type">gboolean</span></a> arg1,
598+ <a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gpointer"><span class="type">gpointer</span></a> user_data) : Run Last</pre>
599 <p>
600 Signaled when we connect to a watcher, or when it drops away.
601 </p>
602@@ -908,7 +908,7 @@
603 <div class="refsect2" title='The "new-attention-icon" signal'>
604 <a name="AppIndicator-new-attention-icon"></a><h3>The <code class="literal">"new-attention-icon"</code> signal</h3>
605 <pre class="programlisting"><span class="returnvalue">void</span> user_function (<a class="link" href="libappindicator-app-indicator.html#AppIndicator"><span class="type">AppIndicator</span></a> *arg0,
606- <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gpointer"><span class="type">gpointer</span></a> user_data) : Run Last</pre>
607+ <a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gpointer"><span class="type">gpointer</span></a> user_data) : Run Last</pre>
608 <p>
609 Emitted when <a class="link" href="libappindicator-app-indicator.html#AppIndicator--attention-icon-name" title='The "attention-icon-name" property'><span class="type">"attention-icon-name"</span></a> is changed
610 </p>
611@@ -931,7 +931,7 @@
612 <div class="refsect2" title='The "new-icon" signal'>
613 <a name="AppIndicator-new-icon"></a><h3>The <code class="literal">"new-icon"</code> signal</h3>
614 <pre class="programlisting"><span class="returnvalue">void</span> user_function (<a class="link" href="libappindicator-app-indicator.html#AppIndicator"><span class="type">AppIndicator</span></a> *arg0,
615- <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gpointer"><span class="type">gpointer</span></a> user_data) : Run Last</pre>
616+ <a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gpointer"><span class="type">gpointer</span></a> user_data) : Run Last</pre>
617 <p>
618 Emitted when <a class="link" href="libappindicator-app-indicator.html#AppIndicator--icon-name" title='The "icon-name" property'><span class="type">"icon-name"</span></a> is changed
619 </p>
620@@ -954,8 +954,8 @@
621 <div class="refsect2" title='The "new-status" signal'>
622 <a name="AppIndicator-new-status"></a><h3>The <code class="literal">"new-status"</code> signal</h3>
623 <pre class="programlisting"><span class="returnvalue">void</span> user_function (<a class="link" href="libappindicator-app-indicator.html#AppIndicator"><span class="type">AppIndicator</span></a> *arg0,
624- <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> *arg1,
625- <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gpointer"><span class="type">gpointer</span></a> user_data) : Run Last</pre>
626+ <a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> *arg1,
627+ <a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gpointer"><span class="type">gpointer</span></a> user_data) : Run Last</pre>
628 <p>
629 Emitted when <a class="link" href="libappindicator-app-indicator.html#AppIndicator--status" title='The "status" property'><span class="type">"status"</span></a> is changed
630 </p>
631
632=== modified file 'docs/reference/html/object-tree.html'
633--- docs/reference/html/object-tree.html 2010-06-21 19:17:44 +0000
634+++ docs/reference/html/object-tree.html 2010-07-15 15:45:53 +0000
635@@ -23,7 +23,7 @@
636 <div class="titlepage"><div><div><h2 class="title">
637 <a name="object-tree"></a>Object Hierarchy</h2></div></div></div>
638 <pre class="screen">
639- <a href="http://library.gnome.org/devel/gobject/unstable/gobject-The-Base-Object-Type.html#GObject">GObject</a>
640+ <a href="/usr/share/gtk-doc/html/gobject/gobject-The-Base-Object-Type.html#GObject">GObject</a>
641 <a class="link" href="libappindicator-app-indicator.html#AppIndicator">AppIndicator</a>
642 </pre>
643 </div>
644
645=== modified file 'docs/reference/libappindicator-docs.sgml'
646--- docs/reference/libappindicator-docs.sgml 2010-07-08 15:22:02 +0000
647+++ docs/reference/libappindicator-docs.sgml 2010-07-15 15:45:53 +0000
648@@ -8,7 +8,7 @@
649 <bookinfo>
650 <title>libappindicator Reference Manual</title>
651 <releaseinfo>
652- for libappindicator 0.2.2
653+ for libappindicator 0.2.3
654 </releaseinfo>
655 </bookinfo>
656
657
658=== modified file 'docs/reference/tmpl/app-indicator.sgml'
659--- docs/reference/tmpl/app-indicator.sgml 2010-06-21 19:22:34 +0000
660+++ docs/reference/tmpl/app-indicator.sgml 2010-07-15 15:45:53 +0000
661@@ -9,13 +9,11 @@
662
663 </para>
664
665-
666 <!-- ##### SECTION See_Also ##### -->
667 <para>
668
669 </para>
670
671-
672 <!-- ##### SECTION Stability_Level ##### -->
673
674
675
676=== modified file 'docs/reference/version.xml'
677--- docs/reference/version.xml 2010-07-08 15:22:02 +0000
678+++ docs/reference/version.xml 2010-07-15 15:45:53 +0000
679@@ -1,1 +1,1 @@
680-0.2.2
681+0.2.3
682
683=== modified file 'docs/reference/xml/app-indicator.xml'
684--- docs/reference/xml/app-indicator.xml 2010-06-03 19:00:39 +0000
685+++ docs/reference/xml/app-indicator.xml 2010-07-15 15:45:53 +0000
686@@ -80,7 +80,7 @@
687 &quot;<link linkend="AppIndicator--attention-icon-name">attention-icon-name</link>&quot; <link linkend="gchar"><type>gchar</type></link>* : Read / Write
688 &quot;<link linkend="AppIndicator--category">category</link>&quot; <link linkend="gchar"><type>gchar</type></link>* : Read / Write / Construct Only
689 &quot;<link linkend="AppIndicator--connected">connected</link>&quot; <link linkend="gboolean"><type>gboolean</type></link> : Read
690- &quot;<link linkend="AppIndicator--icon-name">icon-name</link>&quot; <link linkend="gchar"><type>gchar</type></link>* : Read / Write / Construct
691+ &quot;<link linkend="AppIndicator--icon-name">icon-name</link>&quot; <link linkend="gchar"><type>gchar</type></link>* : Read / Write
692 &quot;<link linkend="AppIndicator--icon-theme-path">icon-theme-path</link>&quot; <link linkend="gchar"><type>gchar</type></link>* : Read / Write / Construct Only
693 &quot;<link linkend="AppIndicator--id">id</link>&quot; <link linkend="gchar"><type>gchar</type></link>* : Read / Write / Construct Only
694 &quot;<link linkend="AppIndicator--menu">menu</link>&quot; <link linkend="DBusGObjectPath"><type>DBusGObjectPath</type></link>* : Read
695@@ -614,7 +614,7 @@
696 </refsect2>
697 <refsect2 id="AppIndicator--icon-name" role="property"><title>The <literal>&quot;icon-name&quot;</literal> property</title>
698 <indexterm zone="AppIndicator--icon-name"><primary>AppIndicator:icon-name</primary></indexterm>
699-<programlisting> &quot;icon-name&quot; <link linkend="gchar"><type>gchar</type></link>* : Read / Write / Construct</programlisting>
700+<programlisting> &quot;icon-name&quot; <link linkend="gchar"><type>gchar</type></link>* : Read / Write</programlisting>
701 <para>
702 The name of the regular icon that is shown for the indicator.
703 </para><para>Default value: NULL</para>
704
705=== modified file 'src/Makefile.am'
706--- src/Makefile.am 2010-06-01 16:07:44 +0000
707+++ src/Makefile.am 2010-07-15 15:45:53 +0000
708@@ -116,6 +116,7 @@
709 DBUS_SPECS = \
710 dbus-properties.xml \
711 application-service.xml \
712+ notification-approver.xml \
713 notification-item.xml \
714 notification-watcher.xml
715
716
717=== modified file 'src/Makefile.in'
718--- src/Makefile.in 2010-06-21 19:22:34 +0000
719+++ src/Makefile.in 2010-07-15 15:45:53 +0000
720@@ -462,6 +462,7 @@
721 DBUS_SPECS = \
722 dbus-properties.xml \
723 application-service.xml \
724+ notification-approver.xml \
725 notification-item.xml \
726 notification-watcher.xml
727
728
729=== modified file 'src/application-service-appstore.c'
730--- src/application-service-appstore.c 2010-06-18 16:22:56 +0000
731+++ src/application-service-appstore.c 2010-07-15 15:45:53 +0000
732@@ -31,6 +31,7 @@
733 #include "application-service-marshal.h"
734 #include "dbus-properties-client.h"
735 #include "dbus-shared.h"
736+#include "notification-approver-client.h"
737
738 /* DBus Prototypes */
739 static gboolean _application_service_server_get_applications (ApplicationServiceAppstore * appstore, GPtrArray ** apps, GError ** error);
740@@ -50,13 +51,18 @@
741 #define NOTIFICATION_ITEM_SIG_NEW_STATUS "NewStatus"
742
743 /* Private Stuff */
744-typedef struct _ApplicationServiceAppstorePrivate ApplicationServiceAppstorePrivate;
745 struct _ApplicationServiceAppstorePrivate {
746 DBusGConnection * bus;
747 GList * applications;
748+ GList * approvers;
749 AppLruFile * lrufile;
750 };
751
752+typedef struct _Approver Approver;
753+struct _Approver {
754+ DBusGProxy * proxy;
755+};
756+
757 typedef struct _Application Application;
758 struct _Application {
759 gchar * id;
760@@ -95,6 +101,9 @@
761 static void application_service_appstore_finalize (GObject *object);
762 static AppIndicatorStatus string_to_status(const gchar * status_string);
763 static void apply_status (Application * app, AppIndicatorStatus status);
764+static void approver_free (gpointer papprover, gpointer user_data);
765+static void check_with_new_approver (gpointer papp, gpointer papprove);
766+static void check_with_old_approver (gpointer papprove, gpointer papp);
767
768 G_DEFINE_TYPE (ApplicationServiceAppstore, application_service_appstore, G_TYPE_OBJECT);
769
770@@ -139,9 +148,11 @@
771 static void
772 application_service_appstore_init (ApplicationServiceAppstore *self)
773 {
774- ApplicationServiceAppstorePrivate * priv = APPLICATION_SERVICE_APPSTORE_GET_PRIVATE(self);
775+
776+ ApplicationServiceAppstorePrivate * priv = APPLICATION_SERVICE_APPSTORE_GET_PRIVATE (self);
777
778 priv->applications = NULL;
779+ priv->approvers = NULL;
780 priv->lrufile = NULL;
781
782 GError * error = NULL;
783@@ -155,6 +166,8 @@
784 dbus_g_connection_register_g_object(priv->bus,
785 INDICATOR_APPLICATION_DBUS_OBJ,
786 G_OBJECT(self));
787+
788+ self->priv = priv;
789
790 return;
791 }
792@@ -162,7 +175,7 @@
793 static void
794 application_service_appstore_dispose (GObject *object)
795 {
796- ApplicationServiceAppstorePrivate * priv = APPLICATION_SERVICE_APPSTORE_GET_PRIVATE(object);
797+ ApplicationServiceAppstorePrivate * priv = APPLICATION_SERVICE_APPSTORE(object)->priv;
798
799 while (priv->applications != NULL) {
800 application_service_appstore_application_remove(APPLICATION_SERVICE_APPSTORE(object),
801@@ -170,6 +183,12 @@
802 ((Application *)priv->applications->data)->dbus_object);
803 }
804
805+ if (priv->approvers != NULL) {
806+ g_list_foreach(priv->approvers, approver_free, NULL);
807+ g_list_free(priv->approvers);
808+ priv->approvers = NULL;
809+ }
810+
811 G_OBJECT_CLASS (application_service_appstore_parent_class)->dispose (object);
812 return;
813 }
814@@ -209,7 +228,7 @@
815
816 app->id = g_value_dup_string(g_hash_table_lookup(properties, NOTIFICATION_ITEM_PROP_ID));
817 app->category = g_value_dup_string(g_hash_table_lookup(properties, NOTIFICATION_ITEM_PROP_CATEGORY));
818- ApplicationServiceAppstorePrivate * priv = APPLICATION_SERVICE_APPSTORE_GET_PRIVATE(app->appstore);
819+ ApplicationServiceAppstorePrivate * priv = app->appstore->priv;
820 app_lru_file_touch(priv->lrufile, app->id, app->category);
821
822 app->icon = g_value_dup_string(g_hash_table_lookup(properties, NOTIFICATION_ITEM_PROP_ICON_NAME));
823@@ -234,11 +253,23 @@
824 app->icon_path = g_strdup("");
825 }
826
827+ /* TODO: Calling approvers, but we're ignoring the results. So, eh. */
828+ g_list_foreach(priv->approvers, check_with_old_approver, app);
829+
830 apply_status(app, string_to_status(g_value_get_string(g_hash_table_lookup(properties, NOTIFICATION_ITEM_PROP_STATUS))));
831
832 return;
833 }
834
835+/* Check the application against an approver */
836+static void
837+check_with_old_approver (gpointer papprove, gpointer papp)
838+{
839+ /* Funny the parallels, eh? */
840+ check_with_new_approver(papp, papprove);
841+ return;
842+}
843+
844 /* Simple translation function -- could be optimized */
845 static AppIndicatorStatus
846 string_to_status(const gchar * status_string)
847@@ -265,7 +296,7 @@
848 static gint
849 get_position (Application * app) {
850 ApplicationServiceAppstore * appstore = app->appstore;
851- ApplicationServiceAppstorePrivate * priv = APPLICATION_SERVICE_APPSTORE_GET_PRIVATE(appstore);
852+ ApplicationServiceAppstorePrivate * priv = appstore->priv;
853
854 GList * applistitem = g_list_find(priv->applications, app);
855 if (applistitem == NULL) {
856@@ -384,7 +415,7 @@
857 g_debug("Changing app status to: %d", status);
858
859 ApplicationServiceAppstore * appstore = app->appstore;
860- ApplicationServiceAppstorePrivate * priv = APPLICATION_SERVICE_APPSTORE_GET_PRIVATE(appstore);
861+ ApplicationServiceAppstorePrivate * priv = appstore->priv;
862
863 /* This means we're going off line */
864 if (status == APP_INDICATOR_STATUS_PASSIVE) {
865@@ -567,7 +598,7 @@
866 g_return_if_fail(IS_APPLICATION_SERVICE_APPSTORE(appstore));
867 g_return_if_fail(dbus_name != NULL && dbus_name[0] != '\0');
868 g_return_if_fail(dbus_object != NULL && dbus_object[0] != '\0');
869- ApplicationServiceAppstorePrivate * priv = APPLICATION_SERVICE_APPSTORE_GET_PRIVATE(appstore);
870+ ApplicationServiceAppstorePrivate * priv = appstore->priv;
871
872 /* Build the application entry. This will be carried
873 along until we're sure we've got everything. */
874@@ -665,7 +696,7 @@
875 g_return_if_fail(dbus_name != NULL && dbus_name[0] != '\0');
876 g_return_if_fail(dbus_object != NULL && dbus_object[0] != '\0');
877
878- ApplicationServiceAppstorePrivate * priv = APPLICATION_SERVICE_APPSTORE_GET_PRIVATE(appstore);
879+ ApplicationServiceAppstorePrivate * priv = appstore->priv;
880 GList * listpntr;
881
882 for (listpntr = priv->applications; listpntr != NULL; listpntr = g_list_next(listpntr)) {
883@@ -687,7 +718,7 @@
884 {
885 g_return_val_if_fail(IS_APP_LRU_FILE(lrufile), NULL);
886 ApplicationServiceAppstore * appstore = APPLICATION_SERVICE_APPSTORE(g_object_new(APPLICATION_SERVICE_APPSTORE_TYPE, NULL));
887- ApplicationServiceAppstorePrivate * priv = APPLICATION_SERVICE_APPSTORE_GET_PRIVATE(appstore);
888+ ApplicationServiceAppstorePrivate * priv = appstore->priv;
889 priv->lrufile = lrufile;
890 return appstore;
891 }
892@@ -696,7 +727,7 @@
893 static gboolean
894 _application_service_server_get_applications (ApplicationServiceAppstore * appstore, GPtrArray ** apps, GError ** error)
895 {
896- ApplicationServiceAppstorePrivate * priv = APPLICATION_SERVICE_APPSTORE_GET_PRIVATE(appstore);
897+ ApplicationServiceAppstorePrivate * priv = appstore->priv;
898
899 *apps = g_ptr_array_new();
900 GList * listpntr;
901@@ -743,3 +774,77 @@
902 return TRUE;
903 }
904
905+/* Frees the data associated with an approver */
906+static void
907+approver_free (gpointer papprover, gpointer user_data)
908+{
909+ Approver * approver = (Approver *)papprover;
910+ g_return_if_fail(approver != NULL);
911+
912+ if (approver->proxy != NULL) {
913+ g_object_unref(approver->proxy);
914+ approver->proxy = NULL;
915+ }
916+
917+ g_free(approver);
918+ return;
919+}
920+
921+/* What did the approver tell us? */
922+static void
923+approver_request_cb (DBusGProxy *proxy, gboolean OUT_approved, GError *error, gpointer userdata)
924+{
925+ g_debug("Approver responded: %s", OUT_approved ? "approve" : "rejected");
926+ return;
927+}
928+
929+/* Run the applications through the new approver */
930+static void
931+check_with_new_approver (gpointer papp, gpointer papprove)
932+{
933+ Application * app = (Application *)papp;
934+ Approver * approver = (Approver *)papprove;
935+
936+ org_ayatana_StatusNotifierApprover_approve_item_async(approver->proxy,
937+ app->id,
938+ app->category,
939+ 0,
940+ app->dbus_name,
941+ app->dbus_object,
942+ approver_request_cb,
943+ app);
944+
945+ return;
946+}
947+
948+/* Adds a new approver to the app store */
949+void
950+application_service_appstore_approver_add (ApplicationServiceAppstore * appstore, const gchar * dbus_name, const gchar * dbus_object)
951+{
952+ g_return_if_fail(IS_APPLICATION_SERVICE_APPSTORE(appstore));
953+ g_return_if_fail(dbus_name != NULL);
954+ g_return_if_fail(dbus_object != NULL);
955+ ApplicationServiceAppstorePrivate * priv = APPLICATION_SERVICE_APPSTORE_GET_PRIVATE (appstore);
956+
957+ Approver * approver = g_new0(Approver, 1);
958+
959+ GError * error = NULL;
960+ approver->proxy = dbus_g_proxy_new_for_name_owner(priv->bus,
961+ dbus_name,
962+ dbus_object,
963+ NOTIFICATION_APPROVER_DBUS_IFACE,
964+ &error);
965+ if (error != NULL) {
966+ g_warning("Unable to get approver interface on '%s:%s' : %s", dbus_name, dbus_object, error->message);
967+ g_error_free(error);
968+ g_free(approver);
969+ return;
970+ }
971+
972+ priv->approvers = g_list_prepend(priv->approvers, approver);
973+
974+ g_list_foreach(priv->applications, check_with_new_approver, approver);
975+
976+ return;
977+}
978+
979
980=== modified file 'src/application-service-appstore.h'
981--- src/application-service-appstore.h 2010-01-19 23:20:21 +0000
982+++ src/application-service-appstore.h 2010-07-15 15:45:53 +0000
983@@ -38,6 +38,7 @@
984
985 typedef struct _ApplicationServiceAppstore ApplicationServiceAppstore;
986 typedef struct _ApplicationServiceAppstoreClass ApplicationServiceAppstoreClass;
987+typedef struct _ApplicationServiceAppstorePrivate ApplicationServiceAppstorePrivate;
988
989 struct _ApplicationServiceAppstoreClass {
990 GObjectClass parent_class;
991@@ -49,16 +50,21 @@
992
993 struct _ApplicationServiceAppstore {
994 GObject parent;
995+
996+ ApplicationServiceAppstorePrivate * priv;
997 };
998
999 ApplicationServiceAppstore * application_service_appstore_new (AppLruFile * lrufile);
1000 GType application_service_appstore_get_type (void);
1001 void application_service_appstore_application_add (ApplicationServiceAppstore * appstore,
1002- const gchar * dbus_name,
1003- const gchar * dbus_object);
1004+ const gchar * dbus_name,
1005+ const gchar * dbus_object);
1006 void application_service_appstore_application_remove (ApplicationServiceAppstore * appstore,
1007- const gchar * dbus_name,
1008- const gchar * dbus_object);
1009+ const gchar * dbus_name,
1010+ const gchar * dbus_object);
1011+void application_service_appstore_approver_add (ApplicationServiceAppstore * appstore,
1012+ const gchar * dbus_name,
1013+ const gchar * dbus_object);
1014
1015 G_END_DECLS
1016
1017
1018=== modified file 'src/application-service-watcher.c'
1019--- src/application-service-watcher.c 2010-01-08 20:57:22 +0000
1020+++ src/application-service-watcher.c 2010-07-15 15:45:53 +0000
1021@@ -34,6 +34,7 @@
1022 static gboolean _notification_watcher_server_registered_status_notifier_items (ApplicationServiceWatcher * appwatcher, GArray ** apps);
1023 static gboolean _notification_watcher_server_protocol_version (ApplicationServiceWatcher * appwatcher, char ** version);
1024 static gboolean _notification_watcher_server_register_notification_host (ApplicationServiceWatcher * appwatcher, const gchar * host);
1025+static gboolean _notification_watcher_server_register_notification_approver (ApplicationServiceWatcher * appwatcher, const gchar * path, const GArray * categories, DBusGMethodInvocation * method);
1026 static gboolean _notification_watcher_server_is_notification_host_registered (ApplicationServiceWatcher * appwatcher, gboolean * haveHost);
1027 static void get_name_cb (DBusGProxy * proxy, guint status, GError * error, gpointer data);
1028
1029@@ -249,3 +250,16 @@
1030
1031 return;
1032 }
1033+
1034+static gboolean
1035+_notification_watcher_server_register_notification_approver (ApplicationServiceWatcher * appwatcher, const gchar * path, const GArray * categories, DBusGMethodInvocation * method)
1036+{
1037+ ApplicationServiceWatcherPrivate * priv = APPLICATION_SERVICE_WATCHER_GET_PRIVATE(appwatcher);
1038+
1039+ application_service_appstore_approver_add(priv->appstore,
1040+ dbus_g_method_get_sender(method),
1041+ path);
1042+
1043+ dbus_g_method_return(method, G_TYPE_NONE);
1044+ return TRUE;
1045+}
1046
1047=== modified file 'src/dbus-shared.h'
1048--- src/dbus-shared.h 2010-03-15 17:10:43 +0000
1049+++ src/dbus-shared.h 2010-07-15 15:45:53 +0000
1050@@ -31,3 +31,5 @@
1051 #define NOTIFICATION_ITEM_DBUS_IFACE "org.kde.StatusNotifierItem"
1052 #define NOTIFICATION_ITEM_DEFAULT_OBJ "/StatusNotifierItem"
1053
1054+#define NOTIFICATION_APPROVER_DBUS_IFACE "org.ayatana.StatusNotifierApprover"
1055+
1056
1057=== added file 'src/notification-approver.xml'
1058--- src/notification-approver.xml 1970-01-01 00:00:00 +0000
1059+++ src/notification-approver.xml 2010-07-15 15:45:53 +0000
1060@@ -0,0 +1,22 @@
1061+<?xml version="1.0" encoding="UTF-8"?>
1062+<node name="/">
1063+ <interface name="org.ayatana.StatusNotifierApprover">
1064+
1065+<!-- Methods -->
1066+ <method name="ApproveItem">
1067+ <!-- KSNI ID -->
1068+ <arg type="s" name="id" direction="in" />
1069+ <!-- KSNI Category -->
1070+ <arg type="s" name="category" direction="in" />
1071+ <!-- Application PID -->
1072+ <arg type="u" name="pid" direction="in" />
1073+ <!-- Application DBus Address -->
1074+ <arg type="s" name="address" direction="in" />
1075+ <!-- Application DBus Path for KSNI interface -->
1076+ <arg type="o" name="path" direction="in" />
1077+ <!-- So, what do you think? -->
1078+ <arg type="b" name="approved" direction="out" />
1079+ </method>
1080+
1081+ </interface>
1082+</node>
1083
1084=== modified file 'src/notification-watcher.xml'
1085--- src/notification-watcher.xml 2010-03-15 17:10:43 +0000
1086+++ src/notification-watcher.xml 2010-07-15 15:45:53 +0000
1087@@ -22,6 +22,13 @@
1088 <method name="IsNotificationHostRegistered">
1089 <arg type="b" name="hasHost" direction="out" />
1090 </method>
1091+ <method name="RegisterNotificationApprover">
1092+ <annotation name="org.freedesktop.DBus.GLib.Async" value="true" />
1093+ <!-- The path where to find the approver interface -->
1094+ <arg type="o" name="path" direction="in" />
1095+ <!-- List of categories to approve, none represents all -->
1096+ <arg type="as" name="categories" direction="in" />
1097+ </method>
1098
1099 <!-- Signals -->
1100 <signal name="ServiceRegistered">
1101
1102=== modified file 'tests/Makefile.am'
1103--- tests/Makefile.am 2010-06-11 17:34:09 +0000
1104+++ tests/Makefile.am 2010-07-15 15:45:53 +0000
1105@@ -1,5 +1,6 @@
1106
1107 check_PROGRAMS = \
1108+ test-approver \
1109 test-libappindicator \
1110 test-libappindicator-dbus-client \
1111 test-libappindicator-dbus-server \
1112@@ -99,6 +100,33 @@
1113 $(top_builddir)/src/libappindicator.la
1114
1115 #########################################
1116+## test-approver
1117+#########################################
1118+
1119+test_approver_SOURCES = \
1120+ test-approver.c
1121+
1122+test_approver_CFLAGS = \
1123+ $(INDICATOR_CFLAGS) \
1124+ -Wall -Werror \
1125+ -I$(top_srcdir)/src \
1126+ -I$(top_builddir)/src
1127+
1128+test_approver_LDADD = \
1129+ $(INDICATOR_LIBS) \
1130+ $(top_builddir)/src/libappindicator.la
1131+
1132+test-approver-tester: test-approver Makefile.am
1133+ @echo "#!/bin/bash" > $@
1134+ @echo export INDICATOR_SERVICE_SHUTDOWN_TIMEOUT=1000 >> $@
1135+ @echo . $(srcdir)/run-xvfb.sh >> $@
1136+ @echo $(DBUS_RUNNER) --task $(builddir)/test-approver --task-name Approver --task $(top_builddir)/src/indicator-application-service --task-name Service --ignore-return >> $@
1137+ @chmod +x $@
1138+
1139+TESTS += test-approver-tester
1140+
1141+
1142+#########################################
1143 ## test-libappindicator-fallback
1144 #########################################
1145
1146
1147=== modified file 'tests/Makefile.in'
1148--- tests/Makefile.in 2010-06-21 19:17:44 +0000
1149+++ tests/Makefile.in 2010-07-15 15:45:53 +0000
1150@@ -33,7 +33,7 @@
1151 POST_UNINSTALL = :
1152 build_triplet = @build@
1153 host_triplet = @host@
1154-check_PROGRAMS = test-libappindicator$(EXEEXT) \
1155+check_PROGRAMS = test-approver$(EXEEXT) test-libappindicator$(EXEEXT) \
1156 test-libappindicator-dbus-client$(EXEEXT) \
1157 test-libappindicator-dbus-server$(EXEEXT) \
1158 test-libappindicator-status-client$(EXEEXT) \
1159@@ -52,15 +52,22 @@
1160 CONFIG_HEADER = $(top_builddir)/config.h
1161 CONFIG_CLEAN_FILES =
1162 CONFIG_CLEAN_VPATH_FILES =
1163+am_test_approver_OBJECTS = test_approver-test-approver.$(OBJEXT)
1164+test_approver_OBJECTS = $(am_test_approver_OBJECTS)
1165+am__DEPENDENCIES_1 =
1166+test_approver_DEPENDENCIES = $(am__DEPENDENCIES_1) \
1167+ $(top_builddir)/src/libappindicator.la
1168+AM_V_lt = $(am__v_lt_$(V))
1169+am__v_lt_ = $(am__v_lt_$(AM_DEFAULT_VERBOSITY))
1170+am__v_lt_0 = --silent
1171+test_approver_LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \
1172+ $(LIBTOOLFLAGS) --mode=link $(CCLD) $(test_approver_CFLAGS) \
1173+ $(CFLAGS) $(AM_LDFLAGS) $(LDFLAGS) -o $@
1174 am_test_libappindicator_OBJECTS = \
1175 test_libappindicator-test-libappindicator.$(OBJEXT)
1176 test_libappindicator_OBJECTS = $(am_test_libappindicator_OBJECTS)
1177-am__DEPENDENCIES_1 =
1178 test_libappindicator_DEPENDENCIES = $(am__DEPENDENCIES_1) \
1179 $(top_builddir)/src/libappindicator.la
1180-AM_V_lt = $(am__v_lt_$(V))
1181-am__v_lt_ = $(am__v_lt_$(AM_DEFAULT_VERBOSITY))
1182-am__v_lt_0 = --silent
1183 test_libappindicator_LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC \
1184 $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=link $(CCLD) \
1185 $(test_libappindicator_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) \
1186@@ -154,7 +161,7 @@
1187 AM_V_GEN = $(am__v_GEN_$(V))
1188 am__v_GEN_ = $(am__v_GEN_$(AM_DEFAULT_VERBOSITY))
1189 am__v_GEN_0 = @echo " GEN " $@;
1190-SOURCES = $(test_libappindicator_SOURCES) \
1191+SOURCES = $(test_approver_SOURCES) $(test_libappindicator_SOURCES) \
1192 $(test_libappindicator_dbus_client_SOURCES) \
1193 $(test_libappindicator_dbus_server_SOURCES) \
1194 $(test_libappindicator_fallback_item_SOURCES) \
1195@@ -162,7 +169,8 @@
1196 $(test_libappindicator_status_client_SOURCES) \
1197 $(test_libappindicator_status_server_SOURCES) \
1198 $(test_simple_app_SOURCES)
1199-DIST_SOURCES = $(test_libappindicator_SOURCES) \
1200+DIST_SOURCES = $(test_approver_SOURCES) \
1201+ $(test_libappindicator_SOURCES) \
1202 $(test_libappindicator_dbus_client_SOURCES) \
1203 $(test_libappindicator_dbus_server_SOURCES) \
1204 $(test_libappindicator_fallback_item_SOURCES) \
1205@@ -341,8 +349,9 @@
1206 top_build_prefix = @top_build_prefix@
1207 top_builddir = @top_builddir@
1208 top_srcdir = @top_srcdir@
1209-TESTS = test-libappindicator-fallback libappindicator-tests \
1210- test-libappindicator-dbus test-libappindicator-status
1211+TESTS = test-approver-tester test-libappindicator-fallback \
1212+ libappindicator-tests test-libappindicator-dbus \
1213+ test-libappindicator-status
1214 DISTCLEANFILES = $(TESTS) $(XML_REPORT) $(HTML_REPORT) \
1215 libappindicator-tests-gtester
1216 EXTRA_DIST = run-xvfb.sh
1217@@ -428,6 +437,22 @@
1218
1219 #########################################
1220 #########################################
1221+test_approver_SOURCES = \
1222+ test-approver.c
1223+
1224+test_approver_CFLAGS = \
1225+ $(INDICATOR_CFLAGS) \
1226+ -Wall -Werror \
1227+ -I$(top_srcdir)/src \
1228+ -I$(top_builddir)/src
1229+
1230+test_approver_LDADD = \
1231+ $(INDICATOR_LIBS) \
1232+ $(top_builddir)/src/libappindicator.la
1233+
1234+
1235+#########################################
1236+#########################################
1237 test_libappindicator_fallback_watcher_SOURCES = \
1238 test-libappindicator-fallback-watcher.c
1239
1240@@ -516,6 +541,9 @@
1241 list=`for p in $$list; do echo "$$p"; done | sed 's/$(EXEEXT)$$//'`; \
1242 echo " rm -f" $$list; \
1243 rm -f $$list
1244+test-approver$(EXEEXT): $(test_approver_OBJECTS) $(test_approver_DEPENDENCIES)
1245+ @rm -f test-approver$(EXEEXT)
1246+ $(AM_V_CCLD)$(test_approver_LINK) $(test_approver_OBJECTS) $(test_approver_LDADD) $(LIBS)
1247 test-libappindicator$(EXEEXT): $(test_libappindicator_OBJECTS) $(test_libappindicator_DEPENDENCIES)
1248 @rm -f test-libappindicator$(EXEEXT)
1249 $(AM_V_CCLD)$(test_libappindicator_LINK) $(test_libappindicator_OBJECTS) $(test_libappindicator_LDADD) $(LIBS)
1250@@ -547,6 +575,7 @@
1251 distclean-compile:
1252 -rm -f *.tab.c
1253
1254+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/test_approver-test-approver.Po@am__quote@
1255 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/test_libappindicator-test-libappindicator.Po@am__quote@
1256 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/test_libappindicator_dbus_client-test-libappindicator-dbus-client.Po@am__quote@
1257 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/test_libappindicator_dbus_server-test-libappindicator-dbus-server.Po@am__quote@
1258@@ -580,6 +609,22 @@
1259 @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
1260 @am__fastdepCC_FALSE@ $(LTCOMPILE) -c -o $@ $<
1261
1262+test_approver-test-approver.o: test-approver.c
1263+@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(test_approver_CFLAGS) $(CFLAGS) -MT test_approver-test-approver.o -MD -MP -MF $(DEPDIR)/test_approver-test-approver.Tpo -c -o test_approver-test-approver.o `test -f 'test-approver.c' || echo '$(srcdir)/'`test-approver.c
1264+@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/test_approver-test-approver.Tpo $(DEPDIR)/test_approver-test-approver.Po
1265+@am__fastdepCC_FALSE@ $(AM_V_CC) @AM_BACKSLASH@
1266+@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='test-approver.c' object='test_approver-test-approver.o' libtool=no @AMDEPBACKSLASH@
1267+@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
1268+@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(test_approver_CFLAGS) $(CFLAGS) -c -o test_approver-test-approver.o `test -f 'test-approver.c' || echo '$(srcdir)/'`test-approver.c
1269+
1270+test_approver-test-approver.obj: test-approver.c
1271+@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(test_approver_CFLAGS) $(CFLAGS) -MT test_approver-test-approver.obj -MD -MP -MF $(DEPDIR)/test_approver-test-approver.Tpo -c -o test_approver-test-approver.obj `if test -f 'test-approver.c'; then $(CYGPATH_W) 'test-approver.c'; else $(CYGPATH_W) '$(srcdir)/test-approver.c'; fi`
1272+@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/test_approver-test-approver.Tpo $(DEPDIR)/test_approver-test-approver.Po
1273+@am__fastdepCC_FALSE@ $(AM_V_CC) @AM_BACKSLASH@
1274+@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='test-approver.c' object='test_approver-test-approver.obj' libtool=no @AMDEPBACKSLASH@
1275+@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
1276+@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(test_approver_CFLAGS) $(CFLAGS) -c -o test_approver-test-approver.obj `if test -f 'test-approver.c'; then $(CYGPATH_W) 'test-approver.c'; else $(CYGPATH_W) '$(srcdir)/test-approver.c'; fi`
1277+
1278 test_libappindicator-test-libappindicator.o: test-libappindicator.c
1279 @am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(test_libappindicator_CFLAGS) $(CFLAGS) -MT test_libappindicator-test-libappindicator.o -MD -MP -MF $(DEPDIR)/test_libappindicator-test-libappindicator.Tpo -c -o test_libappindicator-test-libappindicator.o `test -f 'test-libappindicator.c' || echo '$(srcdir)/'`test-libappindicator.c
1280 @am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/test_libappindicator-test-libappindicator.Tpo $(DEPDIR)/test_libappindicator-test-libappindicator.Po
1281@@ -1008,6 +1053,13 @@
1282 tags uninstall uninstall-am
1283
1284
1285+test-approver-tester: test-approver Makefile.am
1286+ @echo "#!/bin/bash" > $@
1287+ @echo export INDICATOR_SERVICE_SHUTDOWN_TIMEOUT=1000 >> $@
1288+ @echo . $(srcdir)/run-xvfb.sh >> $@
1289+ @echo $(DBUS_RUNNER) --task $(builddir)/test-approver --task-name Approver --task $(top_builddir)/src/indicator-application-service --task-name Service --ignore-return >> $@
1290+ @chmod +x $@
1291+
1292 test-libappindicator-fallback: test-libappindicator-fallback-watcher test-libappindicator-fallback-item Makefile.am
1293 @echo "#!/bin/bash" > $@
1294 @echo . $(srcdir)/run-xvfb.sh >> $@
1295
1296=== added file 'tests/test-approver.c'
1297--- tests/test-approver.c 1970-01-01 00:00:00 +0000
1298+++ tests/test-approver.c 2010-07-15 15:45:53 +0000
1299@@ -0,0 +1,179 @@
1300+#include <glib.h>
1301+#include <glib-object.h>
1302+
1303+#include <dbus/dbus-glib-bindings.h>
1304+
1305+#include "notification-watcher-client.h"
1306+#include "dbus-shared.h"
1307+#include "app-indicator.h"
1308+
1309+#define APPROVER_PATH "/my/approver"
1310+
1311+#define INDICATOR_ID "test-indicator-id"
1312+#define INDICATOR_ICON "test-indicator-icon-name"
1313+#define INDICATOR_CATEGORY APP_INDICATOR_CATEGORY_APPLICATION_STATUS
1314+
1315+#define TEST_APPROVER_TYPE (test_approver_get_type ())
1316+#define TEST_APPROVER(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TEST_APPROVER_TYPE, TestApprover))
1317+#define TEST_APPROVER_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TEST_APPROVER_TYPE, TestApproverClass))
1318+#define IS_TEST_APPROVER(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TEST_APPROVER_TYPE))
1319+#define IS_TEST_APPROVER_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TEST_APPROVER_TYPE))
1320+#define TEST_APPROVER_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TEST_APPROVER_TYPE, TestApproverClass))
1321+
1322+typedef struct _TestApprover TestApprover;
1323+typedef struct _TestApproverClass TestApproverClass;
1324+
1325+struct _TestApproverClass {
1326+ GObjectClass parent_class;
1327+};
1328+
1329+struct _TestApprover {
1330+ GObject parent;
1331+};
1332+
1333+GType test_approver_get_type (void);
1334+
1335+static void test_approver_class_init (TestApproverClass *klass);
1336+static void test_approver_init (TestApprover *self);
1337+static gboolean _notification_approver_server_approve_item (TestApprover * ta, const gchar * id, const gchar * category, guint pid, const gchar * address, const gchar * path, gboolean * approved, GError ** error);
1338+
1339+#include "../src/notification-approver-server.h"
1340+
1341+GMainLoop * main_loop = NULL;
1342+DBusGConnection * session_bus = NULL;
1343+DBusGProxy * bus_proxy = NULL;
1344+AppIndicator * app_indicator = NULL;
1345+gboolean passed = FALSE;
1346+
1347+G_DEFINE_TYPE (TestApprover, test_approver, G_TYPE_OBJECT);
1348+
1349+static void
1350+test_approver_class_init (TestApproverClass *klass)
1351+{
1352+ dbus_g_object_type_install_info(TEST_APPROVER_TYPE,
1353+ &dbus_glib__notification_approver_server_object_info);
1354+
1355+ return;
1356+}
1357+
1358+static void
1359+test_approver_init (TestApprover *self)
1360+{
1361+ dbus_g_connection_register_g_object(session_bus,
1362+ APPROVER_PATH,
1363+ G_OBJECT(self));
1364+
1365+ return;
1366+}
1367+
1368+static gboolean
1369+_notification_approver_server_approve_item (TestApprover * ta, const gchar * id, const gchar * category, guint pid, const gchar * address, const gchar * path, gboolean * approved, GError ** error)
1370+{
1371+ *approved = TRUE;
1372+ g_debug("Asked to approve indicator");
1373+
1374+ if (g_strcmp0(id, INDICATOR_ID) == 0) {
1375+ passed = TRUE;
1376+ }
1377+
1378+ g_main_loop_quit(main_loop);
1379+
1380+ return TRUE;
1381+}
1382+
1383+static void
1384+register_cb (DBusGProxy * proxy, GError * error, gpointer user_data)
1385+{
1386+ if (error != NULL) {
1387+ g_warning("Unable to register approver: %s", error->message);
1388+ g_error_free(error);
1389+ g_main_loop_quit(main_loop);
1390+ return;
1391+ }
1392+
1393+ g_debug("Building App Indicator");
1394+ app_indicator = app_indicator_new(INDICATOR_ID, INDICATOR_ICON, INDICATOR_CATEGORY);
1395+
1396+ GtkWidget * menu = gtk_menu_new();
1397+ GtkWidget * mi = gtk_image_menu_item_new_from_stock(GTK_STOCK_ABOUT, NULL);
1398+ gtk_menu_shell_append(GTK_MENU_SHELL(menu), mi);
1399+
1400+ app_indicator_set_menu(app_indicator, GTK_MENU(menu));
1401+
1402+ return;
1403+}
1404+
1405+gint owner_count = 0;
1406+gboolean
1407+check_for_service (gpointer user_data)
1408+{
1409+ g_debug("Checking for Watcher");
1410+
1411+ if (owner_count > 100) {
1412+ g_warning("Couldn't find watcher after 100 tries.");
1413+ g_main_loop_quit(main_loop);
1414+ return FALSE;
1415+ }
1416+
1417+ owner_count++;
1418+
1419+ gboolean has_owner = FALSE;
1420+ org_freedesktop_DBus_name_has_owner(bus_proxy, NOTIFICATION_WATCHER_DBUS_ADDR, &has_owner, NULL);
1421+
1422+ if (has_owner) {
1423+ const char * cats = NULL;
1424+ DBusGProxy * proxy = dbus_g_proxy_new_for_name(session_bus,
1425+ NOTIFICATION_WATCHER_DBUS_ADDR,
1426+ NOTIFICATION_WATCHER_DBUS_OBJ,
1427+ NOTIFICATION_WATCHER_DBUS_IFACE);
1428+
1429+ g_debug("Registering Approver");
1430+ org_kde_StatusNotifierWatcher_register_notification_approver_async (proxy, APPROVER_PATH, &cats, register_cb, NULL);
1431+
1432+ return FALSE;
1433+ }
1434+
1435+ return TRUE;
1436+}
1437+
1438+gboolean
1439+fail_timeout (gpointer user_data)
1440+{
1441+ g_debug("Failure timeout initiated.");
1442+ g_main_loop_quit(main_loop);
1443+ return FALSE;
1444+}
1445+
1446+int
1447+main (int argc, char ** argv)
1448+{
1449+ GError * error = NULL;
1450+
1451+ gtk_init(&argc, &argv);
1452+ g_debug("Initing");
1453+
1454+ session_bus = dbus_g_bus_get(DBUS_BUS_SESSION, &error);
1455+ if (error != NULL) {
1456+ g_warning("Unable to get session bus: %s", error->message);
1457+ g_error_free(error);
1458+ return -1;
1459+ }
1460+
1461+ TestApprover * approver = g_object_new(TEST_APPROVER_TYPE, NULL);
1462+
1463+ bus_proxy = dbus_g_proxy_new_for_name(session_bus, DBUS_SERVICE_DBUS, DBUS_PATH_DBUS, DBUS_INTERFACE_DBUS);
1464+
1465+ g_timeout_add(100, check_for_service, NULL);
1466+ g_timeout_add_seconds(2, fail_timeout, NULL);
1467+
1468+ main_loop = g_main_loop_new(NULL, FALSE);
1469+ g_main_loop_run(main_loop);
1470+
1471+ g_object_unref(approver);
1472+
1473+ if (!passed) {
1474+ return -1;
1475+ }
1476+
1477+ return 0;
1478+}

Subscribers

People subscribed via source and target branches

to all changes: