From 3ec27f827e64b4d69f7c6ec7357dc6b03b601fc9 Mon Sep 17 00:00:00 2001 From: Holger Hans Peter Freyther Date: Sun, 1 Jan 2012 19:58:20 +0100 Subject: blitter: Kill the isBlitterLocked variable of the QBlitterPaintEngine MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit It starts with being initialized wrongly, the call to buffer() will lock the data while we think it is not locked, it can also get out of sync by someone calling buffer() again. Remove the variable and check with the QBlittable if we need to lock the resource into memory. Change-Id: I350375011138d1b4c2c48c100b7b30b8ea2ae460 Reviewed-by: Jørgen Lind --- src/gui/painting/qblittable.cpp | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'src/gui/painting/qblittable.cpp') diff --git a/src/gui/painting/qblittable.cpp b/src/gui/painting/qblittable.cpp index 11058582ef..fe51f7adb0 100644 --- a/src/gui/painting/qblittable.cpp +++ b/src/gui/painting/qblittable.cpp @@ -100,6 +100,12 @@ void QBlittable::unlock() } } +bool QBlittable::isLocked() const +{ + Q_D(const QBlittable); + return d->locked; +} + QT_END_NAMESPACE #endif //QT_NO_BLITTABLE -- cgit v1.2.3