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

Unified Diff: chrome/browser/resources/chromeos/emulator/battery_settings.js

Issue 2006083002: Use fake Input Device Settings with chrome://device-emulator (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@DevicePageTestsFixes
Patch Set: make dependent on a11y fix Created 4 years, 5 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: chrome/browser/resources/chromeos/emulator/battery_settings.js
diff --git a/chrome/browser/resources/chromeos/emulator/battery_settings.js b/chrome/browser/resources/chromeos/emulator/battery_settings.js
index 3a9c955aac0f8bfcc69313dd05e408337351e35a..8487802f592b45ad73d3c74071d80931099222df 100644
--- a/chrome/browser/resources/chromeos/emulator/battery_settings.js
+++ b/chrome/browser/resources/chromeos/emulator/battery_settings.js
@@ -77,11 +77,8 @@ var BatterySettings = Polymer({
'powerSourcesChanged(powerSourceOptions.*)',
],
- initialize: function() {
- if (!this.initialized) {
- chrome.send('requestPowerInfo');
- this.initialized = true;
- }
+ ready: function() {
+ chrome.send('requestPowerInfo');
},
onBatteryPercentChange: function(e) {

Powered by Google App Engine
This is Rietveld 408576698