Protected ReadonlycustomProtected ReadonlyfactoryProtected OptionallogoProtected OptionalmenuProtected ReadonlypreferenceProtected ReadonlyshellProtected ReadonlystateProtected ReadonlythemeProtected ReadonlytitleProtected OptionaltitleProtectedtitleProtectedtoggleProtected ReadonlywindowProtectedappendProtectedapplyOutside of full screen the top panel also carries the window controls, so it has to stay visible and Alt toggles the menu widgets inside it. In full screen the panel is hidden altogether, so Alt toggles the panel itself and the widgets inside it stay visible.
ProtectedattachProtectedattachProtectedcreateProtectedcreateProtectedcreateProtectedcreateProtectedgetThe widgets a clean Alt press shows and hides in 'toggle' mode in Electron.
ProtectedhandleProtectedhandleProtectedhandleProtectedhandleProtectedhideHides the theia-top-panel depending on the selected titleBarStyle.
The theia-top-panel is used as the container of the main, application menu-bar for the
browser. Native Electron has its own.
By default, this method is called on application onStart.
ProtectedinstallInstalls Alt-key listeners to toggle menu bar visibility. A clean Alt press (press and release without other keys) shows the given toggle targets and focuses the first menu. Pressing Alt again or clicking outside hides them.
the menu bar widget to focus when shown
supplies the widgets to show/hide on Alt toggle. It is consulted on each gesture, because the targets can depend on state that changes while the listener is installed, e.g. whether the window is in full screen.
Called when the application is started. The application shell is not attached yet when this method runs. Should return a promise if it runs asynchronously.
Registers keybindings.
the keybinding registry.
ProtectedsetProtectedtoggleProtectedupdateManages Alt-key toggle behavior for 'toggle' mode in the browser. The top panel's initial visibility is handled by ApplicationShell.setTopPanelVisibility; this method only installs or removes the Alt-key listener.
ProtectedupdateManages Lumino menu bar visibility and Alt-key toggling in Electron.
With native title bar, the native Electron menu bar handles toggle via
autoHideMenuBar, so the Lumino menu bar is simply hidden.
With custom title bar, the Lumino menu bar is the only menu bar visible to the user. For 'toggle' mode, an Alt-key listener is installed to show/hide the menu bar widget.
The command contribution should be implemented to register custom commands and handler.