summaryrefslogtreecommitdiffstats
path: root/hal/Hal.cpp
diff options
context:
space:
mode:
authorMoonchild <moonchild@palemoon.org>2020-08-13 12:10:54 +0000
committerMoonchild <moonchild@palemoon.org>2020-08-13 12:10:54 +0000
commit11285cd0d6ef7de80d22187b99376602ed547214 (patch)
tree034c72eea2e7838b08abd00f37acf8e3c9e97949 /hal/Hal.cpp
parente1e535c1c6372f95b4a14b6a00b6d6e7be400c3b (diff)
parentd3383327a749ddb5c0626146c6f83bdfa3ea9936 (diff)
downloadUXP-11285cd0d6ef7de80d22187b99376602ed547214.tar
UXP-11285cd0d6ef7de80d22187b99376602ed547214.tar.gz
UXP-11285cd0d6ef7de80d22187b99376602ed547214.tar.lz
UXP-11285cd0d6ef7de80d22187b99376602ed547214.tar.xz
UXP-11285cd0d6ef7de80d22187b99376602ed547214.zip
Merge branch 'master' into es-modules-work
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();