diff options
author | Samuel Rødal <samuel.rodal@nokia.com> | 2011-03-29 09:09:39 (GMT) |
---|---|---|
committer | Samuel Rødal <samuel.rodal@nokia.com> | 2011-03-29 09:09:39 (GMT) |
commit | a73af692412630e9a25ae1ddb403413f3d8a1de6 (patch) | |
tree | 21ba754816f65e1f6077060483ad6dc60a43154c /src/openvg/qwindowsurface_vg.cpp | |
parent | 269b61dd08b7e37445f40e3a1d0854bcf85f445b (diff) | |
download | Qt-a73af692412630e9a25ae1ddb403413f3d8a1de6.zip Qt-a73af692412630e9a25ae1ddb403413f3d8a1de6.tar.gz Qt-a73af692412630e9a25ae1ddb403413f3d8a1de6.tar.bz2 |
Added WindowSurfaceFeature enum to QWindowSurface.
Now that we've added hasPreservedContents() it's cleaner to convert the
various features to feature flags, which is also more extensible in case
more flags are needed in the future.
Reviewed-by: Bjørn Erik Nilsen
Diffstat (limited to 'src/openvg/qwindowsurface_vg.cpp')
-rw-r--r-- | src/openvg/qwindowsurface_vg.cpp | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/src/openvg/qwindowsurface_vg.cpp b/src/openvg/qwindowsurface_vg.cpp index 6f99de4..eedfea5 100644 --- a/src/openvg/qwindowsurface_vg.cpp +++ b/src/openvg/qwindowsurface_vg.cpp @@ -119,9 +119,12 @@ QPaintEngine *QVGWindowSurface::paintEngine() const return d_ptr->paintEngine(); } -bool QVGWindowSurface::hasStaticContentsSupport() const +QWindowSurface::WindowSurfaceFeatures QVGWindowSurface::features() const { - d_ptr->supportsStaticContents(); + WindowSurfaceFeatures features = PartialUpdates | PreservedContents; + if (d_ptr->supportsStaticContents()) + features |= StaticContents; + return features; } int QVGWindowSurface::metric(PaintDeviceMetric met) const |