~ubuntu-branches/ubuntu/hardy/pidgin/hardy

« back to all changes in this revision

Viewing changes to finch/libgnt/gntmenuitem.h

  • Committer: Bazaar Package Importer
  • Author(s): Pedro Fragoso
  • Date: 2007-12-21 02:48:06 UTC
  • mfrom: (1.1.7 upstream)
  • Revision ID: james.westby@ubuntu.com-20071221024806-pd44a5k9tiyh12mp
Tags: 1:2.3.1-2ubuntu1
* Sync with Debian, remaining Ubuntu changes; (LP: #177811)
  - Set Maintainer to Ubuntu Core Developers.
  - Add build-deps on liblaunchpad-integration-dev, intltool,
    libnm-glib-dev (for --enable-nm) (Ubuntu #112720).
  - Drop build-deps on libsilc-1.1-2-dev | libsilc-dev (>= 1.1.1) as 
    this library is in universe.
  - Drop the libpurple0 recommends on libpurple-bin.
  - Add a gaim transitionnal package for upgrades.
  - Ship compatibility symlinks via debian/gaim.links.
  - Pass --enable-nm to configure to enable NetworkManager support.
  - Pass --disable-silc to configure to disable silc support even if 
    it's installed in the build environment.
  - Add X-Ubuntu-Gettext-Domain to the desktop file and update the
    translation templates in common-install-impl::.
   - Update debian/prefs.xml to set the notify plugin prefs
    /plugins/gtk/X11/notify/* and set /pidgin/plugins/loaded to load 
    the notify plugin; Ubuntu: #13389.
  - Add LPI integration patch, 02_lpi.
  - Add patch 04_let_crasher_for_apport to stop catching the SIGSEGV signal
    and let apport handle it.
  - Add patch 05_default_to_irc_ubuntu_com to set the default IRC 
    server to irc.ubuntu.com.
  - Add autoconf patch, 70_autoconf.

Show diffs side-by-side

added added

removed removed

Lines of Context:
53
53
        int x;
54
54
        int y;
55
55
        char trigger;
 
56
        char *id;
56
57
};
57
58
 
58
59
typedef void (*GntMenuItemCallback)(GntMenuItem *item, gpointer data);
86
87
G_BEGIN_DECLS
87
88
 
88
89
/**
89
 
 * 
90
 
 *
91
 
 * @return
 
90
 * @return GType for GntMenuItem.
92
91
 */
93
92
GType gnt_menuitem_get_gtype(void);
94
93
 
95
94
/**
96
 
 * 
97
 
 * @param text
98
 
 *
99
 
 * @return
 
95
 * Create a new menuitem.
 
96
 *
 
97
 * @param text   Label for the menuitem.
 
98
 *
 
99
 * @return  The newly created menuitem.
100
100
 */
101
101
GntMenuItem * gnt_menuitem_new(const char *text);
102
102
 
103
103
/**
104
 
 * 
105
 
 * @param item
106
 
 * @param callback
107
 
 * @param data
 
104
 * Set a callback function for a menuitem.
 
105
 *
 
106
 * @param item       The menuitem.
 
107
 * @param callback   The callback function.
 
108
 * @param data       Data to send to the callback function.
108
109
 */
109
110
void gnt_menuitem_set_callback(GntMenuItem *item, GntMenuItemCallback callback, gpointer data);
110
111
 
111
112
/**
112
 
 * 
113
 
 * @param item
114
 
 * @param menu
 
113
 * Set a submenu for a menuitem. A menuitem with a submenu cannot have a callback.
 
114
 *
 
115
 * @param item  The menuitem.
 
116
 * @param menu  The submenu.
115
117
 */
116
118
void gnt_menuitem_set_submenu(GntMenuItem *item, GntMenu *menu);
117
119
 
118
120
/**
 
121
 * Get the submenu for a menuitem.
 
122
 *
 
123
 * @param item   The menuitem.
 
124
 *
 
125
 * @return  The submenu, or @c NULL.
 
126
 *
 
127
 * @since 2.3.0
 
128
 */
 
129
GntMenu *gnt_menuitem_get_submenu(GntMenuItem *item);
 
130
 
 
131
/**
119
132
 * Set a trigger key for the item.
120
133
 *
121
134
 * @param item     The menuitem
134
147
 */
135
148
char gnt_menuitem_get_trigger(GntMenuItem *item);
136
149
 
 
150
/**
 
151
 * Set an ID for the menuitem.
 
152
 *
 
153
 * @param item   The menuitem.
 
154
 * @param id     The ID for the menuitem.
 
155
 *
 
156
 * @since 2.3.0
 
157
 */
 
158
void gnt_menuitem_set_id(GntMenuItem *item, const char *id);
 
159
 
 
160
/**
 
161
 * Get the ID of the menuitem.
 
162
 *
 
163
 * @param item   The menuitem.
 
164
 *
 
165
 * @return  The ID for the menuitem.
 
166
 *
 
167
 * @since 2.3.0
 
168
 */
 
169
const char * gnt_menuitem_get_id(GntMenuItem *item);
 
170
 
 
171
/**
 
172
 * Activate a menuitem.
 
173
 * Activating the menuitem will first trigger the 'activate' signal for the
 
174
 * menuitem. Then the callback for the menuitem is triggered, if there is one.
 
175
 *
 
176
 * @param item   The menuitem.
 
177
 *
 
178
 * @return  Whether the callback for the menuitem was called.
 
179
 *
 
180
 * @since 2.3.0
 
181
 */
 
182
gboolean gnt_menuitem_activate(GntMenuItem *item);
 
183
 
137
184
G_END_DECLS
138
185
 
139
186
#endif /* GNT_MENUITEM_H */