summaryrefslogtreecommitdiff
path: root/Source/Core
diff options
context:
space:
mode:
authormagumagu <magumagu9@gmail.com>2015-03-01 12:53:28 -0800
committermagumagu <magumagu9@gmail.com>2015-03-01 12:53:28 -0800
commitaa24dbc56e910ea0f04d273be25fd892b7903a76 (patch)
tree5e044962c5371149a98dfbd55d9600bfe4468585 /Source/Core
parent6a211978c1037d131acc9767028755c8cb9ad95a (diff)
parent39812120313ba4ff727e1f693eb52baaca14233a (diff)
Merge pull request #2157 from lioncash/leaks
DolphinWX: Allow input subsystems to correctly deinitialize
Diffstat (limited to 'Source/Core')
-rw-r--r--Source/Core/DolphinWX/Frame.cpp17
-rw-r--r--Source/Core/DolphinWX/Frame.h1
2 files changed, 5 insertions, 13 deletions
diff --git a/Source/Core/DolphinWX/Frame.cpp b/Source/Core/DolphinWX/Frame.cpp
index 946cd52da3..82a089eb7e 100644
--- a/Source/Core/DolphinWX/Frame.cpp
+++ b/Source/Core/DolphinWX/Frame.cpp
@@ -506,7 +506,7 @@ CFrame::CFrame(wxFrame* parent,
g_pCodeWindow->UpdateButtonStates();
// check if game is running
- m_bHotkeysInit = InitControllers();
+ InitControllers();
m_poll_hotkey_timer.SetOwner(this);
Bind(wxEVT_TIMER, &CFrame::PollHotkeys, this);
@@ -515,14 +515,10 @@ CFrame::CFrame(wxFrame* parent,
// Destructor
CFrame::~CFrame()
{
- if (m_bHotkeysInit)
- {
- Wiimote::Shutdown();
- Keyboard::Shutdown();
- Pad::Shutdown();
- HotkeyManagerEmu::Shutdown();
- m_bHotkeysInit = false;
- }
+ Wiimote::Shutdown();
+ Keyboard::Shutdown();
+ Pad::Shutdown();
+ HotkeyManagerEmu::Shutdown();
drives.clear();
@@ -1268,10 +1264,7 @@ const CGameListCtrl *CFrame::GetGameListCtrl() const
void CFrame::PollHotkeys(wxTimerEvent& event)
{
if (Core::GetState() == Core::CORE_UNINITIALIZED || Core::GetState() == Core::CORE_PAUSE)
- {
- m_bHotkeysInit = InitControllers();
g_controller_interface.UpdateInput();
- }
if (Core::GetState() != Core::CORE_STOPPING)
{
diff --git a/Source/Core/DolphinWX/Frame.h b/Source/Core/DolphinWX/Frame.h
index f670c27378..749d1d861e 100644
--- a/Source/Core/DolphinWX/Frame.h
+++ b/Source/Core/DolphinWX/Frame.h
@@ -176,7 +176,6 @@ private:
bool m_bGameLoading;
bool m_bClosing;
bool m_confirmStop;
- bool m_bHotkeysInit;
std::vector<std::string> drives;