- Quatre mamonaes que he fet en el portatil

This commit is contained in:
2025-08-15 18:17:09 +02:00
parent 78a4c84db2
commit 0530c255c1
3 changed files with 28 additions and 0 deletions

View File

@@ -172,6 +172,12 @@ int main(int argc, char *argv[])
bool result = true;
if (e.type == SDL_QUIT) { zx_system::shutdown(); break; }
if (e.type == SDL_JOYDEVICEADDED) {
printf("JOYSTICK CONECTAT: %i\n", e.jdevice.which);
}
if (e.type == SDL_JOYDEVICEREMOVED) {
printf("JOYSTICK DESCONECTAT: %i\n", e.jdevice.which);
}
if (e.type == SDL_MOUSEBUTTONDOWN) result = ui::window::sendEvent(e.button.windowID, &e);
if (e.type == SDL_MOUSEBUTTONUP) result = ui::window::sendEvent(e.button.windowID, &e);
if (e.type == SDL_MOUSEMOTION) result = ui::window::sendEvent(e.motion.windowID, &e);