Bug 1569622 - Call VRManager::StartFrame directly instead of using a PostTask on Android. r=kip,rbarker

Call VRManager::StartFrame directly instead of using a PostTask on Android.

Differential Revision: https://phabricator.services.mozilla.com/D39691

--HG--
extra : moz-landing-system : lando
This commit is contained in:
Imanol Fernandez 2019-07-30 00:11:37 +00:00
parent ce8e3ff6b7
commit 1f32c478c3

View File

@ -1212,7 +1212,7 @@ void VRManager::SubmitFrameInternal(const layers::SurfaceDescriptor& aTexture,
mCurrentSubmitTask = nullptr;
}
#if defined(XP_WIN) || defined(XP_MACOSX) || defined(MOZ_WIDGET_ANDROID)
#if defined(XP_WIN) || defined(XP_MACOSX)
/**
* Trigger the next VSync immediately after we are successfully
@ -1228,6 +1228,9 @@ void VRManager::SubmitFrameInternal(const layers::SurfaceDescriptor& aTexture,
loop->PostTask(NewRunnableMethod("gfx::VRManager::StartFrame", this,
&VRManager::StartFrame));
#elif defined(MOZ_WIDGET_ANDROID)
// We are already in the CompositorThreadHolder event loop on Android.
StartFrame();
#endif
}