-
Notifications
You must be signed in to change notification settings - Fork 29.3k
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
Switching menubar display position failed with error #205836
Comments
ref: #199744, because command with the same name cannot be registered now. The process of switching menu bars is accompanied by the destruction and initialization of two custom menu bars from A and B respectively, and their destruction execution order cannot be guaranteed. When one of the instances is destroyed and executed, the initialization of the new instance will have this problem, because initialization means registering a command with the same name.
|
I think the issue here is that the menu bar control gets disposed in the one place and then created in the other place (title bar, activity bar) but the order is not guaranteed to be dispose first and create later, as such this action gets first registered a second time and then gets disposed: vscode/src/vs/workbench/browser/parts/titlebar/menubarControl.ts Lines 437 to 454 in 67f9158
We only recently changed to throwing an error in this case which now breaks this flow, but the issue was there before already... |
Yeah, I found it, too. My original idea was to ensure that it was reasonable to reinstall after the uninstall was completed through some event mechanism, such as use |
Yes, Previously command with the same name can be overwritten without causing a problem. The exception thrown now causes the handler to not be executed and the switch fails. |
This bug has been fixed in the latest release of VS Code Insiders! @yiliang114, you can help us out by commenting If things still don't seem right, please ensure you're on version 4c94dbd of Insiders (today's or later - you can use Happy Coding! |
How can I do this? I'm having trouble understanding how to get the top menu to show at all. I can only get the hamburger menu. |
Finally found it. It's |
Reproduction steps:
https://insiders.vscode.dev/github/microsoft/vscode
Version: 1.87.0-insider
Commit: ee69e28
User Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/121.0.0.0 Safari/537.36
Embedder: vscode.dev
The text was updated successfully, but these errors were encountered: