[Libreoffice-commits] .: 9 commits - autodoc/source basic/source desktop/source l10ntools/inc l10ntools/source padmin/source starmath/inc starmath/source svtools/inc svtools/source tools/inc tools/source unusedcode.easy vcl/inc vcl/source vcl/unx vcl/workben xml2cmp/source xmloff/inc xmloff/source

Caolán McNamara caolan at kemper.freedesktop.org
Wed Jan 25 07:40:00 PST 2012


 autodoc/source/inc/tools/tkpchars.hxx                 |   26 ----
 autodoc/source/parser/inc/tokens/stmstarr.hxx         |   87 ---------------
 autodoc/source/parser/inc/x_parse.hxx                 |   66 -----------
 autodoc/source/parser/kernel/x_parse.cxx              |   63 -----------
 autodoc/source/parser/tokens/makefile.mk              |    1 
 autodoc/source/parser/tokens/stmstarr.cxx             |  101 ------------------
 autodoc/source/tools/tkpchars.cxx                     |   41 -------
 basic/source/runtime/iosys.cxx                        |   13 ++
 basic/source/sbx/sbxdec.cxx                           |   16 --
 desktop/source/deployment/gui/dp_gui_updatedialog.cxx |   31 ++---
 l10ntools/inc/export.hxx                              |    2 
 l10ntools/source/merge.cxx                            |    4 
 padmin/source/adddlg.cxx                              |   73 ++++++-------
 padmin/source/cmddlg.cxx                              |    4 
 padmin/source/newppdlg.cxx                            |    6 -
 starmath/inc/dialog.hxx                               |    8 -
 starmath/source/dialog.cxx                            |   26 ++--
 svtools/inc/svtools/treelist.hxx                      |    1 
 svtools/source/contnr/treelist.cxx                    |   10 -
 svtools/source/filter/ixbm/xbmread.cxx                |   15 +-
 svtools/source/inc/xbmread.hxx                        |    2 
 svtools/source/misc/imap2.cxx                         |   16 +-
 tools/inc/tools/stream.hxx                            |    3 
 tools/source/stream/stream.cxx                        |   27 ----
 unusedcode.easy                                       |   22 ---
 vcl/inc/vcl/octree.hxx                                |    5 
 vcl/source/gdi/octree.cxx                             |   24 ----
 vcl/unx/gtk/fpicker/SalGtkFilePicker.cxx              |    1 
 vcl/workben/outdevgrind.cxx                           |    3 
 xml2cmp/source/support/heap.cxx                       |    6 -
 xml2cmp/source/support/heap.hxx                       |    1 
 xmloff/inc/xmloff/txtparae.hxx                        |    4 
 xmloff/source/text/txtparae.cxx                       |   10 -
 33 files changed, 110 insertions(+), 608 deletions(-)

New commits:
commit 52bb216897b90a7ae37c6ba8fde3fdd9ce94ede0
Author: Caolán McNamara <caolanm at redhat.com>
Date:   Wed Jan 25 15:35:54 2012 +0000

    tweak the ifdefs to clarify the unused SbxDecimal methods

diff --git a/basic/source/sbx/sbxdec.cxx b/basic/source/sbx/sbxdec.cxx
index 992bff0..5f37c46 100644
--- a/basic/source/sbx/sbxdec.cxx
+++ b/basic/source/sbx/sbxdec.cxx
@@ -428,7 +428,6 @@ bool SbxDecimal::getString( ::rtl::OUString& rString )
 
 SbxDecimal* ImpCreateDecimal( SbxValues* p )
 {
-#ifdef WIN32
     if( !p )
         return NULL;
 
@@ -439,15 +438,10 @@ SbxDecimal* ImpCreateDecimal( SbxValues* p )
         rpDecimal->addRef();
     }
     return rpDecimal;
-#else
-    (void)p;
-    return NULL;
-#endif
 }
 
 SbxDecimal* ImpGetDecimal( const SbxValues* p )
 {
-#ifdef WIN32
     SbxValues aTmp;
     SbxDecimal* pnDecRes;
 
@@ -563,16 +557,10 @@ start:
             SbxBase::SetError( SbxERR_CONVERSION ); pnDecRes->setShort( 0 );
     }
     return pnDecRes;
-#else
-    (void)p;
-    return NULL;
-#endif
 }
 
-
 void ImpPutDecimal( SbxValues* p, SbxDecimal* pDec )
 {
-#ifdef WIN32
     if( !pDec )
         return;
 
@@ -739,10 +727,6 @@ start:
         default:
             SbxBase::SetError( SbxERR_CONVERSION );
     }
-#else
-    (void)p;
-    (void)pDec;
-#endif
 }
 
 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/unusedcode.easy b/unusedcode.easy
index 9a1af71..fca03af 100644
--- a/unusedcode.easy
+++ b/unusedcode.easy
@@ -132,20 +132,9 @@ SbiExpression::VBA_Imp()
 SbiIoSystem::NextChannel()
 SbiRuntime::GetParams()
 SbiSymPool::Clear()
-SbxDecimal::SbxDecimal()
 SbxDecimal::getByte(unsigned char&)
-SbxDecimal::getChar(unsigned short&)
 SbxDecimal::getInt(int&)
-SbxDecimal::getLong(int&)
-SbxDecimal::getShort(short&)
-SbxDecimal::getString(rtl::OUString&)
 SbxDecimal::getUInt(unsigned int&)
-SbxDecimal::getULong(unsigned int&)
-SbxDecimal::getUShort(unsigned short&)
-SbxDecimal::setShort(short)
-SbxDecimal::setString(rtl::OUString*)
-SbxDecimal::setUShort(unsigned short)
-SbxValue::PutDecimal(SbxDecimal*)
 ScAddInAsyncs::Insert(ScAddInAsync* const&, unsigned short&)
 ScAddInAsyncs::Insert(ScAddInAsync* const*, unsigned short)
 ScAddInAsyncs::Insert(ScAddInAsyncs const*, unsigned short, unsigned short)
commit 00856ee8107fa2d30e324bd6e5bcf3549c1e56d3
Author: Caolán McNamara <caolanm at redhat.com>
Date:   Wed Jan 25 13:02:41 2012 +0000

    callcatcher: update list

diff --git a/autodoc/source/parser/inc/x_parse.hxx b/autodoc/source/parser/inc/x_parse.hxx
deleted file mode 100644
index 593c766..0000000
--- a/autodoc/source/parser/inc/x_parse.hxx
+++ /dev/null
@@ -1,66 +0,0 @@
-/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
-/*************************************************************************
- *
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * Copyright 2000, 2010 Oracle and/or its affiliates.
- *
- * OpenOffice.org - a multi-platform office productivity suite
- *
- * This file is part of OpenOffice.org.
- *
- * OpenOffice.org is free software: you can redistribute it and/or modify
- * it under the terms of the GNU Lesser General Public License version 3
- * only, as published by the Free Software Foundation.
- *
- * OpenOffice.org is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU Lesser General Public License version 3 for more details
- * (a copy is included in the LICENSE file that accompanied this code).
- *
- * You should have received a copy of the GNU Lesser General Public License
- * version 3 along with OpenOffice.org.  If not, see
- * <http://www.openoffice.org/license.html>
- * for a copy of the LGPLv3 License.
- *
- ************************************************************************/
-
-#ifndef ADC_X_PARSE_HXX
-#define ADC_X_PARSE_HXX
-
-// BASE CLASSES
-#include <autodoc/x_parsing.hxx>
-
-
-
-
-class X_Parser : public autodoc::X_Parser_Ifc
-{
-  public:
-    // LIFECYCLE
-                        X_Parser(
-                            E_Event             i_eEvent,
-                            const char *        i_sObject,
-                            const String &      i_sCausingFile_FullPath,
-                            uintt               i_nCausingLineNr );
-                        ~X_Parser();
-    // INQUIRY
-    virtual E_Event     GetEvent() const;
-    virtual void        GetInfo(
-                            std::ostream &      o_rOutputMedium ) const;
-
-  private:
-    E_Event             eEvent;
-    String              sObject;
-    String              sCausingFile_FullPath;
-    uintt               nCausingLineNr;
-
-};
-
-
-
-
-#endif
-
-/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/autodoc/source/parser/kernel/x_parse.cxx b/autodoc/source/parser/kernel/x_parse.cxx
index f06de7f..8a7c6c6 100644
--- a/autodoc/source/parser/kernel/x_parse.cxx
+++ b/autodoc/source/parser/kernel/x_parse.cxx
@@ -27,68 +27,7 @@
  ************************************************************************/
 
 #include <precomp.h>
-#include <x_parse.hxx>
-
-// NOT FULLY DECLARED SERVICES
-
-
-
-X_Parser::X_Parser( E_Event             i_eEvent,
-                    const char *        i_sObject,
-                    const String &      i_sCausingFile_FullPath,
-                    uintt               i_nCausingLineNr  )
-    :   eEvent(i_eEvent),
-        sObject(i_sObject),
-        sCausingFile_FullPath(i_sCausingFile_FullPath),
-        nCausingLineNr(i_nCausingLineNr)
-{
-}
-
-X_Parser::~X_Parser()
-{
-}
-
-X_Parser::E_Event
-X_Parser::GetEvent() const
-{
-     return eEvent;
-}
-
-void
-X_Parser::GetInfo( std::ostream & o_rOutputMedium ) const
-{
-    o_rOutputMedium << "Error in file "
-                    << sCausingFile_FullPath
-                    << " in line "
-                    << nCausingLineNr
-                    << ": ";
-
-
-    switch (eEvent)
-    {
-        case x_InvalidChar:
-            o_rOutputMedium << "Unknown character '"
-                            << sObject
-                            << "'";
-            break;
-        case x_UnexpectedToken:
-            o_rOutputMedium << "Unexpected token \""
-                            << sObject
-                            << "\"";
-            break;
-        case x_UnexpectedEOF:
-            o_rOutputMedium << "Unexpected end of file.";
-            break;
-        case x_UnspecifiedSyntaxError:
-            o_rOutputMedium << "Unspecified syntax problem in file.";
-            break;
-        case x_Any:
-        default:
-            o_rOutputMedium << "Unspecified parsing exception.";
-    }   // end switch
-    o_rOutputMedium << Endl();
-}
-
+#include <autodoc/x_parsing.hxx>
 
 std::ostream &
 operator<<( std::ostream &                  o_rOut,
diff --git a/unusedcode.easy b/unusedcode.easy
index 4a1170d..9a1af71 100644
--- a/unusedcode.easy
+++ b/unusedcode.easy
@@ -891,8 +891,11 @@ basegfx::maximum(basegfx::B2DHomPoint const&, basegfx::B2DHomPoint const&)
 basegfx::maximum(basegfx::B2ITuple const&, basegfx::B2ITuple const&)
 basegfx::minimum(basegfx::B2DHomPoint const&, basegfx::B2DHomPoint const&)
 basegfx::minimum(basegfx::B2ITuple const&, basegfx::B2ITuple const&)
+basegfx::tools::addPointsAtCuts(basegfx::B2DPolygon const&)
+basegfx::tools::addPointsAtCutsAndTouches(basegfx::B2DPolyPolygon const&, basegfx::B2DPolygon const&)
 basegfx::tools::applyLineDashing(basegfx::B3DPolyPolygon const&, std::__debug::vector<double, std::allocator<double> > const&, basegfx::B3DPolyPolygon*, basegfx::B3DPolyPolygon*, double)
 basegfx::tools::ciexyz2rgb(basegfx::BColor const&)
+basegfx::tools::clipPolygonOnRange(basegfx::B3DPolygon const&, basegfx::B3DRange const&, bool, bool)
 basegfx::tools::createPolygonFromRect(basegfx::B2DRange const&, double)
 basegfx::tools::createShearXB2DHomMatrix(double)
 basegfx::tools::createShearYB2DHomMatrix(double)
commit 905b84557d8ccbdba07f0a82a89f382db08fc0d9
Author: Caolán McNamara <caolanm at redhat.com>
Date:   Wed Jan 25 07:58:34 2012 +0000

    refresh unused code list

diff --git a/autodoc/source/inc/tools/tkpchars.hxx b/autodoc/source/inc/tools/tkpchars.hxx
index c5b952f..e60769e 100644
--- a/autodoc/source/inc/tools/tkpchars.hxx
+++ b/autodoc/source/inc/tools/tkpchars.hxx
@@ -96,32 +96,8 @@ class CharacterSource
         bool            IsFinished() const;
 
     private:
-        struct S_SourceState
-        {
-            DYN char *      dpSource;
-            intt            nSourceSize;
-
-            intt            nCurPos;
-            intt            nLastCut;
-            intt            nLastTokenStart;
-            char            cCharAtLastCut;
-
-                            S_SourceState(
-                                DYN char *      dpSource,
-                                intt            nSourceSize,
-                                intt            nCurPos,
-                                intt            nLastCut,
-                                intt            nLastTokenStart,
-                                char            cCharAtLastCut );
-        };
-
         void            BeginSource();
         intt            CurPos() const;
-        char            MoveOn_OverStack();
-
-        // DATA
-        std::stack< S_SourceState >
-                        aSourcesStack;
 
         DYN char *      dpSource;
         intt            nSourceSize;
@@ -142,8 +118,6 @@ if (DEBUG_ShowText())
 }
         if ( nCurPos < nSourceSize-1 )
             return dpSource[++nCurPos];
-        else if ( aSourcesStack.size() > 0 )
-            return MoveOn_OverStack();
         else
             return dpSource[nCurPos = nSourceSize];
     }
diff --git a/autodoc/source/parser/inc/tokens/stmstarr.hxx b/autodoc/source/parser/inc/tokens/stmstarr.hxx
deleted file mode 100644
index 640177f..0000000
--- a/autodoc/source/parser/inc/tokens/stmstarr.hxx
+++ /dev/null
@@ -1,87 +0,0 @@
-/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
-/*************************************************************************
- *
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * Copyright 2000, 2010 Oracle and/or its affiliates.
- *
- * OpenOffice.org - a multi-platform office productivity suite
- *
- * This file is part of OpenOffice.org.
- *
- * OpenOffice.org is free software: you can redistribute it and/or modify
- * it under the terms of the GNU Lesser General Public License version 3
- * only, as published by the Free Software Foundation.
- *
- * OpenOffice.org is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU Lesser General Public License version 3 for more details
- * (a copy is included in the LICENSE file that accompanied this code).
- *
- * You should have received a copy of the GNU Lesser General Public License
- * version 3 along with OpenOffice.org.  If not, see
- * <http://www.openoffice.org/license.html>
- * for a copy of the LGPLv3 License.
- *
- ************************************************************************/
-
-#ifndef ADC_STMSTARR_HXX
-#define ADC_STMSTARR_HXX
-
-// USED SERVICES
-    // BASE CLASSES
-#include <tokens/stmstate.hxx>
-    // COMPONENTS
-    // PARAMETERS
-#include <tokens/token.hxx>
-
-
-class StmArrayStatus : public StmStatus
-{
-  public:
-    typedef TextToken::F_CRTOK F_CRTOK;
-
-    // LIFECYCLE
-                        StmArrayStatus(
-                            intt                i_nStatusSize,
-                            const INT16 *       in_aArrayModel,
-                            F_CRTOK             i_fTokenCreateFunction,
-                            bool                in_bIsDefault );
-                        ~StmArrayStatus();
-
-    // INQUIRY
-    StmStatus::Branch   NextBy(
-                            intt                in_nFollowersIndex) const;
-    F_CRTOK             TokenCreateFunction() const
-                                                { return fTokenCreateFunction; }
-    virtual bool        IsADefault() const;
-
-    // ACCESS
-    virtual StmArrayStatus *
-                        AsArray();
-    bool                SetBranch(
-                            intt                in_nBranchIx,
-                            StmStatus::Branch   in_nBranch );
-    void                SetTokenCreateFunction(
-                            F_CRTOK             i_fTokenCreateFunction );
-  private:
-    StmStatus::Branch * dpBranches;
-    intt                nNrOfBranches;
-    F_CRTOK             fTokenCreateFunction;
-    bool                bIsADefault;
-};
-
-
-// IMPLEMENTATION
-
-inline void
-StmArrayStatus::SetTokenCreateFunction( F_CRTOK i_fTokenCreateFunction )
-    { fTokenCreateFunction = i_fTokenCreateFunction; }
-
-
-
-#endif
-
-
-/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/autodoc/source/parser/tokens/makefile.mk b/autodoc/source/parser/tokens/makefile.mk
index 32bfac8..76a2b37 100644
--- a/autodoc/source/parser/tokens/makefile.mk
+++ b/autodoc/source/parser/tokens/makefile.mk
@@ -45,7 +45,6 @@ PRJINC=$(PRJ)$/source
 # --- Files --------------------------------------------------------
 
 OBJFILES= \
-    $(OBJ)$/stmstarr.obj	\
     $(OBJ)$/stmstate.obj	\
     $(OBJ)$/tkp.obj			\
     $(OBJ)$/tkpcontx.obj	\
diff --git a/autodoc/source/parser/tokens/stmstarr.cxx b/autodoc/source/parser/tokens/stmstarr.cxx
deleted file mode 100644
index 8070fae..0000000
--- a/autodoc/source/parser/tokens/stmstarr.cxx
+++ /dev/null
@@ -1,101 +0,0 @@
-/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
-/*************************************************************************
- *
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * Copyright 2000, 2010 Oracle and/or its affiliates.
- *
- * OpenOffice.org - a multi-platform office productivity suite
- *
- * This file is part of OpenOffice.org.
- *
- * OpenOffice.org is free software: you can redistribute it and/or modify
- * it under the terms of the GNU Lesser General Public License version 3
- * only, as published by the Free Software Foundation.
- *
- * OpenOffice.org is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU Lesser General Public License version 3 for more details
- * (a copy is included in the LICENSE file that accompanied this code).
- *
- * You should have received a copy of the GNU Lesser General Public License
- * version 3 along with OpenOffice.org.  If not, see
- * <http://www.openoffice.org/license.html>
- * for a copy of the LGPLv3 License.
- *
- ************************************************************************/
-
-#include <precomp.h>
-#include <tokens/stmstarr.hxx>
-
-
-// NOT FULLY DECLARED SERVICES
-#include <x_parse.hxx>
-
-
-
-StmArrayStatus::StmArrayStatus( intt            i_nStatusSize,
-                                const INT16 *   in_aArrayModel,
-                                F_CRTOK         i_fTokenCreateFunction,
-                                bool            in_bIsDefault )
-    :   dpBranches(new StmStatus::Branch[i_nStatusSize]),
-        nNrOfBranches(i_nStatusSize),
-        fTokenCreateFunction(i_fTokenCreateFunction),
-        bIsADefault(in_bIsDefault)
-{
-    if (in_aArrayModel != 0)
-    {
-        intt count = 0;
-        for (const INT16 * get = in_aArrayModel; count < nNrOfBranches; count++, get++)
-            dpBranches[count] = *get;
-    }
-    else //
-    {
-        memset(dpBranches, 0, nNrOfBranches);
-    }  // endif
-}
-
-StmArrayStatus::~StmArrayStatus()
-{
-    delete [] dpBranches;
-}
-
-bool
-StmArrayStatus::SetBranch( intt              in_nBranchIx,
-                           StmStatus::Branch in_nBranch )
-{
-    if ( csv::in_range(intt(0), in_nBranchIx, intt(nNrOfBranches) ) )
-    {
-        dpBranches[in_nBranchIx] = in_nBranch;
-        return true;
-    }
-    return false;
-}
-
-
-StmStatus::Branch
-StmArrayStatus::NextBy(intt in_nIndex) const
-{
-    if (in_nIndex < 0)
-        throw X_Parser(X_Parser::x_InvalidChar, "", String::Null_(), 0);
-
-    return in_nIndex < nNrOfBranches
-                ?   dpBranches[in_nIndex]
-                :   dpBranches[nNrOfBranches - 1];
-}
-
-
-bool
-StmArrayStatus::IsADefault() const
-{
-    return bIsADefault;
-}
-
-StmArrayStatus *
-StmArrayStatus::AsArray()
-{
-    return this;
-}
-
-/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/autodoc/source/tools/tkpchars.cxx b/autodoc/source/tools/tkpchars.cxx
index 92d91d5..b4e7057 100644
--- a/autodoc/source/tools/tkpchars.cxx
+++ b/autodoc/source/tools/tkpchars.cxx
@@ -95,45 +95,4 @@ CharacterSource::BeginSource()
     dpSource[nLastCut] = NULCH;
 }
 
-//  KORR_FUTURE:  So far, this works only when tokens do not cross inserted text boundaries.
-char
-CharacterSource::MoveOn_OverStack()
-{
-    while ( aSourcesStack.size() > 0 AND nCurPos >= nSourceSize-1 )
-    {
-        S_SourceState & aState = aSourcesStack.top();
-        delete [] dpSource;
-
-        dpSource = aState.dpSource;
-        nSourceSize = aState.nSourceSize;
-        nCurPos = aState.nCurPos;
-        nLastCut = aState.nLastCut;
-        nLastTokenStart = aState.nLastTokenStart;
-        cCharAtLastCut = aState.cCharAtLastCut;
-
-        aSourcesStack.pop();
-    }
-
-    if ( nLastCut < nCurPos )
-        CutToken();
-
-    return CurChar();
-}
-
-CharacterSource::
-S_SourceState::S_SourceState( DYN char *    dpSource_,
-                              intt          nSourceSize_,
-                              intt          nCurPos_,
-                              intt          nLastCut_,
-                              intt          nLastTokenStart_,
-                              char          cCharAtLastCut_ )
-    :   dpSource(dpSource_),
-        nSourceSize(nSourceSize_),
-        nCurPos(nCurPos_),
-        nLastCut(nLastCut_),
-        nLastTokenStart(nLastTokenStart_),
-        cCharAtLastCut(cCharAtLastCut_)
-{
-}
-
 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/l10ntools/inc/export.hxx b/l10ntools/inc/export.hxx
index 6b749fc..b3fc196 100644
--- a/l10ntools/inc/export.hxx
+++ b/l10ntools/inc/export.hxx
@@ -492,7 +492,7 @@ class MergeDataFile
         sal_Bool bErrorLog;
         ByteString sErrorLog;
         SvFileStream aErrLog;
-    MergeDataHashMap aMap;
+        MergeDataHashMap aMap;
         std::set<ByteString> aLanguageSet;
 
         MergeData *GetMergeData( ResData *pResData , bool bCaseSensitve = false );
diff --git a/l10ntools/source/merge.cxx b/l10ntools/source/merge.cxx
index f219315..a31ff94 100644
--- a/l10ntools/source/merge.cxx
+++ b/l10ntools/source/merge.cxx
@@ -238,6 +238,8 @@ MergeDataFile::MergeDataFile(
 
 MergeDataFile::~MergeDataFile()
 {
+    for (MergeDataHashMap::iterator aI = aMap.begin(), aEnd = aMap.end(); aI != aEnd; ++aI)
+        delete aI->second;
 }
 
 ByteString MergeDataFile::Dump(){
@@ -248,7 +250,7 @@ ByteString MergeDataFile::Dump(){
     for( idbg = aMap.begin() ; idbg != aMap.end(); ++idbg )
     {
         printf("aMap[ %s ] = ",idbg->first.GetBuffer());
-        ((MergeData*) (idbg->second))->Dump();
+        idbg->second->Dump();
         printf("\n");
     }
     printf("\n");
diff --git a/tools/inc/tools/stream.hxx b/tools/inc/tools/stream.hxx
index d63b7d3..e0a5509 100644
--- a/tools/inc/tools/stream.hxx
+++ b/tools/inc/tools/stream.hxx
@@ -415,8 +415,6 @@ public:
                 /// Read a line of Unicode if eSrcCharSet==RTL_TEXTENCODING_UNICODE,
                 /// otherwise read a line of Bytecode and convert from eSrcCharSet
     sal_Bool        ReadUniOrByteStringLine( String& rStr, rtl_TextEncoding eSrcCharSet );
-                /// Write a sequence of Unicode characters
-    sal_Bool        WriteUnicodeText( const String& rStr );
                 /// Write a sequence of Unicode characters if eDestCharSet==RTL_TEXTENCODING_UNICODE,
                 /// otherwise write a sequence of Bytecodes converted to eDestCharSet
     sal_Bool        WriteUnicodeOrByteText( const String& rStr, rtl_TextEncoding eDestCharSet );
diff --git a/tools/source/stream/stream.cxx b/tools/source/stream/stream.cxx
index db84400..fd5a579 100644
--- a/tools/source/stream/stream.cxx
+++ b/tools/source/stream/stream.cxx
@@ -885,18 +885,6 @@ sal_Size write_uInt16s_FromOUString(SvStream& rStrm, const rtl::OUString& rStr,
     return nWritten;
 }
 
-/*************************************************************************
-|*
-|*    Stream::WriteUnicodeText()
-|*
-*************************************************************************/
-
-sal_Bool SvStream::WriteUnicodeText( const String& rStr )
-{
-    write_uInt16s_FromOUString(*this, rStr, rStr.Len());
-    return nError == SVSTREAM_OK;
-}
-
 sal_Bool SvStream::WriteUnicodeOrByteText( const String& rStr, rtl_TextEncoding eDestCharSet )
 {
     if ( eDestCharSet == RTL_TEXTENCODING_UNICODE )
diff --git a/unusedcode.easy b/unusedcode.easy
index bf2c723..4a1170d 100644
--- a/unusedcode.easy
+++ b/unusedcode.easy
@@ -82,7 +82,6 @@ MailDispatcher::removeListener(rtl::Reference<IMailDispatcherListener>)
 Matrix3d::Inverse() const
 Matrix3d::Matrix3d()
 MenuBar::MenuBar(ResId const&)
-MergeData::~MergeData()
 MergeDataFile::Dump()
 MessBox::MessBox(unsigned short)
 MetaAction::IsEqual(MetaAction const&) const
@@ -382,6 +381,7 @@ SvPersistStream::RemoveObj(SvPersistBase*)
 SvPersistStream::SvPersistStream(SvClassManager&, SvStream*, SvPersistStream const&)
 SvPtrarr::Replace(void* const*, unsigned short, unsigned short)
 SvStream::ReadLine(ByteString&)
+SvStringsISortDtor::Insert(String* const*, unsigned short)
 SvTabListBox::GetTabJustify(unsigned short) const
 SvUnoAttributeContainer::getImplementation(com::sun::star::uno::Reference<com::sun::star::uno::XInterface>)
 SvXMLAutoStylePoolNamesP_Impl::GetPos(rtl::OUString const*) const
@@ -677,8 +677,6 @@ TransferableDataHelper::GetInterface(com::sun::star::datatransfer::DataFlavor co
 TypeDescriptor_Init_Impl::~TypeDescriptor_Init_Impl()
 UCBStorage::IsStorageFile(String const&)
 UCBStream::UCBStream(com::sun::star::uno::Reference<com::sun::star::io::XOutputStream>&)
-UnoApiTest::UnoApiTest()
-UnoApiTest::createFileURL(rtl::OUString const&, rtl::OUString&)
 UnoComboBoxControl::getActionListeners()
 UnoComboBoxControl::getItemListeners()
 UnoControlBase::UnoControlBase()
@@ -1568,6 +1566,7 @@ pdfi::DrawXmlEmitter::GetBreakIterator()
 pdfi::PDFIProcessor::sortDocument(bool)
 pdfi::PDFIRawAdaptor::odfConvert(rtl::OUString const&, com::sun::star::uno::Reference<com::sun::star::io::XOutputStream> const&, com::sun::star::uno::Reference<com::sun::star::task::XStatusIndicator> const&)
 pdfparse::PDFReader::read(char const*, unsigned int)
+pq_sdbc_driver::rollbackNoThrow(com::sun::star::uno::Reference<com::sun::star::sdbc::XConnection> const&)
 psp::GetCommandLineTokenCount(rtl::OString const&)
 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&)
diff --git a/xml2cmp/source/support/heap.cxx b/xml2cmp/source/support/heap.cxx
index e814cbe..0a33f30 100644
--- a/xml2cmp/source/support/heap.cxx
+++ b/xml2cmp/source/support/heap.cxx
@@ -182,12 +182,6 @@ HeapItem::operator<( const HeapItem & i_rOther ) const
 }
 
 const Simstr &
-HeapItem::Value() const
-{
-    return sValue;
-}
-
-const Simstr &
 HeapItem::Key() const
 {
     return sKey;
diff --git a/xml2cmp/source/support/heap.hxx b/xml2cmp/source/support/heap.hxx
index 5d4a9bf..bbf9ed5 100644
--- a/xml2cmp/source/support/heap.hxx
+++ b/xml2cmp/source/support/heap.hxx
@@ -70,7 +70,6 @@ class HeapItem
     bool                operator<=(
                             const HeapItem &    i_rOther ) const
                                                 { return ! (i_rOther < *this); }
-    const Simstr &      Value() const;
     const Simstr &      Key() const;
     HeapItem *          Next() const;
 
commit d6bf32bab10e1bb115aea0c6e5d6ac1753760fe7
Author: Caolán McNamara <caolanm at redhat.com>
Date:   Tue Jan 24 23:10:47 2012 +0000

    make padmin ByteString free

diff --git a/padmin/source/adddlg.cxx b/padmin/source/adddlg.cxx
index 9db6d15..382924c 100644
--- a/padmin/source/adddlg.cxx
+++ b/padmin/source/adddlg.cxx
@@ -498,15 +498,15 @@ APOldPrinterPage::APOldPrinterPage( AddPrinterDialog* pParent )
 
     // read defaults
     aConfig.SetGroup( "Xprinter,PostScript" );
-    ByteString aDefPageSize( aConfig.ReadKey( "PageSize" ) );
-    ByteString aDefOrientation( aConfig.ReadKey( "Orientation" ) );
-    ByteString aDefMarginLeft( aConfig.ReadKey( "MarginLeft" ) );
-    ByteString aDefMarginRight( aConfig.ReadKey( "MarginRight" ) );
-    ByteString aDefMarginTop( aConfig.ReadKey( "MarginTop" ) );
-    ByteString aDefMarginBottom( aConfig.ReadKey( "MarginBottom" ) );
-    ByteString aDefScale( aConfig.ReadKey( "Scale" ) );
-    ByteString aDefCopies( aConfig.ReadKey( "Copies" ) );
-    ByteString aDefDPI( aConfig.ReadKey( "DPI" ) );
+    rtl::OString aDefPageSize( aConfig.ReadKey( "PageSize" ) );
+    rtl::OString aDefOrientation( aConfig.ReadKey( "Orientation" ) );
+    rtl::OString aDefMarginLeft( aConfig.ReadKey( "MarginLeft" ) );
+    rtl::OString aDefMarginRight( aConfig.ReadKey( "MarginRight" ) );
+    rtl::OString aDefMarginTop( aConfig.ReadKey( "MarginTop" ) );
+    rtl::OString aDefMarginBottom( aConfig.ReadKey( "MarginBottom" ) );
+    rtl::OString aDefScale( aConfig.ReadKey( "Scale" ) );
+    rtl::OString aDefCopies( aConfig.ReadKey( "Copies" ) );
+    rtl::OString aDefDPI( aConfig.ReadKey( "DPI" ) );
 
     using comphelper::string::getToken;
 
@@ -540,8 +540,8 @@ APOldPrinterPage::APOldPrinterPage( AddPrinterDialog* pParent )
 
         // read the command
         aConfig.SetGroup( "ports" );
-        ByteString aCommand( aConfig.ReadKey( aPort ) );
-        if( ! aCommand.Len() )
+        rtl::OString aCommand( aConfig.ReadKey( aPort ) );
+        if (aCommand.isEmpty())
         {
             String aText( PaResId( RID_TXT_PRINTERWITHOUTCOMMAND ) );
             aText.SearchAndReplace( String( RTL_CONSTASCII_USTRINGPARAM( "%s" ) ), rtl::OStringToOUString(aPrinter, aEncoding) );
@@ -603,23 +603,22 @@ APOldPrinterPage::APOldPrinterPage( AddPrinterDialog* pParent )
 
         aValue = aConfig.ReadKey( "Orientation", aDefOrientation );
         if (!aValue.isEmpty())
-            aInfo.m_eOrientation = aValue.equalsIgnoreAsciiCase( "landscape" ) == COMPARE_EQUAL ? orientation::Landscape : orientation::Portrait;
+            aInfo.m_eOrientation = aValue.equalsIgnoreAsciiCaseL(RTL_CONSTASCII_STRINGPARAM("landscape")) ? orientation::Landscape : orientation::Portrait;
         int nGroupKeys = aConfig.GetKeyCount();
         for( int nPPDKey = 0; nPPDKey < nGroupKeys; nPPDKey++ )
         {
-            ByteString aPPDKey( aConfig.GetKeyName( nPPDKey ) );
+            rtl::OString aPPDKey( aConfig.GetKeyName( nPPDKey ) );
             // ignore page region
             // there are some ppd keys in old Xpdefaults that
             // should never have been writte because they are defaults
             // PageRegion leads to problems in conjunction
             // with a not matching PageSize
-            if( aPPDKey.CompareTo( "PPD_", 4 ) == COMPARE_EQUAL &&
-                aPPDKey != "PPD_PageRegion"
-                )
+            if (comphelper::string::matchL(aPPDKey, RTL_CONSTASCII_STRINGPARAM("PPD_")) &&
+                !aPPDKey.equalsL(RTL_CONSTASCII_STRINGPARAM("PPD_PageRegion")))
             {
                 aValue = aConfig.ReadKey( nPPDKey );
-                aPPDKey.Erase( 0, 4 );
-                const PPDKey* pKey = aInfo.m_pParser->getKey( String( aPPDKey, RTL_TEXTENCODING_ISO_8859_1 ) );
+                aPPDKey = aPPDKey.copy(4);
+                const PPDKey* pKey = aInfo.m_pParser->getKey( rtl::OStringToOUString(aPPDKey, RTL_TEXTENCODING_ISO_8859_1) );
                 const PPDValue* pValue = pKey ? ( aValue.equalsL(RTL_CONSTASCII_STRINGPARAM("*nil")) ? NULL : pKey->getValue(rtl::OStringToOUString(aValue, RTL_TEXTENCODING_ISO_8859_1)) ) : NULL;
                 if( pKey )
                     aInfo.m_aContext.setValue( pKey, pValue, true );
@@ -1097,40 +1096,40 @@ String AddPrinterDialog::uniquePrinterName( const String& rBase )
 String AddPrinterDialog::getOldPrinterLocation()
 {
     static const char* pHome = getenv( "HOME" );
-    String aRet;
-    ByteString aFileName;
+    rtl::OString aFileName;
 
     rtl_TextEncoding aEncoding = osl_getThreadTextEncoding();
     if( pHome )
     {
-        aFileName = pHome;
-        aFileName.Append( "/.Xpdefaults" );
-        if( access( aFileName.GetBuffer(), F_OK ) )
+        aFileName = rtl::OStringBuffer().append(pHome).
+            append(RTL_CONSTASCII_STRINGPARAM("/.Xpdefaults")).
+            makeStringAndClear();
+        if (access(aFileName.getStr(), F_OK))
         {
-            aFileName = pHome;
-            aFileName.Append( "/.sversionrc" );
-            Config aSVer( String( aFileName, aEncoding ) );
+            aFileName = rtl::OStringBuffer().append(pHome).
+                append(RTL_CONSTASCII_STRINGPARAM("/.sversionrc")).
+                makeStringAndClear();
+            Config aSVer(rtl::OStringToOUString(aFileName, aEncoding));
             aSVer.SetGroup( "Versions" );
             aFileName = aSVer.ReadKey( "StarOffice 5.2" );
-            if( aFileName.Len() )
-                aFileName.Append( "/share/xp3/Xpdefaults" );
+            if (!aFileName.isEmpty())
+                aFileName = aFileName + rtl::OString(RTL_CONSTASCII_STRINGPARAM("/share/xp3/Xpdefaults"));
             else if(
-                    (aFileName = aSVer.ReadKey( "StarOffice 5.1" ) ).Len()
+                    (aFileName = aSVer.ReadKey( "StarOffice 5.1" ) ).getLength()
                     ||
-                    (aFileName = aSVer.ReadKey( "StarOffice 5.0" ) ).Len()
+                    (aFileName = aSVer.ReadKey( "StarOffice 5.0" ) ).getLength()
                     ||
-                    (aFileName = aSVer.ReadKey( "StarOffice 4.0" ) ).Len()
+                    (aFileName = aSVer.ReadKey( "StarOffice 4.0" ) ).getLength()
                     )
             {
-                aFileName.Append( "/xp3/Xpdefaults" );
+                aFileName = aFileName + rtl::OString(RTL_CONSTASCII_STRINGPARAM("/xp3/Xpdefaults"));
             }
-            if( aFileName.Len() && access( aFileName.GetBuffer(), F_OK ) )
-                aFileName.Erase();
+            if (!aFileName.isEmpty() && access(aFileName.getStr(), F_OK))
+                aFileName = rtl::OString();
         }
     }
-    if( aFileName.Len() )
-        aRet = String( aFileName, aEncoding );
-    return aRet;
+
+    return !aFileName.isEmpty() ? rtl::OStringToOUString(aFileName, aEncoding) : rtl::OUString();
 }
 
 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/padmin/source/cmddlg.cxx b/padmin/source/cmddlg.cxx
index 4a54aab..74ba800 100644
--- a/padmin/source/cmddlg.cxx
+++ b/padmin/source/cmddlg.cxx
@@ -82,7 +82,7 @@ void CommandStore::getSystemPdfCommands( ::std::list< String >& rCommands )
                 int nLen = strlen( pBuffer );
                 if( pBuffer[nLen-1] == '\n' ) // strip newline
                     pBuffer[--nLen] = 0;
-                aCommand = String( ByteString( pBuffer ), aEncoding );
+                aCommand = rtl::OUString(pBuffer, nLen, aEncoding);
                 if( ( ( aCommand.GetChar( 0 ) == '/' )
                       || ( aCommand.GetChar( 0 ) == '.' && aCommand.GetChar( 1 ) == '/' )
                       || ( aCommand.GetChar( 0 ) == '.' && aCommand.GetChar( 1 ) == '.' && aCommand.GetChar( 2 ) == '/' ) )
@@ -105,7 +105,7 @@ void CommandStore::getSystemPdfCommands( ::std::list< String >& rCommands )
                 int nLen = strlen( pBuffer );
                 if( pBuffer[nLen-1] == '\n' ) // strip newline
                     pBuffer[--nLen] = 0;
-                aCommand = String( ByteString( pBuffer ), aEncoding );
+                aCommand = rtl::OUString(pBuffer, nLen, aEncoding);
                 if( ( ( aCommand.GetChar( 0 ) == '/' )
                       || ( aCommand.GetChar( 0 ) == '.' && aCommand.GetChar( 1 ) == '/' )
                       || ( aCommand.GetChar( 0 ) == '.' && aCommand.GetChar( 1 ) == '.' && aCommand.GetChar( 2 ) == '/' ) )
diff --git a/padmin/source/newppdlg.cxx b/padmin/source/newppdlg.cxx
index 593c09c..de04c73 100644
--- a/padmin/source/newppdlg.cxx
+++ b/padmin/source/newppdlg.cxx
@@ -80,9 +80,9 @@ PPDImportDialog::PPDImportDialog( Window* pParent ) :
     m_aPathBox.SetText( rtl::OStringToOUString(rConfig.ReadKey("LastDir"), RTL_TEXTENCODING_UTF8) );
     for (sal_Int32 i = 0; i < 11; ++i)
     {
-        ByteString aEntry(rConfig.ReadKey(rtl::OString::valueOf(i)));
-        if( aEntry.Len() )
-            m_aPathBox.InsertEntry( String( aEntry, RTL_TEXTENCODING_UTF8 ) );
+        rtl::OString aEntry(rConfig.ReadKey(rtl::OString::valueOf(i)));
+        if (!aEntry.isEmpty())
+            m_aPathBox.InsertEntry(rtl::OStringToOUString(aEntry, RTL_TEXTENCODING_UTF8));
     }
 
     m_aOKBtn.SetClickHdl( LINK( this, PPDImportDialog, ClickBtnHdl ) );
diff --git a/vcl/workben/outdevgrind.cxx b/vcl/workben/outdevgrind.cxx
index 77b7c5b..ab9b6cd 100644
--- a/vcl/workben/outdevgrind.cxx
+++ b/vcl/workben/outdevgrind.cxx
@@ -123,8 +123,7 @@ void setupMethodStubs( functor_vector_type& res )
     aPoly3.Rotate( aPoly3.GetBoundRect().Center(),
                    900 );
 
-    const String      aString( ByteString("This is a test"),
-                               RTL_TEXTENCODING_ASCII_US );
+    const String      aString(RTL_CONSTASCII_USTRINGPARAM("This is a test"));
     const LineInfo    aLineInfo(LINE_SOLID,5);
 
     // unfortunately, VDevs have inaccessible copy constructors
commit 141c1c7bc6ac9bfadaf3fad6aba16a03836701b1
Author: Caolán McNamara <caolanm at redhat.com>
Date:   Tue Jan 24 22:04:29 2012 +0000

    callcatcher: remove some unused code

diff --git a/svtools/inc/svtools/treelist.hxx b/svtools/inc/svtools/treelist.hxx
index 1e0c266..9db33bb 100644
--- a/svtools/inc/svtools/treelist.hxx
+++ b/svtools/inc/svtools/treelist.hxx
@@ -444,7 +444,6 @@ protected:
 public:
 
                         SvListView();   // !!! setzt das Model auf 0
-                        SvListView( SvTreeList* pModel );
     virtual             ~SvListView();
     void                Clear();
     SvTreeList*         GetModel() const { return pModel; }
diff --git a/svtools/source/contnr/treelist.cxx b/svtools/source/contnr/treelist.cxx
index 51a0d1e..7ea23f3 100644
--- a/svtools/source/contnr/treelist.cxx
+++ b/svtools/source/contnr/treelist.cxx
@@ -1423,16 +1423,6 @@ SvListEntry* SvTreeList::GetRootLevelParent( SvListEntry* pEntry ) const
 
 DBG_NAME(SvListView);
 
-SvListView::SvListView( SvTreeList* pModell )
-{
-    DBG_CTOR(SvListView,0);
-    pModel = 0;
-    nSelectionCount = 0;
-    nVisibleCount = 0;
-    bVisPositionsValid = sal_False;
-    SetModel( pModell );
-}
-
 SvListView::SvListView()
 {
     DBG_CTOR(SvListView,0);
diff --git a/unusedcode.easy b/unusedcode.easy
index a9e5a1a..bf2c723 100644
--- a/unusedcode.easy
+++ b/unusedcode.easy
@@ -109,8 +109,6 @@ NumericFormatter::ConvertToFraction(long)
 NumericFormatter::ConvertToLong(Fraction const&)
 OLEObjCache::SetSize(unsigned long)
 ORegKey::acquireKey(void*)
-Octree::AddColor(BitmapColor const&)
-Octree::Octree(unsigned long)
 OutputDevice::LogicToPixel(PolyPolygon const&, MapMode const&) const
 OutputDevice::PixelToLogic(PolyPolygon const&, MapMode const&) const
 ParagraphObj::ParagraphObj(ParagraphObj&)
@@ -379,13 +377,11 @@ SvLBoxButton::Check(SvLBox*, SvLBoxEntry*, unsigned char)
 SvLBoxButtonData::SvLBoxButtonData()
 SvLBoxEntryArr::DeleteAndDestroy(unsigned short, unsigned short)
 SvLBoxItem::GetSize(SvLBoxEntry*, SvViewDataEntry*)
-SvListView::SvListView(SvTreeList*)
 SvPersistStream::InsertObj(SvPersistBase*)
 SvPersistStream::RemoveObj(SvPersistBase*)
 SvPersistStream::SvPersistStream(SvClassManager&, SvStream*, SvPersistStream const&)
 SvPtrarr::Replace(void* const*, unsigned short, unsigned short)
 SvStream::ReadLine(ByteString&)
-SvStringsISortDtor::Insert(String* const*, unsigned short)
 SvTabListBox::GetTabJustify(unsigned short) const
 SvUnoAttributeContainer::getImplementation(com::sun::star::uno::Reference<com::sun::star::uno::XInterface>)
 SvXMLAutoStylePoolNamesP_Impl::GetPos(rtl::OUString const*) const
@@ -773,7 +769,6 @@ XMLTextListAutoStylePoolNames_Impl::GetPos(rtl::OUString const*) const
 XMLTextListAutoStylePoolNames_Impl::Remove(rtl::OUString*)
 XMLTextListAutoStylePool_Impl::GetPos(XMLTextListAutoStylePoolEntry_Impl const*) const
 XMLTextListAutoStylePool_Impl::Remove(XMLTextListAutoStylePoolEntry_Impl*)
-XMLTextParagraphExport::FindTextStyle(com::sun::star::uno::Reference<com::sun::star::beans::XPropertySet> const&, unsigned char&) const
 XMLVisAreaContext::XMLVisAreaContext(SvXMLImport&, unsigned short, rtl::OUString const&, com::sun::star::uno::Reference<com::sun::star::xml::sax::XAttributeList> const&, Rectangle&, short)
 XPropertyList::Clear()
 XSecController::collectToSign(int, rtl::OUString const&)
diff --git a/vcl/inc/vcl/octree.hxx b/vcl/inc/vcl/octree.hxx
index 3cef638..e458aed 100644
--- a/vcl/inc/vcl/octree.hxx
+++ b/vcl/inc/vcl/octree.hxx
@@ -81,7 +81,7 @@ private:
     const BitmapReadAccess*     pAcc;
     sal_uInt16                      nPalIndex;
 
-                                Octree() {};
+                                Octree() {}
 
     void                        CreatePalette( PNODE pNode );
     void                        GetPalIndex( PNODE pNode );
@@ -94,11 +94,8 @@ private:
 public:
 
                                 Octree( const BitmapReadAccess& rReadAcc, sal_uLong nColors );
-                                Octree( sal_uLong nColors );
                                 ~Octree();
 
-    void                        AddColor( const BitmapColor& rColor );
-
     inline const BitmapPalette& GetPalette();
     inline sal_uInt16               GetBestPaletteIndex( const BitmapColor& rColor );
 };
diff --git a/vcl/source/gdi/octree.cxx b/vcl/source/gdi/octree.cxx
index 844eabb..5f4f823 100644
--- a/vcl/source/gdi/octree.cxx
+++ b/vcl/source/gdi/octree.cxx
@@ -75,18 +75,6 @@ ImpNodeCache::~ImpNodeCache()
 // - Octree -
 // ----------
 
-Octree::Octree( sal_uLong nColors ) :
-            nMax        ( nColors ),
-            nLeafCount  ( 0L ),
-            pTree       ( NULL ),
-            pAcc        ( NULL )
-{
-    pNodeCache = new ImpNodeCache( nColors );
-    memset( pReduce, 0, ( OCTREE_BITS + 1 ) * sizeof( PNODE ) );
-}
-
-// ------------------------------------------------------------------------
-
 Octree::Octree( const BitmapReadAccess& rReadAcc, sal_uLong nColors ) :
             nMax        ( nColors ),
             nLeafCount  ( 0L ),
@@ -108,18 +96,6 @@ Octree::~Octree()
 
 // ------------------------------------------------------------------------
 
-void Octree::AddColor( const BitmapColor& rColor )
-{
-    pColor = &(BitmapColor&) rColor;
-    nLevel = 0L;
-    ImplAdd( &pTree );
-
-    while( nLeafCount > nMax )
-        ImplReduce();
-}
-
-// ------------------------------------------------------------------------
-
 void Octree::ImplCreateOctree()
 {
     if( !!*pAcc )
diff --git a/xmloff/inc/xmloff/txtparae.hxx b/xmloff/inc/xmloff/txtparae.hxx
index 4fb9ad6..02eb4b6 100644
--- a/xmloff/inc/xmloff/txtparae.hxx
+++ b/xmloff/inc/xmloff/txtparae.hxx
@@ -236,10 +236,6 @@ protected:
     const SvXMLAutoStylePoolP& GetAutoStylePool() const { return rAutoStylePool; }
 
 public:
-    ::rtl::OUString FindTextStyle(
-            const ::com::sun::star::uno::Reference <
-                ::com::sun::star::beans::XPropertySet > & rPropSet,
-            sal_Bool& rbHasCharStyle ) const;
     ::rtl::OUString FindTextStyleAndHyperlink(
             const ::com::sun::star::uno::Reference <
                 ::com::sun::star::beans::XPropertySet > & rPropSet,
diff --git a/xmloff/source/text/txtparae.cxx b/xmloff/source/text/txtparae.cxx
index 3761121..ca23ab0 100644
--- a/xmloff/source/text/txtparae.cxx
+++ b/xmloff/source/text/txtparae.cxx
@@ -821,16 +821,6 @@ OUString XMLTextParagraphExport::FindTextStyleAndHyperlink(
     return sName;
 }
 
-OUString XMLTextParagraphExport::FindTextStyle(
-           const Reference < XPropertySet > & rPropSet,
-        sal_Bool& rHasCharStyle ) const
-{
-    sal_Bool bDummy;
-    sal_Bool bDummy2;
-    return FindTextStyleAndHyperlink( rPropSet, bDummy, rHasCharStyle, bDummy2 );
-}
-
-
 // adjustments to support lists independent from list style
 void XMLTextParagraphExport::exportListChange(
         const XMLTextNumRuleInfo& rPrevInfo,
commit 03e3a20868b971595481e6742725a1c80745e7b7
Author: Caolán McNamara <caolanm at redhat.com>
Date:   Tue Jan 24 21:52:07 2012 +0000

    ByteString->rtl::OString

diff --git a/svtools/source/filter/ixbm/xbmread.cxx b/svtools/source/filter/ixbm/xbmread.cxx
index 3e8bec3..aae46dc 100644
--- a/svtools/source/filter/ixbm/xbmread.cxx
+++ b/svtools/source/filter/ixbm/xbmread.cxx
@@ -197,7 +197,7 @@ long XBMReader::ParseDefine( const sal_Char* pDefine )
 
 // ------------------------------------------------------------------------
 
-sal_Bool XBMReader::ParseData( SvStream* pInStm, const ByteString& aLastLine, XBMFormat eFormat )
+sal_Bool XBMReader::ParseData( SvStream* pInStm, const rtl::OString& aLastLine, XBMFormat eFormat )
 {
     rtl::OString    aLine;
     long            nRow = 0;
@@ -283,16 +283,14 @@ ReadState XBMReader::ReadXBM( Graphic& rGraphic )
     // kehren wir zurueck und warten auf neue Daten
     if ( rIStm.GetError() != ERRCODE_IO_PENDING )
     {
-        ByteString  aLine;
-
         rIStm.Seek( nLastPos );
         bStatus = sal_False;
-        aLine = FindTokenLine( &rIStm, "#define", "_width" );
+        rtl::OString aLine = FindTokenLine( &rIStm, "#define", "_width" );
 
         if ( bStatus )
         {
             int nValue;
-            if ( ( nValue = (int) ParseDefine( aLine.GetBuffer() ) ) > 0 )
+            if ( ( nValue = (int) ParseDefine( aLine.getStr() ) ) > 0 )
             {
                 nWidth = nValue;
                 aLine = FindTokenLine( &rIStm, "#define", "_height" );
@@ -310,7 +308,7 @@ ReadState XBMReader::ReadXBM( Graphic& rGraphic )
 
             if ( bStatus )
             {
-                if ( ( nValue = (int) ParseDefine( aLine.GetBuffer() ) ) > 0 )
+                if ( ( nValue = (int) ParseDefine( aLine.getStr() ) ) > 0 )
                 {
                     nHeight = nValue;
                     aLine = FindTokenLine( &rIStm, "static", "_bits" );
@@ -319,9 +317,10 @@ ReadState XBMReader::ReadXBM( Graphic& rGraphic )
                     {
                         XBMFormat eFormat = XBM10;
 
-                        if ( aLine.Search( "short" ) != STRING_NOTFOUND )
+                        using comphelper::string::indexOfL;
+                        if (indexOfL(aLine, RTL_CONSTASCII_STRINGPARAM("short")) != -1)
                             eFormat = XBM10;
-                        else if ( aLine.Search( "char" ) != STRING_NOTFOUND )
+                        else if (indexOfL(aLine, RTL_CONSTASCII_STRINGPARAM("char")) != -1)
                             eFormat = XBM11;
                         else
                             bStatus = sal_False;
diff --git a/svtools/source/inc/xbmread.hxx b/svtools/source/inc/xbmread.hxx
index 0bf5136..4381790 100644
--- a/svtools/source/inc/xbmread.hxx
+++ b/svtools/source/inc/xbmread.hxx
@@ -72,7 +72,7 @@ class XBMReader : public GraphicReader
     rtl::OString        FindTokenLine( SvStream* pInStm, const char* pTok1,
                                        const char* pTok2 = NULL, const char* pTok3 = NULL );
     long                ParseDefine( const sal_Char* pDefine );
-    sal_Bool                ParseData( SvStream* pInStm, const ByteString& aLastLine, XBMFormat eFormat );
+    sal_Bool            ParseData( SvStream* pInStm, const rtl::OString& aLastLine, XBMFormat eFormat );
 
 
 public:
diff --git a/svtools/source/misc/imap2.cxx b/svtools/source/misc/imap2.cxx
index 41dff42..252346b 100644
--- a/svtools/source/misc/imap2.cxx
+++ b/svtools/source/misc/imap2.cxx
@@ -261,14 +261,12 @@ sal_uLong ImageMap::ImpReadCERN( SvStream& rIStm, const String& rBaseURL )
 
 void ImageMap::ImpReadCERNLine( const rtl::OString& rLine, const String& rBaseURL  )
 {
-    ByteString  aStr( rLine );
-
-    aStr = comphelper::string::stripStart(aStr, ' ');
+    rtl::OString aStr = comphelper::string::stripStart(rLine, ' ');
     aStr = comphelper::string::stripStart(aStr, '\t');
     aStr = comphelper::string::remove(aStr, ';');
-    aStr.ToLowerAscii();
+    aStr = aStr.toAsciiLowerCase();
 
-    const char* pStr = aStr.GetBuffer();
+    const char* pStr = aStr.getStr();
     char        cChar = *pStr++;
 
     // Anweisung finden
@@ -405,14 +403,12 @@ sal_uLong ImageMap::ImpReadNCSA( SvStream& rIStm, const String& rBaseURL )
 
 void ImageMap::ImpReadNCSALine( const rtl::OString& rLine, const String& rBaseURL )
 {
-    ByteString  aStr( rLine );
-
-    aStr = comphelper::string::stripStart(aStr, ' ');
+    rtl::OString aStr = comphelper::string::stripStart(rLine, ' ');
     aStr = comphelper::string::stripStart(aStr, '\t');
     aStr = comphelper::string::remove(aStr, ';');
-    aStr.ToLowerAscii();
+    aStr = aStr.toAsciiLowerCase();
 
-    const char* pStr = aStr.GetBuffer();
+    const char* pStr = aStr.getStr();
     char        cChar = *pStr++;
 
     // Anweisung finden
commit 39e54d04804d1d8ad0d0dc10aad8ef89c2ff1e40
Author: Caolán McNamara <caolanm at redhat.com>
Date:   Tue Jan 24 21:36:38 2012 +0000

    move ugly WriteLines out of SvStream to beside sole user

diff --git a/basic/source/runtime/iosys.cxx b/basic/source/runtime/iosys.cxx
index 64ab1d9..79dcb0e 100644
--- a/basic/source/runtime/iosys.cxx
+++ b/basic/source/runtime/iosys.cxx
@@ -703,6 +703,17 @@ void SbiStream::ExpandFile()
     }
 }
 
+namespace
+{
+    void WriteLines(SvStream &rStream, const ByteString& rStr)
+    {
+        ByteString aStr( rStr );
+        aStr.ConvertLineEnd( rStream.GetLineDelimiter() );
+        rStream.Write( aStr.GetBuffer(), aStr.Len() );
+        endl( rStream );
+    }
+}
+
 SbError SbiStream::Write( const ByteString& rBuf, sal_uInt16 n )
 {
     ExpandFile();
@@ -720,7 +731,7 @@ SbError SbiStream::Write( const ByteString& rBuf, sal_uInt16 n )
             aLine.Erase( nLineLen );
             if( nLineLen && aLine.GetBuffer()[ --nLineLen ] == 0x0D )
                 aLine.Erase( nLineLen );
-            pStrm->WriteLines( aLine );
+            WriteLines(*pStrm, aLine);
             aLine.Erase();
         }
     }
diff --git a/tools/inc/tools/stream.hxx b/tools/inc/tools/stream.hxx
index 9fcb729..d63b7d3 100644
--- a/tools/inc/tools/stream.hxx
+++ b/tools/inc/tools/stream.hxx
@@ -383,7 +383,6 @@ public:
     sal_Bool        ReadLine( ByteString& rStr );
     sal_Bool        ReadLine( rtl::OString& rStr );
     sal_Bool        WriteLine( const rtl::OString& rStr );
-    sal_Bool        WriteLines( const ByteString& rStr );
 
     sal_Bool        ReadByteStringLine( String& rStr, rtl_TextEncoding eSrcCharSet );
     sal_Bool        WriteByteStringLine( const String& rStr, rtl_TextEncoding eDestCharSet );
diff --git a/tools/source/stream/stream.cxx b/tools/source/stream/stream.cxx
index 0e89905..db84400 100644
--- a/tools/source/stream/stream.cxx
+++ b/tools/source/stream/stream.cxx
@@ -932,21 +932,6 @@ sal_Bool SvStream::WriteLine(const rtl::OString& rStr)
 
 /*************************************************************************
 |*
-|*    Stream::WriteLines()
-|*
-*************************************************************************/
-
-sal_Bool SvStream::WriteLines( const ByteString& rStr )
-{
-    ByteString aStr( rStr );
-    aStr.ConvertLineEnd( eLineDelimiter );
-    Write( aStr.GetBuffer(), aStr.Len() );
-    endl( *this );
-    return (sal_Bool)(nError == SVSTREAM_OK);
-}
-
-/*************************************************************************
-|*
 |*    Stream::WriteUniOrByteChar()
 |*
 *************************************************************************/
commit 0c5ed3541bd857060b046dace291bb7e971dcc73
Author: Caolán McNamara <caolanm at redhat.com>
Date:   Tue Jan 24 21:20:24 2012 +0000

    String->rtl::OUString

diff --git a/starmath/inc/dialog.hxx b/starmath/inc/dialog.hxx
index 316d1fb..41f6b70 100644
--- a/starmath/inc/dialog.hxx
+++ b/starmath/inc/dialog.hxx
@@ -199,8 +199,8 @@ public:
 
 class SmCategoryDesc : public Resource
 {
-    XubString       Name;
-    XubString      *Strings[4];
+    rtl::OUString   Name;
+    rtl::OUString  *Strings[4];
     Bitmap         *Graphics[4];    /* regular bitmaps */
     sal_uInt16          Minimum[4];
     sal_uInt16          Maximum[4];
@@ -210,8 +210,8 @@ public:
     SmCategoryDesc(const ResId &rResId, sal_uInt16 nCategoryIdx);
     ~SmCategoryDesc();
 
-    const XubString &   GetName() const                 { return Name; }
-    const XubString *   GetString(sal_uInt16 Index) const   { return Strings[Index];  }
+    const rtl::OUString& GetName() const                 { return Name; }
+    const rtl::OUString* GetString(sal_uInt16 Index) const   { return Strings[Index];  }
     sal_uInt16          GetMinimum(sal_uInt16 Index)        { return Minimum[Index]; }
     sal_uInt16          GetMaximum(sal_uInt16 Index)        { return Maximum[Index]; }
     sal_uInt16          GetValue(sal_uInt16 Index) const    { return Value[Index]; }
diff --git a/starmath/source/dialog.cxx b/starmath/source/dialog.cxx
index c46dbc2..bc9037b 100644
--- a/starmath/source/dialog.cxx
+++ b/starmath/source/dialog.cxx
@@ -672,7 +672,7 @@ SmCategoryDesc::SmCategoryDesc(const ResId& rResId, sal_uInt16 nCategoryIdx) :
 
             if (IsAvailableRes(ResId(nI2,*rResId.GetResMgr()).SetRT(RSC_STRING)))
             {
-                Strings  [i] = new XubString(ResId(nI2,*rResId.GetResMgr()));
+                Strings  [i] = new rtl::OUString(ResId::toString(ResId(nI2,*rResId.GetResMgr())));
                 Graphics [i] = new Bitmap(ResId(10*nI2,*rResId.GetResMgr()));
             }
             else
commit 1d4e0d9ec5b3781f8ab778e3e1630db3c2c39c4b
Author: Caolán McNamara <caolanm at redhat.com>
Date:   Tue Jan 24 21:11:49 2012 +0000

    reduce unnecessary includes

diff --git a/desktop/source/deployment/gui/dp_gui_updatedialog.cxx b/desktop/source/deployment/gui/dp_gui_updatedialog.cxx
index a5d9ab3..f81a92f 100644
--- a/desktop/source/deployment/gui/dp_gui_updatedialog.cxx
+++ b/desktop/source/deployment/gui/dp_gui_updatedialog.cxx
@@ -97,7 +97,6 @@
 #include "tools/link.hxx"
 #include "tools/resid.hxx"
 #include "tools/solar.h"
-#include "tools/string.hxx"
 #include "unotools/configmgr.hxx"
 #include "vcl/button.hxx"
 #include "vcl/dialog.hxx"
@@ -533,18 +532,18 @@ UpdateDialog::UpdateDialog(
     m_help(this, DpGuiResId(RID_DLG_UPDATE_HELP)),
     m_ok(this, DpGuiResId(RID_DLG_UPDATE_OK)),
     m_close(this, DpGuiResId(RID_DLG_UPDATE_CLOSE)),
-    m_error(String(DpGuiResId(RID_DLG_UPDATE_ERROR))),
-    m_none(String(DpGuiResId(RID_DLG_UPDATE_NONE))),
-    m_noInstallable(String(DpGuiResId(RID_DLG_UPDATE_NOINSTALLABLE))),
-    m_failure(String(DpGuiResId(RID_DLG_UPDATE_FAILURE))),
-    m_unknownError(String(DpGuiResId(RID_DLG_UPDATE_UNKNOWNERROR))),
-    m_noDescription(String(DpGuiResId(RID_DLG_UPDATE_NODESCRIPTION))),
-    m_noInstall(String(DpGuiResId(RID_DLG_UPDATE_NOINSTALL))),
-    m_noDependency(String(DpGuiResId(RID_DLG_UPDATE_NODEPENDENCY))),
-    m_noDependencyCurVer(String(DpGuiResId(RID_DLG_UPDATE_NODEPENDENCY_CUR_VER))),
-    m_browserbased(String(DpGuiResId(RID_DLG_UPDATE_BROWSERBASED))),
-    m_version(String(DpGuiResId(RID_DLG_UPDATE_VERSION))),
-    m_ignoredUpdate(String(DpGuiResId(RID_DLG_UPDATE_IGNORED_UPDATE))),
+    m_error(ResId::toString(DpGuiResId(RID_DLG_UPDATE_ERROR))),
+    m_none(ResId::toString(DpGuiResId(RID_DLG_UPDATE_NONE))),
+    m_noInstallable(ResId::toString(DpGuiResId(RID_DLG_UPDATE_NOINSTALLABLE))),
+    m_failure(ResId::toString(DpGuiResId(RID_DLG_UPDATE_FAILURE))),
+    m_unknownError(ResId::toString(DpGuiResId(RID_DLG_UPDATE_UNKNOWNERROR))),
+    m_noDescription(ResId::toString(DpGuiResId(RID_DLG_UPDATE_NODESCRIPTION))),
+    m_noInstall(ResId::toString(DpGuiResId(RID_DLG_UPDATE_NOINSTALL))),
+    m_noDependency(ResId::toString(DpGuiResId(RID_DLG_UPDATE_NODEPENDENCY))),
+    m_noDependencyCurVer(ResId::toString(DpGuiResId(RID_DLG_UPDATE_NODEPENDENCY_CUR_VER))),
+    m_browserbased(ResId::toString(DpGuiResId(RID_DLG_UPDATE_BROWSERBASED))),
+    m_version(ResId::toString(DpGuiResId(RID_DLG_UPDATE_VERSION))),
+    m_ignoredUpdate(ResId::toString(DpGuiResId(RID_DLG_UPDATE_IGNORED_UPDATE))),
     m_updateData(*updateData),
     m_thread(
         new UpdateDialog::Thread(
@@ -622,9 +621,9 @@ short UpdateDialog::Execute() {
 UpdateDialog::CheckListBox::CheckListBox( UpdateDialog & dialog, ResId const & resource,
                                           Image const & normalStaticImage ):
     SvxCheckListBox( &dialog, resource, normalStaticImage ),
-    m_ignoreUpdate( String( DpGuiResId( RID_DLG_UPDATE_IGNORE ) ) ),
-    m_ignoreAllUpdates( String( DpGuiResId( RID_DLG_UPDATE_IGNORE_ALL ) ) ),
-    m_enableUpdate( String( DpGuiResId( RID_DLG_UPDATE_ENABLE ) ) ),
+    m_ignoreUpdate( ResId::toString( DpGuiResId( RID_DLG_UPDATE_IGNORE ) ) ),
+    m_ignoreAllUpdates( ResId::toString( DpGuiResId( RID_DLG_UPDATE_IGNORE_ALL ) ) ),
+    m_enableUpdate( ResId::toString( DpGuiResId( RID_DLG_UPDATE_ENABLE ) ) ),
     m_dialog(dialog)
 {}
 
diff --git a/starmath/source/dialog.cxx b/starmath/source/dialog.cxx
index 23fd2de..c46dbc2 100644
--- a/starmath/source/dialog.cxx
+++ b/starmath/source/dialog.cxx
@@ -663,7 +663,7 @@ SmCategoryDesc::SmCategoryDesc(const ResId& rResId, sal_uInt16 nCategoryIdx) :
 {
     if (IsAvailableRes(ResId(1,*rResId.GetResMgr()).SetRT(RSC_STRING)))
     {
-        Name = XubString(ResId(1,*rResId.GetResMgr()));
+        Name = ResId::toString(ResId(1,*rResId.GetResMgr()));
 
         int i;
         for (i = 0; i < 4; i++)
@@ -1510,7 +1510,7 @@ SmSymbolDialog::SmSymbolDialog(Window *pParent, OutputDevice *pFntListDevice,
     if (bFreeRes)
         FreeResource();
 
-    aSymbolSetName = String();
+    aSymbolSetName = rtl::OUString();
     aSymbolSet.clear();
     FillSymbolSets();
     if (aSymbolSets.GetEntryCount() > 0)
@@ -1575,7 +1575,7 @@ bool SmSymbolDialog::SelectSymbolSet(const XubString &rSymbolSetName)
     bool    bRet = false;
     sal_uInt16  nPos = aSymbolSets.GetEntryPos(rSymbolSetName);
 
-    aSymbolSetName = String();
+    aSymbolSetName = rtl::OUString();
     aSymbolSet.clear();
     if (nPos != LISTBOX_ENTRY_NOTFOUND)
     {
@@ -1676,7 +1676,7 @@ void SmSymDefineDialog::FillSymbols(ComboBox &rComboBox, bool bDeleteText)
 
     rComboBox.Clear();
     if (bDeleteText)
-        rComboBox.SetText(XubString());
+        rComboBox.SetText(rtl::OUString());
 
     ComboBox &rBox = &rComboBox == &aOldSymbols ? aOldSymbolSets : aSymbolSets;
     SymbolPtrVec_t aSymSet( aSymbolMgrCopy.GetSymbolSet( rBox.GetText() ) );
@@ -1694,7 +1694,7 @@ void SmSymDefineDialog::FillSymbolSets(ComboBox &rComboBox, bool bDeleteText)
 
     rComboBox.Clear();
     if (bDeleteText)
-        rComboBox.SetText(XubString());
+        rComboBox.SetText(rtl::OUString());
 
     const std::set< String >  aSymbolSetNames( aSymbolMgrCopy.GetSymbolSetNames() );
     std::set< String >::const_iterator aIt( aSymbolSetNames.begin() );
@@ -1725,7 +1725,7 @@ void SmSymDefineDialog::FillStyles(bool bDeleteText)
 {
     aStyles.Clear();
     if (bDeleteText)
-        aStyles.SetText(XubString());
+        aStyles.SetText(rtl::OUString());
 
     XubString aText (aFonts.GetSelectEntry());
     if (aText.Len() != 0)
@@ -1933,7 +1933,7 @@ IMPL_LINK( SmSymDefineDialog, ChangeClickHdl, Button *, EMPTYARG pButton )
 
     // clear display for original symbol if necessary
     if (bNameChanged)
-        SetOrigSymbol(NULL, XubString());
+        SetOrigSymbol(NULL, rtl::OUString());
 
     // update display of new symbol
     aSymbolDisplay.SetSymbol( &aNewSymbol );
@@ -1965,7 +1965,7 @@ IMPL_LINK( SmSymDefineDialog, DeleteClickHdl, Button *, EMPTYARG pButton )
         aSymbolMgrCopy.RemoveSymbol( pOrigSymbol->GetName() );
 
         // clear display for original symbol
-        SetOrigSymbol(NULL, XubString());
+        SetOrigSymbol(NULL, rtl::OUString());
 
         // update list box entries
         FillSymbolSets(aOldSymbolSets, false);
@@ -2200,7 +2200,7 @@ bool SmSymDefineDialog::SelectSymbolSet(ComboBox &rComboBox,
         bRet = true;
     }
     else if (bDeleteText)
-        rComboBox.SetText(XubString());
+        rComboBox.SetText(rtl::OUString());
 
     bool  bIsOld = &rComboBox == &aOldSymbolSets;
 
@@ -2249,7 +2249,7 @@ void SmSymDefineDialog::SetOrigSymbol(const SmSym *pSymbol,
     }
     else
     {   // loeschen des angezeigten Symbols
-        aOldSymbolDisplay.SetText(XubString());
+        aOldSymbolDisplay.SetText(rtl::OUString());
         aOldSymbolDisplay.Invalidate();
     }
     aOldSymbolName   .SetText(aSymName);
@@ -2308,7 +2308,7 @@ bool SmSymDefineDialog::SelectSymbol(ComboBox &rComboBox,
         bRet = true;
     }
     else if (bDeleteText)
-        rComboBox.SetText(XubString());
+        rComboBox.SetText(rtl::OUString());
 
     if (bIsOld)
     {
@@ -2417,7 +2417,7 @@ bool SmSymDefineDialog::SelectStyle(const XubString &rStyleName, bool bApplyFont
         bRet = sal_True;
     }
     else
-        aStyles.SetText(XubString());
+        aStyles.SetText(rtl::OUString());
 
     UpdateButtons();
 
diff --git a/vcl/unx/gtk/fpicker/SalGtkFilePicker.cxx b/vcl/unx/gtk/fpicker/SalGtkFilePicker.cxx
index 9483bd3..27a8dc1 100644
--- a/vcl/unx/gtk/fpicker/SalGtkFilePicker.cxx
+++ b/vcl/unx/gtk/fpicker/SalGtkFilePicker.cxx
@@ -49,7 +49,6 @@
 
 #include <vcl/svapp.hxx>
 
-#include <tools/string.hxx>
 #include <tools/urlobj.hxx>
 
 #include <algorithm>


More information about the Libreoffice-commits mailing list