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. Pick-to: 6.6 6.5 Change-Id: I37443cc1044779f847348a2303a6cebc1a8f3bcb Reviewed-by: Eirik Aavitsland <eirik.aavitsland@qt.io> Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io>
This commit is contained in:
parent
aa48e212d7
commit
774095ed9a
@ -82,7 +82,7 @@ public:
|
|||||||
void markWindowAsDirty()
|
void markWindowAsDirty()
|
||||||
{
|
{
|
||||||
Q_Q(QPaintDeviceWindow);
|
Q_Q(QPaintDeviceWindow);
|
||||||
dirtyRegion += QRect(QPoint(0, 0), q->size());
|
dirtyRegion = QRect(QPoint(0, 0), q->size());
|
||||||
}
|
}
|
||||||
|
|
||||||
private:
|
private:
|
||||||
|
Loading…
Reference in New Issue
Block a user