Revision 5fafdf24 sdl.c
b/sdl.c | ||
---|---|---|
1 | 1 |
/* |
2 | 2 |
* QEMU SDL display driver |
3 |
*
|
|
3 |
* |
|
4 | 4 |
* Copyright (c) 2003 Fabrice Bellard |
5 |
*
|
|
5 |
* |
|
6 | 6 |
* Permission is hereby granted, free of charge, to any person obtaining a copy |
7 | 7 |
* of this software and associated documentation files (the "Software"), to deal |
8 | 8 |
* in the Software without restriction, including without limitation the rights |
... | ... | |
345 | 345 |
{ |
346 | 346 |
SDL_Event ev1, *ev = &ev1; |
347 | 347 |
int mod_state; |
348 |
|
|
348 |
|
|
349 | 349 |
if (last_vm_running != vm_running) { |
350 | 350 |
last_vm_running = vm_running; |
351 | 351 |
sdl_update_caption(); |
... | ... | |
377 | 377 |
toggle_full_screen(ds); |
378 | 378 |
gui_keysym = 1; |
379 | 379 |
break; |
380 |
case 0x02 ... 0x0a: /* '1' to '9' keys */
|
|
380 |
case 0x02 ... 0x0a: /* '1' to '9' keys */ |
|
381 | 381 |
/* Reset the modifiers sent to the current console */ |
382 | 382 |
reset_keys(); |
383 | 383 |
console_select(keycode - 0x02); |
... | ... | |
460 | 460 |
} |
461 | 461 |
} |
462 | 462 |
} |
463 |
if (is_graphic_console() && !gui_keysym)
|
|
463 |
if (is_graphic_console() && !gui_keysym) |
|
464 | 464 |
sdl_process_key(&ev->key); |
465 | 465 |
break; |
466 | 466 |
case SDL_QUIT: |
... | ... | |
494 | 494 |
} else if (bev->button == SDL_BUTTON_WHEELDOWN && ev->type == SDL_MOUSEBUTTONDOWN) { |
495 | 495 |
dz = 1; |
496 | 496 |
} |
497 |
#endif
|
|
497 |
#endif |
|
498 | 498 |
sdl_send_mouse_event(dz); |
499 | 499 |
} |
500 | 500 |
} |
... | ... | |
578 | 578 |
SDL_SetCursor(guest_sprite); |
579 | 579 |
} |
580 | 580 |
|
581 |
static void sdl_cleanup(void)
|
|
581 |
static void sdl_cleanup(void) |
|
582 | 582 |
{ |
583 | 583 |
if (guest_sprite) |
584 | 584 |
SDL_FreeCursor(guest_sprite); |
Also available in: Unified diff