mirror of
https://github.com/hrydgard/ppsspp.git
synced 2026-11-16 02:59:49 +01:00
Misc
This commit is contained in:
1 parent
8e775751fc
commit
ec57b692eb
7 files changed
+91
-20
No files matched your search
+11
-3
@@ -204,13 +204,15 @@ int main(int argc, char *argv[]) {
|
||||
|
||||
InputState input_state;
|
||||
int framecount = 0;
|
||||
|
||||
bool nextFrameMD = 0;
|
||||
while (true) {
|
||||
SDL_Event event;
|
||||
|
||||
input_state.accelerometer_valid = false;
|
||||
input_state.mouse_valid = true;
|
||||
int done = 0;
|
||||
|
||||
// input_state.mouse_down[1] = nextFrameMD;
|
||||
while (SDL_PollEvent(&event)) {
|
||||
if (event.type == SDL_QUIT) {
|
||||
done = 1;
|
||||
@@ -221,19 +223,25 @@ int main(int argc, char *argv[]) {
|
||||
} else if (event.type == SDL_MOUSEMOTION) {
|
||||
input_state.mouse_x[0] = event.motion.x;
|
||||
input_state.mouse_y[0] = event.motion.y;
|
||||
input_state.mouse_x[1] = event.motion.x + 150;
|
||||
input_state.mouse_y[1] = event.motion.y;
|
||||
} else if (event.type == SDL_MOUSEBUTTONDOWN) {
|
||||
if (event.button.button == SDL_BUTTON_LEFT) {
|
||||
///input_state.mouse_buttons_down = 1;
|
||||
input_state.mouse_down[0] = true;
|
||||
input_state.mouse_down[0] = true;
|
||||
nextFrameMD = true;
|
||||
}
|
||||
} else if (event.type == SDL_MOUSEBUTTONUP) {
|
||||
if (event.button.button == SDL_BUTTON_LEFT) {
|
||||
input_state.mouse_down[0] = false;
|
||||
input_state.mouse_down[0] = false;
|
||||
nextFrameMD = false;
|
||||
//input_state.mouse_buttons_up = 1;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
if (done) break;
|
||||
|
||||
input_state.mouse_last[0] = input_state.mouse_down[0];
|
||||
|
||||
Reference in new issue
Block a user