X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/52127426a14176f9e12608952c5dc6ea9a2b6bd4..27f35b6674b796e61986681261ec7a96bef93502:/src/x11/evtloop.cpp diff --git a/src/x11/evtloop.cpp b/src/x11/evtloop.cpp index 6017033289..f15fe04516 100644 --- a/src/x11/evtloop.cpp +++ b/src/x11/evtloop.cpp @@ -37,6 +37,7 @@ #include #include +#if wxUSE_SOCKETS // ---------------------------------------------------------------------------- // wxSocketTable // ---------------------------------------------------------------------------- @@ -246,6 +247,7 @@ extern "C" void wxUnregisterSocketCallback(int fd, wxSocketTableType socketType) wxTheSocketTable->UnregisterCallback(fd, socketType); } } +#endif // ---------------------------------------------------------------------------- // wxEventLoopImpl @@ -469,8 +471,10 @@ bool wxEventLoop::Dispatch() FD_SET(fd, &readset); +#if wxUSE_SOCKETS if (wxTheSocketTable) wxTheSocketTable->FillSets(& readset, & writeset, & highest); +#endif if (select(highest+1, &readset, &writeset, NULL, & tv) == 0) { @@ -483,10 +487,12 @@ bool wxEventLoop::Dispatch() if (FD_ISSET(fd, & readset)) XNextEvent((Display*) wxGetDisplay(), & event); +#if wxUSE_SOCKETS // Check if any socket events were pending, // and if so, call their callbacks if (wxTheSocketTable) wxTheSocketTable->ProcessEvents(& readset, & writeset); +#endif } #endif } else