From ec3b5390984fb1b5ca976af0f95b1c9893aacf60 Mon Sep 17 00:00:00 2001 From: Cosimo Cecchi Date: Thu, 31 Jan 2008 18:53:57 +0000 Subject: Fix keyboard focus remaining in the location entry after entering the address. Bug #513345. svn path=/trunk/; revision=7900 --- embed/mozilla/mozilla-embed.cpp | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/embed/mozilla/mozilla-embed.cpp b/embed/mozilla/mozilla-embed.cpp index d8ffc136b..f5f600934 100644 --- a/embed/mozilla/mozilla-embed.cpp +++ b/embed/mozilla/mozilla-embed.cpp @@ -217,7 +217,10 @@ mozilla_embed_grab_focus (GtkWidget *widget) { GtkWidget *child; - child = gtk_bin_get_child (GTK_BIN (widget)); + /* What we want to focus here is the MozContainer inside the + * GtkMozEmbed, because the GtkMozEmbed itself does not gain focus. + */ + child = gtk_bin_get_child (GTK_BIN (MOZILLA_EMBED (widget)->priv->moz_embed)); if (child && GTK_WIDGET_REALIZED (child)) gtk_widget_grab_focus (child); -- cgit v1.2.3