call oc_on_mouse_wheel() when getting a wheel event
This commit is contained in:
parent
762d2d9d10
commit
0d839a9767
|
@ -680,6 +680,20 @@ i32 orca_runloop(void* user)
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
|
|
||||||
|
case OC_EVENT_MOUSE_WHEEL:
|
||||||
|
{
|
||||||
|
if(exports[OC_EXPORT_MOUSE_WHEEL])
|
||||||
|
{
|
||||||
|
const void* args[2] = { &event->mouse.deltaX, &event->mouse.deltaY };
|
||||||
|
M3Result res = m3_Call(exports[OC_EXPORT_MOUSE_WHEEL], 2, args);
|
||||||
|
if(res)
|
||||||
|
{
|
||||||
|
ORCA_WASM3_ABORT(app->env.m3Runtime, res, "Runtime error");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
break;
|
||||||
|
|
||||||
case OC_EVENT_MOUSE_MOVE:
|
case OC_EVENT_MOUSE_MOVE:
|
||||||
{
|
{
|
||||||
if(exports[OC_EXPORT_MOUSE_MOVE])
|
if(exports[OC_EXPORT_MOUSE_MOVE])
|
||||||
|
|
Loading…
Reference in New Issue