more fixes for using wxSocket in console applications (patch 1756260)

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@48723 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Vadim Zeitlin
2007-09-16 14:29:42 +00:00
parent 7ed0328efd
commit 22b6de6a70
21 changed files with 428 additions and 299 deletions

View File

@@ -25,6 +25,8 @@ class wxGSocketIOHandler;
#include "gsocket.h"
#endif
#include "wx/private/gsocketiohandler.h"
class GSocketGUIFunctionsTableConcrete : public GSocketGUIFunctionsTable
{
public:
@@ -70,9 +72,14 @@ public:
GSocketError GetSockOpt(int level, int optname, void *optval, int *optlen);
GSocketError SetSockOpt(int level, int optname,
const void *optval, int optlen);
// enable or disable notifications
void Notify(bool enable);
virtual void Detected_Read();
virtual void Detected_Write();
protected:
//enable or disable event callback using gsocket gui callback table
void EnableEvents(bool flag = true);
void DisableEvents() { EnableEvents(false); }
void Enable(GSocketEvent event);
void Disable(GSocketEvent event);
GSocketError Input_Timeout();
@@ -100,6 +107,9 @@ public:
bool m_dobind;
unsigned long m_timeout;
// true if socket should fire events (use GUI GSocketFunctionsTable)
bool m_use_events;
/* Callbacks */
GSocketEventFlags m_detected;
GSocketCallback m_cbacks[GSOCK_MAX_EVENT];