From 461ce5f3631c99e928280935d92f084f4b641b9e Mon Sep 17 00:00:00 2001 From: Ivan Molodetskikh Date: Sun, 24 Dec 2023 14:30:19 +0400 Subject: Move output_size to utils --- src/layout/mod.rs | 11 +---------- 1 file changed, 1 insertion(+), 10 deletions(-) (limited to 'src/layout') diff --git a/src/layout/mod.rs b/src/layout/mod.rs index bf012311..8946ffd0 100644 --- a/src/layout/mod.rs +++ b/src/layout/mod.rs @@ -57,6 +57,7 @@ use smithay::wayland::shell::xdg::SurfaceCachedState; use crate::animation::Animation; use crate::config::{self, Color, Config, PresetWidth, SizeChange, Struts}; +use crate::utils::output_size; #[derive(Debug, Clone, PartialEq, Eq)] pub struct OutputId(String); @@ -3264,16 +3265,6 @@ impl Column { } } -pub fn output_size(output: &Output) -> Size { - let output_scale = output.current_scale().integer_scale(); - let output_transform = output.current_transform(); - let output_mode = output.current_mode().unwrap(); - - output_transform - .transform_size(output_mode.size) - .to_logical(output_scale) -} - fn compute_working_area(output: &Output, struts: Struts) -> Rectangle { // Start with the layer-shell non-exclusive zone. let mut working_area = layer_map_for_output(output).non_exclusive_zone(); -- cgit