mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
bug 727847 - meter orientation events on android r=dougt
This commit is contained in:
parent
585ae3af5b
commit
6a55170fc3
@ -95,7 +95,8 @@ nsAppShell::nsAppShell()
|
||||
mCondLock("nsAppShell.mCondLock"),
|
||||
mQueueCond(mCondLock, "nsAppShell.mQueueCond"),
|
||||
mNumDraws(0),
|
||||
mNumViewports(0)
|
||||
mNumViewports(0),
|
||||
mPendingOrientationEvents(false)
|
||||
{
|
||||
gAppShell = this;
|
||||
}
|
||||
@ -342,6 +343,7 @@ nsAppShell::ProcessNextNativeEvent(bool mayWait)
|
||||
-curEvent->Alpha(),
|
||||
curEvent->Beta(),
|
||||
curEvent->Gamma());
|
||||
mPendingOrientationEvents = false;
|
||||
break;
|
||||
|
||||
case AndroidGeckoEvent::LOCATION_EVENT: {
|
||||
@ -589,6 +591,10 @@ nsAppShell::PostEvent(AndroidGeckoEvent *ae)
|
||||
delete event;
|
||||
}
|
||||
}
|
||||
} else if (ae->Type() == AndroidGeckoEvent::ORIENTATION_EVENT) {
|
||||
if (!mPendingOrientationEvents)
|
||||
mEventQueue.AppendElement(ae);
|
||||
mPendingOrientationEvents = true;
|
||||
} else {
|
||||
mEventQueue.AppendElement(ae);
|
||||
}
|
||||
|
@ -110,6 +110,7 @@ protected:
|
||||
mozilla::AndroidGeckoEvent *PeekNextEvent();
|
||||
|
||||
nsCOMPtr<nsIAndroidBrowserApp> mBrowserApp;
|
||||
bool mPendingOrientationEvents;
|
||||
};
|
||||
|
||||
#endif // nsAppShell_h__
|
||||
|
Loading…
Reference in New Issue
Block a user