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

Side by Side Diff: content/shell/renderer/webkit_test_runner.cc

Issue 298263002: Battery Status API: add testing support for LayoutTests. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: fix comments Created 6 years, 6 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 | « content/shell/renderer/webkit_test_runner.h ('k') | content/test/layouttest_support.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 (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 "content/shell/renderer/webkit_test_runner.h" 5 #include "content/shell/renderer/webkit_test_runner.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 #include <clocale> 8 #include <clocale>
9 #include <cmath> 9 #include <cmath>
10 10
(...skipping 217 matching lines...) Expand 10 before | Expand all | Expand 10 after
228 228
229 void WebKitTestRunner::setScreenOrientation( 229 void WebKitTestRunner::setScreenOrientation(
230 const WebScreenOrientationType& orientation) { 230 const WebScreenOrientationType& orientation) {
231 SetMockScreenOrientation(render_view(), orientation); 231 SetMockScreenOrientation(render_view(), orientation);
232 } 232 }
233 233
234 void WebKitTestRunner::resetScreenOrientation() { 234 void WebKitTestRunner::resetScreenOrientation() {
235 ResetMockScreenOrientation(); 235 ResetMockScreenOrientation();
236 } 236 }
237 237
238 void WebKitTestRunner::didChangeBatteryStatus(
239 const blink::WebBatteryStatus& status) {
240 MockBatteryStatusChanged(status);
241 }
242
238 void WebKitTestRunner::printMessage(const std::string& message) { 243 void WebKitTestRunner::printMessage(const std::string& message) {
239 Send(new ShellViewHostMsg_PrintMessage(routing_id(), message)); 244 Send(new ShellViewHostMsg_PrintMessage(routing_id(), message));
240 } 245 }
241 246
242 void WebKitTestRunner::postTask(WebTask* task) { 247 void WebKitTestRunner::postTask(WebTask* task) {
243 Platform::current()->callOnMainThread(InvokeTaskHelper, task); 248 Platform::current()->callOnMainThread(InvokeTaskHelper, task);
244 } 249 }
245 250
246 void WebKitTestRunner::postDelayedTask(WebTask* task, long long ms) { 251 void WebKitTestRunner::postDelayedTask(WebTask* task, long long ms) {
247 base::MessageLoop::current()->PostDelayedTask( 252 base::MessageLoop::current()->PostDelayedTask(
(...skipping 470 matching lines...) Expand 10 before | Expand all | Expand 10 after
718 723
719 leak_detector_->TryLeakDetection(main_frame); 724 leak_detector_->TryLeakDetection(main_frame);
720 } 725 }
721 726
722 void WebKitTestRunner::ReportLeakDetectionResult( 727 void WebKitTestRunner::ReportLeakDetectionResult(
723 const LeakDetectionResult& report) { 728 const LeakDetectionResult& report) {
724 Send(new ShellViewHostMsg_LeakDetectionDone(routing_id(), report)); 729 Send(new ShellViewHostMsg_LeakDetectionDone(routing_id(), report));
725 } 730 }
726 731
727 } // namespace content 732 } // namespace content
OLDNEW
« no previous file with comments | « content/shell/renderer/webkit_test_runner.h ('k') | content/test/layouttest_support.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698