projects
/
rocksndiamonds.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
f681967
)
fixed bug with invisible, but active overlay touch buttons
author
Holger Schemel
<info@artsoft.org>
Mon, 20 Apr 2020 21:23:55 +0000
(23:23 +0200)
committer
Holger Schemel
<info@artsoft.org>
Tue, 19 May 2020 16:21:18 +0000
(18:21 +0200)
This fixes a nasty bug with handling (invisible) overlay touch buttons
on devices without touch screen.
src/libgame/gadgets.c
patch
|
blob
|
history
diff --git
a/src/libgame/gadgets.c
b/src/libgame/gadgets.c
index b30082a296a74e4dfd45aeb34c82807e0692c607..cbe1cabc2e23200c04961b7733fa49ce4db9fa99 100644
(file)
--- a/
src/libgame/gadgets.c
+++ b/
src/libgame/gadgets.c
@@
-1479,6
+1479,10
@@
static void MapGadgetExt(struct GadgetInfo *gi, boolean redraw)
if (gi == NULL || gi->deactivated || gi->mapped)
return;
+ // do not map overlay touch buttons if touch screen is not used
+ if (gi->overlay_touch_button && !runtime.uses_touch_device)
+ return;
+
gi->mapped = TRUE;
if (redraw)