summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMarkus Mohrhard <markus.mohrhard@googlemail.com>2012-07-27 23:03:22 +0200
committerMarkus Mohrhard <markus.mohrhard@googlemail.com>2012-07-27 23:10:14 +0200
commitcbd98c547af4fac641204fb56149e9d7af9ec075 (patch)
tree7f861a80c5e8ed0de58223a7a48e58fc1955a448
parent06b5dfff3aa3005093d427e368ae5eeb5f2ad948 (diff)
copy conditional formats with sheets, fdo#52457
Change-Id: Ic7a337e8a6b36fecbd3aad0e3366fd6f0ccc99c6
-rw-r--r--sc/source/core/data/documen2.cxx6
1 files changed, 6 insertions, 0 deletions
diff --git a/sc/source/core/data/documen2.cxx b/sc/source/core/data/documen2.cxx
index d537c3577f01..1a49d635e438 100644
--- a/sc/source/core/data/documen2.cxx
+++ b/sc/source/core/data/documen2.cxx
@@ -871,6 +871,12 @@ bool ScDocument::CopyTab( SCTAB nOldPos, SCTAB nNewPos, const ScMarkData* pOnlyM
SetNoListening( false );
maTabs[nOldPos]->StartAllListeners();
maTabs[nNewPos]->StartAllListeners();
+
+ ScConditionalFormatList* pNewList = new ScConditionalFormatList(*maTabs[nOldPos]->GetCondFormList());
+ pNewList->UpdateReference(URM_COPY, ScRange( 0, 0, nNewPos , MAXCOL, MAXROW,
+ nNewPos), 0, 0, nDz);
+ maTabs[nNewPos]->SetCondFormList( pNewList );
+
SetDirty();
SetAutoCalc( bOldAutoCalc );