| OLD | NEW |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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 COMPONENTS_TEST_RUNNER_WEB_TEST_PROXY_H_ | 5 #ifndef COMPONENTS_TEST_RUNNER_WEB_TEST_PROXY_H_ |
| 6 #define COMPONENTS_TEST_RUNNER_WEB_TEST_PROXY_H_ | 6 #define COMPONENTS_TEST_RUNNER_WEB_TEST_PROXY_H_ |
| 7 | 7 |
| 8 #include <string> | 8 #include <string> |
| 9 | 9 |
| 10 #include "base/callback.h" | 10 #include "base/callback.h" |
| (...skipping 73 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 84 void GetScreenOrientationForTesting(blink::WebScreenInfo&); | 84 void GetScreenOrientationForTesting(blink::WebScreenInfo&); |
| 85 MockWebSpeechRecognizer* GetSpeechRecognizerMock(); | 85 MockWebSpeechRecognizer* GetSpeechRecognizerMock(); |
| 86 MockCredentialManagerClient* GetCredentialManagerClientMock(); | 86 MockCredentialManagerClient* GetCredentialManagerClientMock(); |
| 87 | 87 |
| 88 WebTaskList* mutable_task_list() { return &task_list_; } | 88 WebTaskList* mutable_task_list() { return &task_list_; } |
| 89 | 89 |
| 90 blink::WebView* GetWebView() const; | 90 blink::WebView* GetWebView() const; |
| 91 | 91 |
| 92 void PostSpellCheckEvent(const blink::WebString& event_name); | 92 void PostSpellCheckEvent(const blink::WebString& event_name); |
| 93 | 93 |
| 94 void SetAcceptLanguages(const std::string& accept_languages); | |
| 95 | |
| 96 bool AnimationScheduled() { return animate_scheduled_; } | 94 bool AnimationScheduled() { return animate_scheduled_; } |
| 97 | 95 |
| 98 protected: | 96 protected: |
| 99 WebTestProxyBase(); | 97 WebTestProxyBase(); |
| 100 ~WebTestProxyBase(); | 98 ~WebTestProxyBase(); |
| 101 | 99 |
| 102 void ScheduleAnimation(); | 100 void ScheduleAnimation(); |
| 103 void StartDragging(blink::WebLocalFrame* frame, | 101 void StartDragging(blink::WebLocalFrame* frame, |
| 104 const blink::WebDragData& data, | 102 const blink::WebDragData& data, |
| 105 blink::WebDragOperationsMask mask, | 103 blink::WebDragOperationsMask mask, |
| (...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 142 | 140 |
| 143 blink::WebImage drag_image_; | 141 blink::WebImage drag_image_; |
| 144 | 142 |
| 145 scoped_ptr<SpellCheckClient> spellcheck_; | 143 scoped_ptr<SpellCheckClient> spellcheck_; |
| 146 | 144 |
| 147 bool animate_scheduled_; | 145 bool animate_scheduled_; |
| 148 | 146 |
| 149 scoped_ptr<MockCredentialManagerClient> credential_manager_client_; | 147 scoped_ptr<MockCredentialManagerClient> credential_manager_client_; |
| 150 scoped_ptr<MockWebSpeechRecognizer> speech_recognizer_; | 148 scoped_ptr<MockWebSpeechRecognizer> speech_recognizer_; |
| 151 | 149 |
| 152 std::string accept_languages_; | |
| 153 | |
| 154 private: | 150 private: |
| 155 DISALLOW_COPY_AND_ASSIGN(WebTestProxyBase); | 151 DISALLOW_COPY_AND_ASSIGN(WebTestProxyBase); |
| 156 }; | 152 }; |
| 157 | 153 |
| 158 // WebTestProxy is used during LayoutTests and always instantiated, at time of | 154 // WebTestProxy is used during LayoutTests and always instantiated, at time of |
| 159 // writing with Base=RenderViewImpl. It does not directly inherit from it for | 155 // writing with Base=RenderViewImpl. It does not directly inherit from it for |
| 160 // layering purposes. | 156 // layering purposes. |
| 161 // The intent of that class is to wrap RenderViewImpl for tests purposes in | 157 // The intent of that class is to wrap RenderViewImpl for tests purposes in |
| 162 // order to reduce the amount of test specific code in the production code. | 158 // order to reduce the amount of test specific code in the production code. |
| 163 // WebTestProxy is only doing the glue between RenderViewImpl and | 159 // WebTestProxy is only doing the glue between RenderViewImpl and |
| (...skipping 100 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 264 | 260 |
| 265 private: | 261 private: |
| 266 virtual ~WebTestProxy() {} | 262 virtual ~WebTestProxy() {} |
| 267 | 263 |
| 268 DISALLOW_COPY_AND_ASSIGN(WebTestProxy); | 264 DISALLOW_COPY_AND_ASSIGN(WebTestProxy); |
| 269 }; | 265 }; |
| 270 | 266 |
| 271 } // namespace test_runner | 267 } // namespace test_runner |
| 272 | 268 |
| 273 #endif // COMPONENTS_TEST_RUNNER_WEB_TEST_PROXY_H_ | 269 #endif // COMPONENTS_TEST_RUNNER_WEB_TEST_PROXY_H_ |
| OLD | NEW |