diff options
-rw-r--r-- | src/gui/kernel/qwidget_lite.cpp | 2 | ||||
-rw-r--r-- | src/plugins/graphicssystems/testlite/qwindowsurface_testlite.cpp | 14 | ||||
-rw-r--r-- | src/plugins/graphicssystems/testlite/qwindowsurface_testlite.h | 1 |
3 files changed, 3 insertions, 14 deletions
diff --git a/src/gui/kernel/qwidget_lite.cpp b/src/gui/kernel/qwidget_lite.cpp index 8601855..3913708 100644 --- a/src/gui/kernel/qwidget_lite.cpp +++ b/src/gui/kernel/qwidget_lite.cpp @@ -507,6 +507,8 @@ void QWidgetPrivate::setGeometry_sys(int x, int y, int w, int h, bool isMove) if (isResize) { QResizeEvent e(r.size(), olds); QApplication::sendEvent(q, &e); + if (q->isWindow()) + q->update(); } } else { // not visible if (isMove && q->pos() != oldPos) diff --git a/src/plugins/graphicssystems/testlite/qwindowsurface_testlite.cpp b/src/plugins/graphicssystems/testlite/qwindowsurface_testlite.cpp index cbb720e..65407fd 100644 --- a/src/plugins/graphicssystems/testlite/qwindowsurface_testlite.cpp +++ b/src/plugins/graphicssystems/testlite/qwindowsurface_testlite.cpp @@ -90,24 +90,13 @@ void QTestLiteWindowSurface::flush(QWidget *widget, const QRegion ®ion, const } -void QTestLiteWindowSurface::geometryChanged(const QRect &rect) -{ - bool resize = rect.size() != geometry().size(); - QWindowSurface::setGeometry(rect); - - if (resize) { - window()->update(); //### this is the wrong place for this... - } -} - - void QTestLiteWindowSurface::setGeometry(const QRect &rect) { QRect oldRect = geometry(); if (rect == oldRect) return; - QTestLiteWindowSurface::geometryChanged(rect); + QWindowSurface::setGeometry(rect); //if unchanged ### // xw->setSize(rect.width(), rect.height()); @@ -276,7 +265,6 @@ void QTestLiteWindowSurface::handleMouseEvent(QEvent::Type type, void *ev) void QTestLiteWindowSurface::handleGeometryChange(int x, int y, int w, int h) { - geometryChanged(QRect(x,y,w,h)); QApplicationPrivate::handleGeometryChange(window(), QRect(x,y,w,h)); } diff --git a/src/plugins/graphicssystems/testlite/qwindowsurface_testlite.h b/src/plugins/graphicssystems/testlite/qwindowsurface_testlite.h index 9f9f052..0c4df1a 100644 --- a/src/plugins/graphicssystems/testlite/qwindowsurface_testlite.h +++ b/src/plugins/graphicssystems/testlite/qwindowsurface_testlite.h @@ -62,7 +62,6 @@ public: QPaintDevice *paintDevice(); void flush(QWidget *widget, const QRegion ®ion, const QPoint &offset); void setGeometry(const QRect &rect); - void geometryChanged(const QRect &rect); bool scroll(const QRegion &area, int dx, int dy); void beginPaint(const QRegion ®ion); |