mirror of
https://github.com/ckaczor/azuredatastudio.git
synced 2026-02-13 11:38:36 -05:00
Merge from vscode a4177f50c475fc0fa278a78235e3bee9ffdec781 (#8649)
* Merge from vscode a4177f50c475fc0fa278a78235e3bee9ffdec781 * distro * fix tests
This commit is contained in:
@@ -1381,7 +1381,7 @@ export class WindowsMainService extends Disposable implements IWindowsMainServic
|
||||
// Window state is not from a previous session: only allow fullscreen if we inherit it or user wants fullscreen
|
||||
let allowFullscreen: boolean;
|
||||
if (state.hasDefaultState) {
|
||||
allowFullscreen = (windowConfig?.newWindowDimensions && ['fullscreen', 'inherit'].indexOf(windowConfig.newWindowDimensions) >= 0);
|
||||
allowFullscreen = (windowConfig?.newWindowDimensions && ['fullscreen', 'inherit', 'offset'].indexOf(windowConfig.newWindowDimensions) >= 0);
|
||||
}
|
||||
|
||||
// Window state is from a previous session: only allow fullscreen when we got updated or user wants to restore
|
||||
@@ -1576,7 +1576,7 @@ export class WindowsMainService extends Disposable implements IWindowsMainServic
|
||||
} else if (windowConfig.newWindowDimensions === 'fullscreen') {
|
||||
state.mode = WindowMode.Fullscreen;
|
||||
ensureNoOverlap = false;
|
||||
} else if (windowConfig.newWindowDimensions === 'inherit' && lastActive) {
|
||||
} else if ((windowConfig.newWindowDimensions === 'inherit' || windowConfig.newWindowDimensions === 'offset') && lastActive) {
|
||||
const lastActiveState = lastActive.serializeWindowState();
|
||||
if (lastActiveState.mode === WindowMode.Fullscreen) {
|
||||
state.mode = WindowMode.Fullscreen; // only take mode (fixes https://github.com/Microsoft/vscode/issues/19331)
|
||||
@@ -1584,7 +1584,7 @@ export class WindowsMainService extends Disposable implements IWindowsMainServic
|
||||
state = lastActiveState;
|
||||
}
|
||||
|
||||
ensureNoOverlap = false;
|
||||
ensureNoOverlap = state.mode !== WindowMode.Fullscreen && windowConfig.newWindowDimensions === 'offset';
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user