From ca881539f11b763fd92e612d6285504ece85744c Mon Sep 17 00:00:00 2001 From: "hinto.janai" Date: Tue, 26 Dec 2023 11:38:46 -0500 Subject: [PATCH] gupax: fix `Frame` resize --- src/gupax.rs | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/gupax.rs b/src/gupax.rs index ea75333..29da0dc 100644 --- a/src/gupax.rs +++ b/src/gupax.rs @@ -259,7 +259,8 @@ impl crate::disk::Gupax { ui.separator(); if ui.add_sized([width, height], SelectableLabel::new(self.ratio == None, "No lock")).on_hover_text(GUPAX_NO_LOCK).clicked() { self.ratio = None; } if ui.add_sized([width, height], Button::new("Set")).on_hover_text(GUPAX_SET).clicked() { - frame.set_window_size(Vec2::new(self.selected_width as f32, self.selected_height as f32)); + let size = Vec2::new(self.selected_width as f32, self.selected_height as f32); + ui.ctx().send_viewport_cmd(egui::viewport::ViewportCommand::InnerSize(size)); } })}); }