Changeset 140398 in webkit
- Timestamp:
- Jan 22, 2013 1:15:07 AM (11 years ago)
- Location:
- trunk
- Files:
-
- 8 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/LayoutTests/ChangeLog
r140395 r140398 1 2013-01-22 Manuel Rego Casasnovas <rego@igalia.com> 2 3 [GTK] Implement testRunner::setTextDirection 4 https://bugs.webkit.org/show_bug.cgi?id=107131 5 6 Reviewed by Philippe Normand. 7 8 * platform/gtk-wk2/TestExpectations: Unflag 9 fast/html/set-text-direction.html as it was already passing in WK2. 10 * platform/gtk/TestExpectations: Remove 11 fast/html/set-text-direction.html. 12 1 13 2013-01-22 Christophe Dumez <christophe.dumez@intel.com> 2 14 -
trunk/LayoutTests/platform/gtk-wk2/TestExpectations
r140258 r140398 508 508 Bug(GTK) fast/events/drag-selects-image.html [ Pass ] 509 509 Bug(GTK) fast/forms/text-input-event.html [ Pass ] 510 Bug(GTK) fast/html/set-text-direction.html [ Pass ]511 510 Bug(GTK) fast/js/names.html [ Pass ] 512 511 Bug(GTK) fast/loader/form-submission-after-beforeunload-cancel.html [ Pass ] -
trunk/LayoutTests/platform/gtk/TestExpectations
r140364 r140398 1087 1087 Bug(GTK) editing/spelling/markers.html [ Skip ] 1088 1088 1089 # testRunner::setTextDirection() is not implemented.1090 Bug(GTK) fast/html/set-text-direction.html [ Failure ]1091 1092 1089 # testRunner.overridePreference("WebKitDefaultFontSize"...) does not take into account screen DPI 1093 1090 webkit.org/b/57160 fast/harness/override-preferences-2.html [ Failure ] -
trunk/Source/WebKit/gtk/ChangeLog
r140336 r140398 1 2013-01-22 Manuel Rego Casasnovas <rego@igalia.com> 2 3 [GTK] Add listener for direction-changed signal in WebKitWebView 4 https://bugs.webkit.org/show_bug.cgi?id=107131 5 6 Reviewed by Philippe Normand. 7 8 * webkit/webkitwebview.cpp: 9 (webkit_web_view_init): Add listener for direction-changed signal. 10 (webkitWebViewDirectionChanged): Implement listener using 11 Editor::setBaseWritingDirection(). 12 1 13 2013-01-21 Oleg Smirnov <oleg.smirnov@lge.com> 2 14 -
trunk/Source/WebKit/gtk/webkit/webkitwebview.cpp
r140153 r140398 270 270 static void webkit_web_view_settings_notify(WebKitWebSettings* webSettings, GParamSpec* pspec, WebKitWebView* webView); 271 271 static void webkit_web_view_set_window_features(WebKitWebView* webView, WebKitWebWindowFeatures* webWindowFeatures); 272 static void webkitWebViewDirectionChanged(WebKitWebView*, GtkTextDirection previousDirection, gpointer); 272 273 273 274 #if ENABLE(CONTEXT_MENUS) … … 3697 3698 priv->acceleratedCompositingContext = AcceleratedCompositingContext::create(webView); 3698 3699 #endif 3700 3701 g_signal_connect(webView, "direction-changed", G_CALLBACK(webkitWebViewDirectionChanged), 0); 3699 3702 } 3700 3703 … … 5362 5365 #endif 5363 5366 5367 void webkitWebViewDirectionChanged(WebKitWebView* webView, GtkTextDirection previousDirection, gpointer) 5368 { 5369 g_return_if_fail(WEBKIT_IS_WEB_VIEW(webView)); 5370 5371 GtkTextDirection direction = gtk_widget_get_direction(GTK_WIDGET(webView)); 5372 5373 Frame* focusedFrame = core(webView)->focusController()->focusedFrame(); 5374 if (!focusedFrame) 5375 return; 5376 5377 Editor* editor = focusedFrame->editor(); 5378 if (!editor || !editor->canEdit()) 5379 return; 5380 5381 switch (direction) { 5382 case GTK_TEXT_DIR_NONE: 5383 editor->setBaseWritingDirection(NaturalWritingDirection); 5384 break; 5385 case GTK_TEXT_DIR_LTR: 5386 editor->setBaseWritingDirection(LeftToRightWritingDirection); 5387 break; 5388 case GTK_TEXT_DIR_RTL: 5389 editor->setBaseWritingDirection(RightToLeftWritingDirection); 5390 break; 5391 default: 5392 g_assert_not_reached(); 5393 return; 5394 } 5395 } 5396 5364 5397 namespace WebKit { 5365 5398 -
trunk/Tools/ChangeLog
r140396 r140398 1 2013-01-22 Manuel Rego Casasnovas <rego@igalia.com> 2 3 [GTK] Implement TestRunner::setTextDirection 4 https://bugs.webkit.org/show_bug.cgi?id=107131 5 6 Reviewed by Philippe Normand. 7 8 * DumpRenderTree/gtk/DumpRenderTree.cpp: 9 (resetDefaultsToConsistentValues): Reset direction to default value. 10 * DumpRenderTree/gtk/TestRunnerGtk.cpp: 11 (TestRunner::setTextDirection): Implement method using 12 gtk_widget_set_direction. 13 1 14 2013-01-22 Jochen Eisinger <jochen@chromium.org> 2 15 -
trunk/Tools/DumpRenderTree/gtk/DumpRenderTree.cpp
r140153 r140398 528 528 gTestRunner->setHandlesAuthenticationChallenges(false); 529 529 } 530 531 gtk_widget_set_direction(GTK_WIDGET(webView), GTK_TEXT_DIR_NONE); 530 532 } 531 533 -
trunk/Tools/DumpRenderTree/gtk/TestRunnerGtk.cpp
r140144 r140398 940 940 void TestRunner::setTextDirection(JSStringRef direction) 941 941 { 942 // FIXME: Implement. 942 GOwnPtr<gchar> writingDirection(JSStringCopyUTF8CString(direction)); 943 944 WebKitWebView* view = webkit_web_frame_get_web_view(mainFrame); 945 ASSERT(view); 946 947 if (g_str_equal(writingDirection.get(), "auto")) 948 gtk_widget_set_direction(GTK_WIDGET(view), GTK_TEXT_DIR_NONE); 949 else if (g_str_equal(writingDirection.get(), "ltr")) 950 gtk_widget_set_direction(GTK_WIDGET(view), GTK_TEXT_DIR_LTR); 951 else if (g_str_equal(writingDirection.get(), "rtl")) 952 gtk_widget_set_direction(GTK_WIDGET(view), GTK_TEXT_DIR_RTL); 953 else 954 fprintf(stderr, "TestRunner::setTextDirection called with unknown direction: '%s'.\n", writingDirection.get()); 943 955 } 944 956
Note: See TracChangeset
for help on using the changeset viewer.