[Qt] WidgetSet.AddEventHandler and friends
zeljko
zeljko at holobit.net
Sat Feb 16 14:17:08 CET 2008
On Saturday 16 February 2008 13:59, Ales Katona wrote:
> zeljko wrote / napĂsal(a):
> > Look at QEvent documentation:
> > QEvent::SockAct 50 Socket activated, used to implement QSocketNotifier.
>
> Ok so if I understand this right, I need to create a subclass of QEvent,
> implement the functionality of "callback" into the SubClass::event() and
> then somehow get that class exported via the qt4pas interface?
You have also QAbstractSocket for implementing common sockets ?
What is INet ? if you really need QSocketNotifier and listen read,write,
exception events then I'm not sure if U need to subclass it.
You can override default EventFilter and add SockAct event, then check when
socket was activated on Sender parameter of EventFilter (Sender should be the
parent of QSocketNotifier).
For each QSocketNotifier type you have to create it's own instance so for read
& write you have to create 2 QSocketNotifiers.
Anyway, this is my wild guess since I've never used QSocketNotifier in this
life :)
More information about the Qt
mailing list