diff --git a/Externals/WiiUseSrc/Src/SConscript b/Externals/WiiUseSrc/Src/SConscript index eb0ed605d0..e4b16f1497 100644 --- a/Externals/WiiUseSrc/Src/SConscript +++ b/Externals/WiiUseSrc/Src/SConscript @@ -3,7 +3,7 @@ import sys Import('env') -if not (env['HAVE_BLUEZ'] and sys.platform != 'darwin'): +if (env['HAVE_BLUEZ'] != 1 and sys.platform != 'darwin'): env['HAVE_WIIUSE'] = 0 Return() diff --git a/Externals/WiiUseSrc/Src/io_osx.m b/Externals/WiiUseSrc/Src/io_osx.m index 8397e70b2d..509ca0e385 100644 --- a/Externals/WiiUseSrc/Src/io_osx.m +++ b/Externals/WiiUseSrc/Src/io_osx.m @@ -31,7 +31,6 @@ * @brief Handles device I/O for *nix. */ -#ifndef WIN32 #include #include @@ -89,9 +88,8 @@ static int wiiuse_connect_single(struct wiimote_t* wm, char* address); #pragma mark - #pragma mark Bluetooth -- (void) l2capChannelOpenComplete:(IOBluetoothL2CAPChannel*) l2capChannel status:(IOReturn) error -{ - //channel opened +- (void) l2capChannelOpenComplete:(IOBluetoothL2CAPChannel*) l2capChannel status:(IOReturn) error { + //channel opened //something to do here ? } @@ -99,10 +97,7 @@ static int wiiuse_connect_single(struct wiimote_t* wm, char* address); - (void)l2capChannelData:(IOBluetoothL2CAPChannel *) l2capChannel data:(byte *)BtData length:(NSUInteger)length { //here we got data from wiimote - for (int o=0; ounid); - /* do the handshake */ - WIIMOTE_ENABLE_STATE(wm, WIIMOTE_STATE_CONNECTED); - wiiuse_handshake(wm, NULL, 0); + /* do the handshake */ + WIIMOTE_ENABLE_STATE(wm, WIIMOTE_STATE_CONNECTED); + wiiuse_handshake(wm, NULL, 0); - wiiuse_set_report_type(wm); + wiiuse_set_report_type(wm); @@ -359,15 +348,15 @@ int wiiuse_io_read(struct wiimote_t* wm) { return 0; - /* if this wiimote is not connected, skip it */ - if (!WIIMOTE_IS_CONNECTED(wm)) - return 0; + /* if this wiimote is not connected, skip it */ + if (!WIIMOTE_IS_CONNECTED(wm)) + return 0; - //run the main loop to get bt data - CFRunLoopRun(); + //run the main loop to get bt data + CFRunLoopRun(); - memcpy(wm->event_buf,DataFromWiimote,sizeof(wm->event_buf)); - return 1; + memcpy(wm->event_buf,DataFromWiimote,sizeof(wm->event_buf)); + return 1; } @@ -378,5 +367,3 @@ int wiiuse_io_write(struct wiimote_t* wm, byte* buf, int len) { } - -#endif /* ifndef WIN32 */ diff --git a/Source/Core/DebuggerUICommon/Src/SConscript b/Source/Core/DebuggerUICommon/Src/SConscript index e433b0420f..713378cc64 100644 --- a/Source/Core/DebuggerUICommon/Src/SConscript +++ b/Source/Core/DebuggerUICommon/Src/SConscript @@ -1,6 +1,7 @@ # -*- python -*- Import('env') +import sys if not env['HAVE_WX']: Return() diff --git a/Source/Core/DolphinWX/Src/Frame.cpp b/Source/Core/DolphinWX/Src/Frame.cpp index 8227dff367..1d3897b74f 100644 --- a/Source/Core/DolphinWX/Src/Frame.cpp +++ b/Source/Core/DolphinWX/Src/Frame.cpp @@ -550,18 +550,18 @@ void CFrame::PostEvent(wxCommandEvent& event) ) { event.StopPropagation(); - g_pCodeWindow->AddPendingEvent(event); + g_pCodeWindow->GetEventHandler()->AddPendingEvent(event); } else event.Skip(); } void CFrame::PostMenuEvent(wxMenuEvent& event) { - if (g_pCodeWindow) g_pCodeWindow->AddPendingEvent(event); + if (g_pCodeWindow) g_pCodeWindow->GetEventHandler()->AddPendingEvent(event); } void CFrame::PostUpdateUIEvent(wxUpdateUIEvent& event) { - if (g_pCodeWindow) g_pCodeWindow->AddPendingEvent(event); + if (g_pCodeWindow) g_pCodeWindow->GetEventHandler()->AddPendingEvent(event); } void CFrame::OnMove(wxMoveEvent& event) diff --git a/Source/Core/DolphinWX/Src/Main.cpp b/Source/Core/DolphinWX/Src/Main.cpp index a7f2d92e3b..9954f460d6 100644 --- a/Source/Core/DolphinWX/Src/Main.cpp +++ b/Source/Core/DolphinWX/Src/Main.cpp @@ -490,11 +490,11 @@ void Host_Message(int Id) void Host_NotifyMapLoaded() { wxCommandEvent event(wxEVT_HOST_COMMAND, IDM_NOTIFYMAPLOADED); - main_frame->AddPendingEvent(event); + main_frame->GetEventHandler()->AddPendingEvent(event); if (main_frame->g_pCodeWindow) { - main_frame->g_pCodeWindow->AddPendingEvent(event); + main_frame->g_pCodeWindow->GetEventHandler()->AddPendingEvent(event); } } @@ -502,11 +502,11 @@ void Host_NotifyMapLoaded() void Host_UpdateLogDisplay() { wxCommandEvent event(wxEVT_HOST_COMMAND, IDM_UPDATELOGDISPLAY); - main_frame->AddPendingEvent(event); + main_frame->GetEventHandler()->AddPendingEvent(event); if (main_frame->g_pCodeWindow) { - main_frame->g_pCodeWindow->AddPendingEvent(event); + main_frame->g_pCodeWindow->GetEventHandler()->AddPendingEvent(event); } } @@ -514,11 +514,11 @@ void Host_UpdateLogDisplay() void Host_UpdateDisasmDialog() { wxCommandEvent event(wxEVT_HOST_COMMAND, IDM_UPDATEDISASMDIALOG); - main_frame->AddPendingEvent(event); + main_frame->GetEventHandler()->AddPendingEvent(event); if (main_frame->g_pCodeWindow) { - main_frame->g_pCodeWindow->AddPendingEvent(event); + main_frame->g_pCodeWindow->GetEventHandler()->AddPendingEvent(event); } } @@ -531,22 +531,22 @@ void Host_ShowJitResults(unsigned int address) void Host_UpdateMainFrame() { wxCommandEvent event(wxEVT_HOST_COMMAND, IDM_UPDATEGUI); - main_frame->AddPendingEvent(event); + main_frame->GetEventHandler()->AddPendingEvent(event); if (main_frame->g_pCodeWindow) { - main_frame->g_pCodeWindow->AddPendingEvent(event); + main_frame->g_pCodeWindow->GetEventHandler()->AddPendingEvent(event); } } void Host_UpdateBreakPointView() { wxCommandEvent event(wxEVT_HOST_COMMAND, IDM_UPDATEBREAKPOINTS); - main_frame->AddPendingEvent(event); + main_frame->GetEventHandler()->AddPendingEvent(event); if (main_frame->g_pCodeWindow) { - main_frame->g_pCodeWindow->AddPendingEvent(event); + main_frame->g_pCodeWindow->GetEventHandler()->AddPendingEvent(event); } } @@ -623,7 +623,7 @@ void Host_UpdateStatusBar(const char* _pText, int Field) // Post message // TODO : this has been said to cause hang (??) how is that even possible ? :d event.StopPropagation(); - main_frame->AddPendingEvent(event); + main_frame->GetEventHandler()->AddPendingEvent(event); // Process the event before continue wxGetApp().ProcessPendingEvents(); } @@ -646,6 +646,6 @@ void Host_SetWiiMoteConnectionState(int _State) // Update field 1 or 2 event.SetInt(1); - main_frame->AddPendingEvent(event); + main_frame->GetEventHandler()->AddPendingEvent(event); } #endif // HAVE_WX diff --git a/Source/Plugins/Plugin_Wiimote/Src/Rumble.cpp b/Source/Plugins/Plugin_Wiimote/Src/Rumble.cpp index 6c558e2bc3..2cfaecdac5 100644 --- a/Source/Plugins/Plugin_Wiimote/Src/Rumble.cpp +++ b/Source/Plugins/Plugin_Wiimote/Src/Rumble.cpp @@ -38,7 +38,7 @@ namespace WiiMoteEmu // SDL Haptic fails on windows, it just doesn't work (even the sample doesn't work) // So until i can make it work, this is all disabled >:( -#if SDL_VERSION_ATLEAST(1, 3, 0) && !defined(_WIN32) +#if SDL_VERSION_ATLEAST(1, 3, 0) && !defined(_WIN32) && !defined(__APPLE__) #define SDL_RUMBLE #else #ifdef _WIN32