mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-07-23 06:09:50 -06:00
Make the gui more accurately reflect connected wiimotes. Also connect and disconnect wiimotes when settings are changed in the wiimote configuration dialog during emulation.
Fix the number of connected wiimotes in the configuration dialog so it works with translations, and update translations accordingly. git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@6771 8ced0084-cf51-0410-be5f-012b33b47a6e
This commit is contained in:
@ -1206,18 +1206,22 @@ void CFrame::OnLoadWiiMenu(wxCommandEvent& event)
|
||||
}
|
||||
}
|
||||
|
||||
void CFrame::OnConnectWiimote(wxCommandEvent& event)
|
||||
void CFrame::ConnectWiimote(int wm_idx, bool connect)
|
||||
{
|
||||
if (Core::isRunning() && SConfig::GetInstance().m_LocalCoreStartupParameter.bWii)
|
||||
{
|
||||
int Id = event.GetId() - IDM_CONNECT_WIIMOTE1;
|
||||
bNoWiimoteMsg = !event.IsChecked();
|
||||
GetUsbPointer()->AccessWiiMote(Id | 0x100)->Activate(event.IsChecked());
|
||||
wxString msg(wxString::Format(wxT("Wiimote %i %s"), Id + 1, (event.IsChecked()) ? _("Connected") : _("Disconnected")));
|
||||
GetUsbPointer()->AccessWiiMote(wm_idx | 0x100)->Activate(connect);
|
||||
wxString msg(wxString::Format(wxT("Wiimote %i %s"), wm_idx + 1,
|
||||
connect ? _("Connected") : _("Disconnected")));
|
||||
Core::DisplayMessage(msg.ToAscii(), 3000);
|
||||
}
|
||||
}
|
||||
|
||||
void CFrame::OnConnectWiimote(wxCommandEvent& event)
|
||||
{
|
||||
ConnectWiimote(event.GetId() - IDM_CONNECT_WIIMOTE1, event.IsChecked());
|
||||
}
|
||||
|
||||
// Toogle fullscreen. In Windows the fullscreen mode is accomplished by expanding the m_Panel to cover
|
||||
// the entire screen (when we render to the main window).
|
||||
void CFrame::OnToggleFullscreen(wxCommandEvent& WXUNUSED (event))
|
||||
|
Reference in New Issue
Block a user