alinebee / Boxer

The DOS game emulator that's fit for your Mac.
http://boxerapp.com/
774 stars 139 forks source link

Disabling Auto-Pause #31

Closed arcanelab closed 10 years ago

arcanelab commented 10 years ago

Even if I have "Auto-Pause in Background" not selected in the Emulation menu, the emulation pauses when the app loses focus or if I open the app menu. Is this the expected behavior? If so, what does this particular menu item do then? (Version 1.3.2, build 20120713.1)

alinebee commented 10 years ago

When the "Auto-Pause in Background" toggle is enabled, Boxer will automatically pause if you minimize the DOS window or if another application becomes the active application (that is, the application whose name appears in the menubar).

Regardless of the state of the toggle, Boxer will always pause in those circumstances if it is at the DOS prompt and no program is currently running, because there is no reason for it to continue emulating in that situation. When it's running a program, Boxer should only pause itself if that toggle is enabled.

(Boxer will also always pause when you open a menu: this is a limitation of Boxer's single-threaded architecture rather than a design choice, and will be eliminated once Boxer moves to a multi-threaded model.)

So, those are the expected behaviours; if you are finding that Boxer is auto-pausing when it goes into the background even when a program is running and the "Auto-Pause in Background" toggle is disabled, then please let me know what program(s) you're running where Boxer is exhibiting that behaviour.

arcanelab commented 10 years ago

Thank you for your reply!

Regardless of the state of the toggle, Boxer will always pause in those circumstances if it is at the DOS prompt and no program is currently running, because there is no reason for it to continue emulating in that situation.

IMHO, this is a little bit counter-intuitive if you have the "Auto-Pause in Background" toggle available for the user. For example - though this might be a niche situation -, what happens if you have a TSR program running behind the DOS prompt?

From the user's perspective I think it would be more straightforward to let the emulation running regardless of the app state (has focus or in background) whether it's the DOS prompt or any other program that is running when the "Auto-pause in Background" toggle is off.

So, those are the expected behaviours; if you are finding that Boxer is auto-pausing when it goes into the background even when a program is running and the "Auto-Pause in Background" toggle is disabled, then please let me know what program(s) you're running where Boxer is exhibiting that behaviour.

I encountered this with Open Cubic Player, however, just like with most nasty bugs, this behavior is not 100% reproducible, it happens only every so often. Sometimes it pauses while playing, sometimes it doesn't. In general, after loading 3-4 songs the behavior starts occuring for me and stays until I restart Boxer.

I hope this helps.

arcanelab commented 10 years ago

Oops, sorry for closing/reopening, I accidentally clicked the button!

alinebee commented 10 years ago

You're right, I didn't consider the case of TSRs; or, in the case of OpenCP, apps that let you drop back to a DOS prompt while they're still performing some operation. I've now changed the behaviour so that Boxer will not auto-pause at the DOS prompt unless the "Auto-pause in background" option really is enabled.

Regardless of all that, the UI interruptions and general CPU thirstiness still make Boxer a pretty poor choice of music player ;)