aboutsummaryrefslogtreecommitdiff
path: root/alacritty/src/event.rs
diff options
context:
space:
mode:
authorKirill Chibisov <contact@kchibisov.com>2023-07-13 11:46:25 +0400
committerKirill Chibisov <contact@kchibisov.com>2023-09-04 03:01:12 +0400
commitbfcebbcd38d7bbf2aa4cce2e446fdb781bc0c4f0 (patch)
treeaba4a49e65c0f10fe871f1e5ca2a1ad7746a6810 /alacritty/src/event.rs
parenta189861880aafcce760e3a142bc2d391f2801f64 (diff)
downloadr-alacritty-bfcebbcd38d7bbf2aa4cce2e446fdb781bc0c4f0.tar.gz
r-alacritty-bfcebbcd38d7bbf2aa4cce2e446fdb781bc0c4f0.tar.bz2
r-alacritty-bfcebbcd38d7bbf2aa4cce2e446fdb781bc0c4f0.zip
Add bindings for macOS tabs
This doesn't represnet the movement to add tabs on any other platform, unless winit could add a similar API for them.
Diffstat (limited to 'alacritty/src/event.rs')
-rw-r--r--alacritty/src/event.rs7
1 files changed, 6 insertions, 1 deletions
diff --git a/alacritty/src/event.rs b/alacritty/src/event.rs
index 6717e0ab..387e768e 100644
--- a/alacritty/src/event.rs
+++ b/alacritty/src/event.rs
@@ -392,12 +392,17 @@ impl<'a, N: Notify + 'a, T: EventListener> input::ActionContext<T> for ActionCon
}
#[cfg(not(windows))]
- fn create_new_window(&mut self) {
+ fn create_new_window(&mut self, #[cfg(target_os = "macos")] tabbing_id: Option<String>) {
let mut options = WindowOptions::default();
if let Ok(working_directory) = foreground_process_path(self.master_fd, self.shell_pid) {
options.terminal_options.working_directory = Some(working_directory);
}
+ #[cfg(target_os = "macos")]
+ {
+ options.window_tabbing_id = tabbing_id;
+ }
+
let _ = self.event_proxy.send_event(Event::new(EventType::CreateWindow(options), None));
}