feat(touch_bar): basic integration

This commit is contained in:
Elian Doran
2025-03-08 11:39:04 +02:00
parent 4cffc50218
commit a170bec3db
2 changed files with 42 additions and 0 deletions

View File

@@ -25,6 +25,7 @@ import type { default as NoteContext, GetTextEditorCallback } from "./note_conte
import type { ContextMenuEvent } from "../menus/context_menu.js";
import type TypeWidget from "../widgets/type_widgets/type_widget.js";
import type EditableTextTypeWidget from "../widgets/type_widgets/editable_text.js";
import TouchBarWidget from "../widgets/touch_bar.js";
interface Layout {
getRootWidget: (appContext: AppContext) => RootWidget;
@@ -444,6 +445,10 @@ class AppContext extends Component {
this.components = [this.tabManager, new RootCommandExecutor(), new Entrypoints(), new MainTreeExecutors(), new ShortcutComponent()];
if (utils.isElectron() && utils.isMac()) {
this.components.push(new TouchBarWidget());
}
if (utils.isMobile()) {
this.components.push(new MobileScreenSwitcherExecutor());
}