Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #ifndef CONTENT_SHELL_RENDERER_TEST_RUNNER_MOCKWEBRTCDTMFSENDERHANDLER_H_ | 5 #ifndef CONTENT_SHELL_RENDERER_TEST_RUNNER_MOCKWEBRTCDTMFSENDERHANDLER_H_ |
| 6 #define CONTENT_SHELL_RENDERER_TEST_RUNNER_MOCKWEBRTCDTMFSENDERHANDLER_H_ | 6 #define CONTENT_SHELL_RENDERER_TEST_RUNNER_MOCKWEBRTCDTMFSENDERHANDLER_H_ |
| 7 | 7 |
| 8 #include "base/basictypes.h" | 8 #include "base/basictypes.h" |
| 9 #include "content/shell/renderer/test_runner/TestCommon.h" | 9 #include "content/shell/renderer/test_runner/TestCommon.h" |
| 10 #include "content/shell/renderer/test_runner/WebTask.h" | 10 #include "content/shell/renderer/test_runner/WebTask.h" |
| 11 #include "third_party/WebKit/public/platform/WebMediaStreamTrack.h" | 11 #include "third_party/WebKit/public/platform/WebMediaStreamTrack.h" |
| 12 #include "third_party/WebKit/public/platform/WebRTCDTMFSenderHandler.h" | 12 #include "third_party/WebKit/public/platform/WebRTCDTMFSenderHandler.h" |
| 13 #include "third_party/WebKit/public/platform/WebString.h" | 13 #include "third_party/WebKit/public/platform/WebString.h" |
| 14 | 14 |
| 15 namespace content { | 15 namespace content { |
| 16 | 16 |
| 17 class WebTestDelegate; | 17 class WebTestDelegate; |
| 18 | 18 |
| 19 class MockWebRTCDTMFSenderHandler : public blink::WebRTCDTMFSenderHandler { | 19 class MockWebRTCDTMFSenderHandler : public blink::WebRTCDTMFSenderHandler { |
| 20 public: | 20 public: |
| 21 MockWebRTCDTMFSenderHandler(const blink::WebMediaStreamTrack&, WebTestDelega te*); | 21 MockWebRTCDTMFSenderHandler(const blink::WebMediaStreamTrack&, |
|
jochen (gone - plz use gerrit)
2014/06/03 12:55:00
nit. add parameter names
Nikhil
2014/06/04 05:33:55
Done.
| |
| 22 WebTestDelegate*); | |
| 22 | 23 |
| 23 virtual void setClient(blink::WebRTCDTMFSenderHandlerClient*) OVERRIDE; | 24 virtual void setClient(blink::WebRTCDTMFSenderHandlerClient*) OVERRIDE; |
|
jochen (gone - plz use gerrit)
2014/06/03 12:55:00
nit. add a comment saying which interface you're o
Nikhil
2014/06/04 05:33:55
Done.
| |
| 24 | 25 |
| 25 virtual blink::WebString currentToneBuffer() OVERRIDE; | 26 virtual blink::WebString currentToneBuffer() OVERRIDE; |
| 26 | 27 |
| 27 virtual bool canInsertDTMF() OVERRIDE; | 28 virtual bool canInsertDTMF() OVERRIDE; |
| 28 virtual bool insertDTMF(const blink::WebString& tones, long duration, long i nterToneGap) OVERRIDE; | 29 virtual bool insertDTMF(const blink::WebString& tones, |
| 30 long duration, | |
| 31 long inter_tone_gap) OVERRIDE; | |
| 29 | 32 |
| 30 // WebTask related methods | 33 // WebTask related methods |
| 31 WebTaskList* mutable_task_list() { return &m_taskList; } | 34 WebTaskList* mutable_task_list() { return &task_list_; } |
| 32 void clearToneBuffer() { m_toneBuffer.reset(); } | 35 void ClearToneBuffer() { tone_buffer_.reset(); } |
| 33 | 36 |
| 34 private: | 37 private: |
| 35 MockWebRTCDTMFSenderHandler(); | 38 MockWebRTCDTMFSenderHandler(); |
| 36 | 39 |
| 37 blink::WebRTCDTMFSenderHandlerClient* m_client; | 40 blink::WebRTCDTMFSenderHandlerClient* client_; |
| 38 blink::WebMediaStreamTrack m_track; | 41 blink::WebMediaStreamTrack track_; |
| 39 blink::WebString m_toneBuffer; | 42 blink::WebString tone_buffer_; |
| 40 WebTaskList m_taskList; | 43 WebTaskList task_list_; |
| 41 WebTestDelegate* m_delegate; | 44 WebTestDelegate* delegate_; |
| 42 | 45 |
| 43 DISALLOW_COPY_AND_ASSIGN(MockWebRTCDTMFSenderHandler); | 46 DISALLOW_COPY_AND_ASSIGN(MockWebRTCDTMFSenderHandler); |
| 44 }; | 47 }; |
| 45 | 48 |
| 46 } // namespace content | 49 } // namespace content |
| 47 | 50 |
| 48 #endif // CONTENT_SHELL_RENDERER_TEST_RUNNER_MOCKWEBRTCDTMFSENDERHANDLER_H_ | 51 #endif // CONTENT_SHELL_RENDERER_TEST_RUNNER_MOCKWEBRTCDTMFSENDERHANDLER_H_ |
| OLD | NEW |