Android: Repaint affected areas when window moves

There are no automatic updates of the window when it moves, since
this is not required on most platforms. This broke drag and drop on
Android, because drag and drop creates a temporary window containing
a pixmap with a snapshot of its content. We need to make sure the old
and new location of the window is repainted when it has moved.

[ChangeLog][Android] Fixed repaint issues in drag and drop.

Task-number: QTBUG-35975
Change-Id: I7b043d728551d9963fb5acec804fb90aec5b50ff
Reviewed-by: Paul Olav Tvete <paul.tvete@digia.com>
This commit is contained in:
Eskil Abrahamsen Blomfeldt 2014-06-04 12:37:19 +02:00 committed by The Qt Project
parent 80b6fbc2d9
commit 91b0b2e1a7

View File

@ -76,6 +76,8 @@ void QAndroidPlatformRasterWindow::setGeometry(const QRect &rect)
{
m_oldGeometry = geometry();
QAndroidPlatformWindow::setGeometry(rect);
if (rect.topLeft() != m_oldGeometry.topLeft())
repaint(QRegion(rect));
}
QT_END_NAMESPACE