diff options
-rw-r--r-- | include/sfx2/objsh.hxx | 2 | ||||
-rw-r--r-- | sfx2/source/doc/objmisc.cxx | 6 | ||||
-rw-r--r-- | sw/inc/docsh.hxx | 1 | ||||
-rw-r--r-- | sw/source/filter/ww8/ww8par.cxx | 2 | ||||
-rw-r--r-- | sw/source/uibase/app/docsh.cxx | 16 | ||||
-rw-r--r-- | writerfilter/source/dmapper/DomainMapper.cxx | 1 |
6 files changed, 3 insertions, 25 deletions
diff --git a/include/sfx2/objsh.hxx b/include/sfx2/objsh.hxx index da28df348996..6f3f1098a479 100644 --- a/include/sfx2/objsh.hxx +++ b/include/sfx2/objsh.hxx @@ -460,8 +460,6 @@ public: bool IsAbortingImport() const; void FinishedLoading( SfxLoadedFlags nWhich = SfxLoadedFlags::ALL ); - virtual void SetFormatSpecificCompatibilityOptions( const OUString& /*rFilterTypeName*/ ) { /* Do not do anything here; Derived classes must overload to do actual work */ }; - void TemplateDisconnectionAfterLoad(); void SetLoading(SfxLoadedFlags nFlags); bool IsLoading() const; diff --git a/sfx2/source/doc/objmisc.cxx b/sfx2/source/doc/objmisc.cxx index 81f9f9ce4573..86764e760ebe 100644 --- a/sfx2/source/doc/objmisc.cxx +++ b/sfx2/source/doc/objmisc.cxx @@ -1058,12 +1058,6 @@ void SfxObjectShell::InitOwnModel_Impl() void SfxObjectShell::FinishedLoading( SfxLoadedFlags nFlags ) { - std::shared_ptr<const SfxFilter> pFlt = pMedium->GetFilter(); - if( pFlt ) - { - SetFormatSpecificCompatibilityOptions( pFlt->GetTypeName() ); - } - bool bSetModifiedTRUE = false; const SfxStringItem* pSalvageItem = SfxItemSet::GetItem<SfxStringItem>(pMedium->GetItemSet(), SID_DOC_SALVAGE, false); if( ( nFlags & SfxLoadedFlags::MAINDOCUMENT ) && !(pImpl->nLoadedFlags & SfxLoadedFlags::MAINDOCUMENT ) diff --git a/sw/inc/docsh.hxx b/sw/inc/docsh.hxx index a182cf8e8d60..db674673f126 100644 --- a/sw/inc/docsh.hxx +++ b/sw/inc/docsh.hxx @@ -273,7 +273,6 @@ public: the load of document being finished. */ void LoadingFinished(); - virtual void SetFormatSpecificCompatibilityOptions( const OUString& rFilterTypeName ) override; /// Cancel transfer (called from SFX). virtual void CancelTransfers() override; diff --git a/sw/source/filter/ww8/ww8par.cxx b/sw/source/filter/ww8/ww8par.cxx index 6183cac5fb94..df66b5db33f2 100644 --- a/sw/source/filter/ww8/ww8par.cxx +++ b/sw/source/filter/ww8/ww8par.cxx @@ -1841,6 +1841,8 @@ void SwWW8ImplReader::ImportDop() // tdf#117923 m_rDoc.getIDocumentSettingAccess().set( DocumentSettingId::APPLY_PARAGRAPH_MARK_FORMAT_TO_NUMBERING, true); + m_rDoc.getIDocumentSettingAccess().set( + DocumentSettingId::MS_WORD_COMP_TRAILING_BLANKS, true); // Import Default Tabs long nDefTabSiz = m_xWDop->dxaTab; diff --git a/sw/source/uibase/app/docsh.cxx b/sw/source/uibase/app/docsh.cxx index d6d4dd480b64..e86630a86ece 100644 --- a/sw/source/uibase/app/docsh.cxx +++ b/sw/source/uibase/app/docsh.cxx @@ -1197,22 +1197,6 @@ void SwDocShell::LoadingFinished() } } -void SwDocShell::SetFormatSpecificCompatibilityOptions( const OUString& rFilterTypeName ) -{ - //Enable MS Word-compatibility trailing blanks option for MS Word files - if ( rFilterTypeName == "writer_MS_Word_95" || - rFilterTypeName == "writer_MS_Word_97" || - rFilterTypeName == "writer_MS_Word_2003_XML" || - rFilterTypeName == "writer_MS_Word_2007" || - rFilterTypeName == "writer_MS_Word_2007_Template" || - rFilterTypeName == "writer_OOXML" || - rFilterTypeName == "writer_OOXML_Text_Template" || - rFilterTypeName == "writer_Rich_Text_Format" ) - { - GetDoc()->getIDocumentSettingAccess().set( DocumentSettingId::MS_WORD_COMP_TRAILING_BLANKS, true ); - } -} - // a Transfer is cancelled (is called from SFX) void SwDocShell::CancelTransfers() { diff --git a/writerfilter/source/dmapper/DomainMapper.cxx b/writerfilter/source/dmapper/DomainMapper.cxx index 12fa4f26090a..4b9c1d13aa88 100644 --- a/writerfilter/source/dmapper/DomainMapper.cxx +++ b/writerfilter/source/dmapper/DomainMapper.cxx @@ -124,6 +124,7 @@ DomainMapper::DomainMapper( const uno::Reference< uno::XComponentContext >& xCon // Don't load the default style definitions to avoid weird mix m_pImpl->SetDocumentSettingsProperty("StylesNoDefault", uno::makeAny(true)); + m_pImpl->SetDocumentSettingsProperty("MsWordCompTrailingBlanks", uno::makeAny(true)); // Initialize RDF metadata, to be able to add statements during the import. try |