fork of PCE focusing on macplus, supporting DaynaPort SCSI network emulation
0
fork

Configure Feed

Select the types of activity you want to include in your feed.

sdl2: Ignore SDL_QUIT while any keys are down and mouse is grabbed

Command+Q and Command+W on macOS cause the app to quit but we want
to pass them through to the emulated Mac.

+5
+5
src/drivers/video/sdl2.c
··· 611 611 static 612 612 void sdl2_check (sdl2_t *sdl) 613 613 { 614 + static SDL_Event cur_keydown_evt = { 0 }; 614 615 SDL_Event evt; 615 616 616 617 while (SDL_PollEvent (&evt)) { 617 618 switch (evt.type) { 618 619 case SDL_KEYDOWN: 620 + cur_keydown_evt = evt; 619 621 sdl2_event_keydown (sdl, evt.key.keysym.scancode, evt.key.keysym.mod); 620 622 break; 621 623 622 624 case SDL_KEYUP: 625 + memset(&cur_keydown_evt, 0, sizeof(cur_keydown_evt)); 623 626 sdl2_event_keyup (sdl, evt.key.keysym.scancode, evt.key.keysym.mod); 624 627 break; 625 628 ··· 644 647 break; 645 648 646 649 case SDL_QUIT: 650 + if (cur_keydown_evt.key.keysym.sym && sdl->grab) 651 + break; 647 652 sdl2_grab_mouse (sdl, 0); 648 653 trm_set_msg_emu (&sdl->trm, "emu.exit", "1"); 649 654 break;