Title: [153481] trunk/Source/WebKit2
Revision
153481
Author
[email protected]
Date
2013-07-30 10:40:09 -0700 (Tue, 30 Jul 2013)

Log Message

[WK2] Move the implementation of WebEditorClient::checkTextOfParagraph to WebEditorClient.cpp
https://bugs.webkit.org/show_bug.cgi?id=119034

Reviewed by Anders Carlsson.

The Mac and EFL ports use the same implementation of
WebEditorClient::checkTextOfParagraph and GTK will use the same
implementation too. So rather than duplicating the same code in
platform specific files, move the implementation to platform agnostic
WebProcess/WebCoreSupport/WebEditorClient.cpp.

* WebProcess/WebCoreSupport/WebEditorClient.cpp:
(WebKit::WebEditorClient::checkTextOfParagraph):
* WebProcess/WebCoreSupport/efl/WebEditorClientEfl.cpp:
* WebProcess/WebCoreSupport/mac/WebEditorClientMac.mm:

Modified Paths

Diff

Modified: trunk/Source/WebKit2/ChangeLog (153480 => 153481)


--- trunk/Source/WebKit2/ChangeLog	2013-07-30 17:38:57 UTC (rev 153480)
+++ trunk/Source/WebKit2/ChangeLog	2013-07-30 17:40:09 UTC (rev 153481)
@@ -1,3 +1,21 @@
+2013-07-30  Kwang Yul Seo  <[email protected]>
+
+        [WK2] Move the implementation of WebEditorClient::checkTextOfParagraph to WebEditorClient.cpp
+        https://bugs.webkit.org/show_bug.cgi?id=119034
+
+        Reviewed by Anders Carlsson.
+
+        The Mac and EFL ports use the same implementation of
+        WebEditorClient::checkTextOfParagraph and GTK will use the same
+        implementation too. So rather than duplicating the same code in
+        platform specific files, move the implementation to platform agnostic
+        WebProcess/WebCoreSupport/WebEditorClient.cpp.
+
+        * WebProcess/WebCoreSupport/WebEditorClient.cpp:
+        (WebKit::WebEditorClient::checkTextOfParagraph):
+        * WebProcess/WebCoreSupport/efl/WebEditorClientEfl.cpp:
+        * WebProcess/WebCoreSupport/mac/WebEditorClientMac.mm:
+
 2013-07-30  Brian Holt  <[email protected]>
 
         [WebKit2] [Gtk] WebKitResponsePolicyDecision URI response property incorrect

Modified: trunk/Source/WebKit2/WebProcess/WebCoreSupport/WebEditorClient.cpp (153480 => 153481)


--- trunk/Source/WebKit2/WebProcess/WebCoreSupport/WebEditorClient.cpp	2013-07-30 17:38:57 UTC (rev 153480)
+++ trunk/Source/WebKit2/WebProcess/WebCoreSupport/WebEditorClient.cpp	2013-07-30 17:40:09 UTC (rev 153481)
@@ -464,6 +464,14 @@
     *badGrammarLength = resultLength;
 }
 
+#if USE(UNIFIED_TEXT_CHECKING)
+void WebEditorClient::checkTextOfParagraph(const UChar* text, int length, WebCore::TextCheckingTypeMask checkingTypes, Vector<TextCheckingResult>& results)
+{
+    // FIXME: It would be nice if we wouldn't have to copy the text here.
+    m_page->sendSync(Messages::WebPageProxy::CheckTextOfParagraph(String(text, length), checkingTypes), Messages::WebPageProxy::CheckTextOfParagraph::Reply(results));
+}
+#endif
+
 void WebEditorClient::updateSpellingUIWithGrammarString(const String& badGrammarPhrase, const GrammarDetail& grammarDetail)
 {
     m_page->send(Messages::WebPageProxy::UpdateSpellingUIWithGrammarString(badGrammarPhrase, grammarDetail));

Modified: trunk/Source/WebKit2/WebProcess/WebCoreSupport/efl/WebEditorClientEfl.cpp (153480 => 153481)


--- trunk/Source/WebKit2/WebProcess/WebCoreSupport/efl/WebEditorClientEfl.cpp	2013-07-30 17:38:57 UTC (rev 153480)
+++ trunk/Source/WebKit2/WebProcess/WebCoreSupport/efl/WebEditorClientEfl.cpp	2013-07-30 17:40:09 UTC (rev 153481)
@@ -61,11 +61,4 @@
         event->setDefaultHandled();
 }
 
-#if USE(UNIFIED_TEXT_CHECKING)
-void WebEditorClient::checkTextOfParagraph(const UChar* text, int length, WebCore::TextCheckingTypeMask checkingTypes, Vector<TextCheckingResult>& results)
-{
-    m_page->sendSync(Messages::WebPageProxy::CheckTextOfParagraph(String(text, length), checkingTypes), Messages::WebPageProxy::CheckTextOfParagraph::Reply(results));
 }
-#endif
-
-}

Modified: trunk/Source/WebKit2/WebProcess/WebCoreSupport/mac/WebEditorClientMac.mm (153480 => 153481)


--- trunk/Source/WebKit2/WebProcess/WebCoreSupport/mac/WebEditorClientMac.mm	2013-07-30 17:38:57 UTC (rev 153480)
+++ trunk/Source/WebKit2/WebProcess/WebCoreSupport/mac/WebEditorClientMac.mm	2013-07-30 17:40:09 UTC (rev 153481)
@@ -234,10 +234,4 @@
 }
 #endif // USE(AUTOMATIC_TEXT_REPLACEMENT)
 
-void WebEditorClient::checkTextOfParagraph(const UChar* text, int length, WebCore::TextCheckingTypeMask checkingTypes, Vector<TextCheckingResult>& results)
-{
-    // FIXME: It would be nice if we wouldn't have to copy the text here.
-    m_page->sendSync(Messages::WebPageProxy::CheckTextOfParagraph(String(text, length), checkingTypes), Messages::WebPageProxy::CheckTextOfParagraph::Reply(results));
-}
-
 } // namespace WebKit
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to