From: Abdelrazak Younes Date: Mon, 3 Mar 2008 11:04:17 +0000 (+0000) Subject: * GuiWorkArea::focusInEvent(): avoid unnecessary full redraw if the work area was... X-Git-Tag: 1.6.10~5931 X-Git-Url: https://git.lyx.org/gitweb/?a=commitdiff_plain;h=f5c54d8b69c79fdf6b3d64e785a7ea2ff177a5d5;p=features.git * GuiWorkArea::focusInEvent(): avoid unnecessary full redraw if the work area was already current. git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23409 a592a061-630c-0410-9148-cb99ea01b6c8 --- diff --git a/src/frontends/qt4/GuiWorkArea.cpp b/src/frontends/qt4/GuiWorkArea.cpp index bbd653397c..1229d6b801 100644 --- a/src/frontends/qt4/GuiWorkArea.cpp +++ b/src/frontends/qt4/GuiWorkArea.cpp @@ -612,7 +612,9 @@ void GuiWorkArea::contextMenuEvent(QContextMenuEvent * e) void GuiWorkArea::focusInEvent(QFocusEvent * e) { - lyx_view_->setCurrentWorkArea(this); + if (lyx_view_->currentWorkArea() != this) + lyx_view_->setCurrentWorkArea(this); + // Repaint the whole screen. // Note: this is different from redraw() as only the backing pixmap // will be redrawn, which is cheap.