Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Pause the emulator based on mouse focus #2224

Merged
merged 4 commits into from Mar 19, 2015
Merged

Conversation

@gerikkub
Copy link
Contributor

@gerikkub gerikkub commented Mar 17, 2015

This was requested in issue #8232. Adds the option to pause the emulator when the mouse leaves the render window's focus. Defaults to false.

@skidau
Copy link
Contributor

@skidau skidau commented Mar 17, 2015

Could add a checkbox for this under Config > Interface

@MayImilae
Copy link
Contributor

@MayImilae MayImilae commented Mar 17, 2015

Added the ability to pause the emulator by moving the mouse outside the window

So just moving the mouse away from the window makes the emulator pause? It doesn't even require clicking away? That doesn't sound like it would work very well for emulated wiimote users...

Why not have it pause when clicked away like most programs?

@gerikkub
Copy link
Contributor Author

@gerikkub gerikkub commented Mar 17, 2015

"Why not have it pause when clicked away like most programs?"

That seems like a better idea. I'll change it to pause when focus is moved away from the rendering window.

@@ -486,6 +488,7 @@ void CConfigMain::InitializeGUITooltips()
ConfirmStop->SetToolTip(_("Show a confirmation box before stopping a game."));
UsePanicHandlers->SetToolTip(_("Show a message box when a potentially serious error has occurred.\nDisabling this may avoid annoying and non-fatal messages, but it may result in major crashes having no explanation at all."));
OnScreenDisplayMessages->SetToolTip(_("Display messages over the emulation screen area.\nThese messages include memory card writes, video backend and CPU information, and JIT cache clearing."));
PauseOnFocusLost->SetToolTip(_("Pauses the emulator when focus is taken away from the emulation screen."));

This comment has been minimized.

@JosJuice

JosJuice Mar 17, 2015
Member

Emulation window, not emulation screen.

m_RenderParent->SetCursor(wxNullCursor);
Core::UpdateTitle();
}
UpdateGUI();

This comment has been minimized.

@lioncash

lioncash Mar 17, 2015
Member

UpdateGUI() can be moved out of this scope into the preceding one, since it's called in both cases of the conditional.

@skidau
Copy link
Contributor

@skidau skidau commented Mar 17, 2015

skidau added a commit that referenced this pull request Mar 19, 2015
Pause the emulator based on mouse focus
@skidau skidau merged commit 7d800b6 into dolphin-emu:master Mar 19, 2015
10 checks passed
10 checks passed
@dolphin-emu-bot
default Very basic checks passed, handed off to Buildbot.
Details
@dolphin-emu-bot
lint Build succeeded on the Buildbot.
Details
@dolphin-emu-bot
pr-android Build succeeded on the Buildbot.
Details
@dolphin-emu-bot
pr-deb-dbg-x64 Build succeeded on the Buildbot.
Details
@dolphin-emu-bot
pr-deb-x64 Build succeeded on the Buildbot.
Details
@dolphin-emu-bot
pr-osx-x64 Build succeeded on the Buildbot.
Details
@dolphin-emu-bot
pr-ubu-nogui-x64 Build succeeded on the Buildbot.
Details
@dolphin-emu-bot
pr-ubu-x64 Build succeeded on the Buildbot.
Details
@dolphin-emu-bot
pr-win-dbg-x64 Build succeeded on the Buildbot.
Details
@dolphin-emu-bot
pr-win-x64 Build succeeded on the Buildbot.
Details
@@ -577,6 +580,7 @@ void CConfigMain::CreateGUIControls()
ConfirmStop = new wxCheckBox(DisplayPage, ID_INTERFACE_CONFIRMSTOP, _("Confirm on Stop"));
UsePanicHandlers = new wxCheckBox(DisplayPage, ID_INTERFACE_USEPANICHANDLERS, _("Use Panic Handlers"));
OnScreenDisplayMessages = new wxCheckBox(DisplayPage, ID_INTERFACE_ONSCREENDISPLAYMESSAGES, _("On-Screen Display Messages"));
PauseOnFocusLost = new wxCheckBox(DisplayPage, ID_INTERFACE_PAUSEONFOCUSLOST, _("Pause on Focus Lost"));

This comment has been minimized.

@neobrain

neobrain Mar 21, 2015
Member

This looks like broken English and is more technical than it needs to be. "Pause on Focus Change" or "Pause on Change of active Window" sound more natural and intuitive.

This comment has been minimized.

@bb010g

bb010g Mar 22, 2015
Contributor

"Pause when Focus is Lost"?

This comment has been minimized.

@neobrain

neobrain Mar 22, 2015
Member

Sounds good, too, but "lost" should be spelt with lowercase L, I think.

This comment has been minimized.

@JosJuice

JosJuice Mar 22, 2015
Member

The correct capitalization would be "Pause When Focus Is Lost". http://en.wikibooks.org/wiki/Basic_Book_Design/Capitalizing_Words_in_Titles

This comment has been minimized.

@neobrain

neobrain Mar 22, 2015
Member

@JosJuice There is no explicit language rule on things like this (the link just takes one arbitrary example set of rules), i.e. nothing to be "correct" about. What matters is to make moderate sense and, more importantly, to be consistent, and I think having "lost" (being an adjective) lowercase here is consistent with the rest of our GUI.

This comment has been minimized.

@JosJuice

JosJuice Mar 22, 2015
Member

Sure. I'm fine with that.

This comment has been minimized.

@skidau

skidau Mar 22, 2015
Contributor

Maybe call the option "Pause On Inactive Window" ?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
7 participants