Skip to content

Commit

Permalink
refs #76442
Browse files Browse the repository at this point in the history
  • Loading branch information
sbatten committed Jul 2, 2019
1 parent 8c2de5e commit c184561
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 5 deletions.
9 changes: 6 additions & 3 deletions src/vs/workbench/browser/parts/titlebar/menubarControl.ts
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ export abstract class MenubarControl extends Disposable {
[index: string]: IMenu | undefined;
};

protected topLevelTitles = {
protected topLevelTitles: { [menu: string]: string } = {
'File': nls.localize({ key: 'mFile', comment: ['&& denotes a mnemonic'] }, "&&File"),
'Edit': nls.localize({ key: 'mEdit', comment: ['&& denotes a mnemonic'] }, "&&Edit"),
'Selection': nls.localize({ key: 'mSelection', comment: ['&& denotes a mnemonic'] }, "&&Selection"),
Expand Down Expand Up @@ -407,9 +407,12 @@ export class NativeMenubarControl extends MenubarControl {
}

private getAdditionalKeybindings(): { [id: string]: IMenubarKeybinding } {
const keybindings = {};
const keybindings: { [id: string]: IMenubarKeybinding } = {};
if (isMacintosh) {
keybindings['workbench.action.quit'] = (this.getMenubarKeybinding('workbench.action.quit'));
const keybinding = this.getMenubarKeybinding('workbench.action.quit');
if (keybinding) {
keybindings['workbench.action.quit'] = keybinding;
}
}

return keybindings;
Expand Down
4 changes: 2 additions & 2 deletions src/vs/workbench/browser/parts/titlebar/titlebarPart.ts
Original file line number Diff line number Diff line change
Expand Up @@ -494,9 +494,9 @@ export class TitlebarPart extends Part implements ITitleService {
private onUpdateAppIconDragBehavior() {
const setting = this.configurationService.getValue('window.doubleClickIconToClose');
if (setting) {
this.appIcon.style['-webkit-app-region'] = 'no-drag';
(this.appIcon.style as any)['-webkit-app-region'] = 'no-drag';
} else {
this.appIcon.style['-webkit-app-region'] = 'drag';
(this.appIcon.style as any)['-webkit-app-region'] = 'drag';
}
}

Expand Down

0 comments on commit c184561

Please sign in to comment.