[Development] Behaviour change of opacity property in QtQuick 2.0

Alan Alpert alan.alpert at nokia.com
Fri Jul 20 04:05:38 CEST 2012


On Thu, 19 Jul 2012 11:06:29 ext Sven Anderson wrote:
> On 19.07.2012 03:29, Alan Alpert wrote:
> > On Wed, 18 Jul 2012 19:00:01 ext Rafael Brandao wrote:
> > 
> > There's a new enabled property which also prevents mouse input. It also
> > affects keyboard focus, but if you aren't using keyboard focus you can
> > bind enabled: opacity > 0 and get effectively the same results as before.
> 
> BTW: I always assumed that binding a bool to a float which is expected
> to be animated, that is, will have a lot of small changes, is very
> inefficent, since a lot of notifies are sent out during the animation,
> and everytime the bool has to be evaluated. So I always set the bool at
> the end of the animation accordingly without binding, or at least I
> created only one bool->float binding, and bound everything else to that
> bool. Is this assumption correct, or don't I have to care about this,
> since it is somehow optimized by the engine?

Yes, that's a good assumption for improved performance. The issue is described 
in more detail on the QtQuick performance considerations page: http://doc-
snapshot.qt-project.org/5.0/qtquick-performance.html#animations .

--
Alan Alpert



More information about the Development mailing list