X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/39b91ecabeb35ad879412df1bcd1cec9ea97a20a..866592d872daa1f4e3d44948d7d3a6c90b0af9d0:/src/gtk/gsockgtk.c diff --git a/src/gtk/gsockgtk.c b/src/gtk/gsockgtk.c index f31333439f..8677ef3626 100644 --- a/src/gtk/gsockgtk.c +++ b/src/gtk/gsockgtk.c @@ -5,26 +5,24 @@ * CVSID: $Id$ * ------------------------------------------------------------------------- */ +#include "wx/setup.h" + +#if wxUSE_SOCKETS + #include -#include -#include -#include -#include "../unix/gsockunx.h" +#include "gdk/gdk.h" +#include "glib.h" +#include "wx/gsocket.h" +#include "wx/unix/gsockunx.h" void _GSocket_GDK_Input(gpointer data, gint source, GdkInputCondition condition) { GSocket *socket = (GSocket *)data; - switch (condition) { - case GDK_INPUT_READ: + if (condition & GDK_INPUT_READ) _GSocket_Detected_Read(socket); - break; - case GDK_INPUT_WRITE: + if (condition & GDK_INPUT_WRITE) _GSocket_Detected_Write(socket); - break; - default: - break; - } } void _GSocket_GUI_Init(GSocket *socket) @@ -105,3 +103,5 @@ unsigned long GSocket_GetEventID(GSocket *socket) void GSocket_DoEvent(unsigned long evt_id) { } + +#endif /* wxUSE_SOCKETS */