Skip to content

Commit

Permalink
multiply const directly
Browse files Browse the repository at this point in the history
  • Loading branch information
dromer committed Sep 3, 2024
1 parent 37ee2ea commit cf4a9a9
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions src/CardinalUI.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1041,8 +1041,7 @@ class CardinalUI : public CardinalBaseUI,
if (inSelfTest) return false;
#endif

rack::math::Vec scrollDelta = rack::math::Vec(-ev.delta.getX(), ev.delta.getY());
scrollDelta = scrollDelta.mult(50.0);
const rack::math::Vec scrollDelta = rack::math::Vec(-ev.delta.getX(), ev.delta.getY()) * 50 ;

const int mods = glfwMods(ev.mod);
const ScopedContext sc(this, mods);
Expand Down

0 comments on commit cf4a9a9

Please sign in to comment.