mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 512575 - Switching out of fullscreen mode and alt-tabbing puts me back in fullscreen mode. r=dholbert
This commit is contained in:
parent
4a0d6558b5
commit
10fd01fde6
@ -383,6 +383,8 @@ nsWindow::nsWindow()
|
||||
mTransientParent = nsnull;
|
||||
mWindowType = eWindowType_child;
|
||||
mSizeState = nsSizeMode_Normal;
|
||||
mLastSizeMode = nsSizeMode_Normal;
|
||||
|
||||
#ifdef MOZ_X11
|
||||
mOldFocusWindow = 0;
|
||||
#endif /* MOZ_X11 */
|
||||
@ -5001,11 +5003,19 @@ nsWindow::MakeFullScreen(PRBool aFullScreen)
|
||||
|
||||
#if GTK_CHECK_VERSION(2,2,0)
|
||||
if (aFullScreen) {
|
||||
if (mSizeMode != nsSizeMode_Fullscreen)
|
||||
mLastSizeMode = mSizeMode;
|
||||
|
||||
mSizeMode = nsSizeMode_Fullscreen;
|
||||
gdk_window_fullscreen (mShell->window);
|
||||
}
|
||||
else
|
||||
else {
|
||||
mSizeMode = mLastSizeMode;
|
||||
gdk_window_unfullscreen (mShell->window);
|
||||
}
|
||||
|
||||
NS_ASSERTION(mLastSizeMode != nsSizeMode_Fullscreen,
|
||||
"mLastSizeMode should never be fullscreen");
|
||||
return NS_OK;
|
||||
#else
|
||||
return nsBaseWidget::MakeFullScreen(aFullScreen);
|
||||
|
@ -530,6 +530,10 @@ private:
|
||||
nsCOMPtr<nsITimer> mDragLeaveTimer;
|
||||
float mLastMotionPressure;
|
||||
|
||||
// Remember the last sizemode so that we can restore it when
|
||||
// leaving fullscreen
|
||||
nsSizeMode mLastSizeMode;
|
||||
|
||||
static PRBool sIsDraggingOutOf;
|
||||
// drag in progress
|
||||
static PRBool DragInProgress(void);
|
||||
|
Loading…
Reference in New Issue
Block a user