Skip to content

Commit

Permalink
Bug Fix Example: custom_window_frame
Browse files Browse the repository at this point in the history
  • Loading branch information
rustbasic authored Jan 17, 2024
1 parent 5be901d commit 389e371
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion examples/custom_window_frame/src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -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));
} else if title_bar_response.is_pointer_button_down_on() {
}
if title_bar_response.is_pointer_button_down_on() {
ui.ctx().send_viewport_cmd(ViewportCommand::StartDrag);
}

Expand Down

0 comments on commit 389e371

Please sign in to comment.