X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/acd523a9648c2fbae593ae5c3529d21fc219fd3a..4b14a2f79bbabc128c72cba399f11e394aa656b2:/src/common/socketiohandler.cpp?ds=sidebyside diff --git a/src/common/socketiohandler.cpp b/src/common/socketiohandler.cpp index 87a9c457bb..080532be0f 100644 --- a/src/common/socketiohandler.cpp +++ b/src/common/socketiohandler.cpp @@ -24,23 +24,24 @@ #include "wx/apptrait.h" #include "wx/private/socket.h" +#include "wx/link.h" // ============================================================================ // implementation // ============================================================================ // ---------------------------------------------------------------------------- -// wxSocketSelectManager +// wxSocketFDIOManager: socket manager using wxFDIODispatcher // ---------------------------------------------------------------------------- -class wxSocketSelectManager : public wxSocketFDBasedManager +class wxSocketFDIOManager : public wxSocketFDBasedManager { public: virtual void Install_Callback(wxSocketImpl *socket, wxSocketNotify event); virtual void Uninstall_Callback(wxSocketImpl *socket, wxSocketNotify event); }; -void wxSocketSelectManager::Install_Callback(wxSocketImpl *socket_, +void wxSocketFDIOManager::Install_Callback(wxSocketImpl *socket_, wxSocketNotify event) { wxSocketImplUnix * const socket = static_cast(socket_); @@ -70,7 +71,7 @@ void wxSocketSelectManager::Install_Callback(wxSocketImpl *socket_, dispatcher->RegisterFD(fd, socket, socket->GetEnabledCallbacks()); } -void wxSocketSelectManager::Uninstall_Callback(wxSocketImpl *socket_, +void wxSocketFDIOManager::Uninstall_Callback(wxSocketImpl *socket_, wxSocketNotify event) { wxSocketImplUnix * const socket = static_cast(socket_); @@ -106,9 +107,13 @@ static struct ManagerSetter { ManagerSetter() { - static wxSocketSelectManager s_manager; + static wxSocketFDIOManager s_manager; wxAppTraits::SetDefaultSocketManager(&s_manager); } } gs_managerSetter; + +// see the relative linker macro in socket.cpp +wxFORCE_LINK_THIS_MODULE( socketiohandler ); + #endif // wxUSE_SOCKETS