mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
bug 1249738 - make sWakeLockObservers a function static r=dhylands
This commit is contained in:
parent
fcc029f7be
commit
6a081240f6
14
hal/Hal.cpp
14
hal/Hal.cpp
@ -336,7 +336,13 @@ protected:
|
||||
}
|
||||
};
|
||||
|
||||
static WakeLockObserversManager sWakeLockObservers;
|
||||
static WakeLockObserversManager&
|
||||
WakeLockObservers()
|
||||
{
|
||||
static WakeLockObserversManager sWakeLockObservers;
|
||||
AssertMainThread();
|
||||
return sWakeLockObservers;
|
||||
}
|
||||
|
||||
class ScreenConfigurationObserversManager : public CachingObserversManager<ScreenConfiguration>
|
||||
{
|
||||
@ -663,14 +669,14 @@ void
|
||||
RegisterWakeLockObserver(WakeLockObserver* aObserver)
|
||||
{
|
||||
AssertMainThread();
|
||||
sWakeLockObservers.AddObserver(aObserver);
|
||||
WakeLockObservers().AddObserver(aObserver);
|
||||
}
|
||||
|
||||
void
|
||||
UnregisterWakeLockObserver(WakeLockObserver* aObserver)
|
||||
{
|
||||
AssertMainThread();
|
||||
sWakeLockObservers.RemoveObserver(aObserver);
|
||||
WakeLockObservers().RemoveObserver(aObserver);
|
||||
}
|
||||
|
||||
void
|
||||
@ -701,7 +707,7 @@ void
|
||||
NotifyWakeLockChange(const WakeLockInformation& aInfo)
|
||||
{
|
||||
AssertMainThread();
|
||||
sWakeLockObservers.BroadcastInformation(aInfo);
|
||||
WakeLockObservers().BroadcastInformation(aInfo);
|
||||
}
|
||||
|
||||
void
|
||||
|
Loading…
Reference in New Issue
Block a user