[Libreoffice-commits] core.git: include/oox oox/source
Takeshi Abe
tabe at fixedpoint.jp
Wed Oct 8 08:15:30 PDT 2014
include/oox/dump/dumperbase.hxx | 13 +++++++++++--
oox/source/dump/dffdumper.cxx | 4 ++--
oox/source/dump/dumperbase.cxx | 4 ++--
3 files changed, 15 insertions(+), 6 deletions(-)
New commits:
commit 413771fa32815672afc6b7799c1433f523088811
Author: Takeshi Abe <tabe at fixedpoint.jp>
Date: Wed Oct 8 21:48:43 2014 +0900
fdo#75757: remove inheritance to std::map
from ItemFormatMap.
Change-Id: I956b5797e677d22eb71fe801b650db7c982d6d51
Reviewed-on: https://gerrit.libreoffice.org/11854
Reviewed-by: Caolán McNamara <caolanm at redhat.com>
Tested-by: Caolán McNamara <caolanm at redhat.com>
diff --git a/include/oox/dump/dumperbase.hxx b/include/oox/dump/dumperbase.hxx
index 9e72588..a747de5 100644
--- a/include/oox/dump/dumperbase.hxx
+++ b/include/oox/dump/dumperbase.hxx
@@ -808,12 +808,21 @@ static const NameListWrapper NO_LIST;
-class ItemFormatMap : public ::std::map< sal_Int64, ItemFormat >
+class ItemFormatMap
{
+private:
+ ::std::map< sal_Int64, ItemFormat > maMap;
+
public:
- ItemFormatMap() {}
+ ItemFormatMap() : maMap() {}
explicit ItemFormatMap( const NameListRef& rxNameList ) { insertFormats( rxNameList ); }
+ ::std::map< sal_Int64, ItemFormat >::const_iterator end() const { return maMap.end(); }
+ ::std::map< sal_Int64, ItemFormat >::const_iterator find(sal_Int64 nId) const
+ {
+ return maMap.find(nId);
+ }
+
void insertFormats( const NameListRef& rxNameList );
};
diff --git a/oox/source/dump/dffdumper.cxx b/oox/source/dump/dffdumper.cxx
index c4c73ac..318a129 100644
--- a/oox/source/dump/dffdumper.cxx
+++ b/oox/source/dump/dffdumper.cxx
@@ -193,7 +193,7 @@ void DffStreamObject::dumpDffOpt()
writeHexItem( "complex-size", nValue, "CONV-DEC" );
String aName;
PropType eType = PROPTYPE_BINARY;
- ItemFormatMap::const_iterator aIt = maComplexProps.find( nBaseId );
+ ::std::map< sal_Int64, ItemFormat >::const_iterator aIt = maComplexProps.find( nBaseId );
if( aIt != maComplexProps.end() )
{
const ItemFormat& rItemFmt = aIt->second;
@@ -211,7 +211,7 @@ void DffStreamObject::dumpDffOpt()
}
else
{
- ItemFormatMap::const_iterator aIt = maSimpleProps.find( nBaseId );
+ ::std::map< sal_Int64, ItemFormat >::const_iterator aIt = maSimpleProps.find( nBaseId );
if( aIt != maSimpleProps.end() )
{
const ItemFormat& rItemFmt = aIt->second;
diff --git a/oox/source/dump/dumperbase.cxx b/oox/source/dump/dumperbase.cxx
index 1143e6a..aa0000c 100644
--- a/oox/source/dump/dumperbase.cxx
+++ b/oox/source/dump/dumperbase.cxx
@@ -936,7 +936,7 @@ void ItemFormatMap::insertFormats( const NameListRef& rxNameList )
{
if( Base::isValid( rxNameList ) )
for( NameListBase::const_iterator aIt = rxNameList->begin(), aEnd = rxNameList->end(); aIt != aEnd; ++aIt )
- (*this)[ aIt->first ].parse( aIt->second );
+ maMap[ aIt->first ].parse( aIt->second );
}
ConstList::ConstList( const SharedConfigData& rCfgData ) :
@@ -2488,7 +2488,7 @@ void RecordObjectBase::implDump()
// record body
if( !mbBinaryOnly && cfg().hasName( xRecNames, mnRecId ) )
{
- ItemFormatMap::const_iterator aIt = aSimpleRecs.find( mnRecId );
+ ::std::map< sal_Int64, ItemFormat >::const_iterator aIt = aSimpleRecs.find( mnRecId );
if( aIt != aSimpleRecs.end() )
dumpItem( aIt->second );
else
More information about the Libreoffice-commits
mailing list