empathy r2781 - trunk/libempathy-gtk
- From: xclaesse svn gnome org
- To: svn-commits-list gnome org
- Subject: empathy r2781 - trunk/libempathy-gtk
- Date: Fri, 10 Apr 2009 16:53:57 +0000 (UTC)
Author: xclaesse
Date: Fri Apr 10 16:53:57 2009
New Revision: 2781
URL: http://svn.gnome.org/viewvc/empathy?rev=2781&view=rev
Log:
Unset focus from GtkEntry when editing is stopped
From: Davyd Madeley <davyd madeley id au>
Modified:
trunk/libempathy-gtk/empathy-presence-chooser.c
Modified: trunk/libempathy-gtk/empathy-presence-chooser.c
==============================================================================
--- trunk/libempathy-gtk/empathy-presence-chooser.c (original)
+++ trunk/libempathy-gtk/empathy-presence-chooser.c Fri Apr 10 16:53:57 2009
@@ -260,7 +260,13 @@
GTK_ENTRY_ICON_PRIMARY,
TRUE);
- // FIXME - move the focus somewhere
+ /* attempt to get the toplevel for this widget */
+ GtkWidget *window = gtk_widget_get_toplevel (GTK_WIDGET (self));
+ if (GTK_WIDGET_TOPLEVEL (window) && GTK_IS_WINDOW (window))
+ {
+ /* unset the focus */
+ gtk_window_set_focus (GTK_WINDOW (window), NULL);
+ }
priv->editing_status = FALSE;
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]