mirror of
https://github.com/emilk/egui.git
synced 2026-09-01 22:30:03 -04:00
Fix mac scroll modifier (#402)
* fix modifier key for mouse wheel zoom * update CHANGELOG * fix zoom modifier for web backend * improve instructions in plot demo window * accept emilk's proposed change Co-authored-by: Emil Ernerfeldt <emil.ernerfeldt@gmail.com> * update UI instructions for Plot demo * improve UI instructions for plot demo Co-authored-by: Emil Ernerfeldt <emil.ernerfeldt@gmail.com>
This commit is contained in:
@@ -188,7 +188,7 @@ pub fn input_to_egui(
|
||||
delta.x *= -1.0;
|
||||
}
|
||||
|
||||
if input_state.raw.modifiers.ctrl {
|
||||
if input_state.raw.modifiers.ctrl || input_state.raw.modifiers.command {
|
||||
// Treat as zoom instead:
|
||||
input_state.raw.zoom_delta *= (delta.y / 200.0).exp();
|
||||
} else {
|
||||
|
||||
Reference in New Issue
Block a user