[Libreoffice-commits] core.git: writerfilter/source

Justin Luth justin_luth at sil.org
Wed Jan 17 16:58:52 UTC 2018


 writerfilter/source/dmapper/StyleSheetTable.cxx |    7 ++-----
 writerfilter/source/dmapper/StyleSheetTable.hxx |    3 +--
 2 files changed, 3 insertions(+), 7 deletions(-)

New commits:
commit ae094e77035baed23c02516b4b445e044e631b40
Author: Justin Luth <justin_luth at sil.org>
Date:   Wed Jan 17 12:13:00 2018 +0300

    NFC writerfilter: remove redundant sStyleIdentifierI
    
    Originally, StyleIdentiferI was the string name, and
    StyleIdentifierD was an integer. That changed a long
    time ago.
    
    Both identifiers are only assigned a value once, and
    both are given identical values at the same time.
    Thus, one is completely redundant and is being removed.
    
    Change-Id: Ia7e9bbeec53110fa8e56cdfb13b9871486f335fa
    Reviewed-on: https://gerrit.libreoffice.org/48035
    Reviewed-by: Justin Luth <justin_luth at sil.org>
    Tested-by: Justin Luth <justin_luth at sil.org>

diff --git a/writerfilter/source/dmapper/StyleSheetTable.cxx b/writerfilter/source/dmapper/StyleSheetTable.cxx
index 3e17b25eae89..eec228747398 100644
--- a/writerfilter/source/dmapper/StyleSheetTable.cxx
+++ b/writerfilter/source/dmapper/StyleSheetTable.cxx
@@ -53,8 +53,7 @@ typedef ::std::map< OUString, OUString> StringPairMap_t;
 
 
 StyleSheetEntry::StyleSheetEntry() :
-        sStyleIdentifierI()
-        ,sStyleIdentifierD()
+        sStyleIdentifierD()
         ,bIsDefaultStyle(false)
         ,bIsChapterNumbering(false)
         ,bInvalidHeight(false)
@@ -83,7 +82,6 @@ TableStyleSheetEntry::TableStyleSheetEntry( StyleSheetEntry const & rEntry ):
     sNextStyleIdentifier = rEntry.sNextStyleIdentifier;
     sStyleName = rEntry.sStyleName;
     sStyleName1 = rEntry.sStyleName1;
-    sStyleIdentifierI = rEntry.sStyleIdentifierI;
     sStyleIdentifierD = rEntry.sStyleIdentifierD;
 }
 
@@ -152,7 +150,7 @@ beans::PropertyValues StyleSheetEntry::GetInteropGrabBagSeq()
 beans::PropertyValue StyleSheetEntry::GetInteropGrabBag()
 {
     beans::PropertyValue aRet;
-    aRet.Name = sStyleIdentifierI;
+    aRet.Name = sStyleIdentifierD;
 
     beans::PropertyValues aSeq = GetInteropGrabBagSeq();
     aRet.Value <<= aSeq;
@@ -477,7 +475,6 @@ void StyleSheetTable::lcl_attribute(Id Name, Value & val)
             }
         break;
         case NS_ooxml::LN_CT_Style_styleId:
-            m_pImpl->m_pCurrentEntry->sStyleIdentifierI = sValue;
             m_pImpl->m_pCurrentEntry->sStyleIdentifierD = sValue;
             if(m_pImpl->m_pCurrentEntry->nStyleTypeCode == STYLE_TYPE_TABLE)
             {
diff --git a/writerfilter/source/dmapper/StyleSheetTable.hxx b/writerfilter/source/dmapper/StyleSheetTable.hxx
index 959a2b9184a1..fa8b40cb0434 100644
--- a/writerfilter/source/dmapper/StyleSheetTable.hxx
+++ b/writerfilter/source/dmapper/StyleSheetTable.hxx
@@ -53,8 +53,7 @@ class StyleSheetEntry
 {
     std::vector<css::beans::PropertyValue> m_aInteropGrabBag;
 public:
-    OUString sStyleIdentifierI;
-    OUString sStyleIdentifierD;
+    OUString sStyleIdentifierD;   // WW8 name
     bool            bIsDefaultStyle;
     bool            bIsChapterNumbering;  //LO built-in Chapter Numbering "Outline" list style
     bool            bInvalidHeight;


More information about the Libreoffice-commits mailing list