[Qt-interest] Notify parent of being focused

David Ching dc at dcsoft.com
Tue Apr 14 18:57:49 CEST 2009


> Date: Sun, 12 Apr 2009 19:49:20 +0200
> From: Benjamin Sonnemann <b.sonnemann at gmail.com>
> Subject: [Qt-interest] Notify parent of being focused
>
> i subclassed a QFrame and added some widgets, amongst others a
> QTableView.
> Now my QFrame must get notified when the QTableView is focused. The
> only way
> 
> i have seen is to subclass it and reimplement focusInEvent. So, coming
> from
> java
> .net and MFC/WTL i am quite confused as there are "normal" events for
> sth
> like
> that, i wanted to ask if i have overseen sth in the documentation.
> 

Call the QTableView's QObject::installEventFilter() to receive its
notifications in the QFrame.

-- David





More information about the Qt-interest-old mailing list