mirror of
https://github.com/ghostty-org/ghostty.git
synced 2025-04-26 03:18:37 +03:00
Add action on Zig side
This commit is contained in:

committed by
Mitchell Hashimoto

parent
03abc18adb
commit
24ba1a6100
@ -508,6 +508,7 @@ typedef enum {
|
|||||||
GHOSTTY_ACTION_TOGGLE_TAB_OVERVIEW,
|
GHOSTTY_ACTION_TOGGLE_TAB_OVERVIEW,
|
||||||
GHOSTTY_ACTION_TOGGLE_WINDOW_DECORATIONS,
|
GHOSTTY_ACTION_TOGGLE_WINDOW_DECORATIONS,
|
||||||
GHOSTTY_ACTION_TOGGLE_QUICK_TERMINAL,
|
GHOSTTY_ACTION_TOGGLE_QUICK_TERMINAL,
|
||||||
|
GHOSTTY_ACTION_TOGGLE_VISIBILITY,
|
||||||
GHOSTTY_ACTION_GOTO_TAB,
|
GHOSTTY_ACTION_GOTO_TAB,
|
||||||
GHOSTTY_ACTION_GOTO_SPLIT,
|
GHOSTTY_ACTION_GOTO_SPLIT,
|
||||||
GHOSTTY_ACTION_RESIZE_SPLIT,
|
GHOSTTY_ACTION_RESIZE_SPLIT,
|
||||||
|
@ -325,6 +325,7 @@ pub fn performAction(
|
|||||||
.reload_config => try self.reloadConfig(rt_app),
|
.reload_config => try self.reloadConfig(rt_app),
|
||||||
.close_all_windows => try rt_app.performAction(.app, .close_all_windows, {}),
|
.close_all_windows => try rt_app.performAction(.app, .close_all_windows, {}),
|
||||||
.toggle_quick_terminal => try rt_app.performAction(.app, .toggle_quick_terminal, {}),
|
.toggle_quick_terminal => try rt_app.performAction(.app, .toggle_quick_terminal, {}),
|
||||||
|
.toggle_visibility => try rt_app.performAction(.app, .toggle_visibility, {}),
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -96,6 +96,9 @@ pub const Action = union(Key) {
|
|||||||
/// Toggle the quick terminal in or out.
|
/// Toggle the quick terminal in or out.
|
||||||
toggle_quick_terminal,
|
toggle_quick_terminal,
|
||||||
|
|
||||||
|
/// Toggle the quick terminal in or out.
|
||||||
|
toggle_visibility,
|
||||||
|
|
||||||
/// Jump to a specific tab. Must handle the scenario that the tab
|
/// Jump to a specific tab. Must handle the scenario that the tab
|
||||||
/// value is invalid.
|
/// value is invalid.
|
||||||
goto_tab: GotoTab,
|
goto_tab: GotoTab,
|
||||||
@ -180,6 +183,7 @@ pub const Action = union(Key) {
|
|||||||
toggle_tab_overview,
|
toggle_tab_overview,
|
||||||
toggle_window_decorations,
|
toggle_window_decorations,
|
||||||
toggle_quick_terminal,
|
toggle_quick_terminal,
|
||||||
|
toggle_visibility,
|
||||||
goto_tab,
|
goto_tab,
|
||||||
goto_split,
|
goto_split,
|
||||||
resize_split,
|
resize_split,
|
||||||
|
@ -197,6 +197,7 @@ pub const App = struct {
|
|||||||
.toggle_tab_overview,
|
.toggle_tab_overview,
|
||||||
.toggle_window_decorations,
|
.toggle_window_decorations,
|
||||||
.toggle_quick_terminal,
|
.toggle_quick_terminal,
|
||||||
|
.toggle_visibility,
|
||||||
.goto_tab,
|
.goto_tab,
|
||||||
.inspector,
|
.inspector,
|
||||||
.render_inspector,
|
.render_inspector,
|
||||||
|
@ -389,6 +389,7 @@ pub fn performAction(
|
|||||||
.close_all_windows,
|
.close_all_windows,
|
||||||
.toggle_split_zoom,
|
.toggle_split_zoom,
|
||||||
.toggle_quick_terminal,
|
.toggle_quick_terminal,
|
||||||
|
.toggle_visibility,
|
||||||
.size_limit,
|
.size_limit,
|
||||||
.cell_size,
|
.cell_size,
|
||||||
.secure_input,
|
.secure_input,
|
||||||
|
@ -387,6 +387,9 @@ pub const Action = union(enum) {
|
|||||||
/// configuration file to customize its behavior.
|
/// configuration file to customize its behavior.
|
||||||
toggle_quick_terminal: void,
|
toggle_quick_terminal: void,
|
||||||
|
|
||||||
|
/// Toggle visibility of all windows
|
||||||
|
toggle_visibility: void,
|
||||||
|
|
||||||
/// Quit ghostty.
|
/// Quit ghostty.
|
||||||
quit: void,
|
quit: void,
|
||||||
|
|
||||||
@ -588,6 +591,7 @@ pub const Action = union(enum) {
|
|||||||
.close_all_windows,
|
.close_all_windows,
|
||||||
.quit,
|
.quit,
|
||||||
.toggle_quick_terminal,
|
.toggle_quick_terminal,
|
||||||
|
.toggle_visibility,
|
||||||
=> .app,
|
=> .app,
|
||||||
|
|
||||||
// These are app but can be special-cased in a surface context.
|
// These are app but can be special-cased in a surface context.
|
||||||
|
Reference in New Issue
Block a user