Kaydet (Commit) 41ef5079 authored tarafından Ashod Nakashian's avatar Ashod Nakashian Kaydeden (comit) Miklos Vajna

editeng: invalidate everything only when toggling header-footer edit

The repaining of the full screen can be costly in certain
cases. Here we avoid it altogether if we don't switch
between header/footer editing and document-body editing.

If for whatever reason this results in some regression,
we should then avoid the invalidation for the Online
version only. The change is unconditional because,
in theory, it shouldn't cause regression, and tests
pass.

Change-Id: I05467c98b5fa4857b94f6742004f98dca3799826
Reviewed-on: https://gerrit.libreoffice.org/29272Tested-by: 's avatarJenkins <ci@libreoffice.org>
Reviewed-by: 's avatarMiklos Vajna <vmiklos@collabora.co.uk>
üst ebcbc970
......@@ -2920,10 +2920,10 @@ void SwEditWin::MouseButtonDown(const MouseEvent& _rMEvt)
!(bWasInFooter && eControl == Footer))
{
rSh.SetShowHeaderFooterSeparator(eControl, !rSh.IsShowHeaderFooterSeparator(eControl));
}
// Repaint everything
Invalidate();
// Repaint everything
Invalidate();
}
}
}
else
......@@ -2934,10 +2934,12 @@ void SwEditWin::MouseButtonDown(const MouseEvent& _rMEvt)
rSh.SetShowHeaderFooterSeparator( Footer, eControl == Footer );
if ( !rSh.IsHeaderFooterEdit() )
{
rSh.ToggleHeaderFooterEdit();
// Repaint everything
rSh.GetWin()->Invalidate();
// Repaint everything
rSh.GetWin()->Invalidate();
}
}
}
else
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment