From b1594725c9ffa883e3dce5bf64b90da0c48a3348 Mon Sep 17 00:00:00 2001 From: chris2oph Date: Fri, 25 Jan 2019 11:26:34 +0000 Subject: [PATCH] Use QWidget::update() rather than repaint() in wxClientDC Qt documentation advises to avoid calling repaint() except when an immediate update is required, i.e. it corresponds to wxWindow::Update(). Use update() instead to avoid many Qt warnings that appeared when resizing the caret sample window, for example. Closes https://github.com/wxWidgets/wxWidgets/pull/1178 --- src/qt/dcclient.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/qt/dcclient.cpp b/src/qt/dcclient.cpp index d062f0455a..0137f4d6e1 100644 --- a/src/qt/dcclient.cpp +++ b/src/qt/dcclient.cpp @@ -106,7 +106,7 @@ wxClientDCImpl::~wxClientDCImpl() if ( !pict->isNull() && !widget->paintingActive() && !rect.isEmpty() ) { // only force the update of the rect affected by the DC - widget->repaint( rect ); + widget->update( rect ); } else {