oox/source/ole/vbaprojectfilter.cxx       |   13 -----
 sc/source/filter/inc/biffinputstream.hxx  |   27 -----------
 sc/source/filter/inc/biffoutputstream.hxx |    5 --
 sc/source/filter/inc/drawingmanager.hxx   |    4 -
 sc/source/filter/oox/biffdetector.cxx     |    5 --
 sc/source/filter/oox/biffinputstream.cxx  |   11 ----
 sc/source/filter/oox/biffoutputstream.cxx |   16 ------
 sc/source/filter/oox/drawingmanager.cxx   |   71 ------------------------------
 sc/source/filter/oox/excelfilter.cxx      |   27 -----------
 sc/source/filter/oox/ooxformulaparser.cxx |    5 --
 unusedcode.easy                           |   13 -----
 vcl/generic/print/text_gfx.cxx            |   31 ++-----------
 12 files changed, 7 insertions(+), 221 deletions(-)

New commits:
commit 7d6656addebcaec4f8873e4a611a970a224a7bf5
Author: Caolán McNamara <caol...@redhat.com>
Date:   Mon Mar 26 15:29:54 2012 +0100

    merge getVerticalDeltaAngle and GetVerticalFlags

diff --git a/vcl/generic/print/text_gfx.cxx b/vcl/generic/print/text_gfx.cxx
index 06dbf7d..a270ac2 100644
--- a/vcl/generic/print/text_gfx.cxx
+++ b/vcl/generic/print/text_gfx.cxx
@@ -87,31 +87,12 @@ Font3::Font3(const PrinterGfx &rGfx)
 
 static int getVerticalDeltaAngle( sal_Unicode nChar )
 {
-    int nAngle = 0;
-    if( ( nChar >= 0x1100 && nChar < 0x11fa ) ||
-        ( nChar >= 0x3000 && nChar < 0xfb00 ) ||
-        ( nChar >= 0xfe20 && nChar < 0xfe70 ) ||
-        ( nChar >= 0xff00 && nChar < 0xff64 )
-        )
-    {
-        /* #i52932# remember:
-         nChar == 0x2010 || nChar == 0x2015
-         nChar == 0x2016 || nChar == 0x2026
-
-         are nAngle = 0 also, but already handled in the first if
-        */
-        if( ( nChar >= 0x3008 && nChar < 0x3019 && nChar != 0x3012 ) ||
-            nChar == 0xff3b || nChar == 0xff3d ||
-            (nChar >= 0xff6b && nChar < 0xff64 ) ||
-            nChar == 0xffe3
-            )
-            nAngle = 0;
-        else if( nChar == 0x30fc )
-            nAngle = -900;
-        else
-            nAngle = 900;
-    }
-    return nAngle;
+    int nRotation = GetVerticalFlags(nChar);
+    if (nRotation == GF_ROTR)
+        return -900;
+    if (nRotation == GF_ROTL)
+        return 900;
+    return 0;
 }
 
 void
commit 226d310c1a31238b7f07d8e7e42ec75f0280fba5
Author: Petr Vorel <petr.vo...@gmail.com>
Date:   Thu Mar 22 20:14:13 2012 +0100

    remove unused code (oox)

diff --git a/oox/source/ole/vbaprojectfilter.cxx 
b/oox/source/ole/vbaprojectfilter.cxx
index e152598..f4698fa 100644
--- a/oox/source/ole/vbaprojectfilter.cxx
+++ b/oox/source/ole/vbaprojectfilter.cxx
@@ -77,19 +77,6 @@ OUString SAL_CALL 
WordVbaProjectFilter_getImplementationName() throw()
     return CREATE_OUSTRING( "com.sun.star.comp.oox.WordVbaProjectFilter" );
 }
 
-Sequence< OUString > SAL_CALL WordVbaProjectFilter_getSupportedServiceNames() 
throw()
-{
-    Sequence< OUString > aSeq( 1 );
-    aSeq[ 0 ] = CREATE_OUSTRING( "com.sun.star.document.ImportFilter" );
-    return aSeq;
-}
-
-Reference< XInterface > SAL_CALL WordVbaProjectFilter_createInstance(
-        const Reference< XComponentContext >& rxContext ) throw( Exception )
-{
-    return static_cast< ::cppu::OWeakObject* >( new WordVbaProjectFilter( 
rxContext ) );
-}
-
 // ----------------------------------------------------------------------------
 
 WordVbaProjectFilter::WordVbaProjectFilter( const Reference< XComponentContext 
>& rxContext ) throw( RuntimeException ) :
diff --git a/sc/source/filter/inc/biffinputstream.hxx 
b/sc/source/filter/inc/biffinputstream.hxx
index 9f01b02..47ee2b0 100644
--- a/sc/source/filter/inc/biffinputstream.hxx
+++ b/sc/source/filter/inc/biffinputstream.hxx
@@ -129,16 +129,7 @@ private:
     Trying to read over the record limits results in a stream error. The
     isValid() function indicates that by returning false. From now on the data
     returned by the read functions is undefined. The error state will be reset,
-    if the record is reset (with the function resetRecord()), or if the next
-    record is started.
-
-    To switch off the automatic lookup of CONTINUE records, use resetRecord()
-    with false parameter. This is useful e.g. on import of drawing layer data,
-    where sometimes solely CONTINUE records will occur. The automatic lookup
-    keeps switched off until the method resetRecord() is called with parameter
-    true. All other settings done on the stream (e.g. alternative CONTINUE
-    record identifier, enabled decryption, NUL substitution character) will be
-    reset to default values, if a new record is started.
+    if the next record is started.
 
     The import stream supports decrypting the stream data. The contents of a
     record (not the record header) will be encrypted by Excel if the file has
@@ -189,22 +180,6 @@ public:
      */
     bool                startRecordByHandle( sal_Int64 nRecHandle );
 
-    /** Sets stream pointer to begin of record content.
-
-        @param bContLookup
-            Automatic CONTINUE lookup on/off. In difference to other stream
-            settings, this setting is persistent until next call of this
-            function (because it is wanted to receive the next CONTINUE records
-            separately).
-        @param nAltContId
-            Sets an alternative record identifier for content continuation.
-            This value is reset automatically when a new record is started with
-            startNextRecord().
-     */
-    void                resetRecord(
-                            bool bContLookup,
-                            sal_uInt16 nAltContId = BIFF_ID_UNKNOWN );
-
     /** Sets stream pointer before current record and invalidates stream.
 
         The next call to startNextRecord() will start again the current record.
diff --git a/sc/source/filter/inc/biffoutputstream.hxx 
b/sc/source/filter/inc/biffoutputstream.hxx
index a38bfdf..f7a6462 100644
--- a/sc/source/filter/inc/biffoutputstream.hxx
+++ b/sc/source/filter/inc/biffoutputstream.hxx
@@ -110,8 +110,6 @@ public:
 
     /** Returns the absolute position in the wrapped binary stream. */
     sal_Int64           tellBase() const;
-    /** Returns the total size of the wrapped binary stream. */
-    sal_Int64           sizeBase() const;
 
     // BinaryOutputStream interface (stream write access) ---------------------
 
@@ -120,9 +118,6 @@ public:
     /** Writes nBytes bytes from the passed buffer pMem. */
     virtual void        writeMemory( const void* pMem, sal_Int32 nBytes, 
size_t nAtomSize = 1 );
 
-    /** Writes a sequence of nBytes bytes with the passed value. */
-    void                fill( sal_uInt8 nValue, sal_Int32 nBytes, size_t 
nAtomSize = 1 );
-
     /** Stream operator for all data types supported by the writeValue() 
function. */
     template< typename Type >
     inline BiffOutputStream& operator<<( Type nValue ) { writeValue( nValue ); 
return *this; }
diff --git a/sc/source/filter/inc/drawingmanager.hxx 
b/sc/source/filter/inc/drawingmanager.hxx
index c597b03..f2f018e 100644
--- a/sc/source/filter/inc/drawingmanager.hxx
+++ b/sc/source/filter/inc/drawingmanager.hxx
@@ -95,8 +95,6 @@ public:
     /** Returns true, if the object list is empty. */
     inline bool         empty() const { return maObjects.empty(); }
 
-    /** Appends the passed object to the list of objects. */
-    void                append( const BiffDrawingObjectRef& rxDrawingObj );
     /** Tries to insert the passed object into the last group or appends it. */
     void                insertGrouped( const BiffDrawingObjectRef& 
rxDrawingObj );
 
@@ -197,8 +195,6 @@ private:
     void                importObjBiff4( BiffInputStream& rStrm );
     /** Reads the contents of a BIFF5 OBJ record. */
     void                importObjBiff5( BiffInputStream& rStrm );
-    /** Reads the contents of a BIFF8 OBJ record. */
-    void                importObjBiff8( BiffInputStream& rStrm );
 
 private:
     ShapeAnchor         maAnchor;       /// Position of the drawing object.
diff --git a/sc/source/filter/oox/biffdetector.cxx 
b/sc/source/filter/oox/biffdetector.cxx
index 5c5a2c2..b099ad2 100644
--- a/sc/source/filter/oox/biffdetector.cxx
+++ b/sc/source/filter/oox/biffdetector.cxx
@@ -64,11 +64,6 @@ OUString BiffDetector_getImplementationName()
     return CREATE_OUSTRING( "com.sun.star.comp.oox.xls.BiffDetector" );
 }
 
-Reference< XInterface > SAL_CALL BiffDetector_createInstance( const Reference< 
XComponentContext >& rxContext ) throw( Exception )
-{
-    return static_cast< ::cppu::OWeakObject* >( new BiffDetector( rxContext ) 
);
-}
-
 // ============================================================================
 
 BiffDetector::BiffDetector( const Reference< XComponentContext >& rxContext ) 
throw( RuntimeException ) :
diff --git a/sc/source/filter/oox/biffinputstream.cxx 
b/sc/source/filter/oox/biffinputstream.cxx
index 71641f5..535359b 100644
--- a/sc/source/filter/oox/biffinputstream.cxx
+++ b/sc/source/filter/oox/biffinputstream.cxx
@@ -213,17 +213,6 @@ bool BiffInputStream::startRecordByHandle( sal_Int64 
nRecHandle )
     return startNextRecord();
 }
 
-void BiffInputStream::resetRecord( bool bContLookup, sal_uInt16 nAltContId )
-{
-    if( isInRecord() )
-    {
-        mbCont = bContLookup;
-        mnAltContId = nAltContId;
-        restartRecord( true );
-        maRecBuffer.enableDecoder( true );
-    }
-}
-
 void BiffInputStream::rewindRecord()
 {
     rewindToRecord( mnRecHandle );
diff --git a/sc/source/filter/oox/biffoutputstream.cxx 
b/sc/source/filter/oox/biffoutputstream.cxx
index 8914cf1..0b2524c 100644
--- a/sc/source/filter/oox/biffoutputstream.cxx
+++ b/sc/source/filter/oox/biffoutputstream.cxx
@@ -107,11 +107,6 @@ sal_Int64 BiffOutputStream::tellBase() const
     return maRecBuffer.getBaseStream().tell();
 }
 
-sal_Int64 BiffOutputStream::sizeBase() const
-{
-    return maRecBuffer.getBaseStream().size();
-}
-
 // BinaryOutputStream interface (stream write access) -------------------------
 
 void BiffOutputStream::writeData( const StreamDataSequence& rData, size_t 
nAtomSize )
@@ -136,17 +131,6 @@ void BiffOutputStream::writeMemory( const void* pMem, 
sal_Int32 nBytes, size_t n
     }
 }
 
-void BiffOutputStream::fill( sal_uInt8 nValue, sal_Int32 nBytes, size_t 
nAtomSize )
-{
-    sal_Int32 nBytesLeft = nBytes;
-    while( nBytesLeft > 0 )
-    {
-        sal_uInt16 nBlockSize = prepareWriteBlock( nBytesLeft, nAtomSize );
-        maRecBuffer.fill( nValue, nBlockSize );
-        nBytesLeft -= nBlockSize;
-    }
-}
-
 // private --------------------------------------------------------------------
 
 sal_uInt16 BiffOutputStream::prepareWriteBlock( sal_Int32 nTotalSize, size_t 
nAtomSize )
diff --git a/sc/source/filter/oox/drawingmanager.cxx 
b/sc/source/filter/oox/drawingmanager.cxx
index a1cfef9..a50e805 100644
--- a/sc/source/filter/oox/drawingmanager.cxx
+++ b/sc/source/filter/oox/drawingmanager.cxx
@@ -230,11 +230,6 @@ BiffDrawingObjectContainer::BiffDrawingObjectContainer()
 {
 }
 
-void BiffDrawingObjectContainer::append( const BiffDrawingObjectRef& 
rxDrawingObj )
-{
-    maObjects.push_back( rxDrawingObj );
-}
-
 void BiffDrawingObjectContainer::insertGrouped( const BiffDrawingObjectRef& 
rxDrawingObj )
 {
     if( !maObjects.empty() )
@@ -745,72 +740,6 @@ void BiffDrawingObjectBase::importObjBiff5( 
BiffInputStream& rStrm )
     implReadObjBiff5( rStrm, nNameLen, nMacroSize );
 }
 
-void BiffDrawingObjectBase::importObjBiff8( BiffInputStream& rStrm )
-{
-    // back to beginning
-    rStrm.seekToStart();
-
-    bool bLoop = true;
-    while( bLoop && (rStrm.getRemaining() >= 4) )
-    {
-        sal_uInt16 nSubRecId, nSubRecSize;
-        rStrm >> nSubRecId >> nSubRecSize;
-        sal_Int64 nStrmPos = rStrm.tell();
-        // sometimes the last subrecord has an invalid length (OBJLBSDATA) -> 
min()
-        nSubRecSize = static_cast< sal_uInt16 >( ::std::min< sal_Int64 >( 
nSubRecSize, rStrm.getRemaining() ) );
-
-        switch( nSubRecId )
-        {
-            case BIFF_ID_OBJCMO:
-                OSL_ENSURE( rStrm.tell() == 4, 
"BiffDrawingObjectBase::importObjBiff8 - unexpected OBJCMO subrecord" );
-                if( (rStrm.tell() == 4) && (nSubRecSize >= 6) )
-                {
-                    sal_uInt16 nObjFlags;
-                    rStrm >> mnObjType >> mnObjId >> nObjFlags;
-                    mbPrintable = getFlag( nObjFlags, BIFF_OBJCMO_PRINTABLE );
-                }
-            break;
-            case BIFF_ID_OBJMACRO:
-                readMacroBiff8( rStrm );
-            break;
-            case BIFF_ID_OBJEND:
-                bLoop = false;
-            break;
-            default:
-                implReadObjBiff8SubRec( rStrm, nSubRecId, nSubRecSize );
-        }
-
-        // seek to end of subrecord
-        rStrm.seek( nStrmPos + nSubRecSize );
-    }
-
-    /*  Call doReadObj8SubRec() with BIFF_ID_OBJEND for further stream
-        processing (e.g. charts), even if the OBJEND subrecord is missing. */
-    implReadObjBiff8SubRec( rStrm, BIFF_ID_OBJEND, 0 );
-
-    /*  Pictures that Excel reads from BIFF5 and writes to BIFF8 still have the
-        IMGDATA record following the OBJ record (but they use the image data
-        stored in DFF). The IMGDATA record may be continued by several CONTINUE
-        records. But the last CONTINUE record may be in fact an MSODRAWING
-        record that contains the DFF data of the next drawing object! So we
-        have to skip just enough CONTINUE records to look at the next
-        MSODRAWING/CONTINUE record. */
-    if( (rStrm.getNextRecId() == BIFF3_ID_IMGDATA) && rStrm.startNextRecord() )
-    {
-        rStrm.skip( 4 );
-        sal_Int64 nDataSize = rStrm.readuInt32();
-        nDataSize -= rStrm.getRemaining();
-        // skip following CONTINUE records until IMGDATA ends
-        while( (nDataSize > 0) && (rStrm.getNextRecId() == BIFF_ID_CONT) && 
rStrm.startNextRecord() )
-        {
-            OSL_ENSURE( nDataSize >= rStrm.getRemaining(), 
"BiffDrawingObjectBase::importObjBiff8 - CONTINUE too long" );
-            nDataSize -= ::std::min( rStrm.getRemaining(), nDataSize );
-        }
-        OSL_ENSURE( nDataSize == 0, "BiffDrawingObjectBase::importObjBiff8 - 
missing CONTINUE records" );
-        // next record may be MSODRAWING or CONTINUE or anything else
-    }
-}
-
 // ============================================================================
 
 BiffPlaceholderObject::BiffPlaceholderObject( const WorksheetHelper& rHelper ) 
:
diff --git a/sc/source/filter/oox/excelfilter.cxx 
b/sc/source/filter/oox/excelfilter.cxx
index 57c9749..08f3ec6 100644
--- a/sc/source/filter/oox/excelfilter.cxx
+++ b/sc/source/filter/oox/excelfilter.cxx
@@ -212,20 +212,6 @@ OUString SAL_CALL ExcelBiffFilter_getImplementationName() 
throw()
     return CREATE_OUSTRING( "com.sun.star.comp.oox.xls.ExcelBiffFilter" );
 }
 
-Sequence< OUString > SAL_CALL ExcelBiffFilter_getSupportedServiceNames() 
throw()
-{
-    Sequence< OUString > aSeq( 2 );
-    aSeq[ 0 ] = CREATE_OUSTRING( "com.sun.star.document.ImportFilter" );
-    aSeq[ 1 ] = CREATE_OUSTRING( "com.sun.star.document.ExportFilter" );
-    return aSeq;
-}
-
-Reference< XInterface > SAL_CALL ExcelBiffFilter_createInstance(
-        const Reference< XComponentContext >& rxContext ) throw( Exception )
-{
-    return static_cast< ::cppu::OWeakObject* >( new ExcelBiffFilter( rxContext 
) );
-}
-
 // ----------------------------------------------------------------------------
 
 ExcelBiffFilter::ExcelBiffFilter( const Reference< XComponentContext >& 
rxContext ) throw( RuntimeException ) :
@@ -295,19 +281,6 @@ OUString SAL_CALL 
ExcelVbaProjectFilter_getImplementationName() throw()
     return CREATE_OUSTRING( "com.sun.star.comp.oox.xls.ExcelVbaProjectFilter" 
);
 }
 
-Sequence< OUString > SAL_CALL ExcelVbaProjectFilter_getSupportedServiceNames() 
throw()
-{
-    Sequence< OUString > aSeq( 1 );
-    aSeq[ 0 ] = CREATE_OUSTRING( "com.sun.star.document.ImportFilter" );
-    return aSeq;
-}
-
-Reference< XInterface > SAL_CALL ExcelVbaProjectFilter_createInstance(
-        const Reference< XComponentContext >& rxContext ) throw( Exception )
-{
-    return static_cast< ::cppu::OWeakObject* >( new ExcelVbaProjectFilter( 
rxContext ) );
-}
-
 // ----------------------------------------------------------------------------
 
 ExcelVbaProjectFilter::ExcelVbaProjectFilter( const Reference< 
XComponentContext >& rxContext ) throw( RuntimeException ) :
diff --git a/sc/source/filter/oox/ooxformulaparser.cxx 
b/sc/source/filter/oox/ooxformulaparser.cxx
index ebb5175..ab2f515 100644
--- a/sc/source/filter/oox/ooxformulaparser.cxx
+++ b/sc/source/filter/oox/ooxformulaparser.cxx
@@ -125,11 +125,6 @@ OUString OOXMLFormulaParser_getImplementationName()
     return CREATE_OUSTRING( "com.sun.star.comp.oox.xls.FormulaParser" );
 }
 
-Reference< XInterface > SAL_CALL OOXMLFormulaParser_createInstance( const 
Reference< XComponentContext >& ) throw( Exception )
-{
-    return static_cast< ::cppu::OWeakObject* >( new OOXMLFormulaParser );
-}
-
 // ============================================================================
 
 OOXMLFormulaParser::OOXMLFormulaParser()
diff --git a/unusedcode.easy b/unusedcode.easy
index 767d6d2..04c33ac 100755
--- a/unusedcode.easy
+++ b/unusedcode.easy
@@ -877,15 +877,7 @@ 
oox::dump::TextStreamObjectBase::construct(oox::dump::InputObjectBase const&, un
 oox::dump::XmlStreamObject::XmlStreamObject(oox::dump::OutputObjectBase 
const&, oox::dump::BinaryInputStreamRef const&)
 oox::formulaimport::XmlStream::AttributeList::hasAttribute(int) const
 oox::formulaimport::XmlStream::skipElement(int)
-oox::ole::WordVbaProjectFilter_createInstance(com::sun::star::uno::Reference<com::sun::star::uno::XComponentContext>
 const&)
-oox::ole::WordVbaProjectFilter_getSupportedServiceNames()
 oox::ppt::PPTShape::findPlaceholder(int, int, 
std::__debug::vector<boost::shared_ptr<oox::drawingml::Shape>, 
std::allocator<boost::shared_ptr<oox::drawingml::Shape> > >&)
-oox::xls::BiffDetector_createInstance(com::sun::star::uno::Reference<com::sun::star::uno::XComponentContext>
 const&)
-oox::xls::BiffDrawingObjectBase::importObjBiff8(oox::xls::BiffInputStream&)
-oox::xls::BiffDrawingObjectContainer::append(boost::shared_ptr<oox::xls::BiffDrawingObjectBase>
 const&)
-oox::xls::BiffInputStream::resetRecord(bool, unsigned short)
-oox::xls::BiffOutputStream::fill(unsigned char, int, unsigned long)
-oox::xls::BiffOutputStream::sizeBase() const
 oox::xls::BiffOutputStream::startRecord(unsigned short)
 oox::xls::BiffOutputStream::tellBase() const
 oox::xls::BinAddress::write(oox::xls::BiffOutputStream&, bool, bool) const
@@ -895,11 +887,6 @@ oox::xls::CellBlock::CellBlock(oox::xls::WorksheetHelper 
const&, oox::ValueRange
 oox::xls::CellBlock::isBefore(oox::ValueRange const&) const
 oox::xls::CellBlock::isExpandable(oox::ValueRange const&) const
 oox::xls::CellBlock::startNextRow()
-oox::xls::ExcelBiffFilter_createInstance(com::sun::star::uno::Reference<com::sun::star::uno::XComponentContext>
 const&)
-oox::xls::ExcelBiffFilter_getSupportedServiceNames()
-oox::xls::ExcelVbaProjectFilter_createInstance(com::sun::star::uno::Reference<com::sun::star::uno::XComponentContext>
 const&)
-oox::xls::ExcelVbaProjectFilter_getSupportedServiceNames()
-oox::xls::OOXMLFormulaParser_createInstance(com::sun::star::uno::Reference<com::sun::star::uno::XComponentContext>
 const&)
 
oox::xls::prv::BiffOutputRecordBuffer::BiffOutputRecordBuffer(oox::BinaryOutputStream&,
 unsigned short)
 psp::PrinterGfx::DrawBitmap(Rectangle const&, Rectangle const&, 
psp::PrinterBmp const&, psp::PrinterBmp const&)
 psp::PrinterGfx::DrawMask(Rectangle const&, Rectangle const&, psp::PrinterBmp 
const&, psp::PrinterColor&)
_______________________________________________
Libreoffice-commits mailing list
Libreoffice-commits@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits

Reply via email to