diff --git a/examples/custom_window_frame/src/main.rs b/examples/custom_window_frame/src/main.rs index 79fc8a89234..093c5c2ec67 100644 --- a/examples/custom_window_frame/src/main.rs +++ b/examples/custom_window_frame/src/main.rs @@ -105,7 +105,8 @@ fn title_bar_ui(ui: &mut egui::Ui, title_bar_rect: eframe::epaint::Rect, title: let is_maximized = ui.input(|i| i.viewport().maximized.unwrap_or(false)); ui.ctx() .send_viewport_cmd(ViewportCommand::Maximized(!is_maximized)); - } + } + if title_bar_response.is_pointer_button_down_on() { ui.ctx().send_viewport_cmd(ViewportCommand::StartDrag); }