[Qt-interest] Passing custom Events from Child to Parent.

Nitin Mahajan nitinm76 at yahoo.com
Tue Dec 1 15:58:51 CET 2009



--- On Tue, 1/12/09, Andre Somers <andre at familiesomers.nl> wrote:

> From: Andre Somers <andre at familiesomers.nl>
> Subject: Re: [Qt-interest] Passing custom Events from Child to Parent.
> To: "Qt-interest" <qt-interest at trolltech.com>
> Date: Tuesday, 1 December, 2009, 5:30 PM
> Nitin Mahajan wrote:
> > I need to pass some custom events from a child to
> parent. The parent, handles all such custom events
> separately.
> >
> > I think in this case it would be safest / best to get
> a custom event type for each event by calling
> QEvent::registerEventType().
> >
> > Now the question is, Whats the best way to communicate
> these custom event types to the child?
> >
> > regards
> >
> > -Nitin
> >
> >   
> I guess that depends on who decides who handles what. If
> the child 
> itself decides, you should probably pass the event up
> yourself. If the 
> parent should decide, I'd simply install an event filter on
> the children 
> and intercept the events before they arrive at the child.
> 
I meant, how can the parent communicate to the child that these are the custom events it can handle. Thus the child can send these custom events.
For example Parent can be the demo browser and child can be a plug-in widget.

regards

-Nitin

> André
> 
> _______________________________________________
> Qt-interest mailing list
> Qt-interest at trolltech.com
> http://lists.trolltech.com/mailman/listinfo/qt-interest
> 


      New Email addresses available on Yahoo!
Get the Email name you&#39;ve always wanted on the new @ymail and @rocketmail. 
Hurry before someone else does!
http://mail.promotions.yahoo.com/newdomains/aa/




More information about the Qt-interest-old mailing list