mirror of
https://gitlab.com/dosowisko.net/libsuperderpy.git
synced 2025-03-04 09:11:27 +01:00
update imgui and clean up the allegro5 impl
This commit is contained in:
parent
ad26fe14ad
commit
3faa50165c
2 changed files with 5 additions and 17 deletions
2
src/3rdparty/cimgui
vendored
2
src/3rdparty/cimgui
vendored
|
@ -1 +1 @@
|
||||||
Subproject commit e5ac5a203bbf47e120ef4cd773071f4d7274a70d
|
Subproject commit 67f3b097a5090dd074be959fb9c794bd75096a1c
|
|
@ -277,17 +277,9 @@ SYMBOL_INTERNAL bool ImGui_ImplAllegro5_ProcessEvent(ALLEGRO_EVENT* ev) {
|
||||||
}
|
}
|
||||||
return true;
|
return true;
|
||||||
case ALLEGRO_EVENT_MOUSE_BUTTON_DOWN:
|
case ALLEGRO_EVENT_MOUSE_BUTTON_DOWN:
|
||||||
if (ev->mouse.display == g_Display) {
|
|
||||||
if (ev->mouse.button <= 5) {
|
|
||||||
io->MouseDown[ev->mouse.button - 1] = true;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
return true;
|
|
||||||
case ALLEGRO_EVENT_MOUSE_BUTTON_UP:
|
case ALLEGRO_EVENT_MOUSE_BUTTON_UP:
|
||||||
if (ev->mouse.display == g_Display) {
|
if (ev->mouse.display == g_Display && ev->mouse.button <= 5) {
|
||||||
if (ev->mouse.button <= 5) {
|
io->MouseDown[ev->mouse.button - 1] = (ev->type == ALLEGRO_EVENT_MOUSE_BUTTON_DOWN);
|
||||||
io->MouseDown[ev->mouse.button - 1] = false;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
return true;
|
return true;
|
||||||
case ALLEGRO_EVENT_TOUCH_MOVE:
|
case ALLEGRO_EVENT_TOUCH_MOVE:
|
||||||
|
@ -296,14 +288,10 @@ SYMBOL_INTERNAL bool ImGui_ImplAllegro5_ProcessEvent(ALLEGRO_EVENT* ev) {
|
||||||
}
|
}
|
||||||
return true;
|
return true;
|
||||||
case ALLEGRO_EVENT_TOUCH_BEGIN:
|
case ALLEGRO_EVENT_TOUCH_BEGIN:
|
||||||
if (ev->touch.display == g_Display) {
|
|
||||||
io->MouseDown[0] = true;
|
|
||||||
}
|
|
||||||
return true;
|
|
||||||
case ALLEGRO_EVENT_TOUCH_END:
|
case ALLEGRO_EVENT_TOUCH_END:
|
||||||
case ALLEGRO_EVENT_TOUCH_CANCEL:
|
case ALLEGRO_EVENT_TOUCH_CANCEL:
|
||||||
if (ev->touch.display == g_Display) {
|
if (ev->touch.display == g_Display && ev->touch.primary) {
|
||||||
io->MouseDown[0] = false;
|
io->MouseDown[0] = (ev->type == ALLEGRO_EVENT_TOUCH_BEGIN);
|
||||||
}
|
}
|
||||||
return true;
|
return true;
|
||||||
case ALLEGRO_EVENT_MOUSE_LEAVE_DISPLAY:
|
case ALLEGRO_EVENT_MOUSE_LEAVE_DISPLAY:
|
||||||
|
|
Loading…
Add table
Reference in a new issue