From ecc5bfaeff6503e9e0752035c5e0c94c5a5263a2 Mon Sep 17 00:00:00 2001 From: Héctor Ramón Jiménez Date: Tue, 31 Jan 2023 04:04:29 +0100 Subject: Improve consistency of `window::Action` --- winit/src/window.rs | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'winit/src/window.rs') diff --git a/winit/src/window.rs b/winit/src/window.rs index 2306bdf1..0685c87c 100644 --- a/winit/src/window.rs +++ b/winit/src/window.rs @@ -22,12 +22,12 @@ pub fn resize(width: u32, height: u32) -> Command { })) } -/// Sets the window to maximized or back. +/// Maximizes the window. pub fn maximize(value: bool) -> Command { Command::single(command::Action::Window(window::Action::Maximize(value))) } -/// Set the window to minimized or back. +/// Minimes the window. pub fn minimize(value: bool) -> Command { Command::single(command::Action::Window(window::Action::Minimize(value))) } @@ -38,11 +38,11 @@ pub fn move_to(x: i32, y: i32) -> Command { } /// Sets the [`Mode`] of the window. -pub fn set_mode(mode: Mode) -> Command { - Command::single(command::Action::Window(window::Action::SetMode(mode))) +pub fn change_mode(mode: Mode) -> Command { + Command::single(command::Action::Window(window::Action::ChangeMode(mode))) } -/// Sets the window to maximized or back. +/// Toggles the window to maximized or back. pub fn toggle_maximize() -> Command { Command::single(command::Action::Window(window::Action::ToggleMaximize)) } -- cgit