Disable custom title bar rendering on macOS (#362)

This commit is contained in:
Karl Burtram
2017-12-19 00:33:42 -08:00
committed by GitHub
parent a75c799b34
commit dbb421f503
2 changed files with 13 additions and 6 deletions

View File

@@ -169,12 +169,16 @@ export class CodeWindow implements ICodeWindow {
}
let useCustomTitleStyle = false;
if (isMacintosh && (!windowConfig || !windowConfig.titleBarStyle || windowConfig.titleBarStyle === 'custom')) {
const isDev = !this.environmentService.isBuilt || !!config.extensionDevelopmentPath;
if (!isDev) {
useCustomTitleStyle = true; // not enabled when developing due to https://github.com/electron/electron/issues/3647
}
}
// {{SQL CARBON EDIT}}
// turn-off custom menus to avoid bug calculating size of SQL editor
//
// if (isMacintosh && (!windowConfig || !windowConfig.titleBarStyle || windowConfig.titleBarStyle === 'custom')) {
// const isDev = !this.environmentService.isBuilt || !!config.extensionDevelopmentPath;
// if (!isDev) {
// useCustomTitleStyle = true; // not enabled when developing due to https://github.com/electron/electron/issues/3647
// }
// }
if (useNativeTabs) {
useCustomTitleStyle = false; // native tabs on sierra do not work with custom title style

View File

@@ -833,6 +833,8 @@ export class Workbench implements IPartService {
}
private getCustomTitleBarStyle(): 'custom' {
// {{SQL CARBON EDIT}}
/*
if (!isMacintosh) {
return null; // custom title bar is only supported on Mac currently
}
@@ -854,6 +856,7 @@ export class Workbench implements IPartService {
return style;
}
}
*/
return null;
}