Rename WebSpeechInputResult::set() to assign()
authorhans@chromium.org <hans@chromium.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Wed, 1 Feb 2012 18:29:20 +0000 (18:29 +0000)
committerhans@chromium.org <hans@chromium.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Wed, 1 Feb 2012 18:29:20 +0000 (18:29 +0000)
https://bugs.webkit.org/show_bug.cgi?id=77540

Reviewed by Darin Fisher.

Source/WebKit/chromium:

It was suggested in a previous code review
(https://bugs.webkit.org/show_bug.cgi?id=77083#c5)
that this function should be called assign().

* public/WebSpeechInputResult.h:
(WebSpeechInputResult):
(WebKit::WebSpeechInputResult::set):
* src/WebSpeechInputResult.cpp:
(WebKit::WebSpeechInputResult::assign):

Tools:

* DumpRenderTree/chromium/MockWebSpeechInputController.cpp:
(MockWebSpeechInputController::addMockRecognitionResult):
(MockWebSpeechInputController::speechTaskFired):

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

Source/WebKit/chromium/ChangeLog
Source/WebKit/chromium/public/WebSpeechInputResult.h
Source/WebKit/chromium/src/WebSpeechInputResult.cpp
Tools/ChangeLog
Tools/DumpRenderTree/chromium/MockWebSpeechInputController.cpp

index c97e4c3..ac9a1f7 100644 (file)
@@ -1,3 +1,20 @@
+2012-02-01  Hans Wennborg  <hans@chromium.org>
+
+        Rename WebSpeechInputResult::set() to assign()
+        https://bugs.webkit.org/show_bug.cgi?id=77540
+
+        Reviewed by Darin Fisher.
+
+        It was suggested in a previous code review
+        (https://bugs.webkit.org/show_bug.cgi?id=77083#c5)
+        that this function should be called assign().
+
+        * public/WebSpeechInputResult.h:
+        (WebSpeechInputResult):
+        (WebKit::WebSpeechInputResult::set):
+        * src/WebSpeechInputResult.cpp:
+        (WebKit::WebSpeechInputResult::assign):
+
 2012-02-01  Kent Tamura  <tkent@chromium.org>
 
         [Chromium] Disable WebFrameTest.FindInPage
index 8d02a49..82eb74a 100644 (file)
@@ -45,7 +45,10 @@ public:
     WebSpeechInputResult(const WebSpeechInputResult& other) { assign(other); }
     ~WebSpeechInputResult() { reset(); }
 
-    WEBKIT_EXPORT void set(const WebString& utterance, double confidence);
+    // FIXME: Remove this when Chromium has been updated.
+    void set(const WebString& utterance, double confidence) { assign(utterance, confidence); }
+
+    WEBKIT_EXPORT void assign(const WebString& utterance, double confidence);
     WEBKIT_EXPORT void assign(const WebSpeechInputResult& other);
     WEBKIT_EXPORT void reset();
 
index 693538f..45de467 100644 (file)
@@ -43,7 +43,7 @@ WebSpeechInputResult::WebSpeechInputResult(const PassRefPtr<WebCore::SpeechInput
 {
 }
 
-void WebSpeechInputResult::set(const WebString& utterance, double confidence)
+void WebSpeechInputResult::assign(const WebString& utterance, double confidence)
 {
     m_private = WebCore::SpeechInputResult::create(utterance, confidence);
 }
index b65415b..8e608d0 100644 (file)
@@ -1,3 +1,14 @@
+2012-02-01  Hans Wennborg  <hans@chromium.org>
+
+        Rename WebSpeechInputResult::set() to assign()
+        https://bugs.webkit.org/show_bug.cgi?id=77540
+
+        Reviewed by Darin Fisher.
+
+        * DumpRenderTree/chromium/MockWebSpeechInputController.cpp:
+        (MockWebSpeechInputController::addMockRecognitionResult):
+        (MockWebSpeechInputController::speechTaskFired):
+
 2012-02-01  Carlos Garcia Campos  <cgarcia@igalia.com>
 
         [GTK] WebKit1 API documentation is not generated when building with gtk-2.0
index 35357a8..0bea45b 100644 (file)
@@ -42,7 +42,7 @@ PassOwnPtr<MockWebSpeechInputController> MockWebSpeechInputController::create(We
 void MockWebSpeechInputController::addMockRecognitionResult(const WebString& result, double confidence, const WebString& language)
 {
     WebSpeechInputResult res;
-    res.set(result, confidence);
+    res.assign(result, confidence);
 
     if (language.isEmpty())
         m_resultsForEmptyLanguage.append(res);
@@ -169,7 +169,7 @@ void MockWebSpeechInputController::speechTaskFired()
             error.append("'");
 
             WebSpeechInputResult res;
-            res.set(WebString::fromUTF8(error.utf8().data()), 1.0);
+            res.assign(WebString::fromUTF8(error.utf8().data()), 1.0);
 
             Vector<WebSpeechInputResult> results;
             results.append(res);