Changeset 70669 in webkit


Ignore:
Timestamp:
Oct 27, 2010 10:46:18 AM (14 years ago)
Author:
satish@chromium.org
Message:

2010-10-27 Satish Sampath <satish@chromium.org>

Unreviewed, rolling out r70665.
http://trac.webkit.org/changeset/70665
https://bugs.webkit.org/show_bug.cgi?id=47089

Need to address Alexey's review comments.

  • fast/speech/input-text-language-tag-expected.txt: Removed.
  • fast/speech/input-text-language-tag.html: Removed.
  • fast/speech/input-text-speechbutton.html:
  • fast/speech/speech-button-ignore-generated-events.html:
  • platform/chromium/test_expectations.txt:

2010-10-27 Satish Sampath <satish@chromium.org>

Unreviewed, rolling out r70665.
http://trac.webkit.org/changeset/70665
https://bugs.webkit.org/show_bug.cgi?id=47089

Need to address Alexey's review comments.

  • page/SpeechInput.cpp: (WebCore::SpeechInput::startRecognition):
  • page/SpeechInput.h:
  • page/SpeechInputClient.h:
  • platform/mock/SpeechInputClientMock.cpp: (WebCore::SpeechInputClientMock::startRecognition): (WebCore::SpeechInputClientMock::setRecognitionResult): (WebCore::SpeechInputClientMock::timerFired):
  • platform/mock/SpeechInputClientMock.h:
  • rendering/TextControlInnerElements.cpp: (WebCore::TextControlInnerElement::attachInnerElement): (WebCore::SearchFieldCancelButtonElement::detach): (WebCore::SpinButtonElement::defaultEventHandler): (WebCore::InputFieldSpeechButtonElement::defaultEventHandler): (WebCore::InputFieldSpeechButtonElement::detach):

2010-10-27 Satish Sampath <satish@chromium.org>

Unreviewed, rolling out r70665.
http://trac.webkit.org/changeset/70665
https://bugs.webkit.org/show_bug.cgi?id=47089

Need to address Alexey's review comments.

  • public/WebSpeechInputController.h: (WebKit::WebSpeechInputController::startRecognition):
  • public/WebSpeechInputControllerMock.h:
  • src/SpeechInputClientImpl.cpp: (WebKit::SpeechInputClientImpl::startRecognition):
  • src/SpeechInputClientImpl.h:
  • src/WebSpeechInputControllerMockImpl.cpp: (WebKit::WebSpeechInputControllerMockImpl::setMockRecognitionResult): (WebKit::WebSpeechInputControllerMockImpl::startRecognition):
  • src/WebSpeechInputControllerMockImpl.h:
  • src/WebViewImpl.cpp: (WebKit::WebViewImpl::WebViewImpl):
  • src/WebViewImpl.h:

2010-10-27 Satish Sampath <satish@chromium.org>

Unreviewed, rolling out r70665.
http://trac.webkit.org/changeset/70665
https://bugs.webkit.org/show_bug.cgi?id=47089

Need to address Alexey's review comments.

  • DumpRenderTree/LayoutTestController.cpp: (setMockSpeechInputResultCallback):
  • DumpRenderTree/LayoutTestController.h:
  • DumpRenderTree/chromium/LayoutTestController.cpp: (LayoutTestController::setMockSpeechInputResult):
  • DumpRenderTree/gtk/LayoutTestControllerGtk.cpp: (LayoutTestController::setMockSpeechInputResult):
  • DumpRenderTree/mac/LayoutTestControllerMac.mm: (LayoutTestController::setMockSpeechInputResult):
  • DumpRenderTree/qt/LayoutTestControllerQt.cpp: (LayoutTestController::setMockSpeechInputResult):
  • DumpRenderTree/qt/LayoutTestControllerQt.h:
  • DumpRenderTree/win/LayoutTestControllerWin.cpp: (LayoutTestController::setMockSpeechInputResult):
  • DumpRenderTree/wx/LayoutTestControllerWx.cpp: (LayoutTestController::setMockSpeechInputResult):
Location:
trunk
Files:
2 deleted
30 edited

Legend:

Unmodified
Added
Removed
  • trunk/LayoutTests/ChangeLog

    r70667 r70669  
     12010-10-27  Satish Sampath  <satish@chromium.org>
     2
     3        Unreviewed, rolling out r70665.
     4        http://trac.webkit.org/changeset/70665
     5        https://bugs.webkit.org/show_bug.cgi?id=47089
     6
     7        Need to address Alexey's review comments.
     8
     9        * fast/speech/input-text-language-tag-expected.txt: Removed.
     10        * fast/speech/input-text-language-tag.html: Removed.
     11        * fast/speech/input-text-speechbutton.html:
     12        * fast/speech/speech-button-ignore-generated-events.html:
     13        * platform/chromium/test_expectations.txt:
     14
    1152010-10-27  Dimitri Glazkov  <dglazkov@chromium.org>
    216
  • trunk/LayoutTests/fast/speech/input-text-speechbutton.html

    r70665 r70669  
    3333function run() {
    3434    if (window.layoutTestController && window.eventSender) {
    35         layoutTestController.setMockSpeechInputResult('Pictures of the moon', '');
     35        layoutTestController.setMockSpeechInputResult('Pictures of the moon');
    3636
    3737        // Clicking the speech button should fill in mock speech-recognized text.
  • trunk/LayoutTests/fast/speech/speech-button-ignore-generated-events.html

    r70665 r70669  
    5050    if (window.layoutTestController && window.eventSender) {
    5151        // Running in DRT, test the eventSender case.
    52         layoutTestController.setMockSpeechInputResult('Pictures of the moon', '');
     52        layoutTestController.setMockSpeechInputResult('Pictures of the moon');
    5353        document.getElementById('speechInput').onwebkitspeechchange = function() {
    5454            shouldBeEqualToString('document.getElementById("speechInput").value', 'Pictures of the moon');
  • trunk/LayoutTests/platform/chromium/test_expectations.txt

    r70665 r70669  
    32543254// Chromium-mac-specific test, and only runs in DRT.
    32553255BUGWK46868 : platform/chromium/fast/text/chromium-mac-duplicate-ime-composition.html = TEXT
    3256 
    3257 // Temporarily disabled for a 4-sided patch. Will be enabled again by BUGWK47420.
    3258 BUGWK47089 : fast/speech/input-text-language-tag.html = FAIL
  • trunk/WebCore/ChangeLog

    r70666 r70669  
     12010-10-27  Satish Sampath  <satish@chromium.org>
     2
     3        Unreviewed, rolling out r70665.
     4        http://trac.webkit.org/changeset/70665
     5        https://bugs.webkit.org/show_bug.cgi?id=47089
     6
     7        Need to address Alexey's review comments.
     8
     9        * page/SpeechInput.cpp:
     10        (WebCore::SpeechInput::startRecognition):
     11        * page/SpeechInput.h:
     12        * page/SpeechInputClient.h:
     13        * platform/mock/SpeechInputClientMock.cpp:
     14        (WebCore::SpeechInputClientMock::startRecognition):
     15        (WebCore::SpeechInputClientMock::setRecognitionResult):
     16        (WebCore::SpeechInputClientMock::timerFired):
     17        * platform/mock/SpeechInputClientMock.h:
     18        * rendering/TextControlInnerElements.cpp:
     19        (WebCore::TextControlInnerElement::attachInnerElement):
     20        (WebCore::SearchFieldCancelButtonElement::detach):
     21        (WebCore::SpinButtonElement::defaultEventHandler):
     22        (WebCore::InputFieldSpeechButtonElement::defaultEventHandler):
     23        (WebCore::InputFieldSpeechButtonElement::detach):
     24
    1252010-10-27  ZHenyao Mo  <zmo@google.com>
    226
  • trunk/WebCore/page/SpeechInput.cpp

    r70665 r70669  
    9494}
    9595
    96 bool SpeechInput::startRecognition(int listenerId, const String& language, const IntRect& elementRect, const String& grammar)
     96bool SpeechInput::startRecognition(int listenerId, const IntRect& elementRect, const String& grammar)
    9797{
    9898    ASSERT(m_listeners.contains(listenerId));
    99     return m_client->startRecognition(listenerId, language, elementRect, grammar);
     99    return m_client->startRecognition(listenerId, elementRect, grammar);
    100100}
    101101
  • trunk/WebCore/page/SpeechInput.h

    r70665 r70669  
    6262
    6363    // Methods invoked by the input elements.
    64     bool startRecognition(int listenerId, const String& language, const IntRect& elementRect, const String& grammar);
     64    bool startRecognition(int listenerId, const IntRect& elementRect, const String& grammar);
    6565    void stopRecording(int);
    6666    void cancelRecognition(int);
  • trunk/WebCore/page/SpeechInputClient.h

    r70665 r70669  
    5151
    5252    // Starts speech recognition and audio recording.
    53     virtual bool startRecognition(int requestId, const String& language, const IntRect& elementRect, const String& grammar) = 0;
     53    virtual bool startRecognition(int requestId, const IntRect& elementRect, const String& grammar) = 0;
    5454
    5555    // Stops audio recording and performs recognition with the audio recorded until now
  • trunk/WebCore/platform/mock/SpeechInputClientMock.cpp

    r70665 r70669  
    3636#include "SpeechInputListener.h"
    3737
    38 namespace {
    39     // HashMap doesn't support empty strings as keys, so this value (an invalid BCP47 tag) is used for those cases.
    40     const String emptyLanguage = "_";
    41 }
    42 
    4338namespace WebCore {
    4439
     
    5651}
    5752
    58 bool SpeechInputClientMock::startRecognition(int requestId, const String& language, const IntRect& elementRect, const String& grammar)
     53bool SpeechInputClientMock::startRecognition(int requestId, const IntRect& elementRect, const String& grammar)
    5954{
    6055    if (m_timer.isActive())
     
    6257    m_requestId = requestId;
    6358    m_recording = true;
    64     m_language = language;
    6559    m_timer.startOneShot(0);
    6660    return true;
     
    8781}
    8882
    89 void SpeechInputClientMock::setRecognitionResult(const String& result, const String& language)
     83void SpeechInputClientMock::setRecognitionResult(const String& result)
    9084{
    91     if (language.isEmpty())
    92         m_recognitionResult.set(emptyLanguage, result);
    93     else
    94         m_recognitionResult.set(language, result);
     85    m_recognitionResult = result;
    9586}
    9687
     
    10394    } else {
    10495        SpeechInputResultArray results;
    105 
    106         // Empty language strings crash the HashMap. Using an invalid language value for that case.
    107         String language = m_language.isEmpty() ? String(emptyLanguage) : m_language;
    108         if (!m_recognitionResult.contains(language)) {
    109             // Can't avoid setting a result on empty or invalid language strings.
    110             // This would avoid generating the events used to check the results and the test would timeout.
    111             String error("error: no result found for language '");
    112             error.append(m_language);
    113             error.append("'");
    114             results.append(SpeechInputResult::create(error, 1.0));
    115         } else
    116             results.append(SpeechInputResult::create(m_recognitionResult.get(language), 1.0));
    117 
     96        results.append(SpeechInputResult::create(m_recognitionResult, 1.0));
    11897        m_listener->setRecognitionResult(m_requestId, results);
    11998        m_listener->didCompleteRecognition(m_requestId);
  • trunk/WebCore/platform/mock/SpeechInputClientMock.h

    r70665 r70669  
    3535#include "SpeechInputClient.h"
    3636#include "Timer.h"
    37 #include <wtf/HashMap.h>
    38 #include <wtf/text/StringHash.h>
    3937
    4038#if ENABLE(INPUT_SPEECH)
     
    4947    SpeechInputClientMock();
    5048
    51     void setRecognitionResult(const String& result, const String& language);
     49    void setRecognitionResult(const String& result);
    5250
    5351    // SpeechInputClient methods.
    5452    void setListener(SpeechInputListener*);
    55     bool startRecognition(int requestId, const String& language, const IntRect& elementRect, const String& grammar);
     53    bool startRecognition(int requestId, const IntRect& elementRect, const String& grammar);
    5654    void stopRecording(int);
    5755    void cancelRecognition(int);
     
    6462    SpeechInputListener* m_listener;
    6563    int m_requestId;
    66 
    67     HashMap<String, String> m_recognitionResult;
    68     String m_language;
     64    String m_recognitionResult;
    6965};
    7066
  • trunk/WebCore/rendering/TextControlInnerElements.cpp

    r70665 r70669  
    2222 * OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
    2323 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
    24  * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
     24 * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 
    2525 */
    26 
     26 
    2727#include "config.h"
    2828#include "TextControlInnerElements.h"
     
    108108        renderer->setStyle(style);
    109109    }
    110 
     110   
    111111    // Set these explicitly since this normally happens during an attach()
    112112    setAttached();
    113113    setInDocument();
    114 
     114   
    115115    // For elements without a shadow parent, add the node to the DOM normally.
    116116    if (!m_shadowParent) {
     
    119119        parent->deprecatedParserAddChild(this);
    120120    }
    121 
     121 
    122122    // Add the renderer to the render tree
    123123    if (renderer)
     
    209209    if (m_capturing) {
    210210        if (Frame* frame = document()->frame())
    211             frame->eventHandler()->setCapturingMouseEventsNode(0);
     211            frame->eventHandler()->setCapturingMouseEventsNode(0);     
    212212    }
    213213    TextControlInnerElement::detach();
     
    282282        if (!event->defaultHandled())
    283283            HTMLDivElement::defaultEventHandler(event);
    284         return;
    285     }
    286 
     284        return;       
     285    }
     286   
    287287    HTMLInputElement* input = static_cast<HTMLInputElement*>(shadowAncestorNode());
    288288    if (input->disabled() || input->isReadOnlyFormControl()) {
     
    432432        switch (m_state) {
    433433        case Idle:
    434             if (speechInput()->startRecognition(m_listenerId, input->computeInheritedLanguage(), input->renderer()->absoluteBoundingBoxRect(), input->getAttribute(webkitgrammarAttr)))
     434            if (speechInput()->startRecognition(m_listenerId, input->renderer()->absoluteBoundingBoxRect(), input->getAttribute(webkitgrammarAttr)))
    435435                setState(Recording);
    436436            break;
     
    490490    if (m_capturing) {
    491491        if (Frame* frame = document()->frame())
    492             frame->eventHandler()->setCapturingMouseEventsNode(0);
     492            frame->eventHandler()->setCapturingMouseEventsNode(0);     
    493493    }
    494494
  • trunk/WebKit/chromium/ChangeLog

    r70666 r70669  
     12010-10-27  Satish Sampath  <satish@chromium.org>
     2
     3        Unreviewed, rolling out r70665.
     4        http://trac.webkit.org/changeset/70665
     5        https://bugs.webkit.org/show_bug.cgi?id=47089
     6
     7        Need to address Alexey's review comments.
     8
     9        * public/WebSpeechInputController.h:
     10        (WebKit::WebSpeechInputController::startRecognition):
     11        * public/WebSpeechInputControllerMock.h:
     12        * src/SpeechInputClientImpl.cpp:
     13        (WebKit::SpeechInputClientImpl::startRecognition):
     14        * src/SpeechInputClientImpl.h:
     15        * src/WebSpeechInputControllerMockImpl.cpp:
     16        (WebKit::WebSpeechInputControllerMockImpl::setMockRecognitionResult):
     17        (WebKit::WebSpeechInputControllerMockImpl::startRecognition):
     18        * src/WebSpeechInputControllerMockImpl.h:
     19        * src/WebViewImpl.cpp:
     20        (WebKit::WebViewImpl::WebViewImpl):
     21        * src/WebViewImpl.h:
     22
    1232010-10-27  ZHenyao Mo  <zmo@google.com>
    224
  • trunk/WebKit/chromium/public/WebSpeechInputController.h

    r70665 r70669  
    3636namespace WebKit {
    3737
    38 class WebString;
    3938struct WebRect;
    4039class WebString;
     
    4645    // runs to the limit or stopRecording is called. Progress indications and the recognized
    4746    // text are returned via the listener interface.
    48     virtual bool startRecognition(int requestId, const WebString& language, const WebRect& elementRect, const WebString& grammar)
     47    virtual bool startRecognition(int requestId, const WebRect& elementRect, const WebString& grammar)
    4948    {
    50         startRecognition(requestId, language, elementRect);
     49        startRecognition(requestId, elementRect);
    5150        return false;
    5251    }
    5352
    5453    // FIXME: Remove this method once chromium implements the above method.
    55     virtual bool startRecognition(int requestId, const WebString& language, const WebRect& elementRect)
     54    virtual bool startRecognition(int requestId, const WebRect&)
    5655    {
    5756        WEBKIT_ASSERT_NOT_REACHED();
  • trunk/WebKit/chromium/public/WebSpeechInputControllerMock.h

    r70665 r70669  
    4545    virtual ~WebSpeechInputControllerMock() { }
    4646
    47     virtual void setMockRecognitionResult(const WebString& result, const WebString& language) = 0;
    48 
    49     // FIXME: this is a fix for a two-sided patch. Delete as soon as the chromium side is patched.
    50     // Chromium patch not uploaded yet, but will depend on http://codereview.chromium.org/3615005/show patch.
    5147    virtual void setMockRecognitionResult(const WebString& result) = 0;
    5248};
  • trunk/WebKit/chromium/src/SpeechInputClientImpl.cpp

    r70665 r70669  
    3333
    3434#include "PlatformString.h"
    35 #include "SpeechInputListener.h"
    3635#include "WebSpeechInputController.h"
    3736#include "WebString.h"
    3837#include "WebViewClient.h"
    39 #include <wtf/PassOwnPtr.h>
     38#include "page/SpeechInputListener.h"
    4039
    4140#if ENABLE(INPUT_SPEECH)
    4241
    4342namespace WebKit {
    44 
    45 PassOwnPtr<SpeechInputClientImpl> SpeechInputClientImpl::create(WebViewClient* client)
    46 {
    47     return adoptPtr(new SpeechInputClientImpl(client));
    48 }
    4943
    5044SpeechInputClientImpl::SpeechInputClientImpl(WebViewClient* web_view_client)
     
    6357}
    6458
    65 bool SpeechInputClientImpl::startRecognition(int requestId, const String& language, const WebCore::IntRect& elementRect, const String& grammar)
     59bool SpeechInputClientImpl::startRecognition(int requestId, const WebCore::IntRect& elementRect, const WTF::String& grammar)
    6660{
    6761    ASSERT(m_listener);
    68     return m_controller->startRecognition(requestId, language, elementRect, grammar);
     62    return m_controller->startRecognition(requestId, elementRect, grammar);
    6963}
    7064
  • trunk/WebKit/chromium/src/SpeechInputClientImpl.h

    r70665 r70669  
    3434#if ENABLE(INPUT_SPEECH)
    3535
    36 #include "SpeechInputClient.h"
    3736#include "WebSpeechInputListener.h"
    38 #include <wtf/Forward.h>
    39 #include <wtf/OwnPtr.h>
    40 #include <wtf/PassOwnPtr.h>
     37#include "page/SpeechInputClient.h"
    4138
    4239namespace WebCore {
     
    5350      public WebSpeechInputListener {
    5451public:
    55     static PassOwnPtr<SpeechInputClientImpl> create(WebViewClient*);
     52    SpeechInputClientImpl(WebViewClient*);
    5653    virtual ~SpeechInputClientImpl();
    5754
    5855    // SpeechInputClient methods.
    5956    void setListener(WebCore::SpeechInputListener*);
    60     bool startRecognition(int requestId, const String& language, const WebCore::IntRect& elementRect, const String& grammar);
     57    bool startRecognition(int requestId, const WebCore::IntRect& elementRect, const WTF::String& grammar);
    6158    void stopRecording(int);
    6259    void cancelRecognition(int);
     
    6865
    6966private:
    70     SpeechInputClientImpl(WebViewClient*);
    71 
    7267    WebSpeechInputController* m_controller; // To call into the embedder.
    7368    WebCore::SpeechInputListener* m_listener;
  • trunk/WebKit/chromium/src/WebSpeechInputControllerMockImpl.cpp

    r70665 r70669  
    5858void WebSpeechInputControllerMockImpl::setMockRecognitionResult(const WebString& result)
    5959{
    60     m_webcoreMock->setRecognitionResult(result, WebString::fromUTF8(""));
    61 }
    62 
    63 void WebSpeechInputControllerMockImpl::setMockRecognitionResult(const WebString& result, const WebString &language)
    64 {
    65     m_webcoreMock->setRecognitionResult(result, language);
     60    m_webcoreMock->setRecognitionResult(result);
    6661}
    6762
     
    8176}
    8277
    83 bool WebSpeechInputControllerMockImpl::startRecognition(int requestId, const WebString& language, const WebRect& elementRect, const WebString& grammar)
     78bool WebSpeechInputControllerMockImpl::startRecognition(int requestId, const WebRect& elementRect, const WebString& grammar)
    8479{
    85     return m_webcoreMock->startRecognition(requestId, language, elementRect, grammar);
     80    return m_webcoreMock->startRecognition(requestId, elementRect, grammar);
    8681}
    8782
  • trunk/WebKit/chromium/src/WebSpeechInputControllerMockImpl.h

    r70665 r70669  
    5858
    5959    // WebSpeechInputController methods.
    60     bool startRecognition(int requestId, const WebString& language, const WebRect& elementRect, const WebString& grammar);
     60    bool startRecognition(int requestId, const WebRect& elementRect, const WebString& grammar);
    6161    void cancelRecognition(int requestId);
    6262    void stopRecording(int requestId);
    6363
    6464    // WebSpeechInputControllerMock methods.
    65     void setMockRecognitionResult(const WebString& result, const WebString& language);
    66 
    67     // FIXME: this is a fix for a two-sided patch. Delete as soon as the chromium side is patched.
    68     // Chromium patch not uploaded yet, but will depend on http://codereview.chromium.org/3615005/show patch.
    6965    void setMockRecognitionResult(const WebString& result);
    7066
     
    7773
    7874#endif // WebSpeechInputControllerMockImpl_h
     75
  • trunk/WebKit/chromium/src/WebViewImpl.cpp

    r70665 r70669  
    8989#include "SelectionController.h"
    9090#include "Settings.h"
    91 #include "SpeechInputClientImpl.h"
    9291#include "Timer.h"
    9392#include "TypingCommand.h"
     
    284283#endif
    285284#if ENABLE(INPUT_SPEECH)
    286     , m_speechInputClient(SpeechInputClientImpl::create(client))
     285    , m_speechInputClient(client)
    287286#endif
    288287    , m_deviceOrientationClientProxy(new DeviceOrientationClientProxy(client ? client->deviceOrientationClient() : 0))
     
    307306    pageClients.inspectorClient = &m_inspectorClientImpl;
    308307#if ENABLE(INPUT_SPEECH)
    309     pageClients.speechInputClient = m_speechInputClient.get();
     308    pageClients.speechInputClient = &m_speechInputClient;
    310309#endif
    311310    pageClients.deviceOrientationClient = m_deviceOrientationClientProxy.get();
  • trunk/WebKit/chromium/src/WebViewImpl.h

    r70665 r70669  
    5050#include "LayerRendererChromium.h"
    5151#include "NotificationPresenterImpl.h"
     52#include "SpeechInputClientImpl.h"
    5253#include <wtf/OwnPtr.h>
    5354#include <wtf/RefCounted.h>
     
    7475class DeviceOrientationClientProxy;
    7576class DragScrollTimer;
    76 class SpeechInputClientImpl;
    7777class WebAccessibilityObject;
    7878class WebDevToolsAgentClient;
     
    549549
    550550#if ENABLE(INPUT_SPEECH)
    551     OwnPtr<SpeechInputClientImpl> m_speechInputClient;
     551    SpeechInputClientImpl m_speechInputClient;
    552552#endif
    553553    // If we attempt to fetch the on-screen GraphicsContext3D before
  • trunk/WebKitTools/ChangeLog

    r70665 r70669  
     12010-10-27  Satish Sampath  <satish@chromium.org>
     2
     3        Unreviewed, rolling out r70665.
     4        http://trac.webkit.org/changeset/70665
     5        https://bugs.webkit.org/show_bug.cgi?id=47089
     6
     7        Need to address Alexey's review comments.
     8
     9        * DumpRenderTree/LayoutTestController.cpp:
     10        (setMockSpeechInputResultCallback):
     11        * DumpRenderTree/LayoutTestController.h:
     12        * DumpRenderTree/chromium/LayoutTestController.cpp:
     13        (LayoutTestController::setMockSpeechInputResult):
     14        * DumpRenderTree/gtk/LayoutTestControllerGtk.cpp:
     15        (LayoutTestController::setMockSpeechInputResult):
     16        * DumpRenderTree/mac/LayoutTestControllerMac.mm:
     17        (LayoutTestController::setMockSpeechInputResult):
     18        * DumpRenderTree/qt/LayoutTestControllerQt.cpp:
     19        (LayoutTestController::setMockSpeechInputResult):
     20        * DumpRenderTree/qt/LayoutTestControllerQt.h:
     21        * DumpRenderTree/win/LayoutTestControllerWin.cpp:
     22        (LayoutTestController::setMockSpeechInputResult):
     23        * DumpRenderTree/wx/LayoutTestControllerWx.cpp:
     24        (LayoutTestController::setMockSpeechInputResult):
     25
    1262010-10-27  Leandro Gracia Gil  <leandrogracia@google.com>
    227
  • trunk/WebKitTools/DumpRenderTree/LayoutTestController.cpp

    r70665 r70669  
    10791079static JSValueRef setMockSpeechInputResultCallback(JSContextRef context, JSObjectRef function, JSObjectRef thisObject, size_t argumentCount, const JSValueRef arguments[], JSValueRef* exception)
    10801080{
    1081     if (argumentCount < 2)
     1081    if (argumentCount < 1)
    10821082        return JSValueMakeUndefined(context);
    10831083
     
    10851085    ASSERT(!*exception);
    10861086
    1087     JSRetainPtr<JSStringRef> language(Adopt, JSValueToStringCopy(context, arguments[1], exception));
    1088     ASSERT(!*exception);
    1089 
    1090     LayoutTestController* controller = static_cast<LayoutTestController*>(JSObjectGetPrivate(thisObject));
    1091     controller->setMockSpeechInputResult(result.get(), language.get());
     1087    LayoutTestController* controller = static_cast<LayoutTestController*>(JSObjectGetPrivate(thisObject));
     1088    controller->setMockSpeechInputResult(result.get());
    10921089
    10931090    return JSValueMakeUndefined(context);
  • trunk/WebKitTools/DumpRenderTree/LayoutTestController.h

    r70665 r70669  
    9595    void setMockGeolocationError(int code, JSStringRef message);
    9696    void setMockGeolocationPosition(double latitude, double longitude, double accuracy);
    97     void setMockSpeechInputResult(JSStringRef result, JSStringRef language);
     97    void setMockSpeechInputResult(JSStringRef result);
    9898    void setPersistentUserStyleSheetLocation(JSStringRef path);
    9999    void setPluginsEnabled(bool flag);
  • trunk/WebKitTools/DumpRenderTree/chromium/LayoutTestController.cpp

    r70665 r70669  
    15351535{
    15361536    result->setNull();
    1537     if (arguments.size() < 2 || !arguments[0].isString() || !arguments[1].isString())
    1538         return;
    1539 
    1540     m_speechInputControllerMock->setMockRecognitionResult(cppVariantToWebString(arguments[0]), cppVariantToWebString(arguments[1]));
     1537    if (arguments.size() < 1 || !arguments[0].isString())
     1538        return;
     1539
     1540    m_speechInputControllerMock->setMockRecognitionResult(cppVariantToWebString(arguments[0]));
    15411541}
    15421542
  • trunk/WebKitTools/DumpRenderTree/gtk/LayoutTestControllerGtk.cpp

    r70665 r70669  
    502502}
    503503
    504 void LayoutTestController::setMockSpeechInputResult(JSStringRef result, JSStringRef language)
     504void LayoutTestController::setMockSpeechInputResult(JSStringRef result)
    505505{
    506506    // FIXME: Implement for speech input layout tests.
  • trunk/WebKitTools/DumpRenderTree/mac/LayoutTestControllerMac.mm

    r70665 r70669  
    372372}
    373373
    374 void LayoutTestController::setMockSpeechInputResult(JSStringRef result, JSStringRef language)
     374void LayoutTestController::setMockSpeechInputResult(JSStringRef result)
    375375{
    376376    // FIXME: Implement for speech input layout tests.
  • trunk/WebKitTools/DumpRenderTree/qt/LayoutTestControllerQt.cpp

    r70665 r70669  
    766766}
    767767
    768 void LayoutTestController::setMockSpeechInputResult(const QString& result, const QString& language)
     768void LayoutTestController::setMockSpeechInputResult(const QString& result)
    769769{
    770770    // FIXME: Implement for speech input layout tests.
  • trunk/WebKitTools/DumpRenderTree/qt/LayoutTestControllerQt.h

    r70665 r70669  
    217217    bool geolocationPermission() const { return m_geolocationPermission; }
    218218
    219     void setMockSpeechInputResult(const QString& result, const QString& language);
     219    void setMockSpeechInputResult(const QString& result);
    220220
    221221    // Empty stub method to keep parity with object model exposed by global LayoutTestController.
  • trunk/WebKitTools/DumpRenderTree/win/LayoutTestControllerWin.cpp

    r70665 r70669  
    406406}
    407407
    408 void LayoutTestController::setMockSpeechInputResult(JSStringRef result, JSStringRef language)
     408void LayoutTestController::setMockSpeechInputResult(JSStringRef result)
    409409{
    410410    // FIXME: Implement for speech input layout tests.
  • trunk/WebKitTools/DumpRenderTree/wx/LayoutTestControllerWx.cpp

    r70665 r70669  
    321321}
    322322
    323 void LayoutTestController::setMockSpeechInputResult(JSStringRef result, JSStringRef language)
     323void LayoutTestController::setMockSpeechInputResult(JSStringRef result)
    324324{
    325325    // FIXME: Implement for speech input layout tests.
     
    529529    return 0;
    530530}
     531
Note: See TracChangeset for help on using the changeset viewer.