Remove some old nonsense.
This commit is contained in:
parent
87bbdbf542
commit
8ce58759e3
|
@ -155,7 +155,6 @@ enum HOST_COMM
|
||||||
WM_USER_CREATE,
|
WM_USER_CREATE,
|
||||||
WM_USER_SETCURSOR,
|
WM_USER_SETCURSOR,
|
||||||
WM_USER_KEYDOWN,
|
WM_USER_KEYDOWN,
|
||||||
WIIMOTE_DISCONNECT // Disconnect Wiimote
|
|
||||||
};
|
};
|
||||||
|
|
||||||
// Used for notification on emulation state
|
// Used for notification on emulation state
|
||||||
|
|
|
@ -211,8 +211,7 @@ void CWII_IPC_HLE_WiiMote::EventConnectionAccepted()
|
||||||
void CWII_IPC_HLE_WiiMote::EventDisconnect()
|
void CWII_IPC_HLE_WiiMote::EventDisconnect()
|
||||||
{
|
{
|
||||||
// Send disconnect message to plugin
|
// Send disconnect message to plugin
|
||||||
u8 Message = WIIMOTE_DISCONNECT;
|
Wiimote::ControlChannel(m_ConnectionHandle & 0xFF, 99, NULL, 0);
|
||||||
Wiimote::ControlChannel(m_ConnectionHandle & 0xFF, 99, &Message, 0);
|
|
||||||
|
|
||||||
m_ConnectionState = CONN_INACTIVE;
|
m_ConnectionState = CONN_INACTIVE;
|
||||||
// Clear channel flags
|
// Clear channel flags
|
||||||
|
|
|
@ -100,37 +100,6 @@ CPanel::CPanel(
|
||||||
else
|
else
|
||||||
SetCursor(wxNullCursor);
|
SetCursor(wxNullCursor);
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case WIIMOTE_DISCONNECT:
|
|
||||||
if (SConfig::GetInstance().m_LocalCoreStartupParameter.bWii)
|
|
||||||
{
|
|
||||||
const int wiimote_idx = lParam;
|
|
||||||
const int wiimote_num = wiimote_idx + 1;
|
|
||||||
|
|
||||||
//Auto reconnect if option is turned on.
|
|
||||||
//TODO: Make this only auto reconnect wiimotes that have the option activated.
|
|
||||||
SConfig::GetInstance().LoadSettingsWii();//Make sure we are using the newest settings.
|
|
||||||
if (SConfig::GetInstance().m_WiiAutoReconnect[wiimote_idx])
|
|
||||||
{
|
|
||||||
GetUsbPointer()->AccessWiiMote(wiimote_idx | 0x100)->Activate(true);
|
|
||||||
NOTICE_LOG(WIIMOTE, "Wiimote %i has been auto-reconnected...", wiimote_num);
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
// The Wiimote has been disconnected, we offer reconnect here.
|
|
||||||
wxMessageDialog *dlg = new wxMessageDialog(
|
|
||||||
this,
|
|
||||||
wxString::Format(_("Wiimote %i has been disconnected by system.\nMaybe this game doesn't support multi-wiimote,\nor maybe it is due to idle time out or other reason.\nDo you want to reconnect immediately?"), wiimote_num),
|
|
||||||
_("Reconnect Wiimote Confirm"),
|
|
||||||
wxYES_NO | wxSTAY_ON_TOP | wxICON_INFORMATION, //wxICON_QUESTION,
|
|
||||||
wxDefaultPosition);
|
|
||||||
|
|
||||||
if (dlg->ShowModal() == wxID_YES)
|
|
||||||
GetUsbPointer()->AccessWiiMote(wiimote_idx | 0x100)->Activate(true);
|
|
||||||
|
|
||||||
dlg->Destroy();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
|
|
||||||
|
|
|
@ -205,10 +205,6 @@ LRESULT CALLBACK WndProc( HWND hWnd, UINT iMsg, WPARAM wParam, LPARAM lParam )
|
||||||
OnKeyDown(lParam);
|
OnKeyDown(lParam);
|
||||||
FreeLookInput((u32)wParam, lParam);
|
FreeLookInput((u32)wParam, lParam);
|
||||||
}
|
}
|
||||||
else if (wParam == WIIMOTE_DISCONNECT)
|
|
||||||
{
|
|
||||||
PostMessage(m_hParent, WM_USER, wParam, lParam);
|
|
||||||
}
|
|
||||||
break;
|
break;
|
||||||
|
|
||||||
// Called when a screensaver wants to show up while this window is active
|
// Called when a screensaver wants to show up while this window is active
|
||||||
|
|
Loading…
Reference in New Issue