Canvas: do not emit paint when resized but hidden
authorJ-P Nurmi <jpnurmi@digia.com>
Fri, 14 Mar 2014 12:04:42 +0000 (13:04 +0100)
committerThe Qt Project <gerrit-noreply@qt-project.org>
Sat, 15 Mar 2014 23:53:31 +0000 (00:53 +0100)
commit4ef1032a4e5b0e612fb2d440fb3ef82fd5af3c5a
treecaf5b863665fa7c14c032d974bc9f0f22a3cabe1
parent156508dbc058e8d43106afb19d1dee50f5d65b93
Canvas: do not emit paint when resized but hidden

It turns out to be a bad idea (as in, breaks the enterprise controls)
to block paint() altogether when hidden. The original bug report
QTBUG-31830 only complained about paint() being emitted upon resize
while _hidden_, so this change solves exactly that. User is still
free to call requestPaint() even when hidden, and Canvas now doesn't
recklessly ignore the request.

Task-number: QTBUG-31830
Change-Id: Icd82188f65406b3ef6ae3b19b5984944576886ff
Reviewed-by: Jens Bache-Wiig <jens.bache-wiig@digia.com>
Reviewed-by: Mitch Curtis <mitch.curtis@digia.com>
Reviewed-by: Gunnar Sletta <gunnar.sletta@jollamobile.com>
src/quick/items/context2d/qquickcanvasitem.cpp
tests/auto/quick/qquickcanvasitem/data/CanvasTestCase.qml
tests/auto/quick/qquickcanvasitem/data/tst_canvas.qml