comparison plugins/docklet/docklet-x11.c @ 10505:91f17026b693

[gaim-migrate @ 11799] Fix the docklet to work with Gtk < 2.2 (without the cool positioning function though). committer: Tailor Script <tailor@pidgin.im>
author Stu Tomlinson <stu@nosnilmot.com>
date Tue, 11 Jan 2005 21:51:26 +0000
parents 1a97d5e88d12
children 77ef3f2f0df8
comparison
equal deleted inserted replaced
10504:1a97d5e88d12 10505:91f17026b693
127 } 127 }
128 128
129 gtk_image_set_from_pixbuf(GTK_IMAGE(image), blank_icon); 129 gtk_image_set_from_pixbuf(GTK_IMAGE(image), blank_icon);
130 } 130 }
131 131
132 #if GTK_CHECK_VERSION(2,2,0)
132 static void 133 static void
133 docklet_x11_position_menu(GtkMenu *menu, int *x, int *y, gboolean *push_in, 134 docklet_x11_position_menu(GtkMenu *menu, int *x, int *y, gboolean *push_in,
134 gpointer user_data) 135 gpointer user_data)
135 { 136 {
136 GtkWidget *widget = GTK_WIDGET(docklet); 137 GtkWidget *widget = GTK_WIDGET(docklet);
151 *x = menu_xpos; 152 *x = menu_xpos;
152 *y = menu_ypos; 153 *y = menu_ypos;
153 154
154 *push_in = TRUE; 155 *push_in = TRUE;
155 } 156 }
157 #endif
156 158
157 static void 159 static void
158 docklet_x11_destroy() 160 docklet_x11_destroy()
159 { 161 {
160 g_return_if_fail(docklet != NULL); 162 g_return_if_fail(docklet != NULL);
227 { 229 {
228 docklet_x11_create, 230 docklet_x11_create,
229 docklet_x11_destroy, 231 docklet_x11_destroy,
230 docklet_x11_update_icon, 232 docklet_x11_update_icon,
231 docklet_x11_blank_icon, 233 docklet_x11_blank_icon,
234 #if GTK_CHECK_VERSION(2,2,0)
232 docklet_x11_position_menu 235 docklet_x11_position_menu
236 #else
237 NULL
238 #endif
233 }; 239 };
234 240
235 void 241 void
236 docklet_ui_init() 242 docklet_ui_init()
237 { 243 {