summaryrefslogtreecommitdiffstats
path: root/src/gui
diff options
context:
space:
mode:
Diffstat (limited to 'src/gui')
-rw-r--r--src/gui/painting/qbackingstore.cpp4
-rw-r--r--src/gui/painting/qwindowsurface.cpp10
-rw-r--r--src/gui/painting/qwindowsurface_p.h1
3 files changed, 13 insertions, 2 deletions
diff --git a/src/gui/painting/qbackingstore.cpp b/src/gui/painting/qbackingstore.cpp
index e5d8abc..a06a121 100644
--- a/src/gui/painting/qbackingstore.cpp
+++ b/src/gui/painting/qbackingstore.cpp
@@ -1143,9 +1143,9 @@ void QWidgetBackingStore::sync(QWidget *exposedWidget, const QRegion &exposedReg
return;
}
- // If there's no partial update support we always need
+ // If there's no preserved contents support we always need
// to do a full repaint before flushing
- if (!windowSurface->hasPartialUpdateSupport())
+ if (!windowSurface->hasPreservedContents())
fullUpdatePending = true;
// Nothing to repaint.
diff --git a/src/gui/painting/qwindowsurface.cpp b/src/gui/painting/qwindowsurface.cpp
index 9b71818..050805e 100644
--- a/src/gui/painting/qwindowsurface.cpp
+++ b/src/gui/painting/qwindowsurface.cpp
@@ -332,6 +332,16 @@ bool QWindowSurface::hasPartialUpdateSupport() const
return true;
}
+/*!
+ Says whether the window surface's contents are preserved on flush.
+ If not, the window surface contents need to be fully repainted before the
+ next flush.
+*/
+bool QWindowSurface::hasPreservedContents() const
+{
+ return hasPartialUpdateSupport();
+}
+
#ifdef Q_WS_QPA
#define Q_EXPORT_SCROLLRECT Q_GUI_EXPORT
#else
diff --git a/src/gui/painting/qwindowsurface_p.h b/src/gui/painting/qwindowsurface_p.h
index 4a2775f..95b2ee4 100644
--- a/src/gui/painting/qwindowsurface_p.h
+++ b/src/gui/painting/qwindowsurface_p.h
@@ -102,6 +102,7 @@ public:
virtual bool hasStaticContentsSupport() const;
virtual bool hasPartialUpdateSupport() const;
+ virtual bool hasPreservedContents() const;
void setStaticContents(const QRegion &region);
QRegion staticContents() const;