mirror of
https://github.com/mozilla/gecko-dev.git
synced 2025-03-02 22:37:50 +00:00
Bug 1676760 - Always use vsync priority for the ParentProcessVsyncNotifier runnable. r=smaug
This check was there for single process Android and is no longer needed. Differential Revision: https://phabricator.services.mozilla.com/D139765
This commit is contained in:
parent
1a8dfa72f1
commit
4062a118bc
@ -507,23 +507,18 @@ class VsyncRefreshDriverTimer : public RefreshDriverTimer {
|
||||
|
||||
NS_IMETHOD Run() override {
|
||||
MOZ_ASSERT(NS_IsMainThread());
|
||||
sVsyncPriorityEnabled = mozilla::BrowserTabsRemoteAutostart();
|
||||
|
||||
mObserver->NotifyVsyncOnMainThread();
|
||||
return NS_OK;
|
||||
}
|
||||
|
||||
NS_IMETHOD GetPriority(uint32_t* aPriority) override {
|
||||
*aPriority = sVsyncPriorityEnabled
|
||||
? nsIRunnablePriority::PRIORITY_VSYNC
|
||||
: nsIRunnablePriority::PRIORITY_NORMAL;
|
||||
*aPriority = nsIRunnablePriority::PRIORITY_VSYNC;
|
||||
return NS_OK;
|
||||
}
|
||||
|
||||
private:
|
||||
~ParentProcessVsyncNotifier() = default;
|
||||
RefPtr<RefreshDriverVsyncObserver> mObserver;
|
||||
static mozilla::Atomic<bool> sVsyncPriorityEnabled;
|
||||
};
|
||||
|
||||
bool NotifyVsync(const VsyncEvent& aVsync) override {
|
||||
@ -833,9 +828,6 @@ NS_IMPL_ISUPPORTS_INHERITED(
|
||||
ParentProcessVsyncNotifier,
|
||||
Runnable, nsIRunnablePriority)
|
||||
|
||||
mozilla::Atomic<bool> VsyncRefreshDriverTimer::RefreshDriverVsyncObserver::
|
||||
ParentProcessVsyncNotifier::sVsyncPriorityEnabled(false);
|
||||
|
||||
/**
|
||||
* Since the content process takes some time to setup
|
||||
* the vsync IPC connection, this timer is used
|
||||
|
Loading…
x
Reference in New Issue
Block a user