ui: add show_pointer

For showing the cursor when hovering over a clickable thing. We need
this in more places.

Signed-off-by: William Casarin <jb55@jb55.com>
This commit is contained in:
William Casarin
2024-12-17 11:52:28 -08:00
parent 482a3cb818
commit 49fe7ae5c7

View File

@@ -59,3 +59,7 @@ pub fn hline(ui: &egui::Ui) {
let stroke = ui.style().visuals.widgets.noninteractive.bg_stroke;
ui.painter().hline(rect.x_range(), resize_y, stroke);
}
pub fn show_pointer(ui: &egui::Ui) {
ui.ctx().set_cursor_icon(egui::CursorIcon::PointingHand);
}