From: Jean-Marc Lasgouttes Date: Wed, 3 Oct 2018 13:57:11 +0000 (+0200) Subject: When ignoring an update, request one for later X-Git-Tag: lyx-2.4.0dev-acb2ca7b~3001 X-Git-Url: https://git.lyx.org/gitweb/?a=commitdiff_plain;h=38f09c177b7da08f852e13c9a50fd2e8098b7491;p=lyx.git When ignoring an update, request one for later If we were not ready to paint the screen, this does not mean that we should give up on repainting, just potpone it. I thought that it was bad to call update() in the paint event, but I cannot find reference to this anymore and everything seems to work as intended. --- diff --git a/src/frontends/qt4/GuiWorkArea.cpp b/src/frontends/qt4/GuiWorkArea.cpp index 2df9342c5a..c190a48d59 100644 --- a/src/frontends/qt4/GuiWorkArea.cpp +++ b/src/frontends/qt4/GuiWorkArea.cpp @@ -1271,6 +1271,8 @@ void GuiWorkArea::paintEvent(QPaintEvent * ev) // backing store has to be copied to screen (this is a no-op // except on macOS). d->updateScreen(ev->rect()); + // Ignore this paint event, but request a new one for later. + viewport()->update(); ev->accept(); return; }