summaryrefslogtreecommitdiffstats
path: root/hal/Hal.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'hal/Hal.cpp')
-rw-r--r--hal/Hal.cpp53
1 files changed, 0 insertions, 53 deletions
diff --git a/hal/Hal.cpp b/hal/Hal.cpp
index 67930c355..981f49125 100644
--- a/hal/Hal.cpp
+++ b/hal/Hal.cpp
@@ -264,30 +264,6 @@ private:
bool mHasValidCache;
};
-class BatteryObserversManager : public CachingObserversManager<BatteryInformation>
-{
-protected:
- void EnableNotifications() {
- PROXY_IF_SANDBOXED(EnableBatteryNotifications());
- }
-
- void DisableNotifications() {
- PROXY_IF_SANDBOXED(DisableBatteryNotifications());
- }
-
- void GetCurrentInformationInternal(BatteryInformation* aInfo) {
- PROXY_IF_SANDBOXED(GetCurrentBatteryInformation(aInfo));
- }
-};
-
-static BatteryObserversManager&
-BatteryObservers()
-{
- static BatteryObserversManager sBatteryObservers;
- AssertMainThread();
- return sBatteryObservers;
-}
-
class NetworkObserversManager : public CachingObserversManager<NetworkInformation>
{
protected:
@@ -356,35 +332,6 @@ ScreenConfigurationObservers()
return sScreenConfigurationObservers;
}
-void
-RegisterBatteryObserver(BatteryObserver* aObserver)
-{
- AssertMainThread();
- BatteryObservers().AddObserver(aObserver);
-}
-
-void
-UnregisterBatteryObserver(BatteryObserver* aObserver)
-{
- AssertMainThread();
- BatteryObservers().RemoveObserver(aObserver);
-}
-
-void
-GetCurrentBatteryInformation(BatteryInformation* aInfo)
-{
- AssertMainThread();
- *aInfo = BatteryObservers().GetCurrentInformation();
-}
-
-void
-NotifyBatteryChange(const BatteryInformation& aInfo)
-{
- AssertMainThread();
- BatteryObservers().CacheInformation(aInfo);
- BatteryObservers().BroadcastCachedInformation();
-}
-
bool GetScreenEnabled()
{
AssertMainThread();