mirror of
https://github.com/LGUG2Z/komorebi.git
synced 2026-11-20 07:31:39 +01:00
refactor(windows): WorkspaceGlobals is komorebi-core's
komorebi/src/workspace.rs re-exports komorebi_core::WorkspaceGlobals instead of defining it (crate::workspace::WorkspaceGlobals keeps working for monitor.rs). Same nine fields, same derives, same schemars derive. BEHAVIOUR (Windows runtime): none expected, the type is plain data and its serialisation is skipped in Workspace; marked because it was only type-checked. Windows e2e scenarios: any that read komorebic state (tiled, stack, float fixtures) and the schema check. Verified: Windows cargo clippy --workspace --locked --all-targets -D warnings: PASS; komorebi-core tests PASS. Not run: Windows tests, e2e.
This commit is contained in:
1 parent
68b661a4ec
commit
f616e3a1c6
1 file changed
+1
-15
@@ -52,6 +52,7 @@ use color_eyre::eyre;
|
||||
use color_eyre::eyre::OptionExt;
|
||||
use komorebi_backend::WindowId;
|
||||
use komorebi_core::ContainerWindow;
|
||||
pub use komorebi_core::WorkspaceGlobals;
|
||||
use komorebi_scrolling::ScrollingSpace;
|
||||
use komorebi_themes::Base16ColourPalette;
|
||||
use komorebi_themes::KomorebiThemeCustom as Custom;
|
||||
@@ -183,21 +184,6 @@ pub enum WorkspaceWindowLocation {
|
||||
Floating(usize), // idx in floating_windows
|
||||
}
|
||||
|
||||
#[derive(Debug, Default, Copy, Clone, Serialize, Deserialize, PartialEq)]
|
||||
#[cfg_attr(feature = "schemars", derive(schemars::JsonSchema))]
|
||||
/// Settings setup either by the parent monitor or by the `WindowManager`
|
||||
pub struct WorkspaceGlobals {
|
||||
pub container_padding: Option<i32>,
|
||||
pub workspace_padding: Option<i32>,
|
||||
pub border_width: i32,
|
||||
pub border_offset: i32,
|
||||
pub work_area: Rect,
|
||||
pub work_area_offset: Option<Rect>,
|
||||
pub window_based_work_area_offset: Option<Rect>,
|
||||
pub window_based_work_area_offset_limit: isize,
|
||||
pub floating_layer_behaviour: Option<FloatingLayerBehaviour>,
|
||||
}
|
||||
|
||||
#[derive(Debug, Clone, Serialize, Deserialize, PartialEq)]
|
||||
/// Cached per-layout default options (pre-sorted rules) derived from the global `layout_defaults`.
|
||||
pub(crate) struct CachedLayoutDefault {
|
||||
|
||||
Reference in new issue
Block a user