Move UI elements into submodule
Browse files at this commitd1fe6930a7bc5b78b0f005c2105c92094fc4ec52Parent: 9e60b348 changed files +10 -9
- src/input.rs +1 -1
- src/lib.rs +1 -4
- src/niri.rs +4 -4
- src/config_error_notification.rs → src/ui/config_error_notification.rs +0 -0
- src/exit_confirm_dialog.rs → src/ui/exit_confirm_dialog.rs +0 -0
- src/hotkey_overlay.rs → src/ui/hotkey_overlay.rs +0 -0
- src/ui/mod.rs +4 -0
- src/screenshot_ui.rs → src/ui/screenshot_ui.rs +0 -0
src/input.rsmodified+1 -1
| @@ -23,7 +23,7 @@ use smithay::wayland::pointer_constraints::{with_pointer_constraint, PointerCons | |||
| 23 | use smithay::wayland::tablet_manager::{TabletDescriptor, TabletSeatTrait}; | 23 | use smithay::wayland::tablet_manager::{TabletDescriptor, TabletSeatTrait}; |
| 24 | 24 | ||
| 25 | use crate::niri::State; | 25 | use crate::niri::State; |
| 26 | -use crate::screenshot_ui::ScreenshotUi; | 26 | +use crate::ui::screenshot_ui::ScreenshotUi; |
| 27 | use crate::utils::spawning::spawn; | 27 | use crate::utils::spawning::spawn; |
| 28 | use crate::utils::{center, get_monotonic_time}; | 28 | use crate::utils::{center, get_monotonic_time}; |
| 29 | 29 | ||
src/lib.rsmodified+1 -4
| @@ -4,21 +4,18 @@ extern crate tracing; | |||
| 4 | pub mod animation; | 4 | pub mod animation; |
| 5 | pub mod backend; | 5 | pub mod backend; |
| 6 | pub mod cli; | 6 | pub mod cli; |
| 7 | -pub mod config_error_notification; | ||
| 8 | pub mod cursor; | 7 | pub mod cursor; |
| 9 | #[cfg(feature = "dbus")] | 8 | #[cfg(feature = "dbus")] |
| 10 | pub mod dbus; | 9 | pub mod dbus; |
| 11 | -pub mod exit_confirm_dialog; | ||
| 12 | pub mod frame_clock; | 10 | pub mod frame_clock; |
| 13 | pub mod handlers; | 11 | pub mod handlers; |
| 14 | -pub mod hotkey_overlay; | ||
| 15 | pub mod input; | 12 | pub mod input; |
| 16 | pub mod ipc; | 13 | pub mod ipc; |
| 17 | pub mod layout; | 14 | pub mod layout; |
| 18 | pub mod niri; | 15 | pub mod niri; |
| 19 | pub mod protocols; | 16 | pub mod protocols; |
| 20 | pub mod render_helpers; | 17 | pub mod render_helpers; |
| 21 | -pub mod screenshot_ui; | 18 | +pub mod ui; |
| 22 | pub mod utils; | 19 | pub mod utils; |
| 23 | 20 | ||
| 24 | #[cfg(not(feature = "xdp-gnome-screencast"))] | 21 | #[cfg(not(feature = "xdp-gnome-screencast"))] |
src/niri.rsmodified+4 -4
| @@ -87,16 +87,13 @@ use smithay::wayland::virtual_keyboard::VirtualKeyboardManagerState; | |||
| 87 | 87 | ||
| 88 | use crate::backend::tty::SurfaceDmabufFeedback; | 88 | use crate::backend::tty::SurfaceDmabufFeedback; |
| 89 | use crate::backend::{Backend, RenderResult, Tty, Winit}; | 89 | use crate::backend::{Backend, RenderResult, Tty, Winit}; |
| 90 | -use crate::config_error_notification::ConfigErrorNotification; | ||
| 91 | use crate::cursor::{CursorManager, CursorTextureCache, RenderCursor, XCursor}; | 90 | use crate::cursor::{CursorManager, CursorTextureCache, RenderCursor, XCursor}; |
| 92 | #[cfg(feature = "dbus")] | 91 | #[cfg(feature = "dbus")] |
| 93 | use crate::dbus::gnome_shell_screenshot::{NiriToScreenshot, ScreenshotToNiri}; | 92 | use crate::dbus::gnome_shell_screenshot::{NiriToScreenshot, ScreenshotToNiri}; |
| 94 | #[cfg(feature = "xdp-gnome-screencast")] | 93 | #[cfg(feature = "xdp-gnome-screencast")] |
| 95 | use crate::dbus::mutter_screen_cast::{self, ScreenCastToNiri}; | 94 | use crate::dbus::mutter_screen_cast::{self, ScreenCastToNiri}; |
| 96 | -use crate::exit_confirm_dialog::ExitConfirmDialog; | ||
| 97 | use crate::frame_clock::FrameClock; | 95 | use crate::frame_clock::FrameClock; |
| 98 | use crate::handlers::configure_lock_surface; | 96 | use crate::handlers::configure_lock_surface; |
| 99 | -use crate::hotkey_overlay::HotkeyOverlay; | ||
| 100 | use crate::input::{apply_libinput_settings, TabletData}; | 97 | use crate::input::{apply_libinput_settings, TabletData}; |
| 101 | use crate::ipc::server::IpcServer; | 98 | use crate::ipc::server::IpcServer; |
| 102 | use crate::layout::{Layout, MonitorRenderElement}; | 99 | use crate::layout::{Layout, MonitorRenderElement}; |
| @@ -104,7 +101,10 @@ use crate::protocols::foreign_toplevel::{self, ForeignToplevelManagerState}; | |||
| 104 | use crate::pw_utils::{Cast, PipeWire}; | 101 | use crate::pw_utils::{Cast, PipeWire}; |
| 105 | use crate::render_helpers::renderer::NiriRenderer; | 102 | use crate::render_helpers::renderer::NiriRenderer; |
| 106 | use crate::render_helpers::{render_to_texture, render_to_vec}; | 103 | use crate::render_helpers::{render_to_texture, render_to_vec}; |
| 107 | -use crate::screenshot_ui::{ScreenshotUi, ScreenshotUiRenderElement}; | 104 | +use crate::ui::config_error_notification::ConfigErrorNotification; |
| 105 | +use crate::ui::exit_confirm_dialog::ExitConfirmDialog; | ||
| 106 | +use crate::ui::hotkey_overlay::HotkeyOverlay; | ||
| 107 | +use crate::ui::screenshot_ui::{ScreenshotUi, ScreenshotUiRenderElement}; | ||
| 108 | use crate::utils::{ | 108 | use crate::utils::{ |
| 109 | center, get_monotonic_time, make_screenshot_path, output_size, write_png_rgba8, | 109 | center, get_monotonic_time, make_screenshot_path, output_size, write_png_rgba8, |
| 110 | }; | 110 | }; |
src/config_error_notification.rs → src/ui/config_error_notification.rsrenamed+0 -0
src/exit_confirm_dialog.rs → src/ui/exit_confirm_dialog.rsrenamed+0 -0
src/hotkey_overlay.rs → src/ui/hotkey_overlay.rsrenamed+0 -0
src/ui/mod.rsadded+4 -0
| @@ -0,0 +1,4 @@ | |||
| 1 | +pub mod config_error_notification; | ||
| 2 | +pub mod exit_confirm_dialog; | ||
| 3 | +pub mod hotkey_overlay; | ||
| 4 | +pub mod screenshot_ui; | ||
src/screenshot_ui.rs → src/ui/screenshot_ui.rsrenamed+0 -0