[Qt-qml] Mouse Event Filtering in QML 2
Leo.Cunha at nokia.com
Leo.Cunha at nokia.com
Tue Jun 7 12:53:57 CEST 2011
hi,
> -----Original Message-----
> From: Alan Alpert [mailto:alan.alpert at nokia.com]
> Sent: Tuesday, June 07, 2011 2:51 AM
>
> On Tue, 7 Jun 2011 01:23:51 Cunha Leo (Nokia-MP-Qt/Oslo) wrote:
> > hi,
> >
> > in qml1 I used to have an empty MouseArea{ enabled: animation.running
> } to
> > filter events while an animation was ongoing.
> >
> > in qml2 this empty mouse area is no longer accepting the events by
> default,
> > so the only way I found was to declare empty handlers for all mouse
> > events.
> >
> > is there a better way to achieve mouse events filtering in qml2 ?
> >
> > cheers,
> > // leo
>
> Currently you do need to declare empty handlers, due to changes in
> mouse event
> propagation, but this is clearly not ideal. I don't think the empty
> mouse area
> was that great either though. Do you have any suggestions on the best
> way to
> accomplish this?
ok, I will stick with empty handlers for now.
we could have a property in MouseArea (either bool or enum) to decide
which events it should propagate.
cheers,
// leo
More information about the Qt-qml
mailing list