Fix one more GTK+ unit test after r108278.
authorphiln@webkit.org <philn@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Tue, 21 Feb 2012 11:46:07 +0000 (11:46 +0000)
committerphiln@webkit.org <philn@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Tue, 21 Feb 2012 11:46:07 +0000 (11:46 +0000)
Reviewed by Alejandro G. Castro.

* tests/testkeyevents.c:
(map_event_cb): No longer grab focus here.
(setup_keyevent_test): Grabbing focus here seems to be late enough in the process.

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@108334 268f45cc-cd09-0410-ab3c-d52691b4dbfc

Source/WebKit/gtk/ChangeLog
Source/WebKit/gtk/tests/testkeyevents.c

index 62a872e..48d7a72 100644 (file)
@@ -1,3 +1,13 @@
+2012-02-21  Philippe Normand  <pnormand@igalia.com>
+
+        Fix one more GTK+ unit test after r108278.
+
+        Reviewed by Alejandro G. Castro.
+
+        * tests/testkeyevents.c:
+        (map_event_cb): No longer grab focus here.
+        (setup_keyevent_test): Grabbing focus here seems to be late enough in the process.
+
 2012-02-20  Martin Robinson  <mrobinson@igalia.com>
 
         Fix GTK+ unit tests after r108281.
index cf33d4a..b55b4bc 100644 (file)
@@ -118,7 +118,6 @@ static void test_keypress_events_load_status_cb(WebKitWebView* webView, GParamSp
 
 gboolean map_event_cb(GtkWidget *widget, GdkEvent* event, gpointer data)
 {
-    gtk_widget_grab_focus(widget);
     KeyEventFixture* fixture = (KeyEventFixture*)data;
     webkit_web_view_load_string(fixture->webView, fixture->info->page,
                                 "text/html", "utf-8", "file://");
@@ -131,6 +130,7 @@ static void setup_keyevent_test(KeyEventFixture* fixture, gconstpointer data, GC
     g_signal_connect(fixture->window, "map-event",
                      G_CALLBACK(map_event_cb), fixture);
 
+    gtk_widget_grab_focus(GTK_WIDGET(fixture->webView));
     gtk_widget_show(fixture->window);
     gtk_widget_show(GTK_WIDGET(fixture->webView));
     gtk_window_present(GTK_WINDOW(fixture->window));