Hi there,
yet another remove unused code patch.
Regards,
Petr
From 38a7f343736f7049d28aae132307eba02a019f27 Mon Sep 17 00:00:00 2001
From: Petr Vorel <petr.vorel@gmail.com>
Date: Wed, 28 Mar 2012 11:20:18 +0200
Subject: [PATCH] remove unused code (oox, sc)
---
oox/inc/oox/drawingml/textparagraphproperties.hxx | 4 -
oox/inc/oox/dump/dffdumper.hxx | 2 -
oox/inc/oox/dump/dumperbase.hxx | 13 ----
oox/source/drawingml/textparagraphproperties.cxx | 25 --------
oox/source/dump/dffdumper.cxx | 11 ----
oox/source/dump/dumperbase.cxx | 65 ---------------------
sd/source/filter/eppt/epptooxml.hxx | 1 -
sd/source/filter/eppt/pptx-epptooxml.cxx | 14 -----
unusedcode.easy | 14 -----
9 files changed, 0 insertions(+), 149 deletions(-)
diff --git a/oox/inc/oox/drawingml/textparagraphproperties.hxx
b/oox/inc/oox/drawingml/textparagraphproperties.hxx
index b2c5096..e037ff2 100644
--- a/oox/inc/oox/drawingml/textparagraphproperties.hxx
+++ b/oox/inc/oox/drawingml/textparagraphproperties.hxx
@@ -114,10 +114,6 @@ public:
size can be zero and the default value is returned. */
float getCharHeightPoints( float fDefault ) const;
-#if OSL_DEBUG_LEVEL > 0
- void dump() const;
-#endif
-
protected:
TextCharacterProperties maTextCharacterProperties;
diff --git a/oox/inc/oox/dump/dffdumper.hxx b/oox/inc/oox/dump/dffdumper.hxx
index a23d071..10f84f3 100644
--- a/oox/inc/oox/dump/dffdumper.hxx
+++ b/oox/inc/oox/dump/dffdumper.hxx
@@ -49,7 +49,6 @@ protected:
inline explicit DffStreamObject() {}
using SequenceRecordObjectBase::construct;
- void construct( const ObjectBase& rParent, const BinaryInputStreamRef& rxStrm,
const ::rtl::OUString& rSysFileName );
void construct( const OutputObjectBase& rParent, const BinaryInputStreamRef&
rxStrm );
virtual bool implReadRecordHeader( BinaryInputStream& rBaseStrm, sal_Int64& ornRecId,
sal_Int64& ornRecSize );
@@ -61,7 +60,6 @@ private:
void constructDffObj();
sal_uInt32 dumpDffSimpleColor( const String& rName );
- sal_uInt32 dumpDffColor( const String& rName );
void dumpDffOpt();
sal_uInt16 dumpDffOptPropHeader();
diff --git a/oox/inc/oox/dump/dumperbase.hxx b/oox/inc/oox/dump/dumperbase.hxx
index 5989c1e..68a4848 100644
--- a/oox/inc/oox/dump/dumperbase.hxx
+++ b/oox/inc/oox/dump/dumperbase.hxx
@@ -480,26 +480,18 @@ static const String EMPTY_STRING;
class FormulaStack
{
public:
- explicit FormulaStack();
-
inline const ::rtl::OUString& getFormulaString() const { return getString( maFmlaStack ); }
inline const ::rtl::OUString& getClassesString() const { return getString( maClassStack ); }
void pushOperand( const String& rOp, const ::rtl::OUString& rTokClass );
- void pushOperand( const String& rOp );
- void pushUnaryOp( const String& rLOp, const String& rROp );
- void pushBinaryOp( const String& rOp );
- void pushFuncOp( const String& rFunc, const ::rtl::OUString& rTokClass,
sal_uInt8 nParamCount );
inline void setError() { mbError = true; }
- void replaceOnTop( const ::rtl::OUString& rOld, const ::rtl::OUString& rNew );
private:
typedef ::std::stack< ::rtl::OUString > StringStack;
inline bool check( bool bCond ) { return (mbError |= !bCond) == false; }
- const ::rtl::OUString& getString( const StringStack& rStack ) const;
void pushUnaryOp( StringStack& rStack, const ::rtl::OUString& rLOp, const
::rtl::OUString& rROp );
void pushBinaryOp( StringStack& rStack, const ::rtl::OUString& rOp );
void pushFuncOp( StringStack& rStack, const ::rtl::OUString& rOp, sal_uInt8
nParamCount );
@@ -612,9 +604,6 @@ private:
::rtl::OUString& orKey,
::rtl::OUString& orData ) const;
- LineType readConfigLine(
- TextInputStream& rStrm ) const;
-
void processConfigItem(
TextInputStream& rStrm,
const ::rtl::OUString& rKey,
@@ -1013,7 +1002,6 @@ public:
template< typename Type >
bool hasName( const NameListWrapper& rListWrp, Type nKey ) const;
- ::com::sun::star::uno::Sequence< ::com::sun::star::beans::NamedValue > requestEncryptionData(
::comphelper::IDocPasswordVerifier& rVerifier );
bool isPasswordCancelled() const;
protected:
@@ -1598,7 +1586,6 @@ protected:
inline void dumpUnused( sal_Int32 nBytes ) { dumpArray( OOX_DUMP_UNUSED, nBytes ); }
inline void dumpUnknown( sal_Int32 nBytes ) { dumpArray( OOX_DUMP_UNKNOWN, nBytes ); }
- sal_Unicode dumpChar( const String& rName, rtl_TextEncoding eTextEnc );
sal_Unicode dumpUnicode( const String& rName );
::rtl::OUString dumpCharArray( const String& rName, sal_Int32 nLen, rtl_TextEncoding
eTextEnc, bool bHideTrailingNul = false );
diff --git a/oox/source/drawingml/textparagraphproperties.cxx
b/oox/source/drawingml/textparagraphproperties.cxx
index 5df6bfe..1aa67ec 100644
--- a/oox/source/drawingml/textparagraphproperties.cxx
+++ b/oox/source/drawingml/textparagraphproperties.cxx
@@ -469,31 +469,6 @@ float TextParagraphProperties::getCharHeightPoints( float fDefault ) const
}
-#ifdef DBG_UTIL
-
-void TextParagraphProperties::dump() const
-{
- Reference< ::com::sun::star::lang::XMultiServiceFactory > xFactory =
comphelper::getProcessServiceFactory();
- Reference< ::com::sun::star::drawing::XShape > xShape(
oox::ppt::PowerPointImport::mpDebugFilterBase->getModelFactory()->createInstance( CREATE_OUSTRING(
"com.sun.star.presentation.TitleTextShape" ) ), UNO_QUERY );
- Reference< ::com::sun::star::text::XText > xText( xShape, UNO_QUERY );
-
- Reference< com::sun::star::drawing::XDrawPage >
xDebugPage(ppt::SlidePersist::mxDebugPage.get(), UNO_QUERY);
- if (xDebugPage.is())
- xDebugPage->add( xShape );
-
- PropertyMap emptyMap;
-
- const OUString sText = CREATE_OUSTRING("debug");
- xText->setString( sText );
- Reference< ::com::sun::star::text::XTextCursor > xStart( xText->createTextCursor(), UNO_QUERY
);
- Reference< ::com::sun::star::text::XTextRange > xRange( xStart, UNO_QUERY );
- xStart->gotoEnd( sal_True );
- Reference< XPropertySet > xPropSet( xRange, UNO_QUERY );
- pushToPropSet( NULL, xPropSet, emptyMap, NULL, false, 0 );
- PropertySet pSet( xPropSet );
- pSet.dump();
-}
-#endif
} }
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/oox/source/dump/dffdumper.cxx b/oox/source/dump/dffdumper.cxx
index 66f4655..9a58cad 100644
--- a/oox/source/dump/dffdumper.cxx
+++ b/oox/source/dump/dffdumper.cxx
@@ -63,12 +63,6 @@ const sal_uInt16 DFF_OPT_FLAGSMASK = 0x003F;
// ============================================================================
-void DffStreamObject::construct( const ObjectBase& rParent, const BinaryInputStreamRef& rxStrm,
const OUString& rSysFileName )
-{
- SequenceRecordObjectBase::construct( rParent, rxStrm, rSysFileName, "DFF-RECORD-NAMES" );
- constructDffObj();
-}
-
void DffStreamObject::construct( const OutputObjectBase& rParent, const BinaryInputStreamRef&
rxStrm )
{
SequenceRecordObjectBase::construct( rParent, rxStrm, "DFF-RECORD-NAMES" );
@@ -199,11 +193,6 @@ sal_uInt32 DffStreamObject::dumpDffSimpleColor( const String& rName )
return dumpHex< sal_uInt32 >( rName, "DFF-SIMPLE-COLOR" );
}
-sal_uInt32 DffStreamObject::dumpDffColor( const String& rName )
-{
- return dumpHex< sal_uInt32 >( rName, "DFF-COLOR" );
-}
-
namespace {
enum PropType { PROPTYPE_BINARY, PROPTYPE_STRING, PROPTYPE_BLIP, PROPTYPE_COLORARRAY };
diff --git a/oox/source/dump/dumperbase.cxx b/oox/source/dump/dumperbase.cxx
index 366090c..447c712 100644
--- a/oox/source/dump/dumperbase.cxx
+++ b/oox/source/dump/dumperbase.cxx
@@ -926,56 +926,12 @@ void StringHelper::convertStringToIntList( Int64Vector& orVec, const
OUString& r
// ============================================================================
// ============================================================================
-FormulaStack::FormulaStack() :
- mbError( false )
-{
-}
-
void FormulaStack::pushOperand( const String& rOp, const OUString& rTokClass )
{
maFmlaStack.push( rOp );
maClassStack.push( rTokClass );
}
-void FormulaStack::pushOperand( const String& rOp )
-{
- pushOperand( rOp, OUString( OOX_DUMP_BASECLASS ) );
-}
-
-void FormulaStack::pushUnaryOp( const String& rLOp, const String& rROp )
-{
- pushUnaryOp( maFmlaStack, rLOp, rROp );
- pushUnaryOp( maClassStack, rLOp, rROp );
-}
-
-void FormulaStack::pushBinaryOp( const String& rOp )
-{
- pushBinaryOp( maFmlaStack, rOp );
- pushBinaryOp( maClassStack, rOp );
-}
-
-void FormulaStack::pushFuncOp( const String& rFunc, const OUString& rTokClass, sal_uInt8
nParamCount )
-{
- pushFuncOp( maFmlaStack, rFunc, nParamCount );
- pushFuncOp( maClassStack, rTokClass, nParamCount );
-}
-
-void FormulaStack::replaceOnTop( const OUString& rOld, const OUString& rNew )
-{
- if( !maFmlaStack.empty() )
- {
- sal_Int32 nPos = maFmlaStack.top().indexOf( rOld );
- if( nPos >= 0 )
- maFmlaStack.top() = maFmlaStack.top().copy( 0, nPos ) + rNew + maFmlaStack.top().copy(
nPos + rOld.getLength() );
- }
-}
-
-const OUString& FormulaStack::getString( const StringStack& rStack ) const
-{
- static const OUString saStackError = OOX_DUMP_ERRSTRING( "stack" );
- return (mbError || rStack.empty()) ? saStackError : rStack.top();
-}
-
void FormulaStack::pushUnaryOp( StringStack& rStack, const OUString& rLOp, const OUString& rROp )
{
if( check( !rStack.empty() ) )
@@ -1080,12 +1036,6 @@ ConfigItemBase::LineType ConfigItemBase::readConfigLine(
LINETYPE_DATA : LINETYPE_END;
}
-ConfigItemBase::LineType ConfigItemBase::readConfigLine( TextInputStream& rStrm ) const
-{
- OUString aKey, aData;
- return readConfigLine( rStrm, aKey, aData );
-}
-
void ConfigItemBase::processConfigItem(
TextInputStream& rStrm, const OUString& rKey, const OUString& rData )
{
@@ -1731,11 +1681,6 @@ NameListRef Config::getNameList( const String& rListName ) const
return implGetNameList( rListName );
}
-Sequence< NamedValue > Config::requestEncryptionData( ::comphelper::IDocPasswordVerifier&
rVerifier )
-{
- return mxCfgData->requestEncryptionData( rVerifier );
-}
-
bool Config::isPasswordCancelled() const
{
return mxCfgData->isPasswordCancelled();
@@ -2634,16 +2579,6 @@ void InputObjectBase::dumpArray( const String& rName, sal_Int32 nBytes,
sal_Unic
dumpHex< sal_uInt8 >( rName );
}
-sal_Unicode InputObjectBase::dumpChar( const String& rName, rtl_TextEncoding eTextEnc )
-{
- sal_uInt8 nChar;
- *mxStrm >> nChar;
- OUString aChar = OStringToOUString( OString( static_cast< sal_Char >( nChar ) ), eTextEnc );
- sal_Unicode cChar = aChar.isEmpty() ? 0 : aChar[ 0 ];
- writeCharItem( rName( "char" ), cChar );
- return cChar;
-}
-
sal_Unicode InputObjectBase::dumpUnicode( const String& rName )
{
sal_uInt16 nChar;
diff --git a/sd/source/filter/eppt/epptooxml.hxx b/sd/source/filter/eppt/epptooxml.hxx
index 0fb9801..7a9679a 100644
--- a/sd/source/filter/eppt/epptooxml.hxx
+++ b/sd/source/filter/eppt/epptooxml.hxx
@@ -125,7 +125,6 @@ protected:
void WriteAnimationProperty( ::sax_fastparser::FSHelperPtr pFS, const
::com::sun::star::uno::Any& rAny );
void WriteAnimationTarget( ::sax_fastparser::FSHelperPtr pFS, ::com::sun::star::uno::Any
aTarget );
bool WriteComments( sal_uInt32 nPageNum );
- void WriteTextStyleLevel( ::sax_fastparser::FSHelperPtr pFS, int nInstance, int nLevel );
void ImplWriteBackground( ::sax_fastparser::FSHelperPtr pFS, ::com::sun::star::uno::Reference<
::com::sun::star::beans::XPropertySet > aXBackgroundPropSet );
void WriteTransition( ::sax_fastparser::FSHelperPtr pFS );
diff --git a/sd/source/filter/eppt/pptx-epptooxml.cxx b/sd/source/filter/eppt/pptx-epptooxml.cxx
index 0ff53d5..1167966 100644
--- a/sd/source/filter/eppt/pptx-epptooxml.cxx
+++ b/sd/source/filter/eppt/pptx-epptooxml.cxx
@@ -1537,20 +1537,6 @@ sal_Int32 PowerPointExport::nStyleLevelToken[5] =
XML_lvl5pPr
};
-void PowerPointExport::WriteTextStyleLevel( FSHelperPtr pFS, int nInstance, int nLevel )
-{
- OSL_ASSERT( nLevel >= 0 && nLevel < 5 );
- OSL_ASSERT( nInstance >= 0 && nInstance < 9 );
-
- PPTExParaLevel rParaLevel = mpStyleSheet->GetParaSheet( nInstance ).maParaLevel[ nLevel ];
-
- pFS->startElementNS( XML_a, PowerPointExport::nStyleLevelToken[ nLevel ],
- XML_algn, DrawingML::GetAlignment( rParaLevel.mnOOAdjust ),
- FSEND );
-
- pFS->endElementNS( XML_a, PowerPointExport::nStyleLevelToken[ nLevel ] );
-}
-
void PowerPointExport::ImplWriteSlideMaster( sal_uInt32 nPageNum, Reference< XPropertySet >
aXBackgroundPropSet )
{
DBG(printf("write slide master: %" SAL_PRIuUINT32 "\n----------------\n", nPageNum));
diff --git a/unusedcode.easy b/unusedcode.easy
index 70c2c61..425bee7 100755
--- a/unusedcode.easy
+++ b/unusedcode.easy
@@ -826,21 +826,7 @@
nullcanvas::SpriteCanvasHelper::genericUpdate(basegfx::B2DConnectedRanges<canvas
nullcanvas::SpriteCanvasHelper::opaqueUpdate(basegfx::B2DConnectedRanges<canvas::SpriteRedrawManager::SpriteInfo>::ConnectedComponents
const&)
nullcanvas::SpriteCanvasHelper::scrollUpdate(basegfx::B2DRange const&, basegfx::B2DRange const&,
basegfx::B2DConnectedRanges<canvas::SpriteRedrawManager::SpriteInfo>::ConnectedComponents const&)
ooo::vba::extractIntFromAny(com::sun::star::uno::Any const&)
-oox::core::PowerPointExport::WriteTextStyleLevel(boost::shared_ptr<sax_fastparser::FastSerializerHelper>,
int, int)
-oox::drawingml::TextParagraphProperties::dump() const
-oox::dump::Config::requestEncryptionData(comphelper::IDocPasswordVerifier&)
-oox::dump::ConfigItemBase::readConfigLine(oox::TextInputStream&) const
-oox::dump::DffStreamObject::construct(oox::dump::ObjectBase const&,
oox::dump::BinaryInputStreamRef const&, rtl::OUString const&)
oox::dump::DffStreamObject::construct(oox::dump::OutputObjectBase const&,
oox::dump::BinaryInputStreamRef const&)
-oox::dump::DffStreamObject::dumpDffColor(oox::dump::String const&)
-oox::dump::FormulaStack::FormulaStack()
-oox::dump::FormulaStack::getString(std::stack<rtl::OUString, std::__debug::deque<rtl::OUString,
std::allocator<rtl::OUString> > > const&) const
-oox::dump::FormulaStack::pushBinaryOp(oox::dump::String const&)
-oox::dump::FormulaStack::pushFuncOp(oox::dump::String const&, rtl::OUString const&, unsigned char)
-oox::dump::FormulaStack::pushOperand(oox::dump::String const&)
-oox::dump::FormulaStack::pushUnaryOp(oox::dump::String const&, oox::dump::String const&)
-oox::dump::FormulaStack::replaceOnTop(rtl::OUString const&, rtl::OUString const&)
-oox::dump::InputObjectBase::dumpChar(oox::dump::String const&, unsigned short)
oox::dump::InputObjectBase::dumpColorABGR(oox::dump::String const&)
oox::dump::InputObjectBase::dumpRk(oox::dump::String const&)
oox::dump::ItemFormat::set(oox::dump::DataType, oox::dump::FormatType, rtl::OUString const&,
rtl::OUString const&)
--
1.7.9.1
Context
- [PATCH] remove unused code (oox, sc) · Petr Vorel
Privacy Policy |
Impressum (Legal Info) |
Copyright information: Unless otherwise specified, all text and images
on this website are licensed under the
Creative Commons Attribution-Share Alike 3.0 License.
This does not include the source code of LibreOffice, which is
licensed under the Mozilla Public License (
MPLv2).
"LibreOffice" and "The Document Foundation" are
registered trademarks of their corresponding registered owners or are
in actual use as trademarks in one or more countries. Their respective
logos and icons are also subject to international copyright laws. Use
thereof is explained in our
trademark policy.