notaz.gp2x.de
/
libpicofe.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
SDL video: Use a hardware surface and double buffering
[libpicofe.git]
/
input.c
diff --git
a/input.c
b/input.c
index
12654e4
..
8d2d552
100644
(file)
--- a/
input.c
+++ b/
input.c
@@
-60,7
+60,8
@@
static int *in_alloc_binds(int drv_id, int key_count)
defbinds = DRV(drv_id).defbinds;
if (defbinds != NULL) {
for (i = 0; ; i++) {
defbinds = DRV(drv_id).defbinds;
if (defbinds != NULL) {
for (i = 0; ; i++) {
- if (defbinds[i].bit == 0 && defbinds[i].code == 0)
+ if (defbinds[i].bit == 0 && defbinds[i].btype == 0
+ && defbinds[i].bit == 0)
break;
binds[IN_BIND_OFFS(defbinds[i].code, defbinds[i].btype)] =
1 << defbinds[i].bit;
break;
binds[IN_BIND_OFFS(defbinds[i].code, defbinds[i].btype)] =
1 << defbinds[i].bit;
@@
-427,6
+428,7
@@
finish:
int in_menu_wait_any(char *charcode, int timeout_ms)
{
int keys_old = menu_key_state;
int in_menu_wait_any(char *charcode, int timeout_ms)
{
int keys_old = menu_key_state;
+ int ret;
while (1)
{
while (1)
{
@@
-442,7
+444,9
@@
int in_menu_wait_any(char *charcode, int timeout_ms)
}
}
}
}
- return menu_key_state;
+ ret = menu_key_state;
+ menu_key_state &= ~PBTN_CHAR;
+ return ret;
}
/* wait for menu input, do autorepeat */
}
/* wait for menu input, do autorepeat */