[Webkit-unassigned] [Bug 36034] [Qt] GraphicsLayer: Opacity change from zero to non-zero doesn't always have effect with AC

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Sat Mar 13 15:49:24 PST 2010


https://bugs.webkit.org/show_bug.cgi?id=36034





--- Comment #5 from Simon Hausmann <hausmann at webkit.org>  2010-03-13 15:49:24 PST ---
(From update of attachment 50544)

> -        m_layer.data()->setOpacity(qMin<qreal>(qMax<qreal>(fromValue + (toValue-fromValue)*progress, 0), 1));
> +        qreal opacity = qBound(qreal(0), fromValue + (toValue-fromValue)*progress, qreal(1));
> +
> +        // FIXME: this is a hack, due to a probable QGraphicsScene bug.
> +        // Without this the opacity change doesn't always have immediate effect.
> +        if (!m_layer.data()->opacity() && opacity)
> +            m_layer.data()->scene()->update();
> +
> +        m_layer.data()->setOpacity(opacity);

It would be good to get a sign-off from Noam on this one and also add a comment
here with a link to the bugreport at http://bugreports.qt.nokia.com/ . Updating
the entire scene is obviously a very expensive operation, so it would be good
to know when we can remove this workaround in the future.

-- 
Configure bugmail: https://bugs.webkit.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.



More information about the webkit-unassigned mailing list