Index: third_party/WebKit/Source/platform/battery/battery_status_listener.h |
diff --git a/third_party/WebKit/Source/platform/PlatformResourceLoader.h b/third_party/WebKit/Source/platform/battery/battery_status_listener.h |
similarity index 33% |
copy from third_party/WebKit/Source/platform/PlatformResourceLoader.h |
copy to third_party/WebKit/Source/platform/battery/battery_status_listener.h |
index e2db013c6374320729c668ddc9cee5f5f198294f..8ba0d967df0a7ce17d120d8e14775ff210b41594 100644 |
--- a/third_party/WebKit/Source/platform/PlatformResourceLoader.h |
+++ b/third_party/WebKit/Source/platform/battery/battery_status_listener.h |
@@ -2,16 +2,23 @@ |
// Use of this source code is governed by a BSD-style license that can be |
// found in the LICENSE file. |
-#ifndef PlatformResourceLoader_h |
-#define PlatformResourceLoader_h |
+#ifndef BLINK_PLATFORM_BATTERY_BATTERY_STATUS_LISTENER_H_ |
+#define BLINK_PLATFORM_BATTERY_BATTERY_STATUS_LISTENER_H_ |
#include "platform/PlatformExport.h" |
-#include "wtf/text/WTFString.h" |
namespace blink { |
-PLATFORM_EXPORT String loadResourceAsASCIIString(const char* resource); |
+class BatteryStatus; |
-} // namespace blink |
+class PLATFORM_EXPORT BatteryStatusListener { |
kinuko
2016/02/16 10:09:18
I think it'd be probably make the structure cleare
Yuki
2016/02/16 13:21:59
Took an idea of BatteryDispatcherProxy::Listener.
|
+ public: |
+ virtual ~BatteryStatusListener() = default; |
-#endif // PlatformResourceLoader_h |
+ // This method is called when a new battery status is available. |
+ virtual void OnUpdateBatteryStatus(const BatteryStatus&) = 0; |
+}; |
+ |
+} // namespace blink |
+ |
+#endif // BLINK_PLATFORM_BATTERY_BATTERY_STATUS_LISTENER_H_ |