Completely split apart wxWidgets and Boost.Asio networkingamule-svn-r10888
commit2fe5e5b2f0b2c071c22093f6c0eec89747bc68b0
authorupstream svn <svn@amule.org>
Mon, 28 Dec 2015 21:13:40 +0000 (28 21:13 +0000)
committerDévai Tamás <gonosztopi@amule.org>
Wed, 24 Feb 2016 11:26:56 +0000 (24 11:26 +0000)
tree7043d4ba19f2a7b2d84ea40c45aafa2c2c2aa591
parent5f3ff492ad8f1aa2b7e9612ac1b3dd80a5d9450d
Completely split apart wxWidgets and Boost.Asio networking

aMule built with wxWidgets networking should not include anything from Boost.Asio
code, and vica versa (well, that's not true, detailed below).

The only valid place to #include <wx/socket.h> is in the socket code wrapper,
LibSocket.h. The only exception from this rule is amule.cpp, which includes
wx/socket.h unconditionally. This is required, as we use wxHTTP for the HTTP
download thread, which in turn uses the wxWidgets socket code. Therefore we
must initialize wxWidgets networking even if we use Boost.Asio for everything
else.

I decided to comment out the SetEventHandler() and SetNotify() calls in ASIO builds,
they do nothing, and this lets us get rid of the event handlers themselves. Also,
adding dummy MULE_SOCKET_*_FLAG definitions to LibSocket.h would clutter it too
much for nothing (since the function would be just a do-nothing in ASIO).
26 files changed:
.svn-revision
src/ClientTCPSocket.cpp
src/EMSocket.cpp
src/ExternalConn.cpp
src/ExternalConn.h
src/LibSocket.h
src/LibSocketAsio.cpp
src/LibSocketWX.cpp
src/ListenSocket.cpp
src/MuleUDPSocket.cpp
src/MuleUDPSocket.h
src/NetworkFunctions.h
src/Proxy.cpp
src/Proxy.h
src/ServerSocket.cpp
src/amule-gui.cpp
src/amule-remote-gui.cpp
src/amule-remote-gui.h
src/amule.cpp
src/amule.h
src/amuled.cpp
src/libs/ec/cpp/ECMuleSocket.cpp
src/libs/ec/cpp/ECMuleSocket.h
src/libs/ec/cpp/RemoteConnect.h
src/webserver/src/WebServer.cpp
src/webserver/src/WebServer.h