Skip to content

Commit 2fe12dd

Browse files
test
Signed-off-by: Roman Nikitenko <rnikiten@redhat.com>
1 parent ab324de commit 2fe12dd

4 files changed

Lines changed: 9 additions & 3 deletions

File tree

.rebase/replace/code/src/vs/workbench/browser/parts/titlebar/windowTitle.ts.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
},
66
{
77
"from": "\tisCustomTitleFormat(): boolean {",
8-
"by": "\tgetHeader(): string | undefined{\n\t\tconst header = this.configurationService.inspect<string>(WindowSettingNames.header);\n\t\treturn header.value;\n\t}\n\n\tisCustomTitleFormat(): boolean {"
8+
"by": "\tgetHeader(): string | undefined{\n\t\treturn this.configurationService.getValue<string>(WindowSettingNames.header);\n\t}\n\n\tisCustomTitleFormat(): boolean {"
99
},
1010
{
1111
"from": "\t\tif (affectsTitleConfiguration || event.affectsConfiguration(WindowSettingNames.titleSeparator)) {\n\t\t\tthis.titleUpdater.schedule();\n\t\t}\n\t}",

code/src/vs/workbench/browser/parts/titlebar/commandCenterControl.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -217,6 +217,7 @@ class CommandCenterCenterViewItem extends BaseActionViewItem {
217217
const { prefix, suffix } = that._windowTitle.getTitleDecorations();
218218
let label = that._windowTitle.workspaceName;
219219
const header = that._windowTitle.getHeader();
220+
console.log(`[window.header] commandCenter._getLabel() header=${JSON.stringify(header)}, workspaceName=${JSON.stringify(label)}`);
220221
if (header) {
221222
label = header;
222223
} else if (that._windowTitle.isCustomTitleFormat()) {

code/src/vs/workbench/browser/parts/titlebar/titlebarPart.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -582,6 +582,8 @@ export class BrowserTitlebarPart extends Part implements ITitlebarPart {
582582

583583
const isShowingTitleInNativeTitlebar = hasNativeTitlebar(this.configurationService, this.titleBarStyle);
584584

585+
console.log(`[window.header] createTitle() isCommandCenterVisible=${this.isCommandCenterVisible}, isShowingTitleInNativeTitlebar=${isShowingTitleInNativeTitlebar}`);
586+
585587
// Text Title
586588
if (!this.isCommandCenterVisible) {
587589
if (!isShowingTitleInNativeTitlebar) {

code/src/vs/workbench/browser/parts/titlebar/windowTitle.ts

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -142,6 +142,7 @@ export class WindowTitle extends Disposable {
142142
}
143143

144144
if (event.affectsConfiguration(WindowSettingNames.header)) {
145+
console.log('[window.header] onConfigurationChanged: window.header configuration changed, firing onDidChange');
145146
this.onDidChangeEmitter.fire();
146147
}
147148
}
@@ -413,8 +414,10 @@ export class WindowTitle extends Disposable {
413414
}
414415

415416
getHeader(): string | undefined{
416-
const header = this.configurationService.inspect<string>(WindowSettingNames.header);
417-
return header.value;
417+
const value = this.configurationService.getValue<string>(WindowSettingNames.header);
418+
const inspected = this.configurationService.inspect<string>(WindowSettingNames.header);
419+
console.log(`[window.header] getHeader() getValue=${JSON.stringify(value)}, inspect.value=${JSON.stringify(inspected.value)}, inspect.userRemoteValue=${JSON.stringify(inspected.userRemoteValue)}, inspect.workspaceValue=${JSON.stringify(inspected.workspaceValue)}, inspect.userLocalValue=${JSON.stringify(inspected.userLocalValue)}, inspect.defaultValue=${JSON.stringify(inspected.defaultValue)}`);
420+
return value;
418421
}
419422

420423
isCustomTitleFormat(): boolean {

0 commit comments

Comments
 (0)