MCPcopy Create free account
hub / github.com/DISTRHO/Cardinal / onScroll

Function onScroll

src/CardinalUI.cpp:1038–1049  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1036 }
1037
1038 bool onScroll(const ScrollEvent& ev) override
1039 {
1040 #ifdef DPF_RUNTIME_TESTING
1041 if (inSelfTest) return false;
1042 #endif
1043
1044 const rack::math::Vec scrollDelta = rack::math::Vec(-ev.delta.getX(), ev.delta.getY()) * 50 ;
1045
1046 const int mods = glfwMods(ev.mod);
1047 const ScopedContext sc(this, mods);
1048 return context->event->handleScroll(lastMousePos, scrollDelta);
1049 }
1050
1051 bool onCharacterInput(const CharacterInputEvent& ev) override
1052 {

Callers

nothing calls this directly

Calls 2

VecClass · 0.85
glfwModsFunction · 0.70

Tested by

no test coverage detected