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

Unified Diff: components/test_runner/test_runner.cc

Issue 1538803002: Migrates battery_status from content/renderer/ to WebKit/platform/ (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 11 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 side-by-side diff with in-line comments
Download patch
Index: components/test_runner/test_runner.cc
diff --git a/components/test_runner/test_runner.cc b/components/test_runner/test_runner.cc
index e4e5877397c06b2262916aa931f2e8f57bcd46aa..aeb03c4a6054aa7ec35736ce2f384384b223d4f3 100644
--- a/components/test_runner/test_runner.cc
+++ b/components/test_runner/test_runner.cc
@@ -26,7 +26,6 @@
#include "gin/handle.h"
#include "gin/object_template_builder.h"
#include "gin/wrappable.h"
-#include "third_party/WebKit/public/platform/WebBatteryStatus.h"
#include "third_party/WebKit/public/platform/WebCanvas.h"
#include "third_party/WebKit/public/platform/WebData.h"
#include "third_party/WebKit/public/platform/WebPasswordCredential.h"
@@ -2531,17 +2530,12 @@ void TestRunner::DidChangeBatteryStatus(bool charging,
double chargingTime,
double dischargingTime,
double level) {
- blink::WebBatteryStatus status;
- status.charging = charging;
- status.chargingTime = chargingTime;
- status.dischargingTime = dischargingTime;
- status.level = level;
- delegate_->DidChangeBatteryStatus(status);
+ web_view_->updateBatteryStatusForTesting(
+ charging, chargingTime, dischargingTime, level);
}
void TestRunner::ResetBatteryStatus() {
- blink::WebBatteryStatus status;
- delegate_->DidChangeBatteryStatus(status);
+ web_view_->resetBatteryStatusForTesting();
}
void TestRunner::DidAcquirePointerLock() {

Powered by Google App Engine
This is Rietveld 408576698