aboutsummaryrefslogtreecommitdiff
path: root/src/window
diff options
context:
space:
mode:
Diffstat (limited to 'src/window')
-rw-r--r--src/window/mod.rs11
-rw-r--r--src/window/unmapped.rs5
2 files changed, 5 insertions, 11 deletions
diff --git a/src/window/mod.rs b/src/window/mod.rs
index 92023032..cc681010 100644
--- a/src/window/mod.rs
+++ b/src/window/mod.rs
@@ -11,7 +11,6 @@ use smithay::wayland::shell::xdg::{
SurfaceCachedState, ToplevelSurface, XdgToplevelSurfaceRoleAttributes,
};
-use crate::layout::scrolling::ColumnWidth;
use crate::utils::with_toplevel_role;
pub mod mapped;
@@ -35,7 +34,7 @@ pub struct ResolvedWindowRules {
/// - `None`: unset (global default should be used).
/// - `Some(None)`: set to empty (window picks its own width).
/// - `Some(Some(width))`: set to a particular width.
- pub default_width: Option<Option<ColumnWidth>>,
+ pub default_width: Option<Option<PresetSize>>,
/// Default height for this window.
///
@@ -230,12 +229,8 @@ impl ResolvedWindowRules {
continue;
}
- if let Some(x) = rule
- .default_column_width
- .as_ref()
- .map(|d| d.0.map(ColumnWidth::from))
- {
- resolved.default_width = Some(x);
+ if let Some(x) = rule.default_column_width {
+ resolved.default_width = Some(x.0);
}
if let Some(x) = rule.default_window_height {
diff --git a/src/window/unmapped.rs b/src/window/unmapped.rs
index cf8754b4..6ca11b50 100644
--- a/src/window/unmapped.rs
+++ b/src/window/unmapped.rs
@@ -5,7 +5,6 @@ use smithay::wayland::shell::xdg::ToplevelSurface;
use smithay::wayland::xdg_activation::XdgActivationTokenData;
use super::ResolvedWindowRules;
-use crate::layout::scrolling::ColumnWidth;
#[derive(Debug)]
pub struct Unmapped {
@@ -34,7 +33,7 @@ pub enum InitialConfigureState {
/// Resolved scrolling default width for this window.
///
/// `None` means that the window will pick its own width.
- width: Option<ColumnWidth>,
+ width: Option<PresetSize>,
/// Resolved scrolling default height for this window.
///
@@ -44,7 +43,7 @@ pub enum InitialConfigureState {
/// Resolved floating default width for this window.
///
/// `None` means that the window will pick its own width.
- floating_width: Option<ColumnWidth>,
+ floating_width: Option<PresetSize>,
/// Resolved floating default height for this window.
///