(Android) Change input process conditional to 'event' -also disable
PERF_TEST for regular usage
This commit is contained in:
parent
035713f124
commit
ff599ac392
|
@ -1,6 +1,7 @@
|
|||
RARCH_VERSION = "0.9.7"
|
||||
LOCAL_PATH := $(call my-dir)
|
||||
PERF_TEST := 1
|
||||
PERF_TEST := 0
|
||||
HAVE_OPENSL := 1
|
||||
|
||||
include $(CLEAR_VARS)
|
||||
|
||||
|
@ -18,7 +19,6 @@ LOCAL_CFLAGS += -DANDROID_MIPS -D__mips__ -D__MIPSEL__
|
|||
endif
|
||||
|
||||
LOCAL_MODULE := retroarch-activity
|
||||
HAVE_OPENSL := 1
|
||||
|
||||
RARCH_PATH := ../../..
|
||||
LOCAL_SRC_FILES = $(RARCH_PATH)/retroarch.c \
|
||||
|
|
|
@ -43,12 +43,6 @@ enum {
|
|||
|
||||
#define LAST_KEYCODE AKEYCODE_ASSIST
|
||||
|
||||
enum {
|
||||
AKEYSTATE_DONT_PROCESS = 0,
|
||||
AKEYSTATE_PROCESS = 1,
|
||||
};
|
||||
|
||||
|
||||
#define PRESSED_UP(x, y) ((-0.80f > y) && (x >= -1.00f))
|
||||
#define PRESSED_DOWN(x, y) ((0.80f < y) && (y <= 1.00f))
|
||||
#define PRESSED_LEFT(x, y) ((-0.80f > x) && (x >= -1.00f))
|
||||
|
@ -329,15 +323,14 @@ static void android_input_poll(void *data)
|
|||
(void)data;
|
||||
|
||||
// Read all pending events.
|
||||
int ident;
|
||||
int event;
|
||||
struct android_poll_source* source;
|
||||
struct android_app* state = g_android.app;
|
||||
|
||||
// We loop until all events are read
|
||||
ident= ALooper_pollOnce(0, NULL, 0, (void**)&source);
|
||||
ALooper_pollOnce(0, NULL, &event, (void**)&source);
|
||||
|
||||
// Process this event.
|
||||
if (ident && source != NULL)
|
||||
if(event)
|
||||
source->process(state, source);
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue