You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
-
MenuBar 支持顶部 horizontal 模式
设置路径:
View -> Appearance -> Menu Bar Horizontal Mode / Menu Bar Vertical Mode
说明:
Horizontal Mode
和Vertical Mode
同时只会展示一个(例如当前是Horizontal
时展示Vertical
项)总体实现:
为 menuBar 新增 mode 属性,值为:
horizontal
,vertical
切换 menuBar mode 时修改 mode 的值
根据 menuBar.mode 来控制 menuBar 在顶部水平展示,还是在左侧垂直展示
具体实现:
为 menuBar 新增 mode 属性:
src/model/workbench/layout.ts
文件新增IMenuBarViewState
接口创建修改 menuBar mode 的方法:
src/services/workbench/layoutService.ts
文件新增setMenuBarMode
方法新增 Horizontal mode 的MenuBar(新增还是修改待定):
src/workbench/menuBar
目录新增horizontalMenuBar.tsx
(DropDown 改为使用 Menu)增加菜单项 Menu Bar Horizontal Mode 和 Menu Bar Vertical Mode:
src/services/builtinService/const.ts
文件增加菜单相关常量根据 menuBar.mode 的值切换 MenuBar:
src/workbench/workbench.tsx
文件修改<MenuBarView />
的展示条件和位置Beta Was this translation helpful? Give feedback.
All reactions