Skip to content

Commit

Permalink
Merge pull request #5791 from leoetlino/wiimote-indicator
Browse files Browse the repository at this point in the history
Remove Wii Remote connection status from status bar
  • Loading branch information
leoetlino committed Jul 22, 2017
2 parents 57affaf + 91f8283 commit efd318d
Show file tree
Hide file tree
Showing 8 changed files with 0 additions and 54 deletions.
4 changes: 0 additions & 4 deletions Source/Android/jni/MainAndroid.cpp
Expand Up @@ -144,10 +144,6 @@ void Host_ConnectWiimote(int wm_idx, bool connect)
{
}

void Host_SetWiiMoteConnectionState(int _State)
{
}

void Host_ShowVideoConfig(void*, const std::string&)
{
}
Expand Down
1 change: 0 additions & 1 deletion Source/Core/Core/Host.h
Expand Up @@ -31,7 +31,6 @@ void Host_Message(int Id);
void Host_NotifyMapLoaded();
void Host_RefreshDSPDebuggerWindow();
void Host_RequestRenderWindowSize(int width, int height);
void Host_SetWiiMoteConnectionState(int _State);
void Host_UpdateDisasmDialog();
void Host_UpdateMainFrame();
void Host_UpdateTitle(const std::string& title);
Expand Down
7 changes: 0 additions & 7 deletions Source/Core/Core/IOS/USB/Bluetooth/BTEmu.cpp
Expand Up @@ -91,13 +91,10 @@ BluetoothEmu::BluetoothEmu(Kernel& ios, const std::string& device_name)
m_ControllerBD.b[3] = 0x79;
m_ControllerBD.b[4] = 0x00;
m_ControllerBD.b[5] = 0xFF;

Host_SetWiiMoteConnectionState(0);
}

BluetoothEmu::~BluetoothEmu()
{
Host_SetWiiMoteConnectionState(0);
m_WiiMotes.clear();
}

Expand Down Expand Up @@ -355,10 +352,7 @@ void BluetoothEmu::Update()
for (auto& wiimote : m_WiiMotes)
{
if (wiimote.EventPagingChanged(m_ScanEnable))
{
Host_SetWiiMoteConnectionState(1);
SendEventRequestConnection(wiimote);
}
}
}

Expand Down Expand Up @@ -1203,7 +1197,6 @@ void BluetoothEmu::CommandDisconnect(const u8* input)
DEBUG_LOG(IOS_WIIMOTE, " ConnectionHandle: 0x%04x", disconnect->con_handle);
DEBUG_LOG(IOS_WIIMOTE, " Reason: 0x%02x", disconnect->reason);

Host_SetWiiMoteConnectionState(0);
DisplayDisconnectMessage((disconnect->con_handle & 0xFF) + 1, disconnect->reason);

SendEventCommandStatus(HCI_CMD_DISCONNECT);
Expand Down
3 changes: 0 additions & 3 deletions Source/Core/Core/IOS/USB/Bluetooth/WiimoteDevice.cpp
Expand Up @@ -910,9 +910,6 @@ void WiimoteDevice::ReceiveL2capData(u16 scid, const void* _pData, u32 _Size)
// Update Offset to the final size of the report
Offset += _Size;

// Update the status bar
Host_SetWiiMoteConnectionState(2);

// Send the report
m_pHost->SendACLPacket(GetConnectionHandle(), DataFrame, Offset);
}
Expand Down
4 changes: 0 additions & 4 deletions Source/Core/DolphinNoGUI/MainNoGUI.cpp
Expand Up @@ -147,10 +147,6 @@ void Host_ConnectWiimote(int wm_idx, bool connect)
});
}

void Host_SetWiiMoteConnectionState(int _State)
{
}

void Host_ShowVideoConfig(void*, const std::string&)
{
}
Expand Down
3 changes: 0 additions & 3 deletions Source/Core/DolphinQt2/Host.cpp
Expand Up @@ -104,9 +104,6 @@ void Host_NotifyMapLoaded()
void Host_UpdateDisasmDialog()
{
}
void Host_SetWiiMoteConnectionState(int state)
{
}
void Host_ConnectWiimote(int wm_idx, bool connect)
{
}
Expand Down
29 changes: 0 additions & 29 deletions Source/Core/DolphinWX/Main.cpp
Expand Up @@ -458,35 +458,6 @@ void Host_RequestRenderWindowSize(int width, int height)
main_frame->GetEventHandler()->AddPendingEvent(event);
}

void Host_SetWiiMoteConnectionState(int _State)
{
static int currentState = -1;
if (_State == currentState)
return;
currentState = _State;

wxCommandEvent event(wxEVT_HOST_COMMAND, IDM_UPDATE_STATUS_BAR);

switch (_State)
{
case 0:
event.SetString(_("Not connected"));
break;
case 1:
event.SetString(_("Connecting..."));
break;
case 2:
event.SetString(_("Wii Remote Connected"));
break;
}
// The second field is used for auxiliary info such as this
event.SetInt(1);

NOTICE_LOG(WIIMOTE, "%s", static_cast<const char*>(event.GetString().c_str()));

main_frame->GetEventHandler()->AddPendingEvent(event);
}

bool Host_UINeedsControllerState()
{
return wxGetApp().IsActiveThreadsafe() && GetUINeedsControllerState();
Expand Down
3 changes: 0 additions & 3 deletions Source/UnitTests/StubHost.cpp
Expand Up @@ -54,9 +54,6 @@ bool Host_RendererIsFullscreen()
void Host_ConnectWiimote(int, bool)
{
}
void Host_SetWiiMoteConnectionState(int)
{
}
void Host_ShowVideoConfig(void*, const std::string&)
{
}
Expand Down

0 comments on commit efd318d

Please sign in to comment.