| 1 | use std::sync::Arc; |
| 2 | use std::sync::atomic::AtomicBool; |
| 3 | |
| 4 | use gpui_kit::Window; |
| 5 | |
| 6 | use calling::ShareKind; |
| 7 | |
| 8 | use super::{NativeHandle, ScreenRect, ShareGeometry, TrayCommand, WorkArea}; |
| 9 | use crate::notify::badge::Badge; |
| 10 | |
| 11 | pub fn native_handle(_window: &Window) -> Option<NativeHandle> { |
| 12 | None |
| 13 | } |
| 14 | |
| 15 | pub fn prepare_toast_window(_handle: NativeHandle) {} |
| 16 | |
| 17 | pub fn set_activatable(_handle: NativeHandle, _activatable: bool) {} |
| 18 | |
| 19 | pub fn work_area(_handle: NativeHandle) -> Option<WorkArea> { |
| 20 | None |
| 21 | } |
| 22 | |
| 23 | pub fn work_area_at(_x: i32, _y: i32) -> Option<WorkArea> { |
| 24 | None |
| 25 | } |
| 26 | |
| 27 | pub fn place(_handle: NativeHandle, _x: i32, _y: i32, _width: i32, _height: i32) {} |
| 28 | |
| 29 | pub fn place_rect(_handle: NativeHandle, _x: i32, _y: i32, _width: i32, _height: i32) {} |
| 30 | |
| 31 | pub fn stack_group_above(_shared: NativeHandle, _group: &[NativeHandle]) {} |
| 32 | |
| 33 | pub fn show_window_inactive(_handle: NativeHandle) {} |
| 34 | |
| 35 | pub fn exclude_from_capture(_handle: NativeHandle) {} |
| 36 | |
| 37 | pub fn include_in_capture(_handle: NativeHandle) {} |
| 38 | |
| 39 | #[cfg(target_os = "linux")] |
| 40 | pub fn make_window_click_through(window: &Window) { |
| 41 | super::x11_input::make_input_transparent(window); |
| 42 | } |
| 43 | |
| 44 | #[cfg(target_os = "linux")] |
| 45 | pub fn window_transparency_available(window: &Window) -> bool { |
| 46 | super::x11_input::window_transparency_available(window) |
| 47 | } |
| 48 | |
| 49 | #[cfg(not(target_os = "linux"))] |
| 50 | pub fn window_transparency_available(_window: &Window) -> bool { |
| 51 | true |
| 52 | } |
| 53 | |
| 54 | #[cfg(not(target_os = "linux"))] |
| 55 | pub fn make_window_click_through(_window: &Window) {} |
| 56 | |
| 57 | #[cfg(target_os = "linux")] |
| 58 | pub fn set_window_icon(window: &Window, png: &[u8]) { |
| 59 | super::x11_input::set_window_icon(window, png); |
| 60 | } |
| 61 | |
| 62 | #[cfg(not(target_os = "linux"))] |
| 63 | pub fn set_window_icon(_window: &Window, _png: &[u8]) {} |
| 64 | |
| 65 | pub fn window_minimized(_handle: NativeHandle) -> bool { |
| 66 | false |
| 67 | } |
| 68 | |
| 69 | pub fn window_rect(_handle: NativeHandle) -> Option<ScreenRect> { |
| 70 | None |
| 71 | } |
| 72 | |
| 73 | pub fn share_geometry(_kind: ShareKind, _id: u64) -> Option<ShareGeometry> { |
| 74 | None |
| 75 | } |
| 76 | |
| 77 | pub fn system_quiet() -> bool { |
| 78 | false |
| 79 | } |
| 80 | |
| 81 | pub fn restore_and_raise(_handle: NativeHandle) {} |
| 82 | |
| 83 | pub fn hide_window(_handle: NativeHandle) {} |
| 84 | |
| 85 | pub fn flash(_handle: NativeHandle) {} |
| 86 | |
| 87 | pub fn stop_flash(_handle: NativeHandle) {} |
| 88 | |
| 89 | pub fn set_badge(_handle: NativeHandle, _badge: Option<&Badge>) {} |
| 90 | |
| 91 | pub fn play_sound() {} |
| 92 | |
| 93 | pub fn set_sound_output(_device_key: Option<String>) {} |
| 94 | |
| 95 | pub fn play_mp3(_bytes: Vec<u8>) {} |
| 96 | |
| 97 | pub fn play_mp3_until(_bytes: Vec<u8>, _looped: bool, _stop: Arc<AtomicBool>) {} |
| 98 | |
| 99 | pub struct Tray; |
| 100 | |
| 101 | impl Tray { |
| 102 | pub fn new(_sound_on: bool, _do_not_disturb: bool, _icon_png: &[u8]) -> Option<Self> { |
| 103 | None |
| 104 | } |
| 105 | |
| 106 | pub fn set_app_icon(&mut self, _icon_png: &[u8], _mention: bool) {} |
| 107 | |
| 108 | pub fn poll(&self) -> Vec<TrayCommand> { |
| 109 | Vec::new() |
| 110 | } |
| 111 | |
| 112 | pub fn sync(&self, _sound_on: bool, _do_not_disturb: bool, _mention: bool) {} |
| 113 | } |
| 114 | |
| 115 | pub fn animations_enabled() -> bool { |
| 116 | true |
| 117 | } |