Don't keep around old dirty region when entire window is invalidated
QPaintDeviceWindowPrivate::markWindowAsDirty() is used to signal that the entire window needs repaint, for example when the window is being resized. If multiple resize events come in before we have a chance to redraw the window, we'll end up redrawing the window based on the window's current size and exposed region, as we should, but we'll still have a dirty region, because we didn't redraw the window at any of its old (larger) sizes. Resetting the dirty region instead of appending to it should be enough. Change-Id: I37443cc1044779f847348a2303a6cebc1a8f3bcb Reviewed-by: Eirik Aavitsland <eirik.aavitsland@qt.io> Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io> (cherry picked from commit 774095ed9aea96e3a9e56441079735cd726c072a) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
This commit is contained in:
parent
b37be2387e
commit
9cb4100e7a
@ -82,7 +82,7 @@ public:
|
||||
void markWindowAsDirty()
|
||||
{
|
||||
Q_Q(QPaintDeviceWindow);
|
||||
dirtyRegion += QRect(QPoint(0, 0), q->size());
|
||||
dirtyRegion = QRect(QPoint(0, 0), q->size());
|
||||
}
|
||||
|
||||
private:
|
||||
|
Loading…
x
Reference in New Issue
Block a user