summaryrefslogtreecommitdiff
path: root/sc/source/ui/view/tabvwshf.cxx
diff options
context:
space:
mode:
authorMichael Stahl <mstahl@redhat.com>2016-01-13 14:36:23 +0100
committerMichael Stahl <mstahl@redhat.com>2016-01-13 14:55:11 +0100
commit93adda8562b09e14624e52a9bb3fd1e5f321789d (patch)
treeb0898495ef678ee08576b18bbe8248b7d3c4d6ea /sc/source/ui/view/tabvwshf.cxx
parenta3f5f4f6369552a3da870de1ed4ea9d8c628c7a8 (diff)
Revert "sc: Further .uno:Insert (inserting a new sheet) tweak."
This reverts commit b550d3b10adf3a7f8c3013c231e8251059343c5e.
Diffstat (limited to 'sc/source/ui/view/tabvwshf.cxx')
-rw-r--r--sc/source/ui/view/tabvwshf.cxx6
1 files changed, 2 insertions, 4 deletions
diff --git a/sc/source/ui/view/tabvwshf.cxx b/sc/source/ui/view/tabvwshf.cxx
index 8ed4937c1f8c..2b838bf69b04 100644
--- a/sc/source/ui/view/tabvwshf.cxx
+++ b/sc/source/ui/view/tabvwshf.cxx
@@ -192,10 +192,8 @@ void ScTabViewShell::ExecuteTable( SfxRequest& rReq )
else
--nTabNr;
- if (nTabNr > nTabCount)
- nTabNr = nTabCount;
-
- bOk = InsertTable(aName, nTabNr);
+ if ( nTabNr <= nTabCount )
+ bOk = InsertTable( aName, nTabNr );
}
if (bOk)