VOGONS


Unpausing in OSX

Topic actions

First post, by Wisq

User metadata
Rank Newbie
Rank
Newbie

Before I trace this further and/or file a bug report, is anyone aware of an issue re: unpausing in OSX?

Specifically: just launching a stock DOSBox 0.74 — no configuration whatsoever, in a window with just a Z:\ prompt — I can press alt-F16 (equivalent to the default keypress alt-pause). I see the titlebar change from "Program: DOSBOX" to "Program: DOSBOX PAUSED". I can then wail away on alt-F16 all I want and it'll never unpause.

I've tried using the mapper to change the pause button to more obvious things, like a letter (with or without modifiers), or backspace, or etc. Same deal no matter what.

Reply 2 of 3, by Wisq

User metadata
Rank Newbie
Rank
Newbie

The process isn't actually stopped at the OS layer (it continues to render etc.), so SIGCONT doesn't help here (though I tried it anyway).

Tested and confirmed that it still happens with SVN build r3871.

I saw that thread and it didn't help the first time, but I just re-read it and realised — is DOSBox actually hardcoded so that the unpause button is always the literal keyboard pause button, no matter what? That could explain the problem, then; I was assuming that it would always be a toggle, i.e. you press the same key to pause and unpause. However, it still doesn't give me a way to unpause, since F16 alone (or with any combination of modifiers I've tried) still does not unpause.

Reply 3 of 3, by truth_deleted

User metadata

1st Test
In the dosbox configuration file, try modifying a line so it appears like so:
priority=higher,pause

Next, start dosbox and then make the window "out of focus", so the cursor is not captured inside dosbox. This should pause dosbox; it may be unpaused by re-activating the dosbox window. This is another test for the unpause function in OSX version of dosbox.

2nd Test
In addition, it may be possible to debug the issue in sdlmain.cpp (don't modify lines yet):

			case SDL_QUIT: KillSwitch(true); break;
case SDL_KEYDOWN: // Must use Pause/Break Key to resume.
case SDL_KEYUP:
if(event.key.keysym.sym == SDLK_PAUSE) {

Does "cmd-q" quit dosbox while paused and unpaused? If so, then edit lines surrounding the OSX specific code in sdlmain.cpp:

if (event.key.keysym.sym == SDLK_q && (event.key.keysym.mod == KMOD_RMETA || event.key.keysym.mod == KMOD_LMETA) ) {
paused = false;
GFX_SetTitle(-1,-1,false);
break;
}

That may test whether "cmd-q" binds to the unpause function. It's difficult to debug without using OSX, so it requires some experimenting at the OSX desktop.