diff options
author | Adam Co <rattles2013@gmail.com> | 2013-05-23 11:05:16 +0300 |
---|---|---|
committer | Miklos Vajna <vmiklos@suse.cz> | 2013-05-23 12:28:27 +0000 |
commit | 286bfde8c3b855db8487dbc1337993056026a5a9 (patch) | |
tree | 88ddf81b9e493d19c62bd252b1a835d54087b357 /sw | |
parent | 47a208560f10637e3262594d16a643c87aa07b5c (diff) |
fdo#64826 : fix for track-changes export in DOCX
Change-Id: I44b505f977edcf9e0af2108487870352277ee9f0
Reviewed-on: https://gerrit.libreoffice.org/4011
Reviewed-by: Miklos Vajna <vmiklos@suse.cz>
Tested-by: Miklos Vajna <vmiklos@suse.cz>
Diffstat (limited to 'sw')
-rw-r--r-- | sw/qa/extras/ooxmlexport/data/fdo64826.docx | bin | 0 -> 12018 bytes | |||
-rw-r--r-- | sw/qa/extras/ooxmlexport/ooxmlexport.cxx | 8 | ||||
-rw-r--r-- | sw/source/filter/ww8/docxexport.cxx | 6 |
3 files changed, 11 insertions, 3 deletions
diff --git a/sw/qa/extras/ooxmlexport/data/fdo64826.docx b/sw/qa/extras/ooxmlexport/data/fdo64826.docx Binary files differnew file mode 100644 index 000000000000..ce4287cea522 --- /dev/null +++ b/sw/qa/extras/ooxmlexport/data/fdo64826.docx diff --git a/sw/qa/extras/ooxmlexport/ooxmlexport.cxx b/sw/qa/extras/ooxmlexport/ooxmlexport.cxx index 8dc69f2a197e..3ed2f188b175 100644 --- a/sw/qa/extras/ooxmlexport/ooxmlexport.cxx +++ b/sw/qa/extras/ooxmlexport/ooxmlexport.cxx @@ -69,6 +69,7 @@ public: void testMathLiteral(); void testFdo48557(); void testI120928(); + void testFdo64826(); CPPUNIT_TEST_SUITE(Test); #if !defined(MACOSX) && !defined(WNT) @@ -116,6 +117,7 @@ void Test::run() {"math-literal.docx", &Test::testMathLiteral}, {"fdo48557.odt", &Test::testFdo48557}, {"i120928.docx", &Test::testI120928}, + {"fdo64826.docx", &Test::testFdo64826}, }; // Don't test the first import of these, for some reason those tests fail const char* aBlacklist[] = { @@ -672,6 +674,12 @@ void Test::testI120928() CPPUNIT_ASSERT_EQUAL(true, bIsGraphic); } +void Test::testFdo64826() +{ + // 'Track-Changes' (Track Revisions) wasn't exported. + CPPUNIT_ASSERT_EQUAL(true, bool(getProperty<sal_Bool>(mxComponent, "RecordChanges"))); +} + CPPUNIT_TEST_SUITE_REGISTRATION(Test); CPPUNIT_PLUGIN_IMPLEMENT(); diff --git a/sw/source/filter/ww8/docxexport.cxx b/sw/source/filter/ww8/docxexport.cxx index ca46cae61aa6..0ceacc05b15d 100644 --- a/sw/source/filter/ww8/docxexport.cxx +++ b/sw/source/filter/ww8/docxexport.cxx @@ -318,6 +318,9 @@ OString DocxExport::OutputChart( uno::Reference< frame::XModel >& xModel, sal_In void DocxExport::ExportDocument_Impl() { + // Set the 'Track Revisions' flag in the settings structure + settings.trackRevisions = 0 != ( nsRedlineMode_t::REDLINE_ON & mnRedlineMode ); + InitStyles(); // init sections @@ -824,9 +827,6 @@ DocxExport::DocxExport( DocxExportFilter *pFilter, SwDoc *pDocument, SwPaM *pCur m_nFooters( 0 ), m_pVMLExport( NULL ) { - // Set the 'Track Revisions' flag in the settings structure - settings.trackRevisions = 0 != ( nsRedlineMode_t::REDLINE_ON & mnRedlineMode ); - // Write the document properies WriteProperties( ); |