[gaim-migrate @ 14784]

Tue, 13 Dec 2005 00:49:56 +0000

author
Sadrul Habib Chowdhury <sadrul@pidgin.im>
date
Tue, 13 Dec 2005 00:49:56 +0000
changeset 12473
c905bbdc39ca
parent 12472
1a11e00f8c88
child 12474
630f34dde22d

[gaim-migrate @ 14784]
Sadrul's patch to enable formatting key shortcuts in the statusbox uses a function that was introduced in GTK+ 2.4.0. This will keep things building on older versions, but ideally, we'd find some other way to provide the same functionality that would work on all versions of GTK+ 2.

I'm away from my normal Internet connections. I realized I forgot to commit this before I left, and I just had some downtime so I figured I'd take care of it. The modem on my laptop isn't playing nicely today, so I retyped these changes onto another computer (thankfully MacOS X has an SSH client). If it's broken, please accept my apologies.

committer: Richard Laager <rlaager@pidgin.im>

src/gtkblist.c file | annotate | diff | comparison | revisions
--- a/src/gtkblist.c	Mon Dec 12 20:38:10 2005 +0000
+++ b/src/gtkblist.c	Tue Dec 13 00:49:56 2005 +0000
@@ -3439,6 +3439,7 @@
 	return FALSE;
 }
 
+#if GTK_CHECK_VERSION(2,4,0)
 static gboolean
 gtk_blist_window_key_press_cb(GtkWidget *w, GdkEventKey *event, GaimGtkBuddyList *gtkblist)
 {
@@ -3453,6 +3454,7 @@
 		return TRUE;
 	return FALSE;
 }
+#endif
 
 static void gaim_gtk_blist_show(GaimBuddyList *list)
 {
@@ -3492,7 +3494,9 @@
 	g_signal_connect(G_OBJECT(gtkblist->window), "configure_event", G_CALLBACK(gtk_blist_configure_cb), NULL);
 	g_signal_connect(G_OBJECT(gtkblist->window), "visibility_notify_event", G_CALLBACK(gtk_blist_visibility_cb), NULL);
 	g_signal_connect(G_OBJECT(gtkblist->window), "window_state_event", G_CALLBACK(gtk_blist_window_state_cb), NULL);
+#if GTK_CHECK_VERSION(2,4,0)
 	g_signal_connect(G_OBJECT(gtkblist->window), "key_press_event", G_CALLBACK(gtk_blist_window_key_press_cb), gtkblist);
+#endif
 	gtk_widget_add_events(gtkblist->window, GDK_VISIBILITY_NOTIFY_MASK);
 
 	/******************************* Menu bar *************************************/

mercurial