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
=== modified file 'ChangeLog'
--- ChangeLog 2010-07-08 15:22:02 +0000
+++ ChangeLog 2010-07-15 15:45:53 +0000
@@ -1,5 +1,133 @@
1# Generated by Makefile. Do not edit.1# Generated by Makefile. Do not edit.
22
32010-07-13 Ted Gould <ted@gould.cx>
4
5 Adjusting the tests so they can deal with slow systems better.
6
72010-07-12 Ted Gould <ted@gould.cx>
8
9 Ignoring the tester script
10
112010-07-12 Ted Gould <ted@gould.cx>
12
13 Add a fail timeout so this test can't block.
14
152010-07-12 Ted Gould <ted@gould.cx>
16
17 Adding in setting the environment variable to adjust the timeout to be twice as long for slow systems.
18
192010-07-12 Ted Gould <ted@gould.cx>
20
21 Putting in a basic approver API.
22
232010-07-09 Ted Gould <ted@gould.cx>
24
25 Need the built headers too
26
272010-07-09 Ted Gould <ted@gould.cx>
28
29 Oops, with a menu we're all GTK now.
30
312010-07-09 Ted Gould <ted@gould.cx>
32
33 Building up to a formal test
34
352010-07-09 Ted Gould <ted@gould.cx>
36
37 Filling out the approve function.
38
392010-07-09 Ted Gould <ted@gould.cx>
40
41 Filling out the approver prototype
42
432010-07-09 Ted Gould <ted@gould.cx>
44
45 Building an application indicator too!
46
472010-07-09 Ted Gould <ted@gould.cx>
48
49 Making the registration async to clean things up, and async is better anyway.
50
512010-07-09 Ted Gould <ted@gould.cx>
52
53 Some more error handling and better debug messages.
54
552010-07-09 Ted Gould <ted@gould.cx>
56
57 Helpful debug info
58
592010-07-09 Ted Gould <ted@gould.cx>
60
61 Okay, so now we're detecing when the watcher comes up, and registering ourselves as the approver.
62
632010-07-09 Ted Gould <ted@gould.cx>
64
65 Adding a new sample approver
66
672010-07-09 Ted Gould <ted@gould.cx>
68
69 When we have new apps we can ask the approver about them.
70
712010-07-09 Ted Gould <ted@gould.cx>
72
73 Looking at all the applications when we get a new approver.
74
752010-07-09 Ted Gould <ted@gould.cx>
76
77 Building the approver structure and putting it in the list.
78
792010-07-09 Ted Gould <ted@gould.cx>
80
81 Comments
82
832010-07-09 Ted Gould <ted@gould.cx>
84
85 Adding some structures for approvers and making them real.
86
872010-07-09 Ted Gould <ted@gould.cx>
88
89 For DBus to real objects, the signal shall travel.
90
912010-07-09 Ted Gould <ted@gould.cx>
92
93 Adding a function to bring in approvers
94
952010-07-09 Ted Gould <ted@gould.cx>
96
97 Sync to trunk
98
992010-07-01 Ted Gould <ted@gould.cx>
100
101 Return a boolean
102
1032010-06-25 Ted Gould <ted@gould.cx>
104
105 Adding in a template function to register approvers.
106
1072010-06-25 Ted Gould <ted@gould.cx>
108
109 Adding a function to register an approver.
110
1112010-06-25 Ted Gould <ted@gould.cx>
112
113 Adding an approver interface.
114
1152010-07-08 Ted Gould <ted@gould.cx>
116
117 Use a private pointer instead of a lookup.
118
1192010-07-08 Sense Hofstede <qense@ubuntu.com>
120
121 Removed all but one calls to the APPLICATION_SERVICE_APPSTORE_GET_PRIVATE() macro
122
123 All references to the APPLICATION_SERVICE_APPSTORE_GET_PRIVATE() macro were removed
124 from src/application-service-appstore.c. This makes this file comply with the
125 recommended practise, which should reduce overhead.
126
1272010-07-08 Ted Gould <ted@gould.cx>
128
129 0.2.2
130
32010-07-07 Ted Gould <ted@gould.cx>1312010-07-07 Ted Gould <ted@gould.cx>
4132
5 Merging this branch, but I think it's fixes must have gone in with another.133 Merging this branch, but I think it's fixes must have gone in with another.
6134
=== modified file 'configure'
--- configure 2010-07-08 15:23:57 +0000
+++ configure 2010-07-15 15:45:53 +0000
@@ -1,6 +1,6 @@
1#! /bin/sh1#! /bin/sh
2# Guess values for system-dependent variables and create Makefiles.2# Guess values for system-dependent variables and create Makefiles.
3# Generated by GNU Autoconf 2.65 for indicator-application 0.2.2.3# Generated by GNU Autoconf 2.65 for indicator-application 0.2.3.
4#4#
5# Report bugs to <ted@canonical.com>.5# Report bugs to <ted@canonical.com>.
6#6#
@@ -703,8 +703,8 @@
703# Identity of this package.703# Identity of this package.
704PACKAGE_NAME='indicator-application'704PACKAGE_NAME='indicator-application'
705PACKAGE_TARNAME='indicator-application'705PACKAGE_TARNAME='indicator-application'
706PACKAGE_VERSION='0.2.2'706PACKAGE_VERSION='0.2.3'
707PACKAGE_STRING='indicator-application 0.2.2'707PACKAGE_STRING='indicator-application 0.2.3'
708PACKAGE_BUGREPORT='ted@canonical.com'708PACKAGE_BUGREPORT='ted@canonical.com'
709PACKAGE_URL=''709PACKAGE_URL=''
710710
@@ -1505,7 +1505,7 @@
1505 # Omit some internal or obsolete options to make the list less imposing.1505 # Omit some internal or obsolete options to make the list less imposing.
1506 # This message is too long to be a string in the A/UX 3.1 sh.1506 # This message is too long to be a string in the A/UX 3.1 sh.
1507 cat <<_ACEOF1507 cat <<_ACEOF
1508\`configure' configures indicator-application 0.2.2 to adapt to many kinds of systems.1508\`configure' configures indicator-application 0.2.3 to adapt to many kinds of systems.
15091509
1510Usage: $0 [OPTION]... [VAR=VALUE]...1510Usage: $0 [OPTION]... [VAR=VALUE]...
15111511
@@ -1576,7 +1576,7 @@
15761576
1577if test -n "$ac_init_help"; then1577if test -n "$ac_init_help"; then
1578 case $ac_init_help in1578 case $ac_init_help in
1579 short | recursive ) echo "Configuration of indicator-application 0.2.2:";;1579 short | recursive ) echo "Configuration of indicator-application 0.2.3:";;
1580 esac1580 esac
1581 cat <<\_ACEOF1581 cat <<\_ACEOF
15821582
@@ -1709,7 +1709,7 @@
1709test -n "$ac_init_help" && exit $ac_status1709test -n "$ac_init_help" && exit $ac_status
1710if $ac_init_version; then1710if $ac_init_version; then
1711 cat <<\_ACEOF1711 cat <<\_ACEOF
1712indicator-application configure 0.2.21712indicator-application configure 0.2.3
1713generated by GNU Autoconf 2.651713generated by GNU Autoconf 2.65
17141714
1715Copyright (C) 2009 Free Software Foundation, Inc.1715Copyright (C) 2009 Free Software Foundation, Inc.
@@ -1989,7 +1989,7 @@
1989This file contains any messages produced by compilers while1989This file contains any messages produced by compilers while
1990running configure, to aid debugging if configure makes a mistake.1990running configure, to aid debugging if configure makes a mistake.
19911991
1992It was created by indicator-application $as_me 0.2.2, which was1992It was created by indicator-application $as_me 0.2.3, which was
1993generated by GNU Autoconf 2.65. Invocation command line was1993generated by GNU Autoconf 2.65. Invocation command line was
19941994
1995 $ $0 $@1995 $ $0 $@
@@ -2803,7 +2803,7 @@
28032803
2804# Define the identity of the package.2804# Define the identity of the package.
2805 PACKAGE=indicator-application2805 PACKAGE=indicator-application
2806 VERSION=0.2.22806 VERSION=0.2.3
28072807
28082808
2809cat >>confdefs.h <<_ACEOF2809cat >>confdefs.h <<_ACEOF
@@ -13684,7 +13684,7 @@
13684# report actual input values of CONFIG_FILES etc. instead of their13684# report actual input values of CONFIG_FILES etc. instead of their
13685# values after options handling.13685# values after options handling.
13686ac_log="13686ac_log="
13687This file was extended by indicator-application $as_me 0.2.2, which was13687This file was extended by indicator-application $as_me 0.2.3, which was
13688generated by GNU Autoconf 2.65. Invocation command line was13688generated by GNU Autoconf 2.65. Invocation command line was
1368913689
13690 CONFIG_FILES = $CONFIG_FILES13690 CONFIG_FILES = $CONFIG_FILES
@@ -13750,7 +13750,7 @@
13750cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=113750cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
13751ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"13751ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
13752ac_cs_version="\\13752ac_cs_version="\\
13753indicator-application config.status 0.2.213753indicator-application config.status 0.2.3
13754configured by $0, generated by GNU Autoconf 2.65,13754configured by $0, generated by GNU Autoconf 2.65,
13755 with options \\"\$ac_cs_config\\"13755 with options \\"\$ac_cs_config\\"
1375613756
1375713757
=== modified file 'configure.ac'
--- configure.ac 2010-07-08 15:08:02 +0000
+++ configure.ac 2010-07-15 15:45:53 +0000
@@ -1,11 +1,11 @@
11
2AC_INIT(indicator-application, 0.2.2, ted@canonical.com)2AC_INIT(indicator-application, 0.2.3, ted@canonical.com)
3AC_COPYRIGHT([Copyright 2009, 2010 Canonical])3AC_COPYRIGHT([Copyright 2009, 2010 Canonical])
44
5AC_PREREQ(2.53)5AC_PREREQ(2.53)
66
7AM_CONFIG_HEADER(config.h)7AM_CONFIG_HEADER(config.h)
8AM_INIT_AUTOMAKE(indicator-application, 0.2.2)8AM_INIT_AUTOMAKE(indicator-application, 0.2.3)
99
10AM_MAINTAINER_MODE10AM_MAINTAINER_MODE
1111
1212
=== modified file 'debian/changelog'
--- debian/changelog 2010-07-08 16:26:25 +0000
+++ debian/changelog 2010-07-15 15:45:53 +0000
@@ -1,3 +1,11 @@
1indicator-application (0.2.3-0ubuntu1~ppa1) lucid; urgency=low
2
3 * New upstream release.
4 * Fixing test for slower machines
5 * Adding an Approver API to remove things from the AppIndicators.
6
7 -- Ted Gould <ted@ubuntu.com> Thu, 15 Jul 2010 10:22:33 -0500
8
1indicator-application (0.2.2-0ubuntu1) maverick; urgency=low9indicator-application (0.2.2-0ubuntu1) maverick; urgency=low
210
3 * debian/control, debian/rules:11 * debian/control, debian/rules:
412
=== modified file 'docs/reference/html/ch01.html'
--- docs/reference/html/ch01.html 2010-06-21 19:22:34 +0000
+++ docs/reference/html/ch01.html 2010-07-15 15:45:53 +0000
@@ -21,7 +21,7 @@
21</tr></table>21</tr></table>
22<div class="chapter" title="Base Classes for Applications">22<div class="chapter" title="Base Classes for Applications">
23<div class="titlepage"><div><div><h2 class="title">23<div class="titlepage"><div><div><h2 class="title">
24<a name="id460829"></a>Base Classes for Applications</h2></div></div></div>24<a name="id495610"></a>Base Classes for Applications</h2></div></div></div>
25<div class="toc"><dl><dt>25<div class="toc"><dl><dt>
26<span class="refentrytitle"><a href="libappindicator-app-indicator.html">AppIndicator</a></span><span class="refpurpose"> — An object to put application information26<span class="refentrytitle"><a href="libappindicator-app-indicator.html">AppIndicator</a></span><span class="refpurpose"> — An object to put application information
27 into the panel.</span>27 into the panel.</span>
2828
=== modified file 'docs/reference/html/index.html'
--- docs/reference/html/index.html 2010-06-03 19:00:39 +0000
+++ docs/reference/html/index.html 2010-07-15 15:45:53 +0000
@@ -15,7 +15,7 @@
15<div>15<div>
16<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>16<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>
17<div><p class="releaseinfo">17<div><p class="releaseinfo">
18 for libappindicator 0.2.018 for libappindicator 0.2.2
19 </p></div>19 </p></div>
20</div>20</div>
21<hr>21<hr>
2222
=== modified file 'docs/reference/html/libappindicator-app-indicator.html'
--- docs/reference/html/libappindicator-app-indicator.html 2010-06-21 19:17:44 +0000
+++ docs/reference/html/libappindicator-app-indicator.html 2010-07-15 15:45:53 +0000
@@ -66,48 +66,48 @@
66 <a class="link" href="libappindicator-app-indicator.html#AppIndicatorPrivate" title="AppIndicatorPrivate">AppIndicatorPrivate</a>;66 <a class="link" href="libappindicator-app-indicator.html#AppIndicatorPrivate" title="AppIndicatorPrivate">AppIndicatorPrivate</a>;
67 <a class="link" href="libappindicator-app-indicator.html#AppIndicator-struct" title="AppIndicator">AppIndicator</a>;67 <a class="link" href="libappindicator-app-indicator.html#AppIndicator-struct" title="AppIndicator">AppIndicator</a>;
68 <a class="link" href="libappindicator-app-indicator.html#AppIndicatorClass" title="AppIndicatorClass">AppIndicatorClass</a>;68 <a class="link" href="libappindicator-app-indicator.html#AppIndicatorClass" title="AppIndicatorClass">AppIndicatorClass</a>;
69<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>);69<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>);
70<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>,70<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>,
71 <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>,71 <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>,
72 <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>);72 <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>);
73<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>,73<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>,
74 <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>,74 <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>,
75 <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>,75 <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>,
76 <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>);76 <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>);
77<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>,77<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>,
78 <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>);78 <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>);
79<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>,79<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>,
80 <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>);80 <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>);
81<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>,81<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>,
82 <em class="parameter"><code><a href="/usr/share/gtk-doc/html/gtk/GtkMenu.html"><span class="type">GtkMenu</span></a> *menu</code></em>);82 <em class="parameter"><code><a href="/usr/share/gtk-doc/html/gtk/GtkMenu.html"><span class="type">GtkMenu</span></a> *menu</code></em>);
83<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>,83<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>,
84 <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>);84 <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>);
85const <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>);85const <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>);
86<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>);86<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>);
87<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>);87<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>);
88const <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>);88const <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>);
89const <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>);89const <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>);
90<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>);90<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>);
91</pre>91</pre>
92</div>92</div>
93<div class="refsect1" title="Object Hierarchy">93<div class="refsect1" title="Object Hierarchy">
94<a name="libappindicator-app-indicator.object-hierarchy"></a><h2>Object Hierarchy</h2>94<a name="libappindicator-app-indicator.object-hierarchy"></a><h2>Object Hierarchy</h2>
95<pre class="synopsis">95<pre class="synopsis">
96 <a href="http://library.gnome.org/devel/gobject/unstable/gobject-The-Base-Object-Type.html#GObject">GObject</a>96 <a href="/usr/share/gtk-doc/html/gobject/gobject-The-Base-Object-Type.html#GObject">GObject</a>
97 +----AppIndicator97 +----AppIndicator
98</pre>98</pre>
99</div>99</div>
100<div class="refsect1" title="Properties">100<div class="refsect1" title="Properties">
101<a name="libappindicator-app-indicator.properties"></a><h2>Properties</h2>101<a name="libappindicator-app-indicator.properties"></a><h2>Properties</h2>
102<pre class="synopsis">102<pre class="synopsis">
103 "<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 / Write103 "<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
104 "<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 Only104 "<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
105 "<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> : Read105 "<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
106 "<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 / Construct106 "<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
107 "<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 Only107 "<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
108 "<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 Only108 "<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
109 "<a class="link" href="libappindicator-app-indicator.html#AppIndicator--menu" title='The "menu" property'>menu</a>" <span class="type">DBusGObjectPath</span>* : Read109 "<a class="link" href="libappindicator-app-indicator.html#AppIndicator--menu" title='The "menu" property'>menu</a>" <span class="type">DBusGObjectPath</span>* : Read
110 "<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 / Write110 "<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
111</pre>111</pre>
112</div>112</div>
113<div class="refsect1" title="Signals">113<div class="refsect1" title="Signals">
@@ -139,7 +139,7 @@
139<pre class="programlisting">#define APP_INDICATOR_TYPE (app_indicator_get_type ())139<pre class="programlisting">#define APP_INDICATOR_TYPE (app_indicator_get_type ())
140</pre>140</pre>
141<p>141<p>
142Get 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>.142Get 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>.
143</p>143</p>
144</div>144</div>
145<hr>145<hr>
@@ -148,7 +148,7 @@
148<pre class="programlisting">#define APP_INDICATOR(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), APP_INDICATOR_TYPE, AppIndicator))148<pre class="programlisting">#define APP_INDICATOR(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), APP_INDICATOR_TYPE, AppIndicator))
149</pre>149</pre>
150<p>150<p>
151Safely 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>.151Safely 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>.
152</p>152</p>
153<div class="variablelist"><table border="0">153<div class="variablelist"><table border="0">
154<col align="left" valign="top">154<col align="left" valign="top">
@@ -165,14 +165,14 @@
165<pre class="programlisting">#define APP_INDICATOR_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), APP_INDICATOR_TYPE, AppIndicatorClass))165<pre class="programlisting">#define APP_INDICATOR_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), APP_INDICATOR_TYPE, AppIndicatorClass))
166</pre>166</pre>
167<p>167<p>
168Safely 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>.168Safely 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>.
169</p>169</p>
170<div class="variablelist"><table border="0">170<div class="variablelist"><table border="0">
171<col align="left" valign="top">171<col align="left" valign="top">
172<tbody><tr>172<tbody><tr>
173<td><p><span class="term"><em class="parameter"><code>klass</code></em> :</span></p></td>173<td><p><span class="term"><em class="parameter"><code>klass</code></em> :</span></p></td>
174<td>174<td>
175<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.175<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.
176</td>176</td>
177</tr></tbody>177</tr></tbody>
178</table></div>178</table></div>
@@ -189,7 +189,7 @@
189<col align="left" valign="top">189<col align="left" valign="top">
190<tbody><tr>190<tbody><tr>
191<td><p><span class="term"><em class="parameter"><code>obj</code></em> :</span></p></td>191<td><p><span class="term"><em class="parameter"><code>obj</code></em> :</span></p></td>
192<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 check192<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
193</td>193</td>
194</tr></tbody>194</tr></tbody>
195</table></div>195</table></div>
@@ -206,7 +206,7 @@
206<col align="left" valign="top">206<col align="left" valign="top">
207<tbody><tr>207<tbody><tr>
208<td><p><span class="term"><em class="parameter"><code>klass</code></em> :</span></p></td>208<td><p><span class="term"><em class="parameter"><code>klass</code></em> :</span></p></td>
209<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 check209<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
210</td>210</td>
211</tr></tbody>211</tr></tbody>
212</table></div>212</table></div>
@@ -223,7 +223,7 @@
223<col align="left" valign="top">223<col align="left" valign="top">
224<tbody><tr>224<tbody><tr>
225<td><p><span class="term"><em class="parameter"><code>obj</code></em> :</span></p></td>225<td><p><span class="term"><em class="parameter"><code>obj</code></em> :</span></p></td>
226<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>.226<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>.
227</td>227</td>
228</tr></tbody>228</tr></tbody>
229</table></div>229</table></div>
@@ -405,7 +405,7 @@
405<col align="left" valign="top">405<col align="left" valign="top">
406<tbody>406<tbody>
407<tr>407<tr>
408<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>408<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>
409<td>Mia familia409<td>Mia familia
410</td>410</td>
411</tr>411</tr>
@@ -457,15 +457,15 @@
457<hr>457<hr>
458<div class="refsect2" title="app_indicator_get_type ()">458<div class="refsect2" title="app_indicator_get_type ()">
459<a name="app-indicator-get-type"></a><h3>app_indicator_get_type ()</h3>459<a name="app-indicator-get-type"></a><h3>app_indicator_get_type ()</h3>
460<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>460<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>
461<p>461<p>
462Generates 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>.462Generates 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>.
463</p>463</p>
464<div class="variablelist"><table border="0">464<div class="variablelist"><table border="0">
465<col align="left" valign="top">465<col align="left" valign="top">
466<tbody><tr>466<tbody><tr>
467<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>467<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
468<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.468<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.
469</td>469</td>
470</tr></tbody>470</tr></tbody>
471</table></div>471</table></div>
@@ -473,8 +473,8 @@
473<hr>473<hr>
474<div class="refsect2" title="app_indicator_new ()">474<div class="refsect2" title="app_indicator_new ()">
475<a name="app-indicator-new"></a><h3>app_indicator_new ()</h3>475<a name="app-indicator-new"></a><h3>app_indicator_new ()</h3>
476<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>,476<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>,
477 <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>,477 <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>,
478 <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>478 <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>
479<p>479<p>
480Creates a new <a class="link" href="libappindicator-app-indicator.html#AppIndicator"><span class="type">AppIndicator</span></a> setting the properties:480Creates a new <a class="link" href="libappindicator-app-indicator.html#AppIndicator"><span class="type">AppIndicator</span></a> setting the properties:
@@ -511,10 +511,10 @@
511<hr>511<hr>
512<div class="refsect2" title="app_indicator_new_with_path ()">512<div class="refsect2" title="app_indicator_new_with_path ()">
513<a name="app-indicator-new-with-path"></a><h3>app_indicator_new_with_path ()</h3>513<a name="app-indicator-new-with-path"></a><h3>app_indicator_new_with_path ()</h3>
514<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>,514<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>,
515 <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>,515 <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>,
516 <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>,516 <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>,
517 <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>517 <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>
518<p>518<p>
519Creates a new <a class="link" href="libappindicator-app-indicator.html#AppIndicator"><span class="type">AppIndicator</span></a> setting the properties:519Creates a new <a class="link" href="libappindicator-app-indicator.html#AppIndicator"><span class="type">AppIndicator</span></a> setting the properties:
520 <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>520 <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>
@@ -580,7 +580,7 @@
580<div class="refsect2" title="app_indicator_set_attention_icon ()">580<div class="refsect2" title="app_indicator_set_attention_icon ()">
581<a name="app-indicator-set-attention-icon"></a><h3>app_indicator_set_attention_icon ()</h3>581<a name="app-indicator-set-attention-icon"></a><h3>app_indicator_set_attention_icon ()</h3>
582<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>,582<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>,
583 <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>583 <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>
584<p>584<p>
585Wrapper 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>.585Wrapper 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>.
586</p>586</p>
@@ -632,7 +632,7 @@
632<div class="refsect2" title="app_indicator_set_icon ()">632<div class="refsect2" title="app_indicator_set_icon ()">
633<a name="app-indicator-set-icon"></a><h3>app_indicator_set_icon ()</h3>633<a name="app-indicator-set-icon"></a><h3>app_indicator_set_icon ()</h3>
634<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>,634<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>,
635 <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>635 <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>
636<p>636<p>
637Sets the default icon to use when the status is active but637Sets the default icon to use when the status is active but
638 not set to attention. In most cases, this should be the638 not set to attention. In most cases, this should be the
@@ -658,7 +658,7 @@
658<hr>658<hr>
659<div class="refsect2" title="app_indicator_get_id ()">659<div class="refsect2" title="app_indicator_get_id ()">
660<a name="app-indicator-get-id"></a><h3>app_indicator_get_id ()</h3>660<a name="app-indicator-get-id"></a><h3>app_indicator_get_id ()</h3>
661<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>661<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>
662<p>662<p>
663Wrapper function for property <a class="link" href="libappindicator-app-indicator.html#AppIndicator--id" title='The "id" property'><span class="type">"id"</span></a>.663Wrapper function for property <a class="link" href="libappindicator-app-indicator.html#AppIndicator--id" title='The "id" property'><span class="type">"id"</span></a>.
664</p>664</p>
@@ -727,7 +727,7 @@
727<hr>727<hr>
728<div class="refsect2" title="app_indicator_get_icon ()">728<div class="refsect2" title="app_indicator_get_icon ()">
729<a name="app-indicator-get-icon"></a><h3>app_indicator_get_icon ()</h3>729<a name="app-indicator-get-icon"></a><h3>app_indicator_get_icon ()</h3>
730<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>730<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>
731<p>731<p>
732Wrapper 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>.732Wrapper 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>.
733</p>733</p>
@@ -750,7 +750,7 @@
750<hr>750<hr>
751<div class="refsect2" title="app_indicator_get_attention_icon ()">751<div class="refsect2" title="app_indicator_get_attention_icon ()">
752<a name="app-indicator-get-attention-icon"></a><h3>app_indicator_get_attention_icon ()</h3>752<a name="app-indicator-get-attention-icon"></a><h3>app_indicator_get_attention_icon ()</h3>
753<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>753<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>
754<p>754<p>
755Wrapper 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>.755Wrapper 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>.
756</p>756</p>
@@ -788,7 +788,7 @@
788</tr>788</tr>
789<tr>789<tr>
790<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>790<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
791<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.791<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.
792</td>792</td>
793</tr>793</tr>
794</tbody>794</tbody>
@@ -799,7 +799,7 @@
799<a name="libappindicator-app-indicator.property-details"></a><h2>Property Details</h2>799<a name="libappindicator-app-indicator.property-details"></a><h2>Property Details</h2>
800<div class="refsect2" title='The "attention-icon-name" property'>800<div class="refsect2" title='The "attention-icon-name" property'>
801<a name="AppIndicator--attention-icon-name"></a><h3>The <code class="literal">"attention-icon-name"</code> property</h3>801<a name="AppIndicator--attention-icon-name"></a><h3>The <code class="literal">"attention-icon-name"</code> property</h3>
802<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>802<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>
803<p>803<p>
804If 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>804If 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>
805 then this icon is shown.805 then this icon is shown.
@@ -809,7 +809,7 @@
809<hr>809<hr>
810<div class="refsect2" title='The "category" property'>810<div class="refsect2" title='The "category" property'>
811<a name="AppIndicator--category"></a><h3>The <code class="literal">"category"</code> property</h3>811<a name="AppIndicator--category"></a><h3>The <code class="literal">"category"</code> property</h3>
812<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>812<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>
813<p>813<p>
814The type of indicator that this represents. Please don't use 'Other'.814The type of indicator that this represents. Please don't use 'Other'.
815 Defaults to 'ApplicationStatus'.815 Defaults to 'ApplicationStatus'.
@@ -819,9 +819,9 @@
819<hr>819<hr>
820<div class="refsect2" title='The "connected" property'>820<div class="refsect2" title='The "connected" property'>
821<a name="AppIndicator--connected"></a><h3>The <code class="literal">"connected"</code> property</h3>821<a name="AppIndicator--connected"></a><h3>The <code class="literal">"connected"</code> property</h3>
822<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>822<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>
823<p>823<p>
824Pretty 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 824Pretty 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
825 displayed through this object. You should hide your TrayIcon if so.825 displayed through this object. You should hide your TrayIcon if so.
826</p>826</p>
827<p>Default value: FALSE</p>827<p>Default value: FALSE</p>
@@ -829,7 +829,7 @@
829<hr>829<hr>
830<div class="refsect2" title='The "icon-name" property'>830<div class="refsect2" title='The "icon-name" property'>
831<a name="AppIndicator--icon-name"></a><h3>The <code class="literal">"icon-name"</code> property</h3>831<a name="AppIndicator--icon-name"></a><h3>The <code class="literal">"icon-name"</code> property</h3>
832<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>832<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>
833<p>833<p>
834The name of the regular icon that is shown for the indicator.834The name of the regular icon that is shown for the indicator.
835</p>835</p>
@@ -838,7 +838,7 @@
838<hr>838<hr>
839<div class="refsect2" title='The "icon-theme-path" property'>839<div class="refsect2" title='The "icon-theme-path" property'>
840<a name="AppIndicator--icon-theme-path"></a><h3>The <code class="literal">"icon-theme-path"</code> property</h3>840<a name="AppIndicator--icon-theme-path"></a><h3>The <code class="literal">"icon-theme-path"</code> property</h3>
841<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>841<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>
842<p>842<p>
843An additional place to look for icon names that may be installed by the843An additional place to look for icon names that may be installed by the
844 application.844 application.
@@ -848,7 +848,7 @@
848<hr>848<hr>
849<div class="refsect2" title='The "id" property'>849<div class="refsect2" title='The "id" property'>
850<a name="AppIndicator--id"></a><h3>The <code class="literal">"id"</code> property</h3>850<a name="AppIndicator--id"></a><h3>The <code class="literal">"id"</code> property</h3>
851<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>851<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>
852<p>852<p>
853The ID for this indicator, which should be unique, but used consistently853The ID for this indicator, which should be unique, but used consistently
854 by this program and its indicator.854 by this program and its indicator.
@@ -866,7 +866,7 @@
866<hr>866<hr>
867<div class="refsect2" title='The "status" property'>867<div class="refsect2" title='The "status" property'>
868<a name="AppIndicator--status"></a><h3>The <code class="literal">"status"</code> property</h3>868<a name="AppIndicator--status"></a><h3>The <code class="literal">"status"</code> property</h3>
869<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>869<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>
870<p>870<p>
871Whether the indicator is shown or requests attention. Defaults to871Whether the indicator is shown or requests attention. Defaults to
872 'Passive'.872 'Passive'.
@@ -879,8 +879,8 @@
879<div class="refsect2" title='The "connection-changed" signal'>879<div class="refsect2" title='The "connection-changed" signal'>
880<a name="AppIndicator-connection-changed"></a><h3>The <code class="literal">"connection-changed"</code> signal</h3>880<a name="AppIndicator-connection-changed"></a><h3>The <code class="literal">"connection-changed"</code> signal</h3>
881<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,881<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,
882 <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gboolean"><span class="type">gboolean</span></a> arg1,882 <a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gboolean"><span class="type">gboolean</span></a> arg1,
883 <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>883 <a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gpointer"><span class="type">gpointer</span></a> user_data) : Run Last</pre>
884<p>884<p>
885Signaled when we connect to a watcher, or when it drops away.885Signaled when we connect to a watcher, or when it drops away.
886</p>886</p>
@@ -908,7 +908,7 @@
908<div class="refsect2" title='The "new-attention-icon" signal'>908<div class="refsect2" title='The "new-attention-icon" signal'>
909<a name="AppIndicator-new-attention-icon"></a><h3>The <code class="literal">"new-attention-icon"</code> signal</h3>909<a name="AppIndicator-new-attention-icon"></a><h3>The <code class="literal">"new-attention-icon"</code> signal</h3>
910<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,910<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,
911 <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>911 <a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gpointer"><span class="type">gpointer</span></a> user_data) : Run Last</pre>
912<p>912<p>
913Emitted 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 changed913Emitted 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
914</p>914</p>
@@ -931,7 +931,7 @@
931<div class="refsect2" title='The "new-icon" signal'>931<div class="refsect2" title='The "new-icon" signal'>
932<a name="AppIndicator-new-icon"></a><h3>The <code class="literal">"new-icon"</code> signal</h3>932<a name="AppIndicator-new-icon"></a><h3>The <code class="literal">"new-icon"</code> signal</h3>
933<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,933<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,
934 <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>934 <a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gpointer"><span class="type">gpointer</span></a> user_data) : Run Last</pre>
935<p>935<p>
936Emitted 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 changed936Emitted 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
937</p>937</p>
@@ -954,8 +954,8 @@
954<div class="refsect2" title='The "new-status" signal'>954<div class="refsect2" title='The "new-status" signal'>
955<a name="AppIndicator-new-status"></a><h3>The <code class="literal">"new-status"</code> signal</h3>955<a name="AppIndicator-new-status"></a><h3>The <code class="literal">"new-status"</code> signal</h3>
956<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,956<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,
957 <a href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> *arg1,957 <a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gchar"><span class="type">gchar</span></a> *arg1,
958 <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>958 <a href="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gpointer"><span class="type">gpointer</span></a> user_data) : Run Last</pre>
959<p>959<p>
960Emitted when <a class="link" href="libappindicator-app-indicator.html#AppIndicator--status" title='The "status" property'><span class="type">"status"</span></a> is changed960Emitted when <a class="link" href="libappindicator-app-indicator.html#AppIndicator--status" title='The "status" property'><span class="type">"status"</span></a> is changed
961</p>961</p>
962962
=== modified file 'docs/reference/html/object-tree.html'
--- docs/reference/html/object-tree.html 2010-06-21 19:17:44 +0000
+++ docs/reference/html/object-tree.html 2010-07-15 15:45:53 +0000
@@ -23,7 +23,7 @@
23<div class="titlepage"><div><div><h2 class="title">23<div class="titlepage"><div><div><h2 class="title">
24<a name="object-tree"></a>Object Hierarchy</h2></div></div></div>24<a name="object-tree"></a>Object Hierarchy</h2></div></div></div>
25<pre class="screen">25<pre class="screen">
26 <a href="http://library.gnome.org/devel/gobject/unstable/gobject-The-Base-Object-Type.html#GObject">GObject</a>26 <a href="/usr/share/gtk-doc/html/gobject/gobject-The-Base-Object-Type.html#GObject">GObject</a>
27 <a class="link" href="libappindicator-app-indicator.html#AppIndicator">AppIndicator</a>27 <a class="link" href="libappindicator-app-indicator.html#AppIndicator">AppIndicator</a>
28</pre>28</pre>
29</div>29</div>
3030
=== modified file 'docs/reference/libappindicator-docs.sgml'
--- docs/reference/libappindicator-docs.sgml 2010-07-08 15:22:02 +0000
+++ docs/reference/libappindicator-docs.sgml 2010-07-15 15:45:53 +0000
@@ -8,7 +8,7 @@
8 <bookinfo>8 <bookinfo>
9 <title>libappindicator Reference Manual</title>9 <title>libappindicator Reference Manual</title>
10 <releaseinfo>10 <releaseinfo>
11 for libappindicator 0.2.211 for libappindicator 0.2.3
12 </releaseinfo>12 </releaseinfo>
13 </bookinfo>13 </bookinfo>
1414
1515
=== modified file 'docs/reference/tmpl/app-indicator.sgml'
--- docs/reference/tmpl/app-indicator.sgml 2010-06-21 19:22:34 +0000
+++ docs/reference/tmpl/app-indicator.sgml 2010-07-15 15:45:53 +0000
@@ -9,13 +9,11 @@
99
10</para>10</para>
1111
12
13<!-- ##### SECTION See_Also ##### -->12<!-- ##### SECTION See_Also ##### -->
14<para>13<para>
1514
16</para>15</para>
1716
18
19<!-- ##### SECTION Stability_Level ##### -->17<!-- ##### SECTION Stability_Level ##### -->
2018
2119
2220
=== modified file 'docs/reference/version.xml'
--- docs/reference/version.xml 2010-07-08 15:22:02 +0000
+++ docs/reference/version.xml 2010-07-15 15:45:53 +0000
@@ -1,1 +1,1 @@
10.2.210.2.3
22
=== modified file 'docs/reference/xml/app-indicator.xml'
--- docs/reference/xml/app-indicator.xml 2010-06-03 19:00:39 +0000
+++ docs/reference/xml/app-indicator.xml 2010-07-15 15:45:53 +0000
@@ -80,7 +80,7 @@
80 &quot;<link linkend="AppIndicator--attention-icon-name">attention-icon-name</link>&quot; <link linkend="gchar"><type>gchar</type></link>* : Read / Write80 &quot;<link linkend="AppIndicator--attention-icon-name">attention-icon-name</link>&quot; <link linkend="gchar"><type>gchar</type></link>* : Read / Write
81 &quot;<link linkend="AppIndicator--category">category</link>&quot; <link linkend="gchar"><type>gchar</type></link>* : Read / Write / Construct Only81 &quot;<link linkend="AppIndicator--category">category</link>&quot; <link linkend="gchar"><type>gchar</type></link>* : Read / Write / Construct Only
82 &quot;<link linkend="AppIndicator--connected">connected</link>&quot; <link linkend="gboolean"><type>gboolean</type></link> : Read82 &quot;<link linkend="AppIndicator--connected">connected</link>&quot; <link linkend="gboolean"><type>gboolean</type></link> : Read
83 &quot;<link linkend="AppIndicator--icon-name">icon-name</link>&quot; <link linkend="gchar"><type>gchar</type></link>* : Read / Write / Construct83 &quot;<link linkend="AppIndicator--icon-name">icon-name</link>&quot; <link linkend="gchar"><type>gchar</type></link>* : Read / Write
84 &quot;<link linkend="AppIndicator--icon-theme-path">icon-theme-path</link>&quot; <link linkend="gchar"><type>gchar</type></link>* : Read / Write / Construct Only84 &quot;<link linkend="AppIndicator--icon-theme-path">icon-theme-path</link>&quot; <link linkend="gchar"><type>gchar</type></link>* : Read / Write / Construct Only
85 &quot;<link linkend="AppIndicator--id">id</link>&quot; <link linkend="gchar"><type>gchar</type></link>* : Read / Write / Construct Only85 &quot;<link linkend="AppIndicator--id">id</link>&quot; <link linkend="gchar"><type>gchar</type></link>* : Read / Write / Construct Only
86 &quot;<link linkend="AppIndicator--menu">menu</link>&quot; <link linkend="DBusGObjectPath"><type>DBusGObjectPath</type></link>* : Read86 &quot;<link linkend="AppIndicator--menu">menu</link>&quot; <link linkend="DBusGObjectPath"><type>DBusGObjectPath</type></link>* : Read
@@ -614,7 +614,7 @@
614</refsect2>614</refsect2>
615<refsect2 id="AppIndicator--icon-name" role="property"><title>The <literal>&quot;icon-name&quot;</literal> property</title>615<refsect2 id="AppIndicator--icon-name" role="property"><title>The <literal>&quot;icon-name&quot;</literal> property</title>
616<indexterm zone="AppIndicator--icon-name"><primary>AppIndicator:icon-name</primary></indexterm>616<indexterm zone="AppIndicator--icon-name"><primary>AppIndicator:icon-name</primary></indexterm>
617<programlisting> &quot;icon-name&quot; <link linkend="gchar"><type>gchar</type></link>* : Read / Write / Construct</programlisting>617<programlisting> &quot;icon-name&quot; <link linkend="gchar"><type>gchar</type></link>* : Read / Write</programlisting>
618<para>618<para>
619The name of the regular icon that is shown for the indicator.619The name of the regular icon that is shown for the indicator.
620</para><para>Default value: NULL</para>620</para><para>Default value: NULL</para>
621621
=== modified file 'src/Makefile.am'
--- src/Makefile.am 2010-06-01 16:07:44 +0000
+++ src/Makefile.am 2010-07-15 15:45:53 +0000
@@ -116,6 +116,7 @@
116DBUS_SPECS = \116DBUS_SPECS = \
117 dbus-properties.xml \117 dbus-properties.xml \
118 application-service.xml \118 application-service.xml \
119 notification-approver.xml \
119 notification-item.xml \120 notification-item.xml \
120 notification-watcher.xml121 notification-watcher.xml
121122
122123
=== modified file 'src/Makefile.in'
--- src/Makefile.in 2010-06-21 19:22:34 +0000
+++ src/Makefile.in 2010-07-15 15:45:53 +0000
@@ -462,6 +462,7 @@
462DBUS_SPECS = \462DBUS_SPECS = \
463 dbus-properties.xml \463 dbus-properties.xml \
464 application-service.xml \464 application-service.xml \
465 notification-approver.xml \
465 notification-item.xml \466 notification-item.xml \
466 notification-watcher.xml467 notification-watcher.xml
467468
468469
=== modified file 'src/application-service-appstore.c'
--- src/application-service-appstore.c 2010-06-18 16:22:56 +0000
+++ src/application-service-appstore.c 2010-07-15 15:45:53 +0000
@@ -31,6 +31,7 @@
31#include "application-service-marshal.h"31#include "application-service-marshal.h"
32#include "dbus-properties-client.h"32#include "dbus-properties-client.h"
33#include "dbus-shared.h"33#include "dbus-shared.h"
34#include "notification-approver-client.h"
3435
35/* DBus Prototypes */36/* DBus Prototypes */
36static gboolean _application_service_server_get_applications (ApplicationServiceAppstore * appstore, GPtrArray ** apps, GError ** error);37static gboolean _application_service_server_get_applications (ApplicationServiceAppstore * appstore, GPtrArray ** apps, GError ** error);
@@ -50,13 +51,18 @@
50#define NOTIFICATION_ITEM_SIG_NEW_STATUS "NewStatus"51#define NOTIFICATION_ITEM_SIG_NEW_STATUS "NewStatus"
5152
52/* Private Stuff */53/* Private Stuff */
53typedef struct _ApplicationServiceAppstorePrivate ApplicationServiceAppstorePrivate;
54struct _ApplicationServiceAppstorePrivate {54struct _ApplicationServiceAppstorePrivate {
55 DBusGConnection * bus;55 DBusGConnection * bus;
56 GList * applications;56 GList * applications;
57 GList * approvers;
57 AppLruFile * lrufile;58 AppLruFile * lrufile;
58};59};
5960
61typedef struct _Approver Approver;
62struct _Approver {
63 DBusGProxy * proxy;
64};
65
60typedef struct _Application Application;66typedef struct _Application Application;
61struct _Application {67struct _Application {
62 gchar * id;68 gchar * id;
@@ -95,6 +101,9 @@
95static void application_service_appstore_finalize (GObject *object);101static void application_service_appstore_finalize (GObject *object);
96static AppIndicatorStatus string_to_status(const gchar * status_string);102static AppIndicatorStatus string_to_status(const gchar * status_string);
97static void apply_status (Application * app, AppIndicatorStatus status);103static void apply_status (Application * app, AppIndicatorStatus status);
104static void approver_free (gpointer papprover, gpointer user_data);
105static void check_with_new_approver (gpointer papp, gpointer papprove);
106static void check_with_old_approver (gpointer papprove, gpointer papp);
98107
99G_DEFINE_TYPE (ApplicationServiceAppstore, application_service_appstore, G_TYPE_OBJECT);108G_DEFINE_TYPE (ApplicationServiceAppstore, application_service_appstore, G_TYPE_OBJECT);
100109
@@ -139,9 +148,11 @@
139static void148static void
140application_service_appstore_init (ApplicationServiceAppstore *self)149application_service_appstore_init (ApplicationServiceAppstore *self)
141{150{
142 ApplicationServiceAppstorePrivate * priv = APPLICATION_SERVICE_APPSTORE_GET_PRIVATE(self);151
152 ApplicationServiceAppstorePrivate * priv = APPLICATION_SERVICE_APPSTORE_GET_PRIVATE (self);
143153
144 priv->applications = NULL;154 priv->applications = NULL;
155 priv->approvers = NULL;
145 priv->lrufile = NULL;156 priv->lrufile = NULL;
146 157
147 GError * error = NULL;158 GError * error = NULL;
@@ -155,6 +166,8 @@
155 dbus_g_connection_register_g_object(priv->bus,166 dbus_g_connection_register_g_object(priv->bus,
156 INDICATOR_APPLICATION_DBUS_OBJ,167 INDICATOR_APPLICATION_DBUS_OBJ,
157 G_OBJECT(self));168 G_OBJECT(self));
169
170 self->priv = priv;
158171
159 return;172 return;
160}173}
@@ -162,7 +175,7 @@
162static void175static void
163application_service_appstore_dispose (GObject *object)176application_service_appstore_dispose (GObject *object)
164{177{
165 ApplicationServiceAppstorePrivate * priv = APPLICATION_SERVICE_APPSTORE_GET_PRIVATE(object);178 ApplicationServiceAppstorePrivate * priv = APPLICATION_SERVICE_APPSTORE(object)->priv;
166179
167 while (priv->applications != NULL) {180 while (priv->applications != NULL) {
168 application_service_appstore_application_remove(APPLICATION_SERVICE_APPSTORE(object),181 application_service_appstore_application_remove(APPLICATION_SERVICE_APPSTORE(object),
@@ -170,6 +183,12 @@
170 ((Application *)priv->applications->data)->dbus_object);183 ((Application *)priv->applications->data)->dbus_object);
171 }184 }
172185
186 if (priv->approvers != NULL) {
187 g_list_foreach(priv->approvers, approver_free, NULL);
188 g_list_free(priv->approvers);
189 priv->approvers = NULL;
190 }
191
173 G_OBJECT_CLASS (application_service_appstore_parent_class)->dispose (object);192 G_OBJECT_CLASS (application_service_appstore_parent_class)->dispose (object);
174 return;193 return;
175}194}
@@ -209,7 +228,7 @@
209228
210 app->id = g_value_dup_string(g_hash_table_lookup(properties, NOTIFICATION_ITEM_PROP_ID));229 app->id = g_value_dup_string(g_hash_table_lookup(properties, NOTIFICATION_ITEM_PROP_ID));
211 app->category = g_value_dup_string(g_hash_table_lookup(properties, NOTIFICATION_ITEM_PROP_CATEGORY));230 app->category = g_value_dup_string(g_hash_table_lookup(properties, NOTIFICATION_ITEM_PROP_CATEGORY));
212 ApplicationServiceAppstorePrivate * priv = APPLICATION_SERVICE_APPSTORE_GET_PRIVATE(app->appstore);231 ApplicationServiceAppstorePrivate * priv = app->appstore->priv;
213 app_lru_file_touch(priv->lrufile, app->id, app->category);232 app_lru_file_touch(priv->lrufile, app->id, app->category);
214233
215 app->icon = g_value_dup_string(g_hash_table_lookup(properties, NOTIFICATION_ITEM_PROP_ICON_NAME));234 app->icon = g_value_dup_string(g_hash_table_lookup(properties, NOTIFICATION_ITEM_PROP_ICON_NAME));
@@ -234,11 +253,23 @@
234 app->icon_path = g_strdup("");253 app->icon_path = g_strdup("");
235 }254 }
236255
256 /* TODO: Calling approvers, but we're ignoring the results. So, eh. */
257 g_list_foreach(priv->approvers, check_with_old_approver, app);
258
237 apply_status(app, string_to_status(g_value_get_string(g_hash_table_lookup(properties, NOTIFICATION_ITEM_PROP_STATUS))));259 apply_status(app, string_to_status(g_value_get_string(g_hash_table_lookup(properties, NOTIFICATION_ITEM_PROP_STATUS))));
238260
239 return;261 return;
240}262}
241263
264/* Check the application against an approver */
265static void
266check_with_old_approver (gpointer papprove, gpointer papp)
267{
268 /* Funny the parallels, eh? */
269 check_with_new_approver(papp, papprove);
270 return;
271}
272
242/* Simple translation function -- could be optimized */273/* Simple translation function -- could be optimized */
243static AppIndicatorStatus274static AppIndicatorStatus
244string_to_status(const gchar * status_string)275string_to_status(const gchar * status_string)
@@ -265,7 +296,7 @@
265static gint 296static gint
266get_position (Application * app) {297get_position (Application * app) {
267 ApplicationServiceAppstore * appstore = app->appstore;298 ApplicationServiceAppstore * appstore = app->appstore;
268 ApplicationServiceAppstorePrivate * priv = APPLICATION_SERVICE_APPSTORE_GET_PRIVATE(appstore);299 ApplicationServiceAppstorePrivate * priv = appstore->priv;
269300
270 GList * applistitem = g_list_find(priv->applications, app);301 GList * applistitem = g_list_find(priv->applications, app);
271 if (applistitem == NULL) {302 if (applistitem == NULL) {
@@ -384,7 +415,7 @@
384 g_debug("Changing app status to: %d", status);415 g_debug("Changing app status to: %d", status);
385416
386 ApplicationServiceAppstore * appstore = app->appstore;417 ApplicationServiceAppstore * appstore = app->appstore;
387 ApplicationServiceAppstorePrivate * priv = APPLICATION_SERVICE_APPSTORE_GET_PRIVATE(appstore);418 ApplicationServiceAppstorePrivate * priv = appstore->priv;
388419
389 /* This means we're going off line */420 /* This means we're going off line */
390 if (status == APP_INDICATOR_STATUS_PASSIVE) {421 if (status == APP_INDICATOR_STATUS_PASSIVE) {
@@ -567,7 +598,7 @@
567 g_return_if_fail(IS_APPLICATION_SERVICE_APPSTORE(appstore));598 g_return_if_fail(IS_APPLICATION_SERVICE_APPSTORE(appstore));
568 g_return_if_fail(dbus_name != NULL && dbus_name[0] != '\0');599 g_return_if_fail(dbus_name != NULL && dbus_name[0] != '\0');
569 g_return_if_fail(dbus_object != NULL && dbus_object[0] != '\0');600 g_return_if_fail(dbus_object != NULL && dbus_object[0] != '\0');
570 ApplicationServiceAppstorePrivate * priv = APPLICATION_SERVICE_APPSTORE_GET_PRIVATE(appstore);601 ApplicationServiceAppstorePrivate * priv = appstore->priv;
571602
572 /* Build the application entry. This will be carried603 /* Build the application entry. This will be carried
573 along until we're sure we've got everything. */604 along until we're sure we've got everything. */
@@ -665,7 +696,7 @@
665 g_return_if_fail(dbus_name != NULL && dbus_name[0] != '\0');696 g_return_if_fail(dbus_name != NULL && dbus_name[0] != '\0');
666 g_return_if_fail(dbus_object != NULL && dbus_object[0] != '\0');697 g_return_if_fail(dbus_object != NULL && dbus_object[0] != '\0');
667698
668 ApplicationServiceAppstorePrivate * priv = APPLICATION_SERVICE_APPSTORE_GET_PRIVATE(appstore);699 ApplicationServiceAppstorePrivate * priv = appstore->priv;
669 GList * listpntr;700 GList * listpntr;
670701
671 for (listpntr = priv->applications; listpntr != NULL; listpntr = g_list_next(listpntr)) {702 for (listpntr = priv->applications; listpntr != NULL; listpntr = g_list_next(listpntr)) {
@@ -687,7 +718,7 @@
687{718{
688 g_return_val_if_fail(IS_APP_LRU_FILE(lrufile), NULL);719 g_return_val_if_fail(IS_APP_LRU_FILE(lrufile), NULL);
689 ApplicationServiceAppstore * appstore = APPLICATION_SERVICE_APPSTORE(g_object_new(APPLICATION_SERVICE_APPSTORE_TYPE, NULL));720 ApplicationServiceAppstore * appstore = APPLICATION_SERVICE_APPSTORE(g_object_new(APPLICATION_SERVICE_APPSTORE_TYPE, NULL));
690 ApplicationServiceAppstorePrivate * priv = APPLICATION_SERVICE_APPSTORE_GET_PRIVATE(appstore);721 ApplicationServiceAppstorePrivate * priv = appstore->priv;
691 priv->lrufile = lrufile;722 priv->lrufile = lrufile;
692 return appstore;723 return appstore;
693}724}
@@ -696,7 +727,7 @@
696static gboolean727static gboolean
697_application_service_server_get_applications (ApplicationServiceAppstore * appstore, GPtrArray ** apps, GError ** error)728_application_service_server_get_applications (ApplicationServiceAppstore * appstore, GPtrArray ** apps, GError ** error)
698{729{
699 ApplicationServiceAppstorePrivate * priv = APPLICATION_SERVICE_APPSTORE_GET_PRIVATE(appstore);730 ApplicationServiceAppstorePrivate * priv = appstore->priv;
700731
701 *apps = g_ptr_array_new();732 *apps = g_ptr_array_new();
702 GList * listpntr;733 GList * listpntr;
@@ -743,3 +774,77 @@
743 return TRUE;774 return TRUE;
744}775}
745776
777/* Frees the data associated with an approver */
778static void
779approver_free (gpointer papprover, gpointer user_data)
780{
781 Approver * approver = (Approver *)papprover;
782 g_return_if_fail(approver != NULL);
783
784 if (approver->proxy != NULL) {
785 g_object_unref(approver->proxy);
786 approver->proxy = NULL;
787 }
788
789 g_free(approver);
790 return;
791}
792
793/* What did the approver tell us? */
794static void
795approver_request_cb (DBusGProxy *proxy, gboolean OUT_approved, GError *error, gpointer userdata)
796{
797 g_debug("Approver responded: %s", OUT_approved ? "approve" : "rejected");
798 return;
799}
800
801/* Run the applications through the new approver */
802static void
803check_with_new_approver (gpointer papp, gpointer papprove)
804{
805 Application * app = (Application *)papp;
806 Approver * approver = (Approver *)papprove;
807
808 org_ayatana_StatusNotifierApprover_approve_item_async(approver->proxy,
809 app->id,
810 app->category,
811 0,
812 app->dbus_name,
813 app->dbus_object,
814 approver_request_cb,
815 app);
816
817 return;
818}
819
820/* Adds a new approver to the app store */
821void
822application_service_appstore_approver_add (ApplicationServiceAppstore * appstore, const gchar * dbus_name, const gchar * dbus_object)
823{
824 g_return_if_fail(IS_APPLICATION_SERVICE_APPSTORE(appstore));
825 g_return_if_fail(dbus_name != NULL);
826 g_return_if_fail(dbus_object != NULL);
827 ApplicationServiceAppstorePrivate * priv = APPLICATION_SERVICE_APPSTORE_GET_PRIVATE (appstore);
828
829 Approver * approver = g_new0(Approver, 1);
830
831 GError * error = NULL;
832 approver->proxy = dbus_g_proxy_new_for_name_owner(priv->bus,
833 dbus_name,
834 dbus_object,
835 NOTIFICATION_APPROVER_DBUS_IFACE,
836 &error);
837 if (error != NULL) {
838 g_warning("Unable to get approver interface on '%s:%s' : %s", dbus_name, dbus_object, error->message);
839 g_error_free(error);
840 g_free(approver);
841 return;
842 }
843
844 priv->approvers = g_list_prepend(priv->approvers, approver);
845
846 g_list_foreach(priv->applications, check_with_new_approver, approver);
847
848 return;
849}
850
746851
=== modified file 'src/application-service-appstore.h'
--- src/application-service-appstore.h 2010-01-19 23:20:21 +0000
+++ src/application-service-appstore.h 2010-07-15 15:45:53 +0000
@@ -38,6 +38,7 @@
3838
39typedef struct _ApplicationServiceAppstore ApplicationServiceAppstore;39typedef struct _ApplicationServiceAppstore ApplicationServiceAppstore;
40typedef struct _ApplicationServiceAppstoreClass ApplicationServiceAppstoreClass;40typedef struct _ApplicationServiceAppstoreClass ApplicationServiceAppstoreClass;
41typedef struct _ApplicationServiceAppstorePrivate ApplicationServiceAppstorePrivate;
4142
42struct _ApplicationServiceAppstoreClass {43struct _ApplicationServiceAppstoreClass {
43 GObjectClass parent_class;44 GObjectClass parent_class;
@@ -49,16 +50,21 @@
4950
50struct _ApplicationServiceAppstore {51struct _ApplicationServiceAppstore {
51 GObject parent;52 GObject parent;
53
54 ApplicationServiceAppstorePrivate * priv;
52};55};
5356
54ApplicationServiceAppstore * application_service_appstore_new (AppLruFile * lrufile);57ApplicationServiceAppstore * application_service_appstore_new (AppLruFile * lrufile);
55GType application_service_appstore_get_type (void);58GType application_service_appstore_get_type (void);
56void application_service_appstore_application_add (ApplicationServiceAppstore * appstore,59void application_service_appstore_application_add (ApplicationServiceAppstore * appstore,
57 const gchar * dbus_name,60 const gchar * dbus_name,
58 const gchar * dbus_object);61 const gchar * dbus_object);
59void application_service_appstore_application_remove (ApplicationServiceAppstore * appstore,62void application_service_appstore_application_remove (ApplicationServiceAppstore * appstore,
60 const gchar * dbus_name,63 const gchar * dbus_name,
61 const gchar * dbus_object);64 const gchar * dbus_object);
65void application_service_appstore_approver_add (ApplicationServiceAppstore * appstore,
66 const gchar * dbus_name,
67 const gchar * dbus_object);
6268
63G_END_DECLS69G_END_DECLS
6470
6571
=== modified file 'src/application-service-watcher.c'
--- src/application-service-watcher.c 2010-01-08 20:57:22 +0000
+++ src/application-service-watcher.c 2010-07-15 15:45:53 +0000
@@ -34,6 +34,7 @@
34static gboolean _notification_watcher_server_registered_status_notifier_items (ApplicationServiceWatcher * appwatcher, GArray ** apps);34static gboolean _notification_watcher_server_registered_status_notifier_items (ApplicationServiceWatcher * appwatcher, GArray ** apps);
35static gboolean _notification_watcher_server_protocol_version (ApplicationServiceWatcher * appwatcher, char ** version);35static gboolean _notification_watcher_server_protocol_version (ApplicationServiceWatcher * appwatcher, char ** version);
36static gboolean _notification_watcher_server_register_notification_host (ApplicationServiceWatcher * appwatcher, const gchar * host);36static gboolean _notification_watcher_server_register_notification_host (ApplicationServiceWatcher * appwatcher, const gchar * host);
37static gboolean _notification_watcher_server_register_notification_approver (ApplicationServiceWatcher * appwatcher, const gchar * path, const GArray * categories, DBusGMethodInvocation * method);
37static gboolean _notification_watcher_server_is_notification_host_registered (ApplicationServiceWatcher * appwatcher, gboolean * haveHost);38static gboolean _notification_watcher_server_is_notification_host_registered (ApplicationServiceWatcher * appwatcher, gboolean * haveHost);
38static void get_name_cb (DBusGProxy * proxy, guint status, GError * error, gpointer data);39static void get_name_cb (DBusGProxy * proxy, guint status, GError * error, gpointer data);
3940
@@ -249,3 +250,16 @@
249250
250 return;251 return;
251}252}
253
254static gboolean
255_notification_watcher_server_register_notification_approver (ApplicationServiceWatcher * appwatcher, const gchar * path, const GArray * categories, DBusGMethodInvocation * method)
256{
257 ApplicationServiceWatcherPrivate * priv = APPLICATION_SERVICE_WATCHER_GET_PRIVATE(appwatcher);
258
259 application_service_appstore_approver_add(priv->appstore,
260 dbus_g_method_get_sender(method),
261 path);
262
263 dbus_g_method_return(method, G_TYPE_NONE);
264 return TRUE;
265}
252266
=== modified file 'src/dbus-shared.h'
--- src/dbus-shared.h 2010-03-15 17:10:43 +0000
+++ src/dbus-shared.h 2010-07-15 15:45:53 +0000
@@ -31,3 +31,5 @@
31#define NOTIFICATION_ITEM_DBUS_IFACE "org.kde.StatusNotifierItem"31#define NOTIFICATION_ITEM_DBUS_IFACE "org.kde.StatusNotifierItem"
32#define NOTIFICATION_ITEM_DEFAULT_OBJ "/StatusNotifierItem"32#define NOTIFICATION_ITEM_DEFAULT_OBJ "/StatusNotifierItem"
3333
34#define NOTIFICATION_APPROVER_DBUS_IFACE "org.ayatana.StatusNotifierApprover"
35
3436
=== added file 'src/notification-approver.xml'
--- src/notification-approver.xml 1970-01-01 00:00:00 +0000
+++ src/notification-approver.xml 2010-07-15 15:45:53 +0000
@@ -0,0 +1,22 @@
1<?xml version="1.0" encoding="UTF-8"?>
2<node name="/">
3 <interface name="org.ayatana.StatusNotifierApprover">
4
5<!-- Methods -->
6 <method name="ApproveItem">
7 <!-- KSNI ID -->
8 <arg type="s" name="id" direction="in" />
9 <!-- KSNI Category -->
10 <arg type="s" name="category" direction="in" />
11 <!-- Application PID -->
12 <arg type="u" name="pid" direction="in" />
13 <!-- Application DBus Address -->
14 <arg type="s" name="address" direction="in" />
15 <!-- Application DBus Path for KSNI interface -->
16 <arg type="o" name="path" direction="in" />
17 <!-- So, what do you think? -->
18 <arg type="b" name="approved" direction="out" />
19 </method>
20
21 </interface>
22</node>
023
=== modified file 'src/notification-watcher.xml'
--- src/notification-watcher.xml 2010-03-15 17:10:43 +0000
+++ src/notification-watcher.xml 2010-07-15 15:45:53 +0000
@@ -22,6 +22,13 @@
22 <method name="IsNotificationHostRegistered">22 <method name="IsNotificationHostRegistered">
23 <arg type="b" name="hasHost" direction="out" />23 <arg type="b" name="hasHost" direction="out" />
24 </method>24 </method>
25 <method name="RegisterNotificationApprover">
26 <annotation name="org.freedesktop.DBus.GLib.Async" value="true" />
27 <!-- The path where to find the approver interface -->
28 <arg type="o" name="path" direction="in" />
29 <!-- List of categories to approve, none represents all -->
30 <arg type="as" name="categories" direction="in" />
31 </method>
2532
26<!-- Signals -->33<!-- Signals -->
27 <signal name="ServiceRegistered">34 <signal name="ServiceRegistered">
2835
=== modified file 'tests/Makefile.am'
--- tests/Makefile.am 2010-06-11 17:34:09 +0000
+++ tests/Makefile.am 2010-07-15 15:45:53 +0000
@@ -1,5 +1,6 @@
11
2check_PROGRAMS = \2check_PROGRAMS = \
3 test-approver \
3 test-libappindicator \4 test-libappindicator \
4 test-libappindicator-dbus-client \5 test-libappindicator-dbus-client \
5 test-libappindicator-dbus-server \6 test-libappindicator-dbus-server \
@@ -99,6 +100,33 @@
99 $(top_builddir)/src/libappindicator.la100 $(top_builddir)/src/libappindicator.la
100101
101#########################################102#########################################
103## test-approver
104#########################################
105
106test_approver_SOURCES = \
107 test-approver.c
108
109test_approver_CFLAGS = \
110 $(INDICATOR_CFLAGS) \
111 -Wall -Werror \
112 -I$(top_srcdir)/src \
113 -I$(top_builddir)/src
114
115test_approver_LDADD = \
116 $(INDICATOR_LIBS) \
117 $(top_builddir)/src/libappindicator.la
118
119test-approver-tester: test-approver Makefile.am
120 @echo "#!/bin/bash" > $@
121 @echo export INDICATOR_SERVICE_SHUTDOWN_TIMEOUT=1000 >> $@
122 @echo . $(srcdir)/run-xvfb.sh >> $@
123 @echo $(DBUS_RUNNER) --task $(builddir)/test-approver --task-name Approver --task $(top_builddir)/src/indicator-application-service --task-name Service --ignore-return >> $@
124 @chmod +x $@
125
126TESTS += test-approver-tester
127
128
129#########################################
102## test-libappindicator-fallback130## test-libappindicator-fallback
103#########################################131#########################################
104132
105133
=== modified file 'tests/Makefile.in'
--- tests/Makefile.in 2010-06-21 19:17:44 +0000
+++ tests/Makefile.in 2010-07-15 15:45:53 +0000
@@ -33,7 +33,7 @@
33POST_UNINSTALL = :33POST_UNINSTALL = :
34build_triplet = @build@34build_triplet = @build@
35host_triplet = @host@35host_triplet = @host@
36check_PROGRAMS = test-libappindicator$(EXEEXT) \36check_PROGRAMS = test-approver$(EXEEXT) test-libappindicator$(EXEEXT) \
37 test-libappindicator-dbus-client$(EXEEXT) \37 test-libappindicator-dbus-client$(EXEEXT) \
38 test-libappindicator-dbus-server$(EXEEXT) \38 test-libappindicator-dbus-server$(EXEEXT) \
39 test-libappindicator-status-client$(EXEEXT) \39 test-libappindicator-status-client$(EXEEXT) \
@@ -52,15 +52,22 @@
52CONFIG_HEADER = $(top_builddir)/config.h52CONFIG_HEADER = $(top_builddir)/config.h
53CONFIG_CLEAN_FILES =53CONFIG_CLEAN_FILES =
54CONFIG_CLEAN_VPATH_FILES =54CONFIG_CLEAN_VPATH_FILES =
55am_test_approver_OBJECTS = test_approver-test-approver.$(OBJEXT)
56test_approver_OBJECTS = $(am_test_approver_OBJECTS)
57am__DEPENDENCIES_1 =
58test_approver_DEPENDENCIES = $(am__DEPENDENCIES_1) \
59 $(top_builddir)/src/libappindicator.la
60AM_V_lt = $(am__v_lt_$(V))
61am__v_lt_ = $(am__v_lt_$(AM_DEFAULT_VERBOSITY))
62am__v_lt_0 = --silent
63test_approver_LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \
64 $(LIBTOOLFLAGS) --mode=link $(CCLD) $(test_approver_CFLAGS) \
65 $(CFLAGS) $(AM_LDFLAGS) $(LDFLAGS) -o $@
55am_test_libappindicator_OBJECTS = \66am_test_libappindicator_OBJECTS = \
56 test_libappindicator-test-libappindicator.$(OBJEXT)67 test_libappindicator-test-libappindicator.$(OBJEXT)
57test_libappindicator_OBJECTS = $(am_test_libappindicator_OBJECTS)68test_libappindicator_OBJECTS = $(am_test_libappindicator_OBJECTS)
58am__DEPENDENCIES_1 =
59test_libappindicator_DEPENDENCIES = $(am__DEPENDENCIES_1) \69test_libappindicator_DEPENDENCIES = $(am__DEPENDENCIES_1) \
60 $(top_builddir)/src/libappindicator.la70 $(top_builddir)/src/libappindicator.la
61AM_V_lt = $(am__v_lt_$(V))
62am__v_lt_ = $(am__v_lt_$(AM_DEFAULT_VERBOSITY))
63am__v_lt_0 = --silent
64test_libappindicator_LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC \71test_libappindicator_LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC \
65 $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=link $(CCLD) \72 $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=link $(CCLD) \
66 $(test_libappindicator_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) \73 $(test_libappindicator_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) \
@@ -154,7 +161,7 @@
154AM_V_GEN = $(am__v_GEN_$(V))161AM_V_GEN = $(am__v_GEN_$(V))
155am__v_GEN_ = $(am__v_GEN_$(AM_DEFAULT_VERBOSITY))162am__v_GEN_ = $(am__v_GEN_$(AM_DEFAULT_VERBOSITY))
156am__v_GEN_0 = @echo " GEN " $@;163am__v_GEN_0 = @echo " GEN " $@;
157SOURCES = $(test_libappindicator_SOURCES) \164SOURCES = $(test_approver_SOURCES) $(test_libappindicator_SOURCES) \
158 $(test_libappindicator_dbus_client_SOURCES) \165 $(test_libappindicator_dbus_client_SOURCES) \
159 $(test_libappindicator_dbus_server_SOURCES) \166 $(test_libappindicator_dbus_server_SOURCES) \
160 $(test_libappindicator_fallback_item_SOURCES) \167 $(test_libappindicator_fallback_item_SOURCES) \
@@ -162,7 +169,8 @@
162 $(test_libappindicator_status_client_SOURCES) \169 $(test_libappindicator_status_client_SOURCES) \
163 $(test_libappindicator_status_server_SOURCES) \170 $(test_libappindicator_status_server_SOURCES) \
164 $(test_simple_app_SOURCES)171 $(test_simple_app_SOURCES)
165DIST_SOURCES = $(test_libappindicator_SOURCES) \172DIST_SOURCES = $(test_approver_SOURCES) \
173 $(test_libappindicator_SOURCES) \
166 $(test_libappindicator_dbus_client_SOURCES) \174 $(test_libappindicator_dbus_client_SOURCES) \
167 $(test_libappindicator_dbus_server_SOURCES) \175 $(test_libappindicator_dbus_server_SOURCES) \
168 $(test_libappindicator_fallback_item_SOURCES) \176 $(test_libappindicator_fallback_item_SOURCES) \
@@ -341,8 +349,9 @@
341top_build_prefix = @top_build_prefix@349top_build_prefix = @top_build_prefix@
342top_builddir = @top_builddir@350top_builddir = @top_builddir@
343top_srcdir = @top_srcdir@351top_srcdir = @top_srcdir@
344TESTS = test-libappindicator-fallback libappindicator-tests \352TESTS = test-approver-tester test-libappindicator-fallback \
345 test-libappindicator-dbus test-libappindicator-status353 libappindicator-tests test-libappindicator-dbus \
354 test-libappindicator-status
346DISTCLEANFILES = $(TESTS) $(XML_REPORT) $(HTML_REPORT) \355DISTCLEANFILES = $(TESTS) $(XML_REPORT) $(HTML_REPORT) \
347 libappindicator-tests-gtester356 libappindicator-tests-gtester
348EXTRA_DIST = run-xvfb.sh357EXTRA_DIST = run-xvfb.sh
@@ -428,6 +437,22 @@
428437
429#########################################438#########################################
430#########################################439#########################################
440test_approver_SOURCES = \
441 test-approver.c
442
443test_approver_CFLAGS = \
444 $(INDICATOR_CFLAGS) \
445 -Wall -Werror \
446 -I$(top_srcdir)/src \
447 -I$(top_builddir)/src
448
449test_approver_LDADD = \
450 $(INDICATOR_LIBS) \
451 $(top_builddir)/src/libappindicator.la
452
453
454#########################################
455#########################################
431test_libappindicator_fallback_watcher_SOURCES = \456test_libappindicator_fallback_watcher_SOURCES = \
432 test-libappindicator-fallback-watcher.c457 test-libappindicator-fallback-watcher.c
433458
@@ -516,6 +541,9 @@
516 list=`for p in $$list; do echo "$$p"; done | sed 's/$(EXEEXT)$$//'`; \541 list=`for p in $$list; do echo "$$p"; done | sed 's/$(EXEEXT)$$//'`; \
517 echo " rm -f" $$list; \542 echo " rm -f" $$list; \
518 rm -f $$list543 rm -f $$list
544test-approver$(EXEEXT): $(test_approver_OBJECTS) $(test_approver_DEPENDENCIES)
545 @rm -f test-approver$(EXEEXT)
546 $(AM_V_CCLD)$(test_approver_LINK) $(test_approver_OBJECTS) $(test_approver_LDADD) $(LIBS)
519test-libappindicator$(EXEEXT): $(test_libappindicator_OBJECTS) $(test_libappindicator_DEPENDENCIES) 547test-libappindicator$(EXEEXT): $(test_libappindicator_OBJECTS) $(test_libappindicator_DEPENDENCIES)
520 @rm -f test-libappindicator$(EXEEXT)548 @rm -f test-libappindicator$(EXEEXT)
521 $(AM_V_CCLD)$(test_libappindicator_LINK) $(test_libappindicator_OBJECTS) $(test_libappindicator_LDADD) $(LIBS)549 $(AM_V_CCLD)$(test_libappindicator_LINK) $(test_libappindicator_OBJECTS) $(test_libappindicator_LDADD) $(LIBS)
@@ -547,6 +575,7 @@
547distclean-compile:575distclean-compile:
548 -rm -f *.tab.c576 -rm -f *.tab.c
549577
578@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/test_approver-test-approver.Po@am__quote@
550@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/test_libappindicator-test-libappindicator.Po@am__quote@579@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/test_libappindicator-test-libappindicator.Po@am__quote@
551@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/test_libappindicator_dbus_client-test-libappindicator-dbus-client.Po@am__quote@580@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/test_libappindicator_dbus_client-test-libappindicator-dbus-client.Po@am__quote@
552@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/test_libappindicator_dbus_server-test-libappindicator-dbus-server.Po@am__quote@581@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/test_libappindicator_dbus_server-test-libappindicator-dbus-server.Po@am__quote@
@@ -580,6 +609,22 @@
580@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@609@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
581@am__fastdepCC_FALSE@ $(LTCOMPILE) -c -o $@ $<610@am__fastdepCC_FALSE@ $(LTCOMPILE) -c -o $@ $<
582611
612test_approver-test-approver.o: test-approver.c
613@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
614@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/test_approver-test-approver.Tpo $(DEPDIR)/test_approver-test-approver.Po
615@am__fastdepCC_FALSE@ $(AM_V_CC) @AM_BACKSLASH@
616@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='test-approver.c' object='test_approver-test-approver.o' libtool=no @AMDEPBACKSLASH@
617@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
618@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
619
620test_approver-test-approver.obj: test-approver.c
621@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`
622@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/test_approver-test-approver.Tpo $(DEPDIR)/test_approver-test-approver.Po
623@am__fastdepCC_FALSE@ $(AM_V_CC) @AM_BACKSLASH@
624@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='test-approver.c' object='test_approver-test-approver.obj' libtool=no @AMDEPBACKSLASH@
625@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
626@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`
627
583test_libappindicator-test-libappindicator.o: test-libappindicator.c628test_libappindicator-test-libappindicator.o: test-libappindicator.c
584@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.c629@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
585@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/test_libappindicator-test-libappindicator.Tpo $(DEPDIR)/test_libappindicator-test-libappindicator.Po630@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/test_libappindicator-test-libappindicator.Tpo $(DEPDIR)/test_libappindicator-test-libappindicator.Po
@@ -1008,6 +1053,13 @@
1008 tags uninstall uninstall-am1053 tags uninstall uninstall-am
10091054
10101055
1056test-approver-tester: test-approver Makefile.am
1057 @echo "#!/bin/bash" > $@
1058 @echo export INDICATOR_SERVICE_SHUTDOWN_TIMEOUT=1000 >> $@
1059 @echo . $(srcdir)/run-xvfb.sh >> $@
1060 @echo $(DBUS_RUNNER) --task $(builddir)/test-approver --task-name Approver --task $(top_builddir)/src/indicator-application-service --task-name Service --ignore-return >> $@
1061 @chmod +x $@
1062
1011test-libappindicator-fallback: test-libappindicator-fallback-watcher test-libappindicator-fallback-item Makefile.am1063test-libappindicator-fallback: test-libappindicator-fallback-watcher test-libappindicator-fallback-item Makefile.am
1012 @echo "#!/bin/bash" > $@1064 @echo "#!/bin/bash" > $@
1013 @echo . $(srcdir)/run-xvfb.sh >> $@1065 @echo . $(srcdir)/run-xvfb.sh >> $@
10141066
=== added file 'tests/test-approver.c'
--- tests/test-approver.c 1970-01-01 00:00:00 +0000
+++ tests/test-approver.c 2010-07-15 15:45:53 +0000
@@ -0,0 +1,179 @@
1#include <glib.h>
2#include <glib-object.h>
3
4#include <dbus/dbus-glib-bindings.h>
5
6#include "notification-watcher-client.h"
7#include "dbus-shared.h"
8#include "app-indicator.h"
9
10#define APPROVER_PATH "/my/approver"
11
12#define INDICATOR_ID "test-indicator-id"
13#define INDICATOR_ICON "test-indicator-icon-name"
14#define INDICATOR_CATEGORY APP_INDICATOR_CATEGORY_APPLICATION_STATUS
15
16#define TEST_APPROVER_TYPE (test_approver_get_type ())
17#define TEST_APPROVER(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TEST_APPROVER_TYPE, TestApprover))
18#define TEST_APPROVER_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TEST_APPROVER_TYPE, TestApproverClass))
19#define IS_TEST_APPROVER(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TEST_APPROVER_TYPE))
20#define IS_TEST_APPROVER_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TEST_APPROVER_TYPE))
21#define TEST_APPROVER_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TEST_APPROVER_TYPE, TestApproverClass))
22
23typedef struct _TestApprover TestApprover;
24typedef struct _TestApproverClass TestApproverClass;
25
26struct _TestApproverClass {
27 GObjectClass parent_class;
28};
29
30struct _TestApprover {
31 GObject parent;
32};
33
34GType test_approver_get_type (void);
35
36static void test_approver_class_init (TestApproverClass *klass);
37static void test_approver_init (TestApprover *self);
38static 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);
39
40#include "../src/notification-approver-server.h"
41
42GMainLoop * main_loop = NULL;
43DBusGConnection * session_bus = NULL;
44DBusGProxy * bus_proxy = NULL;
45AppIndicator * app_indicator = NULL;
46gboolean passed = FALSE;
47
48G_DEFINE_TYPE (TestApprover, test_approver, G_TYPE_OBJECT);
49
50static void
51test_approver_class_init (TestApproverClass *klass)
52{
53 dbus_g_object_type_install_info(TEST_APPROVER_TYPE,
54 &dbus_glib__notification_approver_server_object_info);
55
56 return;
57}
58
59static void
60test_approver_init (TestApprover *self)
61{
62 dbus_g_connection_register_g_object(session_bus,
63 APPROVER_PATH,
64 G_OBJECT(self));
65
66 return;
67}
68
69static gboolean
70_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)
71{
72 *approved = TRUE;
73 g_debug("Asked to approve indicator");
74
75 if (g_strcmp0(id, INDICATOR_ID) == 0) {
76 passed = TRUE;
77 }
78
79 g_main_loop_quit(main_loop);
80
81 return TRUE;
82}
83
84static void
85register_cb (DBusGProxy * proxy, GError * error, gpointer user_data)
86{
87 if (error != NULL) {
88 g_warning("Unable to register approver: %s", error->message);
89 g_error_free(error);
90 g_main_loop_quit(main_loop);
91 return;
92 }
93
94 g_debug("Building App Indicator");
95 app_indicator = app_indicator_new(INDICATOR_ID, INDICATOR_ICON, INDICATOR_CATEGORY);
96
97 GtkWidget * menu = gtk_menu_new();
98 GtkWidget * mi = gtk_image_menu_item_new_from_stock(GTK_STOCK_ABOUT, NULL);
99 gtk_menu_shell_append(GTK_MENU_SHELL(menu), mi);
100
101 app_indicator_set_menu(app_indicator, GTK_MENU(menu));
102
103 return;
104}
105
106gint owner_count = 0;
107gboolean
108check_for_service (gpointer user_data)
109{
110 g_debug("Checking for Watcher");
111
112 if (owner_count > 100) {
113 g_warning("Couldn't find watcher after 100 tries.");
114 g_main_loop_quit(main_loop);
115 return FALSE;
116 }
117
118 owner_count++;
119
120 gboolean has_owner = FALSE;
121 org_freedesktop_DBus_name_has_owner(bus_proxy, NOTIFICATION_WATCHER_DBUS_ADDR, &has_owner, NULL);
122
123 if (has_owner) {
124 const char * cats = NULL;
125 DBusGProxy * proxy = dbus_g_proxy_new_for_name(session_bus,
126 NOTIFICATION_WATCHER_DBUS_ADDR,
127 NOTIFICATION_WATCHER_DBUS_OBJ,
128 NOTIFICATION_WATCHER_DBUS_IFACE);
129
130 g_debug("Registering Approver");
131 org_kde_StatusNotifierWatcher_register_notification_approver_async (proxy, APPROVER_PATH, &cats, register_cb, NULL);
132
133 return FALSE;
134 }
135
136 return TRUE;
137}
138
139gboolean
140fail_timeout (gpointer user_data)
141{
142 g_debug("Failure timeout initiated.");
143 g_main_loop_quit(main_loop);
144 return FALSE;
145}
146
147int
148main (int argc, char ** argv)
149{
150 GError * error = NULL;
151
152 gtk_init(&argc, &argv);
153 g_debug("Initing");
154
155 session_bus = dbus_g_bus_get(DBUS_BUS_SESSION, &error);
156 if (error != NULL) {
157 g_warning("Unable to get session bus: %s", error->message);
158 g_error_free(error);
159 return -1;
160 }
161
162 TestApprover * approver = g_object_new(TEST_APPROVER_TYPE, NULL);
163
164 bus_proxy = dbus_g_proxy_new_for_name(session_bus, DBUS_SERVICE_DBUS, DBUS_PATH_DBUS, DBUS_INTERFACE_DBUS);
165
166 g_timeout_add(100, check_for_service, NULL);
167 g_timeout_add_seconds(2, fail_timeout, NULL);
168
169 main_loop = g_main_loop_new(NULL, FALSE);
170 g_main_loop_run(main_loop);
171
172 g_object_unref(approver);
173
174 if (!passed) {
175 return -1;
176 }
177
178 return 0;
179}

Subscribers

People subscribed via source and target branches

to all changes: