From 19ab82e521acaa792ed553033012daef16f29f0f Mon Sep 17 00:00:00 2001 From: Malik Olivier Boussejra Date: Tue, 9 Oct 2018 20:29:13 +0900 Subject: [PATCH] [imgui-glutin-support] get_frame_size: Pass immutable Window There is no reason to pass an immutable window, as the function does not mutate it. --- imgui-glutin-support/src/lib.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/imgui-glutin-support/src/lib.rs b/imgui-glutin-support/src/lib.rs index bd3efc9..0b206ff 100644 --- a/imgui-glutin-support/src/lib.rs +++ b/imgui-glutin-support/src/lib.rs @@ -223,7 +223,7 @@ pub fn update_mouse_cursor(imgui: &ImGui, window: &Window) { /// Get the current frame size for imgui frame rendering. /// /// Returns `None` if the window no longer exists -pub fn get_frame_size(window: &mut Window) -> Option { +pub fn get_frame_size(window: &Window) -> Option { window.get_inner_size().map(|logical_size| FrameSize { logical_size: logical_size.into(), hidpi_factor: window.get_hidpi_factor(),