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

Side by Side Diff: components/test_runner/test_interfaces.cc

Issue 1908183002: Use correct WebView from TestRunner methods called via testRunner bindings. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@accessibility-controller-per-view
Patch Set: Explicit constructor for TestRunnerForSpecificView. Created 4 years, 7 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 | « no previous file | components/test_runner/test_runner.h » ('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 #include "components/test_runner/test_interfaces.h" 5 #include "components/test_runner/test_interfaces.h"
6 6
7 #include <stddef.h> 7 #include <stddef.h>
8 8
9 #include <string> 9 #include <string>
10 10
(...skipping 42 matching lines...) Expand 10 before | Expand all | Expand 10 after
53 53
54 void TestInterfaces::SetDelegate(WebTestDelegate* delegate) { 54 void TestInterfaces::SetDelegate(WebTestDelegate* delegate) {
55 gamepad_controller_ = GamepadController::Create(delegate); 55 gamepad_controller_ = GamepadController::Create(delegate);
56 test_runner_->SetDelegate(delegate); 56 test_runner_->SetDelegate(delegate);
57 delegate_ = delegate; 57 delegate_ = delegate;
58 } 58 }
59 59
60 void TestInterfaces::BindTo(blink::WebFrame* frame) { 60 void TestInterfaces::BindTo(blink::WebFrame* frame) {
61 if (gamepad_controller_) 61 if (gamepad_controller_)
62 gamepad_controller_->Install(frame); 62 gamepad_controller_->Install(frame);
63 test_runner_->Install(frame);
64 GCController::Install(frame); 63 GCController::Install(frame);
65 } 64 }
66 65
67 void TestInterfaces::ResetTestHelperControllers() { 66 void TestInterfaces::ResetTestHelperControllers() {
68 if (gamepad_controller_) 67 if (gamepad_controller_)
69 gamepad_controller_->Reset(); 68 gamepad_controller_->Reset();
70 blink::WebCache::clear(); 69 blink::WebCache::clear();
71 70
72 for (WebTestProxyBase* web_test_proxy_base : window_list_) 71 for (WebTestProxyBase* web_test_proxy_base : window_list_)
73 web_test_proxy_base->Reset(); 72 web_test_proxy_base->Reset();
(...skipping 76 matching lines...) Expand 10 before | Expand all | Expand 10 after
150 if (!theme_engine_.get()) 149 if (!theme_engine_.get())
151 theme_engine_.reset(new MockWebThemeEngine()); 150 theme_engine_.reset(new MockWebThemeEngine());
152 return theme_engine_.get(); 151 return theme_engine_.get();
153 } 152 }
154 153
155 AppBannerClient* TestInterfaces::GetAppBannerClient() { 154 AppBannerClient* TestInterfaces::GetAppBannerClient() {
156 return app_banner_client_; 155 return app_banner_client_;
157 } 156 }
158 157
159 } // namespace test_runner 158 } // namespace test_runner
OLDNEW
« no previous file with comments | « no previous file | components/test_runner/test_runner.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698