diff options
author | Justin Luth <justin_luth@sil.org> | 2021-12-13 13:59:11 +0200 |
---|---|---|
committer | Justin Luth <jluth@mail.com> | 2021-12-13 17:11:40 +0100 |
commit | 6a7daa7ece8442e70351eea071bddbe0d24803de (patch) | |
tree | 03a6998ba8d1606db3cb0705f6c42257b2aa0042 /sc | |
parent | 186a275ffb1309fac9c4ef36d5b3126f0350760f (diff) |
NFC simplify sc: !(!A() const || B) is !B && A()
Not new AND Is the same tab
is much easier to wrap your mind around than
Not (Not the same tab OR New)
Plus it allows avoiding a (trivial) const function call.
Change-Id: Ie0d8a1e490fc3dffe6fc87c9b4d9bd1c41d34dc8
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/126733
Tested-by: Jenkins
Reviewed-by: Justin Luth <jluth@mail.com>
Diffstat (limited to 'sc')
-rw-r--r-- | sc/source/ui/view/tabview3.cxx | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/sc/source/ui/view/tabview3.cxx b/sc/source/ui/view/tabview3.cxx index a500d5fe03ab..d1543b22cfe6 100644 --- a/sc/source/ui/view/tabview3.cxx +++ b/sc/source/ui/view/tabview3.cxx @@ -1803,7 +1803,7 @@ void ScTabView::SetTabNo( SCTAB nTab, bool bNew, bool bExtendSelection, bool bSa return; } - if ( !(nTab != aViewData.GetTabNo() || bNew) ) + if (!bNew && nTab == aViewData.GetTabNo()) return; // FormShell would like to be informed before the switch |