Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(169)

Side by Side Diff: components/test_runner/web_test_proxy.h

Issue 1903043002: Use correct WebView from AccessibilityController. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@event-sender-per-view
Patch Set: Rebasing... Created 4 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « components/test_runner/web_test_interfaces.cc ('k') | components/test_runner/web_test_proxy.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 #include <utility> 9 #include <utility>
10 10
(...skipping 23 matching lines...) Expand all
34 class WebString; 34 class WebString;
35 class WebView; 35 class WebView;
36 class WebWidget; 36 class WebWidget;
37 struct WebFileChooserParams; 37 struct WebFileChooserParams;
38 struct WebPoint; 38 struct WebPoint;
39 struct WebWindowFeatures; 39 struct WebWindowFeatures;
40 } 40 }
41 41
42 namespace test_runner { 42 namespace test_runner {
43 43
44 class AccessibilityController;
44 class EventSender; 45 class EventSender;
45 class TestInterfaces; 46 class TestInterfaces;
46 class TextInputController; 47 class TextInputController;
47 class WebTestDelegate; 48 class WebTestDelegate;
48 class WebTestInterfaces; 49 class WebTestInterfaces;
49 50
50 // WebTestProxyBase is the "brain" of WebTestProxy in the sense that 51 // WebTestProxyBase is the "brain" of WebTestProxy in the sense that
51 // WebTestProxy does the bridge between RenderViewImpl and WebTestProxyBase and 52 // WebTestProxy does the bridge between RenderViewImpl and WebTestProxyBase and
52 // when it requires a behavior to be different from the usual, it will call 53 // when it requires a behavior to be different from the usual, it will call
53 // WebTestProxyBase that implements the expected behavior. 54 // WebTestProxyBase that implements the expected behavior.
(...skipping 26 matching lines...) Expand all
80 DCHECK(!delegate_); 81 DCHECK(!delegate_);
81 delegate_ = delegate; 82 delegate_ = delegate;
82 } 83 }
83 84
84 TestInterfaces* test_interfaces() { return test_interfaces_; } 85 TestInterfaces* test_interfaces() { return test_interfaces_; }
85 void SetInterfaces(WebTestInterfaces* web_test_interfaces); 86 void SetInterfaces(WebTestInterfaces* web_test_interfaces);
86 87
87 EventSender* event_sender() { return event_sender_.get(); } 88 EventSender* event_sender() { return event_sender_.get(); }
88 void SetSendWheelGestures(bool send_gestures); 89 void SetSendWheelGestures(bool send_gestures);
89 90
91 AccessibilityController* accessibility_controller() {
92 return accessibility_controller_.get();
93 }
94
90 void Reset(); 95 void Reset();
91 void BindTo(blink::WebLocalFrame* frame); 96 void BindTo(blink::WebLocalFrame* frame);
92 97
93 void GetScreenOrientationForTesting(blink::WebScreenInfo&); 98 void GetScreenOrientationForTesting(blink::WebScreenInfo&);
94 99
95 protected: 100 protected:
96 WebTestProxyBase(); 101 WebTestProxyBase();
97 ~WebTestProxyBase(); 102 ~WebTestProxyBase();
98 103
99 blink::WebViewClient* view_test_client() { return view_test_client_.get(); } 104 blink::WebViewClient* view_test_client() { return view_test_client_.get(); }
100 105
101 private: 106 private:
102 TestInterfaces* test_interfaces_; 107 TestInterfaces* test_interfaces_;
103 WebTestDelegate* delegate_; 108 WebTestDelegate* delegate_;
104 blink::WebView* web_view_; 109 blink::WebView* web_view_;
105 blink::WebWidget* web_widget_; 110 blink::WebWidget* web_widget_;
106 scoped_ptr<WebViewTestClient> view_test_client_; 111 scoped_ptr<WebViewTestClient> view_test_client_;
112 scoped_ptr<AccessibilityController> accessibility_controller_;
107 scoped_ptr<EventSender> event_sender_; 113 scoped_ptr<EventSender> event_sender_;
108 scoped_ptr<TextInputController> text_input_controller_; 114 scoped_ptr<TextInputController> text_input_controller_;
109 115
110 DISALLOW_COPY_AND_ASSIGN(WebTestProxyBase); 116 DISALLOW_COPY_AND_ASSIGN(WebTestProxyBase);
111 }; 117 };
112 118
113 // WebTestProxy is used during LayoutTests and always instantiated, at time of 119 // WebTestProxy is used during LayoutTests and always instantiated, at time of
114 // writing with Base=RenderViewImpl. It does not directly inherit from it for 120 // writing with Base=RenderViewImpl. It does not directly inherit from it for
115 // layering purposes. 121 // layering purposes.
116 // The intent of that class is to wrap RenderViewImpl for tests purposes in 122 // The intent of that class is to wrap RenderViewImpl for tests purposes in
(...skipping 103 matching lines...) Expand 10 before | Expand all | Expand 10 after
220 226
221 private: 227 private:
222 virtual ~WebTestProxy() {} 228 virtual ~WebTestProxy() {}
223 229
224 DISALLOW_COPY_AND_ASSIGN(WebTestProxy); 230 DISALLOW_COPY_AND_ASSIGN(WebTestProxy);
225 }; 231 };
226 232
227 } // namespace test_runner 233 } // namespace test_runner
228 234
229 #endif // COMPONENTS_TEST_RUNNER_WEB_TEST_PROXY_H_ 235 #endif // COMPONENTS_TEST_RUNNER_WEB_TEST_PROXY_H_
OLDNEW
« no previous file with comments | « components/test_runner/web_test_interfaces.cc ('k') | components/test_runner/web_test_proxy.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698