-
Notifications
You must be signed in to change notification settings - Fork 28.8k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add registerWindowTitleVariable command #225408
Add registerWindowTitleVariable command #225408
Conversation
@BABA983 any reason this is still a draft? |
I was thinking should we separate the behaviour into 2 commands? e.g. |
Both options are not optimal, but having just one might be the better choice. If we have a |
@bpasero can you have a glance at this PR? |
src/vs/workbench/contrib/windowTitle/browser/windowTitle.contribution.ts
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think the title variable service thing is overkill unless we plan on using it somewhere else, so in that case we could just inline the command into the title bar part?
146b321
to
bcb4fd8
Compare
4717e83
to
5649053
Compare
Thanks for the feedback, I have addressed the issues mentioned in the previous review. Could you please take a moment to review the changes again? |
@BABA983 we decided that it would make sense for an extension to create the context key and then provide it to the
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I went ahead and did the changes I had in mind because I think we spend a bit too much time engineering this.
Close #202991
Usage in extension
vscode.commands.executeCommand('registerWindowTitleVariable', key, value)
settings.json
"window.title": "${windowTitleVariable.aa}"
window-title-variable-demo.mp4