mirror of
https://github.com/niri-wm/niri.git
synced 2026-06-24 02:01:18 +07:00
Rename FoIPosition to FloatingPosition
This commit is contained in:
@@ -1020,7 +1020,7 @@ pub struct WindowRule {
|
|||||||
#[knuffel(child, unwrap(argument))]
|
#[knuffel(child, unwrap(argument))]
|
||||||
pub variable_refresh_rate: Option<bool>,
|
pub variable_refresh_rate: Option<bool>,
|
||||||
#[knuffel(child)]
|
#[knuffel(child)]
|
||||||
pub default_floating_position: Option<FoIPosition>,
|
pub default_floating_position: Option<FloatingPosition>,
|
||||||
}
|
}
|
||||||
|
|
||||||
#[derive(knuffel::Decode, Debug, Default, Clone, PartialEq)]
|
#[derive(knuffel::Decode, Debug, Default, Clone, PartialEq)]
|
||||||
@@ -1085,7 +1085,7 @@ pub struct BorderRule {
|
|||||||
}
|
}
|
||||||
|
|
||||||
#[derive(knuffel::Decode, Debug, Clone, Copy, PartialEq)]
|
#[derive(knuffel::Decode, Debug, Clone, Copy, PartialEq)]
|
||||||
pub struct FoIPosition {
|
pub struct FloatingPosition {
|
||||||
#[knuffel(property)]
|
#[knuffel(property)]
|
||||||
pub x: FloatOrInt<-65535, 65535>,
|
pub x: FloatOrInt<-65535, 65535>,
|
||||||
#[knuffel(property)]
|
#[knuffel(property)]
|
||||||
@@ -3586,7 +3586,7 @@ mod tests {
|
|||||||
open_floating: Some(false),
|
open_floating: Some(false),
|
||||||
open_focused: Some(true),
|
open_focused: Some(true),
|
||||||
default_window_height: Some(DefaultPresetSize(Some(PresetSize::Fixed(500)))),
|
default_window_height: Some(DefaultPresetSize(Some(PresetSize::Fixed(500)))),
|
||||||
default_floating_position: Some(FoIPosition {
|
default_floating_position: Some(FloatingPosition {
|
||||||
x: FloatOrInt(100.),
|
x: FloatOrInt(100.),
|
||||||
y: FloatOrInt(-200.),
|
y: FloatOrInt(-200.),
|
||||||
relative_to: RelativeTo::BottomLeft,
|
relative_to: RelativeTo::BottomLeft,
|
||||||
|
|||||||
+2
-2
@@ -1,7 +1,7 @@
|
|||||||
use std::cmp::{max, min};
|
use std::cmp::{max, min};
|
||||||
|
|
||||||
use niri_config::{
|
use niri_config::{
|
||||||
BlockOutFrom, BorderRule, CornerRadius, FoIPosition, Match, PresetSize, WindowRule,
|
BlockOutFrom, BorderRule, CornerRadius, FloatingPosition, Match, PresetSize, WindowRule,
|
||||||
};
|
};
|
||||||
use smithay::reexports::wayland_protocols::xdg::shell::server::xdg_toplevel;
|
use smithay::reexports::wayland_protocols::xdg::shell::server::xdg_toplevel;
|
||||||
use smithay::utils::{Logical, Size};
|
use smithay::utils::{Logical, Size};
|
||||||
@@ -44,7 +44,7 @@ pub struct ResolvedWindowRules {
|
|||||||
pub default_height: Option<Option<PresetSize>>,
|
pub default_height: Option<Option<PresetSize>>,
|
||||||
|
|
||||||
/// Default floating position for this window.
|
/// Default floating position for this window.
|
||||||
pub default_floating_position: Option<FoIPosition>,
|
pub default_floating_position: Option<FloatingPosition>,
|
||||||
|
|
||||||
/// Output to open this window on.
|
/// Output to open this window on.
|
||||||
pub open_on_output: Option<String>,
|
pub open_on_output: Option<String>,
|
||||||
|
|||||||
Reference in New Issue
Block a user