[Libreoffice-commits] .: 13 commits - accessibility/source canvas/source chart2/source connectivity/source cppcanvas/source desktop/source editeng/source extensions/source forms/source fpicker/source oox/source padmin/source sd/source starmath/source stoc/source svl/inc svtools/inc svtools/source svtools/workben svx/inc svx/source sw/inc sw/qa sw/source toolkit/source tools/inc tools/source unotools/source unusedcode.easy unusedcode.README uui/source xmloff/inc xmloff/source
Caolán McNamara
caolan at kemper.freedesktop.org
Thu Apr 5 05:59:53 PDT 2012
accessibility/source/extended/accessibleeditbrowseboxcell.cxx | 14 -
canvas/source/cairo/cairo_devicehelper.cxx | 8
canvas/source/vcl/devicehelper.cxx | 8
canvas/source/vcl/spritedevicehelper.cxx | 8
chart2/source/controller/dialogs/DataBrowser.cxx | 2
chart2/source/controller/dialogs/tp_3D_SceneIllumination.cxx | 18 -
chart2/source/controller/dialogs/tp_DataSource.cxx | 2
chart2/source/controller/main/DragMethod_PieSegment.cxx | 4
connectivity/source/drivers/mozab/MPreparedStatement.cxx | 7
connectivity/source/drivers/mozab/MPreparedStatement.hxx | 3
cppcanvas/source/mtfrenderer/transparencygroupaction.cxx | 62 ------
desktop/source/app/app.cxx | 53 ++---
editeng/source/editeng/editdoc.cxx | 10
editeng/source/editeng/editdoc.hxx | 3
editeng/source/items/svxfont.cxx | 3
extensions/source/bibliography/general.cxx | 4
extensions/source/dbpilots/groupboxwiz.cxx | 2
extensions/source/propctrlr/newdatatype.cxx | 2
forms/source/solar/component/navbarcontrol.cxx | 2
fpicker/source/office/PlacesListBox.cxx | 4
fpicker/source/office/PlacesListBox.hxx | 1
fpicker/source/office/iodlg.cxx | 35 ---
fpicker/source/office/iodlgimp.cxx | 78 -------
fpicker/source/office/iodlgimp.hxx | 18 -
oox/source/ole/olehelper.cxx | 2
padmin/source/adddlg.cxx | 4
sd/source/ui/slidesorter/view/SlsInsertAnimator.cxx | 30 --
starmath/source/cfgitem.cxx | 20 -
starmath/source/cfgitem.hxx | 2
stoc/source/inspect/introspection.cxx | 82 ++++----
svl/inc/svl/zformat.hxx | 12 -
svtools/inc/svtools/calendar.hxx | 1
svtools/source/brwbox/datwin.cxx | 4
svtools/source/control/calendar.cxx | 13 -
svtools/workben/svdem.cxx | 18 -
svx/inc/svx/svdotable.hxx | 2
svx/source/form/fmdmod.cxx | 2
svx/source/form/fmdpage.cxx | 2
svx/source/form/fmobj.cxx | 12 -
svx/source/form/fmobjfac.cxx | 4
svx/source/inc/fmobj.hxx | 9
svx/source/svdraw/svdopath.cxx | 2
svx/source/table/cell.cxx | 10
svx/source/table/cell.hxx | 1
svx/source/table/svdotable.cxx | 14 -
sw/inc/docstat.hxx | 1
sw/inc/ndtxt.hxx | 2
sw/qa/core/swdoc-test.cxx | 54 ++++-
sw/source/core/doc/docstat.cxx | 2
sw/source/core/txtnode/txtedt.cxx | 76 +++++++
sw/source/ui/dialog/wordcountdialog.cxx | 2
toolkit/source/awt/vclxaccessiblecomponent.cxx | 6
toolkit/source/controls/stdtabcontroller.cxx | 34 ---
toolkit/source/controls/unocontrolmodel.cxx | 7
tools/inc/tools/stream.hxx | 2
tools/source/stream/stream.cxx | 8
unotools/source/config/securityoptions.cxx | 4
unotools/source/i18n/localedatawrapper.cxx | 19 -
unusedcode.README | 41 ++++
unusedcode.easy | 102 +++++++---
uui/source/iahndl.cxx | 2
xmloff/inc/txtflde.hxx | 6
xmloff/source/style/xmlnumfi.cxx | 4
xmloff/source/text/XMLPropertyBackpatcher.cxx | 41 ----
xmloff/source/text/XMLPropertyBackpatcher.hxx | 15 -
xmloff/source/text/txtflde.cxx | 15 -
66 files changed, 407 insertions(+), 633 deletions(-)
New commits:
commit 47bc24a6bf5074c59d2f2a6bef79e5e70c842889
Author: Caolán McNamara <caolanm at redhat.com>
Date: Thu Apr 5 13:09:24 2012 +0100
Resolves: fdo#47068 use of pointer to deleted object
diff --git a/stoc/source/inspect/introspection.cxx b/stoc/source/inspect/introspection.cxx
index a1f239f..1b57eb7 100644
--- a/stoc/source/inspect/introspection.cxx
+++ b/stoc/source/inspect/introspection.cxx
@@ -712,9 +712,6 @@ class ImplIntrospectionAdapter :
public XEnumerationAccess, public XIdlArray,
public OWeakObject
{
- // Parent-Objekt
- ImplIntrospectionAccess* mpAccess;
-
// Untersuchtes Objekt
const Any& mrInspectedObject;
@@ -734,8 +731,7 @@ class ImplIntrospectionAdapter :
Reference<XIdlArray> mxObjIdlArray;
public:
- ImplIntrospectionAdapter( ImplIntrospectionAccess* pAccess_,
- const Any& obj,
+ ImplIntrospectionAdapter( const Any& obj,
rtl::Reference< IntrospectionAccessStatic_Impl > const & pStaticImpl_ );
// Methoden von XInterface
@@ -813,10 +809,9 @@ public:
throw( IllegalArgumentException, ArrayIndexOutOfBoundsException, RuntimeException );
};
-ImplIntrospectionAdapter::ImplIntrospectionAdapter( ImplIntrospectionAccess* pAccess_,
- const Any& obj,
+ImplIntrospectionAdapter::ImplIntrospectionAdapter(const Any& obj,
rtl::Reference< IntrospectionAccessStatic_Impl > const & pStaticImpl_ )
- : mpAccess( pAccess_), mrInspectedObject( obj ), mpStaticImpl( pStaticImpl_ )
+ : mrInspectedObject( obj ), mpStaticImpl( pStaticImpl_ )
{
// Objekt als Interfaceholen
TypeClass eType = mrInspectedObject.getValueType().getTypeClass();
@@ -1035,16 +1030,54 @@ Sequence< Property > ImplIntrospectionAdapter::getProperties(void) throw( Runtim
return mpStaticImpl->getProperties();
}
+namespace
+{
+ Property getPropertyImpl(IntrospectionAccessStatic_Impl *pStaticImpl, const OUString& Name, sal_Int32 PropertyConcepts)
+ throw( NoSuchElementException, RuntimeException )
+ {
+ Property aRet;
+ sal_Int32 i = pStaticImpl->getPropertyIndex( Name );
+ sal_Bool bFound = sal_False;
+ if( i != -1 )
+ {
+ sal_Int32 nConcept = pStaticImpl->getPropertyConcepts().getConstArray()[ i ];
+ if( (PropertyConcepts & nConcept) != 0 )
+ {
+ const Property* pProps = pStaticImpl->getProperties().getConstArray();
+ aRet = pProps[ i ];
+ bFound = sal_True;
+ }
+ }
+ if( !bFound )
+ throw NoSuchElementException() ;
+ return aRet;
+ }
+
+ sal_Bool hasPropertyImpl(IntrospectionAccessStatic_Impl *pStaticImpl, const OUString& Name, sal_Int32 PropertyConcepts)
+ throw( RuntimeException )
+ {
+ sal_Int32 i = pStaticImpl->getPropertyIndex( Name );
+ sal_Bool bRet = sal_False;
+ if( i != -1 )
+ {
+ sal_Int32 nConcept = pStaticImpl->getPropertyConcepts().getConstArray()[ i ];
+ if( (PropertyConcepts & nConcept) != 0 )
+ bRet = sal_True;
+ }
+ return bRet;
+ }
+}
+
Property ImplIntrospectionAdapter::getPropertyByName(const OUString& Name)
throw( RuntimeException )
{
- return mpAccess->getProperty( Name, PropertyConcept::ALL );
+ return getPropertyImpl(mpStaticImpl.get(), Name, PropertyConcept::ALL);
}
sal_Bool ImplIntrospectionAdapter::hasPropertyByName(const OUString& Name)
throw( RuntimeException )
{
- return mpAccess->hasProperty( Name, PropertyConcept::ALL );
+ return hasPropertyImpl(mpStaticImpl.get(), Name, PropertyConcept::ALL);
}
// Methoden von XElementAccess
@@ -1189,36 +1222,13 @@ sal_Int32 ImplIntrospectionAccess::getSuppliedPropertyConcepts(void)
Property ImplIntrospectionAccess::getProperty(const OUString& Name, sal_Int32 PropertyConcepts)
throw( NoSuchElementException, RuntimeException )
{
- Property aRet;
- sal_Int32 i = mpStaticImpl->getPropertyIndex( Name );
- sal_Bool bFound = sal_False;
- if( i != -1 )
- {
- sal_Int32 nConcept = mpStaticImpl->getPropertyConcepts().getConstArray()[ i ];
- if( (PropertyConcepts & nConcept) != 0 )
- {
- const Property* pProps = mpStaticImpl->getProperties().getConstArray();
- aRet = pProps[ i ];
- bFound = sal_True;
- }
- }
- if( !bFound )
- throw NoSuchElementException() ;
- return aRet;
+ return getPropertyImpl(mpStaticImpl.get(), Name, PropertyConcepts);
}
sal_Bool ImplIntrospectionAccess::hasProperty(const OUString& Name, sal_Int32 PropertyConcepts)
throw( RuntimeException )
{
- sal_Int32 i = mpStaticImpl->getPropertyIndex( Name );
- sal_Bool bRet = sal_False;
- if( i != -1 )
- {
- sal_Int32 nConcept = mpStaticImpl->getPropertyConcepts().getConstArray()[ i ];
- if( (PropertyConcepts & nConcept) != 0 )
- bRet = sal_True;
- }
- return bRet;
+ return hasPropertyImpl(mpStaticImpl.get(), Name, PropertyConcepts);
}
Sequence< Property > ImplIntrospectionAccess::getProperties(sal_Int32 PropertyConcepts)
@@ -1405,7 +1415,7 @@ Reference<XInterface> SAL_CALL ImplIntrospectionAccess::queryAdapter( const Type
if( !mpAdapter.is() )
{
((ImplIntrospectionAccess*)this)->mpAdapter =
- new ImplIntrospectionAdapter( this, maInspectedObject, mpStaticImpl );
+ new ImplIntrospectionAdapter( maInspectedObject, mpStaticImpl );
}
Reference<XInterface> xRet;
commit 01028864214a1b1ee6bf3f00fca142baf7b1d40c
Author: Caolán McNamara <caolanm at redhat.com>
Date: Thu Apr 5 11:09:35 2012 +0100
Resolves: fdo#45271, i#17964 count CJK words the way that's expected by users
diff --git a/sw/inc/docstat.hxx b/sw/inc/docstat.hxx
index 554d506..1869120 100644
--- a/sw/inc/docstat.hxx
+++ b/sw/inc/docstat.hxx
@@ -43,6 +43,7 @@ struct SW_DLLPUBLIC SwDocStat
/// all paragraphs, including empty/hidden ones
sal_uLong nAllPara;
sal_uLong nWord;
+ sal_uLong nAsianWord;
sal_uLong nChar;
sal_uLong nCharExcludingSpaces;
sal_Bool bModified;
diff --git a/sw/inc/ndtxt.hxx b/sw/inc/ndtxt.hxx
index 21e9fb4..83b3e2f 100644
--- a/sw/inc/ndtxt.hxx
+++ b/sw/inc/ndtxt.hxx
@@ -173,6 +173,8 @@ class SW_DLLPUBLIC SwTxtNode: public SwCntntNode, public ::sfx2::Metadatable
//
SW_DLLPRIVATE void SetParaNumberOfWords( sal_uLong nTmpWords ) const;
SW_DLLPRIVATE sal_uLong GetParaNumberOfWords() const;
+ SW_DLLPRIVATE void SetParaNumberOfAsianWords( sal_uLong nTmpAsianWords ) const;
+ SW_DLLPRIVATE sal_uLong GetParaNumberOfAsianWords() const;
SW_DLLPRIVATE void SetParaNumberOfChars( sal_uLong nTmpChars ) const;
SW_DLLPRIVATE sal_uLong GetParaNumberOfChars() const;
SW_DLLPRIVATE void SetParaNumberOfCharsExcludingSpaces( sal_uLong nTmpChars ) const;
diff --git a/sw/qa/core/swdoc-test.cxx b/sw/qa/core/swdoc-test.cxx
index 72c5ad3..8469c0d 100644
--- a/sw/qa/core/swdoc-test.cxx
+++ b/sw/qa/core/swdoc-test.cxx
@@ -113,7 +113,7 @@ void SwDocTest::testPageDescName()
CPPUNIT_ASSERT_MESSAGE("GetPageDescName results must be unique", aResults.size() == 3);
}
-//See https://bugs.freedesktop.org/show_bug.cgi?id=32463 for motivation
+//See https://bugs.freedesktop.org/show_bug.cgi?id=32463
void SwDocTest::testFileNameFields()
{
//Here's a file name with some chars in it that will be %% encoded, when expanding
@@ -225,8 +225,8 @@ void SwDocTest::testSwScanner()
CPPUNIT_ASSERT_MESSAGE("Has Text Node", pTxtNode);
- //See https://bugs.freedesktop.org/show_bug.cgi?id=40449 for motivation
- //See https://bugs.freedesktop.org/show_bug.cgi?id=39365 for motivation
+ //See https://bugs.freedesktop.org/show_bug.cgi?id=40449
+ //See https://bugs.freedesktop.org/show_bug.cgi?id=39365
//Use a temporary rtl::OUString as the arg, as that's the trouble behind
//fdo#40449 and fdo#39365
{
@@ -248,7 +248,7 @@ void SwDocTest::testSwScanner()
rWorld.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("World")));
}
- //See https://www.libreoffice.org/bugzilla/show_bug.cgi?id=45271 for motivation
+ //See https://www.libreoffice.org/bugzilla/show_bug.cgi?id=45271
{
const sal_Unicode IDEOGRAPHICFULLSTOP_D[] = { 0x3002, 'D' };
@@ -261,13 +261,51 @@ void SwDocTest::testSwScanner()
m_pDoc->InsertPoolItem(aPaM, aWestLangItem, 0 );
SwDocStat aDocStat;
+ pTxtNode = aPaM.GetNode()->GetTxtNode();
pTxtNode->CountWords(aDocStat, 0, SAL_N_ELEMENTS(IDEOGRAPHICFULLSTOP_D));
CPPUNIT_ASSERT_MESSAGE("Should be 2", aDocStat.nChar == 2);
CPPUNIT_ASSERT_MESSAGE("Should be 2", aDocStat.nCharExcludingSpaces == 2);
}
+ {
+ const sal_Unicode test[] =
+ {
+ 0x3053, 0x306E, 0x65E5, 0x672C, 0x8A9E, 0x306F, 0x6B63, 0x3057,
+ 0x304F, 0x6570, 0x3048, 0x3089, 0x308C, 0x308B, 0x3067, 0x3057,
+ 0x3087, 0x3046, 0x304B, 0x3002, 0x0041, 0x006E, 0x0064, 0x0020,
+ 0x006C, 0x0065, 0x0074, 0x0027, 0x0073, 0x0020, 0x0074, 0x0068,
+ 0x0072, 0x006F, 0x0077, 0x0020, 0x0073, 0x006F, 0x006D, 0x0065,
+ 0x0020, 0x0045, 0x006E, 0x0067, 0x006C, 0x0069, 0x0073, 0x0068,
+ 0x0020, 0x0069, 0x006E, 0x0020, 0x0074, 0x006F, 0x0020, 0x006D,
+ 0x0061, 0x006B, 0x0065, 0x0020, 0x0069, 0x0074, 0x0020, 0x0069,
+ 0x006E, 0x0074, 0x0065, 0x0072, 0x0065, 0x0073, 0x0074, 0x0069,
+ 0x006E, 0x0067, 0x002E, 0x0020, 0x0020, 0x305D, 0x3057, 0x3066,
+ 0x3001, 0x307E, 0x305F, 0x65E5, 0x672C, 0x8A9E, 0x3000, 0x3000,
+ 0x3067, 0x3082, 0x4ECA, 0x56DE, 0x306F, 0x7A7A, 0x767D, 0x3092,
+ 0x3000, 0x3000, 0x5165, 0x308C, 0x307E, 0x3057, 0x305F, 0x3002,
+ 0x0020, 0x0020, 0x0053, 0x006F, 0x0020, 0x0068, 0x006F, 0x0077,
+ 0x0020, 0x0064, 0x006F, 0x0065, 0x0073, 0x0020, 0x0074, 0x0068,
+ 0x0069, 0x0073, 0x0020, 0x0064, 0x006F, 0x003F, 0x0020, 0x0020
+ };
+ m_pDoc->AppendTxtNode(*aPaM.GetPoint());
+ m_pDoc->InsertString(aPaM, rtl::OUString(test,
+ SAL_N_ELEMENTS(test)));
+
+ SvxLanguageItem aCJKLangItem( LANGUAGE_JAPANESE, RES_CHRATR_CJK_LANGUAGE );
+ SvxLanguageItem aWestLangItem( LANGUAGE_ENGLISH_US, RES_CHRATR_LANGUAGE );
+ m_pDoc->InsertPoolItem(aPaM, aCJKLangItem, 0 );
+ m_pDoc->InsertPoolItem(aPaM, aWestLangItem, 0 );
+
+ SwDocStat aDocStat;
+ pTxtNode = aPaM.GetNode()->GetTxtNode();
+ pTxtNode->CountWords(aDocStat, 0, SAL_N_ELEMENTS(test));
+ CPPUNIT_ASSERT_MESSAGE("58 words", aDocStat.nWord == 58);
+ CPPUNIT_ASSERT_MESSAGE("43 Asian characters and Korean syllables", aDocStat.nAsianWord == 43);
+ CPPUNIT_ASSERT_MESSAGE("105 non-whitespace chars", aDocStat.nCharExcludingSpaces == 105);
+ CPPUNIT_ASSERT_MESSAGE("128 characters", aDocStat.nChar == 128);
+ }
- //See https://issues.apache.org/ooo/show_bug.cgi?id=89042 for motivation
+ //See https://issues.apache.org/ooo/show_bug.cgi?id=89042
{
SwDocStat aDocStat;
@@ -298,8 +336,7 @@ void SwDocTest::testSwScanner()
}
}
-
-//See https://bugs.freedesktop.org/show_bug.cgi?id=40599 for motivation
+//See https://bugs.freedesktop.org/show_bug.cgi?id=40599
void SwDocTest::testGraphicAnchorDeletion()
{
CPPUNIT_ASSERT_MESSAGE("Expected initial 0 count", m_pDoc->GetDocStat().nChar == 0);
diff --git a/sw/source/core/doc/docstat.cxx b/sw/source/core/doc/docstat.cxx
index c84f943..fd0c6e6 100644
--- a/sw/source/core/doc/docstat.cxx
+++ b/sw/source/core/doc/docstat.cxx
@@ -43,6 +43,7 @@ SwDocStat::SwDocStat() :
nPara(1),
nAllPara(1),
nWord(0),
+ nAsianWord(0),
nChar(0),
nCharExcludingSpaces(0),
bModified(sal_True)
@@ -61,6 +62,7 @@ void SwDocStat::Reset()
nPara = 1;
nAllPara= 1;
nWord = 0;
+ nAsianWord = 0;
nChar = 0;
nCharExcludingSpaces = 0;
bModified = sal_True;
diff --git a/sw/source/core/txtnode/txtedt.cxx b/sw/source/core/txtnode/txtedt.cxx
index a186cc6..cb5e472 100644
--- a/sw/source/core/txtnode/txtedt.cxx
+++ b/sw/source/core/txtnode/txtedt.cxx
@@ -680,6 +680,44 @@ SwScanner::SwScanner( const SwTxtNode& rNd, const rtl::OUString& rTxt,
}
}
+namespace
+{
+ //fdo#45271 for Asian words count characters instead of words
+ sal_Int32 forceEachAsianCodePointToWord(const rtl::OUString &rText, sal_Int32 nBegin, sal_Int32 nLen)
+ {
+ if (nLen > 1)
+ {
+ const uno::Reference< XBreakIterator > &rxBreak = pBreakIt->GetBreakIter();
+
+ sal_uInt16 nCurrScript = rxBreak->getScriptType( rText, nBegin );
+
+ sal_Int32 indexUtf16 = nBegin;
+ rText.iterateCodePoints(&indexUtf16, 1);
+
+ //First character is Asian, consider it a word :-(
+ if (nCurrScript == i18n::ScriptType::ASIAN)
+ {
+ nLen = indexUtf16 - nBegin;
+ return nLen;
+ }
+
+ //First character was not Asian, consider appearance of any Asian character
+ //to be the end of the word
+ while (indexUtf16 < nBegin + nLen)
+ {
+ nCurrScript = rxBreak->getScriptType( rText, indexUtf16 );
+ if (nCurrScript == i18n::ScriptType::ASIAN)
+ {
+ nLen = indexUtf16 - nBegin;
+ return nLen;
+ }
+ rText.iterateCodePoints(&indexUtf16, 1);
+ }
+ }
+ return nLen;
+ }
+}
+
sal_Bool SwScanner::NextWord()
{
nBegin = nBegin + nLen;
@@ -802,6 +840,9 @@ sal_Bool SwScanner::NextWord()
if( ! nLen )
return sal_False;
+ if ( nWordType == i18n::WordType::WORD_COUNT )
+ nLen = forceEachAsianCodePointToWord(aText, nBegin, nLen);
+
aWord = aText.copy( nBegin, nLen );
return sal_True;
@@ -1812,6 +1853,7 @@ void SwTxtNode::CountWords( SwDocStat& rStat,
{
// accumulate into DocStat record to return the values
rStat.nWord += GetParaNumberOfWords();
+ rStat.nAsianWord += GetParaNumberOfAsianWords();
rStat.nChar += GetParaNumberOfChars();
rStat.nCharExcludingSpaces += GetParaNumberOfCharsExcludingSpaces();
return;
@@ -1842,7 +1884,8 @@ void SwTxtNode::CountWords( SwDocStat& rStat,
// all counts exclude hidden paras and hidden+redlined within para
// definition of space/white chars in SwScanner (and BreakIter!)
// uses both lcl_IsSkippableWhiteSpace and BreakIter getWordBoundary in SwScanner
- sal_uInt32 nTmpWords = 0; // count of all contiguous blocks of non-white chars
+ sal_uInt32 nTmpWords = 0; // count of all words
+ sal_uInt32 nTmpAsianWords = 0; //count of all Asian codepoints
sal_uInt32 nTmpChars = 0; // count of all chars
sal_uInt32 nTmpCharsExcludingSpaces = 0; // all non-white chars
@@ -1862,7 +1905,10 @@ void SwTxtNode::CountWords( SwDocStat& rStat,
if( 1 != aExpandText.match(aBreakWord, aScanner.GetBegin() ))
{
++nTmpWords;
- nTmpCharsExcludingSpaces += pBreakIt->getGraphemeCount(aScanner.GetWord());
+ const rtl::OUString &rWord = aScanner.GetWord();
+ if (pBreakIt->GetBreakIter()->getScriptType(rWord, 0) == i18n::ScriptType::ASIAN)
+ ++nTmpAsianWords;
+ nTmpCharsExcludingSpaces += pBreakIt->getGraphemeCount(rWord);
}
}
}
@@ -1890,7 +1936,10 @@ void SwTxtNode::CountWords( SwDocStat& rStat,
while ( aScanner.NextWord() )
{
++nTmpWords;
- nTmpCharsExcludingSpaces += pBreakIt->getGraphemeCount(aScanner.GetWord());
+ const rtl::OUString &rWord = aScanner.GetWord();
+ if (pBreakIt->GetBreakIter()->getScriptType(rWord, 0) == i18n::ScriptType::ASIAN)
+ ++nTmpAsianWords;
+ nTmpCharsExcludingSpaces += pBreakIt->getGraphemeCount(rWord);
}
nTmpChars = pBreakIt->getGraphemeCount(aNumString);
@@ -1909,12 +1958,14 @@ void SwTxtNode::CountWords( SwDocStat& rStat,
if ( isCountAll )
{
SetParaNumberOfWords( nTmpWords );
+ SetParaNumberOfAsianWords( nTmpAsianWords );
SetParaNumberOfChars( nTmpChars );
SetParaNumberOfCharsExcludingSpaces( nTmpCharsExcludingSpaces );
SetWordCountDirty( false );
}
// accumulate into DocStat record to return the values
rStat.nWord += nTmpWords;
+ rStat.nAsianWord += nTmpAsianWords;
rStat.nChar += nTmpChars;
rStat.nCharExcludingSpaces += nTmpCharsExcludingSpaces;
}
@@ -1928,6 +1979,7 @@ struct SwParaIdleData_Impl
SwGrammarMarkUp* pGrammarCheck; // for grammar checking / proof reading
SwWrongList* pSmartTags;
sal_uLong nNumberOfWords;
+ sal_uLong nNumberOfAsianWords;
sal_uLong nNumberOfChars;
sal_uLong nNumberOfCharsExcludingSpaces;
bool bWordCountDirty;
@@ -1941,6 +1993,7 @@ struct SwParaIdleData_Impl
pGrammarCheck ( 0 ),
pSmartTags ( 0 ),
nNumberOfWords ( 0 ),
+ nNumberOfAsianWords ( 0 ),
nNumberOfChars ( 0 ),
nNumberOfCharsExcludingSpaces ( 0 ),
bWordCountDirty ( true ),
@@ -2033,10 +2086,25 @@ void SwTxtNode::SetParaNumberOfWords( sal_uLong nNew ) const
m_pParaIdleData_Impl->nNumberOfWords = nNew;
}
}
+
sal_uLong SwTxtNode::GetParaNumberOfWords() const
{
return m_pParaIdleData_Impl ? m_pParaIdleData_Impl->nNumberOfWords : 0;
}
+
+void SwTxtNode::SetParaNumberOfAsianWords( sal_uLong nNew ) const
+{
+ if ( m_pParaIdleData_Impl )
+ {
+ m_pParaIdleData_Impl->nNumberOfAsianWords = nNew;
+ }
+}
+
+sal_uLong SwTxtNode::GetParaNumberOfAsianWords() const
+{
+ return m_pParaIdleData_Impl ? m_pParaIdleData_Impl->nNumberOfAsianWords : 0;
+}
+
void SwTxtNode::SetParaNumberOfChars( sal_uLong nNew ) const
{
if ( m_pParaIdleData_Impl )
@@ -2044,10 +2112,12 @@ void SwTxtNode::SetParaNumberOfChars( sal_uLong nNew ) const
m_pParaIdleData_Impl->nNumberOfChars = nNew;
}
}
+
sal_uLong SwTxtNode::GetParaNumberOfChars() const
{
return m_pParaIdleData_Impl ? m_pParaIdleData_Impl->nNumberOfChars : 0;
}
+
void SwTxtNode::SetWordCountDirty( bool bNew ) const
{
if ( m_pParaIdleData_Impl )
diff --git a/sw/source/ui/dialog/wordcountdialog.cxx b/sw/source/ui/dialog/wordcountdialog.cxx
index 3fdc895..f5b1c3b 100644
--- a/sw/source/ui/dialog/wordcountdialog.cxx
+++ b/sw/source/ui/dialog/wordcountdialog.cxx
@@ -42,6 +42,8 @@
#include <swwait.hxx>
#include <wrtsh.hxx>
+//TODO, add asian/non-asian word count to UI when CJK mode is enabled.
+
SwWordCountDialog::SwWordCountDialog(Window* pParent) :
#if defined _MSC_VER
#pragma warning (disable : 4355)
commit 53600134ec737d50808c0f630b536229ad3310bb
Author: Caolán McNamara <caolanm at redhat.com>
Date: Thu Apr 5 08:38:09 2012 +0100
no use is made of FmFormObj::m_nType
diff --git a/connectivity/source/drivers/mozab/MPreparedStatement.cxx b/connectivity/source/drivers/mozab/MPreparedStatement.cxx
index bc19e36..c9b27e3 100644
--- a/connectivity/source/drivers/mozab/MPreparedStatement.cxx
+++ b/connectivity/source/drivers/mozab/MPreparedStatement.cxx
@@ -382,12 +382,7 @@ void OPreparedStatement::setFastPropertyValue_NoBroadcast(sal_Int32 nHandle,cons
OCommonStatement::setFastPropertyValue_NoBroadcast(nHandle,rValue);
}
}
-// -----------------------------------------------------------------------------
-void OPreparedStatement::checkParameterIndex(sal_Int32 _parameterIndex)
-{
- if( !_parameterIndex || _parameterIndex > m_nNumParams)
- ::dbtools::throwInvalidIndexException(*this);
-}
+
// -----------------------------------------------------------------------------
void OPreparedStatement::checkAndResizeParameters(sal_Int32 parameterIndex)
{
diff --git a/connectivity/source/drivers/mozab/MPreparedStatement.hxx b/connectivity/source/drivers/mozab/MPreparedStatement.hxx
index 2151b3d..eca24fd 100644
--- a/connectivity/source/drivers/mozab/MPreparedStatement.hxx
+++ b/connectivity/source/drivers/mozab/MPreparedStatement.hxx
@@ -78,9 +78,6 @@ namespace connectivity
::rtl::Reference<connectivity::OSQLColumns> m_xParamColumns; // the parameter columns
OValueRow m_aParameterRow;
-
- void checkParameterIndex(sal_Int32 _parameterIndex);
-
protected:
virtual void SAL_CALL setFastPropertyValue_NoBroadcast(sal_Int32 nHandle,
const ::com::sun::star::uno::Any& rValue)
diff --git a/editeng/source/editeng/editdoc.cxx b/editeng/source/editeng/editdoc.cxx
index c444950..f797d24 100644
--- a/editeng/source/editeng/editdoc.cxx
+++ b/editeng/source/editeng/editdoc.cxx
@@ -1154,16 +1154,6 @@ void EditPaM::SetNode(ContentNode* p)
pNode = p;
}
-bool EditPaM::IsParaStart() const
-{
- return nIndex == 0;
-}
-
-bool EditPaM::IsParaEnd() const
-{
- return nIndex == pNode->Len();
-}
-
sal_Bool EditPaM::DbgIsBuggy( EditDoc& rDoc )
{
if ( !pNode )
diff --git a/editeng/source/editeng/editdoc.hxx b/editeng/source/editeng/editdoc.hxx
index 8b70806..27c5b14 100644
--- a/editeng/source/editeng/editdoc.hxx
+++ b/editeng/source/editeng/editdoc.hxx
@@ -337,9 +337,6 @@ public:
sal_uInt16& GetIndex() { return nIndex; }
void SetIndex( sal_uInt16 n ) { nIndex = n; }
- bool IsParaStart() const;
- bool IsParaEnd() const;
-
sal_Bool DbgIsBuggy( EditDoc& rDoc );
EditPaM& operator = ( const EditPaM& rPaM );
diff --git a/svx/source/form/fmdmod.cxx b/svx/source/form/fmdmod.cxx
index fbc4b5a..86ee670 100644
--- a/svx/source/form/fmdmod.cxx
+++ b/svx/source/form/fmdmod.cxx
@@ -46,7 +46,7 @@ using namespace ::svxform;
}
else if ( ServiceSpecifier.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("com.sun.star.drawing.ControlShape")) )
{
- SdrObject* pObj = new FmFormObj(OBJ_FM_CONTROL);
+ SdrObject* pObj = new FmFormObj();
xRet = static_cast<cppu::OWeakObject*>(static_cast<SvxShape_UnoImplHelper*>(new SvxShapeControl(pObj)));
}
if (!xRet.is())
diff --git a/svx/source/form/fmdpage.cxx b/svx/source/form/fmdpage.cxx
index 450d85c..5b87919 100644
--- a/svx/source/form/fmdpage.cxx
+++ b/svx/source/form/fmdpage.cxx
@@ -97,7 +97,7 @@ SdrObject *SvxFmDrawPage::_CreateSdrObject( const ::com::sun::star::uno::Referen
if ( aShapeType.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "com.sun.star.drawing.ShapeControl" ) ) // compatibility
|| aShapeType.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "com.sun.star.drawing.ControlShape" ) )
)
- return new FmFormObj( OBJ_FM_CONTROL );
+ return new FmFormObj();
else
return SvxDrawPage::_CreateSdrObject( xDescr );
diff --git a/svx/source/form/fmobj.cxx b/svx/source/form/fmobj.cxx
index 1610bb1..c8e8689 100644
--- a/svx/source/form/fmobj.cxx
+++ b/svx/source/form/fmobj.cxx
@@ -69,10 +69,9 @@ using namespace ::svxform;
TYPEINIT1(FmFormObj, SdrUnoObj);
DBG_NAME(FmFormObj);
//------------------------------------------------------------------
-FmFormObj::FmFormObj(const ::rtl::OUString& rModelName,sal_Int32 _nType)
+FmFormObj::FmFormObj(const ::rtl::OUString& rModelName)
:SdrUnoObj ( rModelName )
,m_nPos ( -1 )
- ,m_nType ( _nType )
,m_pLastKnownRefDevice ( NULL )
{
DBG_CTOR(FmFormObj, NULL);
@@ -83,10 +82,9 @@ FmFormObj::FmFormObj(const ::rtl::OUString& rModelName,sal_Int32 _nType)
}
//------------------------------------------------------------------
-FmFormObj::FmFormObj( sal_Int32 _nType )
+FmFormObj::FmFormObj()
:SdrUnoObj ( String() )
,m_nPos ( -1 )
- ,m_nType ( _nType )
,m_pLastKnownRefDevice ( NULL )
{
DBG_CTOR(FmFormObj, NULL);
@@ -706,12 +704,6 @@ void FmFormObj::BrkCreate( SdrDragStat& rStat )
}
// -----------------------------------------------------------------------------
-sal_Int32 FmFormObj::getType() const
-{
- return m_nType;
-}
-
-// -----------------------------------------------------------------------------
// #i70852# overload Layer interface to force to FormColtrol layer
SdrLayerID FmFormObj::GetLayer() const
diff --git a/svx/source/form/fmobjfac.cxx b/svx/source/form/fmobjfac.cxx
index a2b6925..37afeec 100644
--- a/svx/source/form/fmobjfac.cxx
+++ b/svx/source/form/fmobjfac.cxx
@@ -237,9 +237,9 @@ IMPL_LINK(FmFormObjFactory, MakeObject, SdrObjFactory*, pObjFactory)
// create the actual object
if ( !sServiceSpecifier.isEmpty() )
- pObjFactory->pNewObj = new FmFormObj( sServiceSpecifier, pObjFactory->nIdentifier );
+ pObjFactory->pNewObj = new FmFormObj(sServiceSpecifier);
else
- pObjFactory->pNewObj = new FmFormObj( pObjFactory->nIdentifier );
+ pObjFactory->pNewObj = new FmFormObj();
// initialize some properties which we want to differ from the defaults
for ( PropertyValueArray::const_iterator aInitProp = aInitialProperties.begin();
diff --git a/svx/source/inc/fmobj.hxx b/svx/source/inc/fmobj.hxx
index 35297c2..b86b8ef 100644
--- a/svx/source/inc/fmobj.hxx
+++ b/svx/source/inc/fmobj.hxx
@@ -53,15 +53,14 @@ class FmFormObj: public SdrUnoObj
::com::sun::star::uno::Reference< ::com::sun::star::container::XIndexContainer> m_xParent;
::com::sun::star::uno::Reference< ::com::sun::star::container::XIndexContainer > m_xEnvironmentHistory;
sal_Int32 m_nPos;
- sal_Int32 m_nType;
OutputDevice* m_pLastKnownRefDevice;
// the last ref device we know, as set at the model
// only to be used for comparison with the current ref device!
public:
- SVX_DLLPUBLIC FmFormObj(const ::rtl::OUString& rModelName,sal_Int32 _nType);
- SVX_DLLPUBLIC FmFormObj(sal_Int32 _nType);
+ SVX_DLLPUBLIC FmFormObj(const ::rtl::OUString& rModelName);
+ SVX_DLLPUBLIC FmFormObj();
TYPEINFO();
@@ -105,10 +104,6 @@ public:
static FmFormObj* GetFormObject( SdrObject* _pSdrObject );
static const FmFormObj* GetFormObject( const SdrObject* _pSdrObject );
- /** returns the type of this form object. See fmglob.hxx
- */
- sal_Int32 getType() const;
-
virtual void SetUnoControlModel( const ::com::sun::star::uno::Reference< com::sun::star::awt::XControlModel >& _rxModel );
protected:
diff --git a/unusedcode.easy b/unusedcode.easy
index ed53d24..19586de 100755
--- a/unusedcode.easy
+++ b/unusedcode.easy
@@ -7,7 +7,6 @@ FmEntryDataArray::Insert(FmEntryData* const*, unsigned short)
FmEntryDataArray::Insert(FmEntryDataArray const*, unsigned short, unsigned short)
FmEntryDataArray::Remove(FmEntryData* const&, unsigned short)
FmFieldWinMgr::GetChildWindowId()
-FmFormObj::getType() const
FmPropBrwMgr::GetChildWindowId()
FontSelectPattern::FontSelectPattern(ImplFontData const&, Size const&, float, int, bool)
FontStyleBox::FontStyleBox(Window*, long)
@@ -326,13 +325,6 @@ XMLFontAutoStylePoolNames_Impl::Remove(rtl::OUString*)
XMLFontAutoStylePool_Impl::GetPos(XMLFontAutoStylePoolEntry_Impl const*) const
XMLFontAutoStylePool_Impl::Remove(XMLFontAutoStylePoolEntry_Impl*)
XMLParentNode::AddChild(XMLChildNode*, unsigned long)
-XMLPropertyBackpatcher<rtl::OUString>::XMLPropertyBackpatcher(char const*)
-XMLPropertyBackpatcher<rtl::OUString>::XMLPropertyBackpatcher(char const*, char const*, unsigned char, rtl::OUString)
-XMLPropertyBackpatcher<rtl::OUString>::XMLPropertyBackpatcher(rtl::OUString const&, rtl::OUString const&, unsigned char, rtl::OUString)
-XMLPropertyBackpatcher<short>::XMLPropertyBackpatcher(char const*)
-XMLPropertyBackpatcher<short>::XMLPropertyBackpatcher(char const*, char const*, unsigned char, short)
-XMLPropertyBackpatcher<short>::XMLPropertyBackpatcher(rtl::OUString const&, rtl::OUString const&, unsigned char, short)
-XMLTextFieldExport::ProcessDate(xmloff::token::XMLTokenEnum, com::sun::star::util::Date const&, unsigned short)
XMLTextListAutoStylePoolNames_Impl::GetPos(rtl::OUString const*) const
XMLTextListAutoStylePoolNames_Impl::Remove(rtl::OUString*)
XMLTextListAutoStylePool_Impl::GetPos(XMLTextListAutoStylePoolEntry_Impl const*) const
@@ -768,7 +760,6 @@ connectivity::mozab::MQueryHelper::hasMore() const
connectivity::mozab::MQueryHelper::next()
connectivity::mozab::MQueryHelper::rewind()
connectivity::mozab::OCatalog::getDot()
-connectivity::mozab::OPreparedStatement::checkParameterIndex(int)
connectivity::mozab::OResultSet::initializeRow(rtl::Reference<connectivity::ODeleteVector<connectivity::ORowSetValue> >&, int)
connectivity::mozab::OTable::OTable(connectivity::sdbcx::OCollection*, connectivity::mozab::OConnection*)
connectivity::sdbcx::OGroup::OGroup(rtl::OUString const&, unsigned char)
diff --git a/xmloff/inc/txtflde.hxx b/xmloff/inc/txtflde.hxx
index 2c94703..4aad9a6 100644
--- a/xmloff/inc/txtflde.hxx
+++ b/xmloff/inc/txtflde.hxx
@@ -377,12 +377,6 @@ protected:
sal_Bool bIsDate, /// export as date (rather than date/time)?
sal_uInt16 nPrefix = XML_NAMESPACE_TEXT); /// attribute name prefix
- /// export date according to ISO 8601
- void ProcessDate(
- enum ::xmloff::token::XMLTokenEnum eXMLName, /// attribute token
- const ::com::sun::star::util::Date& rTime, /// date value
- sal_uInt16 nPrefix = XML_NAMESPACE_TEXT); /// attribute name prefix
-
/// export all attributes for bibliography data fields
void ProcessBibliographyData(
const ::com::sun::star::uno::Reference <
diff --git a/xmloff/source/text/XMLPropertyBackpatcher.cxx b/xmloff/source/text/XMLPropertyBackpatcher.cxx
index 0d8beec..9e4f47d 100644
--- a/xmloff/source/text/XMLPropertyBackpatcher.cxx
+++ b/xmloff/source/text/XMLPropertyBackpatcher.cxx
@@ -53,47 +53,6 @@ XMLPropertyBackpatcher<A>::XMLPropertyBackpatcher(
{
}
-template<class A>
-XMLPropertyBackpatcher<A>::XMLPropertyBackpatcher(
- const OUString& sPropName,
- const OUString& sPreserveName,
- sal_Bool bDefault,
- A aDef)
-: sPropertyName(sPropName)
-, bDefaultHandling(bDefault)
-, bPreserveProperty(!sPreserveName.isEmpty())
-, sPreservePropertyName(sPreserveName)
-, aDefault(aDef)
-{
-}
-
-template<class A>
-XMLPropertyBackpatcher<A>::XMLPropertyBackpatcher(
- const sal_Char* pPropName)
-: bDefaultHandling(sal_False)
-, bPreserveProperty(sal_False)
-{
- DBG_ASSERT(pPropName != NULL, "need property name");
- sPropertyName = OUString::createFromAscii(pPropName);
-}
-
-template<class A>
-XMLPropertyBackpatcher<A>::XMLPropertyBackpatcher(
- const sal_Char* pPropName,
- const sal_Char* pPreservePropName,
- sal_Bool bDefault,
- A aDef)
-: bDefaultHandling(bDefault)
-, bPreserveProperty(pPreservePropName != NULL)
-, aDefault(aDef)
-{
- DBG_ASSERT(pPropName != NULL, "need property name");
- sPropertyName = OUString::createFromAscii(pPropName);
- if (pPreservePropName != NULL)
- {
- sPreservePropertyName = OUString::createFromAscii(pPreservePropName);
- }
-}
template<class A>
XMLPropertyBackpatcher<A>::~XMLPropertyBackpatcher()
diff --git a/xmloff/source/text/XMLPropertyBackpatcher.hxx b/xmloff/source/text/XMLPropertyBackpatcher.hxx
index 42f2009..872bf2d 100644
--- a/xmloff/source/text/XMLPropertyBackpatcher.hxx
+++ b/xmloff/source/text/XMLPropertyBackpatcher.hxx
@@ -105,21 +105,6 @@ public:
XMLPropertyBackpatcher(
const ::rtl::OUString& sPropertyName);
- XMLPropertyBackpatcher(
- const ::rtl::OUString& sPropertyName,
- const ::rtl::OUString& sPreservePropertyName,
- sal_Bool bDefault,
- A aDef);
-
- XMLPropertyBackpatcher(
- const sal_Char* pPropertyName);
-
- XMLPropertyBackpatcher(
- const sal_Char* pPropertyName,
- const sal_Char* pPreservePropertyName,
- sal_Bool bDefault,
- A aDef);
-
~XMLPropertyBackpatcher();
/// resolve a known ID.
diff --git a/xmloff/source/text/txtflde.cxx b/xmloff/source/text/txtflde.cxx
index cc8a399..410bb05 100644
--- a/xmloff/source/text/txtflde.cxx
+++ b/xmloff/source/text/txtflde.cxx
@@ -2656,21 +2656,6 @@ void XMLTextFieldExport::ProcessDateTime(enum XMLTokenEnum eName,
ProcessString(eName, aBuffer.makeStringAndClear(), sal_True, nPrefix);
}
-/// export date according to ISO 8601
-void XMLTextFieldExport::ProcessDate(
- enum XMLTokenEnum eName,
- const ::com::sun::star::util::Date& rDate,
- sal_uInt16 nPrefix)
-{
- // the easiest way: delegate to ProcessDateTime (as date)
- DateTime aDateTime;
- aDateTime.Day = rDate.Day;
- aDateTime.Month = rDate.Month;
- aDateTime.Year = rDate.Year;
- ProcessDateTime(eName, aDateTime, sal_True, nPrefix);
-}
-
-
/// export a date, time, or duration
void XMLTextFieldExport::ProcessDateTime(enum XMLTokenEnum eName,
sal_Int32 nMinutes,
commit 5688b51bcb23b12b335dadf4430b7b7c4407cbfb
Author: Caolán McNamara <caolanm at redhat.com>
Date: Wed Apr 4 21:30:30 2012 +0100
UniString::CreateFromInt32 -> rtl::OUString::valueOf
diff --git a/accessibility/source/extended/accessibleeditbrowseboxcell.cxx b/accessibility/source/extended/accessibleeditbrowseboxcell.cxx
index 7ff06ba..3af5117 100644
--- a/accessibility/source/extended/accessibleeditbrowseboxcell.cxx
+++ b/accessibility/source/extended/accessibleeditbrowseboxcell.cxx
@@ -133,17 +133,17 @@ namespace accessibility
SolarMethodGuard aGuard( *this );
// TODO: localize this!
- String sName = mpBrowseBox->GetColumnDescription( ::sal::static_int_cast< sal_uInt16 >( getColumnPos() ) );
- if ( 0 == sName.Len() )
+ rtl::OUStringBuffer sName(mpBrowseBox->GetColumnDescription( ::sal::static_int_cast< sal_uInt16 >( getColumnPos() ) ));
+ if ( 0 == sName.getLength() )
{
- sName = String::CreateFromAscii( "Column " );
- sName += String::CreateFromInt32( getColumnPos( ) );
+ sName.appendAscii(RTL_CONSTASCII_STRINGPARAM("Column "));
+ sName.append(getColumnPos());
}
- sName += String::CreateFromAscii( ", Row " );
- sName += String::CreateFromInt32( getRowPos( ) );
+ sName.appendAscii(RTL_CONSTASCII_STRINGPARAM(", Row "));
+ sName.append(getRowPos());
- return ::rtl::OUString( sName );
+ return sName.makeStringAndClear();
}
// -----------------------------------------------------------------------------
diff --git a/canvas/source/cairo/cairo_devicehelper.cxx b/canvas/source/cairo/cairo_devicehelper.cxx
index bf1679a..2e2bc06 100644
--- a/canvas/source/cairo/cairo_devicehelper.cxx
+++ b/canvas/source/cairo/cairo_devicehelper.cxx
@@ -257,13 +257,13 @@ namespace cairocanvas
void DeviceHelper::dumpScreenContent() const
{
- static sal_uInt32 nFilePostfixCount(0);
+ static sal_Int32 nFilePostfixCount(0);
if( mpRefDevice )
{
- String aFilename( String::CreateFromAscii("dbg_frontbuffer") );
- aFilename += String::CreateFromInt32(nFilePostfixCount);
- aFilename += String::CreateFromAscii(".bmp");
+ rtl::OUString aFilename("dbg_frontbuffer");
+ aFilename += rtl::OUString::valueOf(nFilePostfixCount);
+ aFilename += rtl::OUString(".bmp");
SvFileStream aStream( aFilename, STREAM_STD_READWRITE );
diff --git a/canvas/source/vcl/devicehelper.cxx b/canvas/source/vcl/devicehelper.cxx
index 1c2c085..44c35cb 100644
--- a/canvas/source/vcl/devicehelper.cxx
+++ b/canvas/source/vcl/devicehelper.cxx
@@ -216,13 +216,13 @@ namespace vclcanvas
void DeviceHelper::dumpScreenContent() const
{
- static sal_uInt32 nFilePostfixCount(0);
+ static sal_Int32 nFilePostfixCount(0);
if( mpOutDev )
{
- String aFilename( String::CreateFromAscii("dbg_frontbuffer") );
- aFilename += String::CreateFromInt32(nFilePostfixCount);
- aFilename += String::CreateFromAscii(".bmp");
+ rtl::OUString aFilename("dbg_frontbuffer");
+ aFilename += rtl::OUString::valueOf(nFilePostfixCount);
+ aFilename += rtl::OUString(".bmp");
SvFileStream aStream( aFilename, STREAM_STD_READWRITE );
diff --git a/canvas/source/vcl/spritedevicehelper.cxx b/canvas/source/vcl/spritedevicehelper.cxx
index 627ce37..b99dc4e 100644
--- a/canvas/source/vcl/spritedevicehelper.cxx
+++ b/canvas/source/vcl/spritedevicehelper.cxx
@@ -135,13 +135,13 @@ namespace vclcanvas
{
DeviceHelper::dumpScreenContent();
- static sal_uInt32 nFilePostfixCount(0);
+ static sal_Int32 nFilePostfixCount(0);
if( mpBackBuffer )
{
- String aFilename( String::CreateFromAscii("dbg_backbuffer") );
- aFilename += String::CreateFromInt32(nFilePostfixCount);
- aFilename += String::CreateFromAscii(".bmp");
+ rtl::OUString aFilename("dbg_backbuffer");
+ aFilename += rtl::OUString::valueOf(nFilePostfixCount);
+ aFilename += rtl::OUString(".bmp");
SvFileStream aStream( aFilename, STREAM_STD_READWRITE );
diff --git a/chart2/source/controller/dialogs/DataBrowser.cxx b/chart2/source/controller/dialogs/DataBrowser.cxx
index c518e64..cff38ee 100644
--- a/chart2/source/controller/dialogs/DataBrowser.cxx
+++ b/chart2/source/controller/dialogs/DataBrowser.cxx
@@ -658,7 +658,7 @@ String DataBrowser::GetColString( sal_Int32 nColumnId ) const
String DataBrowser::GetRowString( sal_Int32 nRow ) const
{
- return String::CreateFromInt32( nRow + 1 );
+ return rtl::OUString::valueOf(nRow + 1);
}
String DataBrowser::GetCellText( long nRow, sal_uInt16 nColumnId ) const
diff --git a/chart2/source/controller/dialogs/tp_3D_SceneIllumination.cxx b/chart2/source/controller/dialogs/tp_3D_SceneIllumination.cxx
index b094fb9..df6c47d 100644
--- a/chart2/source/controller/dialogs/tp_3D_SceneIllumination.cxx
+++ b/chart2/source/controller/dialogs/tp_3D_SceneIllumination.cxx
@@ -160,15 +160,15 @@ namespace
{
rtl::OUString lcl_makeColorName( Color rColor )
{
- String aStr(SVX_RES(RID_SVXFLOAT3D_FIX_R));
- aStr += String::CreateFromInt32((sal_Int32)rColor.GetRed());
- aStr += sal_Unicode(' ');
- aStr += String(SVX_RES(RID_SVXFLOAT3D_FIX_G));
- aStr += String::CreateFromInt32((sal_Int32)rColor.GetGreen());
- aStr += sal_Unicode(' ');
- aStr += String(SVX_RES(RID_SVXFLOAT3D_FIX_B));
- aStr += String::CreateFromInt32((sal_Int32)rColor.GetBlue());
- return aStr;
+ rtl::OUStringBuffer aStr(SVX_RESSTR(RID_SVXFLOAT3D_FIX_R));
+ aStr.append((sal_Int32)rColor.GetRed());
+ aStr.append(' ');
+ aStr.append(SVX_RESSTR(RID_SVXFLOAT3D_FIX_G));
+ aStr.append((sal_Int32)rColor.GetGreen());
+ aStr.append(' ');
+ aStr.append(SVX_RESSTR(RID_SVXFLOAT3D_FIX_B));
+ aStr.append((sal_Int32)rColor.GetBlue());
+ return aStr.makeStringAndClear();
}
void lcl_selectColor( ColorListBox& rListBox, const Color& rColor )
{
diff --git a/chart2/source/controller/dialogs/tp_DataSource.cxx b/chart2/source/controller/dialogs/tp_DataSource.cxx
index 0c66967..bde97f0 100644
--- a/chart2/source/controller/dialogs/tp_DataSource.cxx
+++ b/chart2/source/controller/dialogs/tp_DataSource.cxx
@@ -491,7 +491,7 @@ void DataSourceTabPage::fillSeriesListBox()
if( nIndex != -1 )
aLabel = String( aResString.replaceAt(
nIndex, aReplacementStr.getLength(),
- String::CreateFromInt32( nUnnamedSeriesIndex )));
+ rtl::OUString::valueOf(nUnnamedSeriesIndex)));
}
if( aLabel.Len() == 0 )
aLabel = String( ::chart::SchResId( STR_DATA_UNNAMED_SERIES ));
diff --git a/chart2/source/controller/main/DragMethod_PieSegment.cxx b/chart2/source/controller/main/DragMethod_PieSegment.cxx
index 94ce189..c9395eb 100644
--- a/chart2/source/controller/main/DragMethod_PieSegment.cxx
+++ b/chart2/source/controller/main/DragMethod_PieSegment.cxx
@@ -83,8 +83,8 @@ DragMethod_PieSegment::~DragMethod_PieSegment()
}
void DragMethod_PieSegment::TakeSdrDragComment(String& rStr) const
{
- rStr = String( SchResId( STR_STATUS_PIE_SEGMENT_EXPLODED ) );
- rStr.SearchAndReplaceAscii( "%PERCENTVALUE", String::CreateFromInt32( static_cast<sal_Int32>((m_fAdditionalOffset+m_fInitialOffset)*100.0) ));
+ rStr = ResId::toString(SchResId(STR_STATUS_PIE_SEGMENT_EXPLODED));
+ rStr.SearchAndReplaceAscii( "%PERCENTVALUE", rtl::OUString::valueOf( static_cast<sal_Int32>((m_fAdditionalOffset+m_fInitialOffset)*100.0) ));
}
bool DragMethod_PieSegment::BeginSdrDrag()
{
diff --git a/extensions/source/bibliography/general.cxx b/extensions/source/bibliography/general.cxx
index 9c80778..65dafe5 100644
--- a/extensions/source/bibliography/general.cxx
+++ b/extensions/source/bibliography/general.cxx
@@ -510,8 +510,8 @@ uno::Reference< awt::XControlModel > BibGeneralPage::AddXControl(
uno::Sequence<rtl::OUString> aListSource(TYPE_COUNT);
rtl::OUString* pListSourceArr = aListSource.getArray();
//pListSourceArr[0] = C2U("select TypeName, TypeIndex from TypeNms");
- for(sal_uInt16 i = 0; i < TYPE_COUNT; i++)
- pListSourceArr[i] = String::CreateFromInt32(i);
+ for(sal_Int32 i = 0; i < TYPE_COUNT; ++i)
+ pListSourceArr[i] = rtl::OUString::valueOf(i);
aAny.setValue(&aListSource, ::getCppuType((uno::Sequence<rtl::OUString>*)0));
xPropSet->setPropertyValue(C2U("ListSource"), aAny);
diff --git a/extensions/source/dbpilots/groupboxwiz.cxx b/extensions/source/dbpilots/groupboxwiz.cxx
index de30269..1776726 100644
--- a/extensions/source/dbpilots/groupboxwiz.cxx
+++ b/extensions/source/dbpilots/groupboxwiz.cxx
@@ -273,7 +273,7 @@ namespace dbp
for (::svt::WizardTypes::WizardState i=0; i<m_aExistingRadios.GetEntryCount(); ++i)
{
rSettings.aLabels.push_back(m_aExistingRadios.GetEntry(i));
- rSettings.aValues.push_back(String::CreateFromInt32((sal_Int32)(i + 1)));
+ rSettings.aValues.push_back(rtl::OUString::valueOf((sal_Int32)(i + 1)));
}
return sal_True;
diff --git a/extensions/source/propctrlr/newdatatype.cxx b/extensions/source/propctrlr/newdatatype.cxx
index dd26f82..367a550 100644
--- a/extensions/source/propctrlr/newdatatype.cxx
+++ b/extensions/source/propctrlr/newdatatype.cxx
@@ -76,7 +76,7 @@ namespace pcr
sal_Int32 nPostfixNumber = 1;
do
{
- ( sInitialName = sNameBase ) += String::CreateFromInt32( nPostfixNumber++ );
+ ( sInitialName = sNameBase ) += rtl::OUString::valueOf(nPostfixNumber++);
}
while ( m_aProhibitedNames.find( sInitialName ) != m_aProhibitedNames.end() );
diff --git a/forms/source/solar/component/navbarcontrol.cxx b/forms/source/solar/component/navbarcontrol.cxx
index c18ff8b..e814595 100644
--- a/forms/source/solar/component/navbarcontrol.cxx
+++ b/forms/source/solar/component/navbarcontrol.cxx
@@ -486,7 +486,7 @@ namespace frm
}
else if ( _nFeatureId == FormFeature::MoveAbsolute )
{
- pNavBar->setFeatureText( _nFeatureId, String::CreateFromInt32( getIntegerState( _nFeatureId ) ) );
+ pNavBar->setFeatureText( _nFeatureId, rtl::OUString::valueOf(getIntegerState(_nFeatureId)) );
}
}
diff --git a/oox/source/ole/olehelper.cxx b/oox/source/ole/olehelper.cxx
index 012fc20..91953f3 100644
--- a/oox/source/ole/olehelper.cxx
+++ b/oox/source/ole/olehelper.cxx
@@ -755,7 +755,7 @@ const Reference< XIndexContainer >&
while( xNameCont->hasByName( sName ) )
{
sName = sStdName;
- sName += String::CreateFromInt32( ++n );
+ sName += rtl::OUString::valueOf(static_cast<sal_Int32>(++n));
}
const Reference< XMultiServiceFactory > &rServiceFactory
diff --git a/padmin/source/adddlg.cxx b/padmin/source/adddlg.cxx
index df2f4e2..ae1964d 100644
--- a/padmin/source/adddlg.cxx
+++ b/padmin/source/adddlg.cxx
@@ -1074,7 +1074,7 @@ String AddPrinterDialog::uniquePrinterName( const String& rBase )
PrinterInfoManager& rManager( PrinterInfoManager::get() );
- int nVersion = 1;
+ sal_Int32 nVersion = 1;
list< OUString > aPrinterList;
rManager.listPrinters( aPrinterList );
boost::unordered_set< OUString, OUStringHash > aPrinters;
@@ -1084,7 +1084,7 @@ String AddPrinterDialog::uniquePrinterName( const String& rBase )
{
aResult = rBase;
aResult.AppendAscii( "_" );
- aResult += String::CreateFromInt32( nVersion++ );
+ aResult += rtl::OUString::valueOf(nVersion++);
}
return aResult;
diff --git a/starmath/source/cfgitem.cxx b/starmath/source/cfgitem.cxx
index 15e71c5..4870c61 100644
--- a/starmath/source/cfgitem.cxx
+++ b/starmath/source/cfgitem.cxx
@@ -395,27 +395,21 @@ const String SmFontFormatList::GetFontFormatId( size_t nPos ) const
}
-const String SmFontFormatList::GetNewFontFormatId() const
+const rtl::OUString SmFontFormatList::GetNewFontFormatId() const
{
// returns first unused FormatId
- String aRes;
-
- String aPrefix( RTL_CONSTASCII_USTRINGPARAM( "Id" ) );
+ rtl::OUString aPrefix("Id");
sal_Int32 nCnt = GetCount();
for (sal_Int32 i = 1; i <= nCnt + 1; ++i)
{
- String aTmpId( aPrefix );
- aTmpId += String::CreateFromInt32( i );
- if (!GetFontFormat( aTmpId ))
- {
- aRes = aTmpId;
- break;
- }
+ rtl::OUString aTmpId = aPrefix + rtl::OUString::valueOf(i);
+ if (!GetFontFormat(aTmpId))
+ return aTmpId;
}
- OSL_ENSURE( 0 != aRes.Len(), "failed to create new FontFormatId" );
+ OSL_ENSURE( !this, "failed to create new FontFormatId" );
- return aRes;
+ return rtl::OUString();
}
/////////////////////////////////////////////////////////////////
diff --git a/starmath/source/cfgitem.hxx b/starmath/source/cfgitem.hxx
index e3fb818..2fc98b4 100644
--- a/starmath/source/cfgitem.hxx
+++ b/starmath/source/cfgitem.hxx
@@ -104,7 +104,7 @@ public:
const String GetFontFormatId( const SmFontFormat &rFntFmt ) const;
const String GetFontFormatId( const SmFontFormat &rFntFmt, bool bAdd );
const String GetFontFormatId( size_t nPos ) const;
- const String GetNewFontFormatId() const;
+ const rtl::OUString GetNewFontFormatId() const;
size_t GetCount() const { return aEntries.size(); }
bool IsModified() const { return bModified; }
diff --git a/svl/inc/svl/zformat.hxx b/svl/inc/svl/zformat.hxx
index 2633128..03c2661 100644
--- a/svl/inc/svl/zformat.hxx
+++ b/svl/inc/svl/zformat.hxx
@@ -649,12 +649,12 @@ private:
sal_uInt16 nMinDigits = 0 ) const;
String ImpIntToString( sal_uInt16 nIx, sal_Int32 nVal, sal_uInt16 nMinDigits = 0 ) const
- {
- const SvNumberNatNum& rNum = NumFor[nIx].GetNatNum();
- if ( nMinDigits || rNum.IsComplete() )
- return ImpGetNatNumString( rNum, nVal, nMinDigits );
- return String::CreateFromInt32( nVal );
- }
+ {
+ const SvNumberNatNum& rNum = NumFor[nIx].GetNatNum();
+ if ( nMinDigits || rNum.IsComplete() )
+ return ImpGetNatNumString( rNum, nVal, nMinDigits );
+ return rtl::OUString::valueOf(nVal);
+ }
// transliterate according to NativeNumber
SVL_DLLPRIVATE void ImpTransliterateImpl( String& rStr, const SvNumberNatNum& rNum ) const;
diff --git a/svtools/source/brwbox/datwin.cxx b/svtools/source/brwbox/datwin.cxx
index 8db2a15..40beb7d 100644
--- a/svtools/source/brwbox/datwin.cxx
+++ b/svtools/source/brwbox/datwin.cxx
@@ -738,12 +738,12 @@ void BrowserScrollBar::Tracking( const TrackingEvent& rTEvt )
sal_uLong nPos = GetThumbPos();
if ( nPos != _nLastPos )
{
- String aTip( String::CreateFromInt32(nPos) );
+ String aTip( rtl::OUString::valueOf(static_cast<sal_Int32>(nPos)) );
aTip += '/';
if ( _pDataWin->GetRealRowCount().Len() )
aTip += _pDataWin->GetRealRowCount();
else
- aTip += String::CreateFromInt32(GetRangeMax());
+ aTip += rtl::OUString::valueOf(static_cast<sal_Int32>(GetRangeMax()));
Rectangle aRect( GetPointerPosPixel(), Size( GetTextHeight(), GetTextWidth( aTip ) ) );
if ( _nTip )
diff --git a/svtools/workben/svdem.cxx b/svtools/workben/svdem.cxx
index be6ce3d..c18e749 100644
--- a/svtools/workben/svdem.cxx
+++ b/svtools/workben/svdem.cxx
@@ -308,7 +308,7 @@ void ShowFont::Paint( const Rectangle& )
if ( rFont.GetOrientation() )
{
- aText.Append( String::CreateFromInt32( rFont.GetOrientation()/10 ) );
+ aText.Append( rtl::OUString::valueOf(static_cast<sal_Int32>(rFont.GetOrientation()/10)) );
aText.AppendAscii( " degree." );
x = aWindowSize.Width()/2;
diff --git a/sw/qa/core/swdoc-test.cxx b/sw/qa/core/swdoc-test.cxx
index 6106da2..72c5ad3 100644
--- a/sw/qa/core/swdoc-test.cxx
+++ b/sw/qa/core/swdoc-test.cxx
@@ -367,8 +367,7 @@ getRand(int modulus)
static rtl::OUString
getRandString()
{
- static rtl::OUString aText(RTL_CONSTASCII_USTRINGPARAM(
- "AAAAA BBBB CCC DD E \n"));
+ rtl::OUString aText("AAAAA BBBB CCC DD E \n");
int s = getRand(aText.getLength());
int j = getRand(aText.getLength() - s);
rtl::OUString aRet(aText.copy(s, j));
diff --git a/toolkit/source/awt/vclxaccessiblecomponent.cxx b/toolkit/source/awt/vclxaccessiblecomponent.cxx
index 9f8e52c..c0c5f96 100644
--- a/toolkit/source/awt/vclxaccessiblecomponent.cxx
+++ b/toolkit/source/awt/vclxaccessiblecomponent.cxx
@@ -692,9 +692,9 @@ sal_Int16 VCLXAccessibleComponent::getAccessibleRole( ) throw (uno::RuntimeExce
{
aName = GetWindow()->GetAccessibleName();
#if OSL_DEBUG_LEVEL > 1
- aName += String( RTL_CONSTASCII_USTRINGPARAM( " (Type = " ) );
- aName += String::CreateFromInt32( GetWindow()->GetType() );
- aName += String( RTL_CONSTASCII_USTRINGPARAM( ")" ) );
+ aName += rtl::OUString(" (Type = ");
+ aName += rtl::OUString::valueOf(static_cast<sal_Int32>(GetWindow()->GetType()));
+ aName += rtl::OUString( ")");
#endif
}
return aName;
diff --git a/unotools/source/config/securityoptions.cxx b/unotools/source/config/securityoptions.cxx
index 2b762f0..c8d65e2 100644
--- a/unotools/source/config/securityoptions.cxx
+++ b/unotools/source/config/securityoptions.cxx
@@ -720,9 +720,7 @@ void SvtSecurityOptions_Impl::Commit()
Sequence< Sequence< com::sun::star::beans::PropertyValue > > lPropertyValuesSeq( nCnt );
for( sal_Int32 i = 0 ; i < nCnt ; ++i )
{
- String aPrefix( s );
- aPrefix += String::CreateFromInt32( i );
- aPrefix.AppendAscii( "/" );
+ rtl::OUString aPrefix = rtl::OUStringBuffer(s).append(i).append('/').makeStringAndClear();
Sequence< com::sun::star::beans::PropertyValue > lPropertyValues( 3 );
lPropertyValues[ 0 ].Name = aPrefix + PROPERTYNAME_TRUSTEDAUTHOR_SUBJECTNAME;
lPropertyValues[ 0 ].Value <<= m_seqTrustedAuthors[ i ][0];
diff --git a/unotools/source/i18n/localedatawrapper.cxx b/unotools/source/i18n/localedatawrapper.cxx
index 977b7b9..1e2ee15 100644
--- a/unotools/source/i18n/localedatawrapper.cxx
+++ b/unotools/source/i18n/localedatawrapper.cxx
@@ -342,19 +342,20 @@ void LocaleDataWrapper::invalidateData()
// && !aDebugLocale.EqualsAscii( "es_BR" ) // ?!? Brazil/es
)
{
- String aMsg( RTL_CONSTASCII_USTRINGPARAM(
+ rtl::OUStringBuffer aMsg;
+ aMsg.appendAscii(RTL_CONSTASCII_STRINGPARAM(
"ConvertIsoNamesToLanguage/ConvertLanguageToIsoNames: ambiguous locale (MS-LCID?)\n"));
- aMsg += aDebugLocale;
- aMsg.AppendAscii( RTL_CONSTASCII_STRINGPARAM( " -> 0x" ) );
- aMsg += String::CreateFromInt32( eLang, 16 );
- aMsg.AppendAscii( RTL_CONSTASCII_STRINGPARAM( " -> " ) );
- aMsg += String( aLanguage);
+ aMsg.append(aDebugLocale);
+ aMsg.appendAscii(RTL_CONSTASCII_STRINGPARAM( " -> 0x"));
+ aMsg.append(static_cast<sal_Int32>(eLang), 16);
+ aMsg.appendAscii(RTL_CONSTASCII_STRINGPARAM( " -> "));
+ aMsg.append(aLanguage);
if ( !aCountry.isEmpty() )
{
- aMsg += '_';
- aMsg += String( aCountry);
+ aMsg.append('_');
+ aMsg.append(aCountry);
}
- outputCheckMessage( aMsg );
+ outputCheckMessage( aMsg.makeStringAndClear() );
}
eLang = LANGUAGE_DONTKNOW;
}
diff --git a/uui/source/iahndl.cxx b/uui/source/iahndl.cxx
index cb60a48..38739bd 100644
--- a/uui/source/iahndl.cxx
+++ b/uui/source/iahndl.cxx
@@ -632,7 +632,7 @@ UUIInteractionHelper::handleRequest_impl(
sal_Int32 nMedium = 0;
aWrongMediumException.Medium >>= nMedium;
std::vector< rtl::OUString > aArguments;
- aArguments.push_back(UniString::CreateFromInt32(nMedium + 1));
+ aArguments.push_back(rtl::OUString::valueOf(nMedium + 1));
handleErrorHandlerRequest(aWrongMediumException.Classification,
ERRCODE_UUI_WRONGMEDIUM,
aArguments,
diff --git a/xmloff/source/style/xmlnumfi.cxx b/xmloff/source/style/xmlnumfi.cxx
index f428ab9..bd953a3 100644
--- a/xmloff/source/style/xmlnumfi.cxx
+++ b/xmloff/source/style/xmlnumfi.cxx
@@ -1380,7 +1380,7 @@ SvXMLNumFormatContext::SvXMLNumFormatContext( SvXMLImport& rImport,
{
aFormatCode.appendAscii( RTL_CONSTASCII_STRINGPARAM( "][$-" ) );
// language code in upper hex:
- aFormatCode.append( String::CreateFromInt32( sal_Int32( eLang ), 16 ).ToUpperAscii() );
+ aFormatCode.append(rtl::OUString::valueOf(sal_Int32(eLang), 16).toAsciiUpperCase());
}
aFormatCode.append( sal_Unicode(']') );
}
@@ -1905,7 +1905,7 @@ void SvXMLNumFormatContext::AddCurrency( const rtl::OUString& rContent, Language
{
// '-' sign and language code in hex:
aFormatCode.append( (sal_Unicode) '-' );
- aFormatCode.append( String::CreateFromInt32( sal_Int32( nLang ), 16 ).ToUpperAscii() );
+ aFormatCode.append(rtl::OUString::valueOf(sal_Int32(nLang), 16).toAsciiUpperCase());
}
aFormatCode.append( (sal_Unicode) ']' ); // end of "new" currency symbol
commit dd20a8c6e2ebeceff90567597d712e4c03c2ac7d
Author: Caolán McNamara <caolanm at redhat.com>
Date: Wed Apr 4 11:53:34 2012 +0100
SvtFileDialogURLSelector::OpenURL can go apparently
diff --git a/fpicker/source/office/iodlgimp.cxx b/fpicker/source/office/iodlgimp.cxx
index f93b84d..99797da 100644
--- a/fpicker/source/office/iodlgimp.cxx
+++ b/fpicker/source/office/iodlgimp.cxx
@@ -165,14 +165,6 @@ SvtFileDialogURLSelector::~SvtFileDialogURLSelector()
}
//-----------------------------------------------------------------------------
-void SvtFileDialogURLSelector::OpenURL( const String& rURL )
-{
- INetURLObject aObj( rURL );
- DBG_ASSERT( aObj.GetProtocol() != INET_PROT_NOT_VALID, "SvtFileDialogURLSelector::OpenURL: Invalid URL!" );
- m_pParent->OpenURL_Impl( aObj.GetMainURL( INetURLObject::NO_DECODE ) );
-}
-
-//-----------------------------------------------------------------------------
void SvtFileDialogURLSelector::Activate()
{
m_pMenu->Clear();
diff --git a/fpicker/source/office/iodlgimp.hxx b/fpicker/source/office/iodlgimp.hxx
index 5478452..7a30e93 100644
--- a/fpicker/source/office/iodlgimp.hxx
+++ b/fpicker/source/office/iodlgimp.hxx
@@ -100,7 +100,6 @@ protected:
inline SvtFileDialog* GetDialogParent() { return m_pParent; }
protected:
- void OpenURL( const String& rURL );
virtual void FillURLMenu( PopupMenu* _pMenu ) = 0;
diff --git a/unusedcode.README b/unusedcode.README
index 08f51b7..c721d62 100644
--- a/unusedcode.README
+++ b/unusedcode.README
@@ -28,7 +28,9 @@ d) gcc will only emit code for inlines if those inlines are used, so
e) if a constructor is listed as unused, and it's the *only* ctor in the class,
then no object of that class can be construsted, so the whole thing is
unused, which can lead to a whole cascade of tricky but logical fallout.
-f) there's more actually unused code then what's listed. The idea is that what's
+f) if a destructor is listed as unused, and a constructor isn't, then there's
+ a leak somewhere, and the destructor most likely *should* be called.
+g) there's more actually unused code then what's listed. The idea is that what's
listed is definitely unused under the generation configuration, not that
it's a list of all unused code. If the count of unused easy hits 0 then
we can have a look at the non-easy and if that hits 0, then strip out
commit fe630f3b097ca2bf173f21de77ed1535c767d0b9
Author: Caolán McNamara <caolanm at redhat.com>
Date: Wed Apr 4 10:24:36 2012 +0100
callcatcher: update list, add README, remove some newly unused code
diff --git a/cppcanvas/source/mtfrenderer/transparencygroupaction.cxx b/cppcanvas/source/mtfrenderer/transparencygroupaction.cxx
index ce29585..69b5173 100644
--- a/cppcanvas/source/mtfrenderer/transparencygroupaction.cxx
+++ b/cppcanvas/source/mtfrenderer/transparencygroupaction.cxx
@@ -82,34 +82,6 @@ namespace cppcanvas
@param rGroupMtf
Metafile that groups all actions to be rendered
- transparent
-
- @param rParms
- Render parameters
-
- @param rDstPoint
- Left, top edge of destination, in current state
- coordinate system
-
- @param rDstSize
- Size of the transparency group object, in current
- state coordinate system.
-
- @param nAlpha
- Alpha value, must be in the range [0,1]
- */
- TransparencyGroupAction( MtfAutoPtr& rGroupMtf,
- const Renderer::Parameters& rParms,
- const ::basegfx::B2DPoint& rDstPoint,
- const ::basegfx::B2DVector& rDstSize,
- double nAlpha,
- const CanvasSharedPtr& rCanvas,
- const OutDevState& rState );
-
- /** Create new transparency group action.
-
- @param rGroupMtf
- Metafile that groups all actions to be rendered
transparent.
@param rAlphaGradient
@@ -182,40 +154,6 @@ namespace cppcanvas
SAL_WNODEPRECATED_DECLARATIONS_PUSH
TransparencyGroupAction::TransparencyGroupAction( MtfAutoPtr& rGroupMtf,
- const Renderer::Parameters& rParms,
- const ::basegfx::B2DPoint& rDstPoint,
- const ::basegfx::B2DVector& rDstSize,
- double nAlpha,
- const CanvasSharedPtr& rCanvas,
- const OutDevState& rState ) :
- mpGroupMtf( rGroupMtf ),
- mpAlphaGradient(),
- maParms( rParms ),
- maDstSize( rDstSize ),
- mxBufferBitmap(),
- maLastTransformation(),
- mpCanvas( rCanvas ),
- maState(),
- mnAlpha( nAlpha )
- {
- tools::initRenderState(maState,rState);
- implSetupTransform( maState, rDstPoint );
-
- // correct clip (which is relative to original transform)
- tools::modifyClip( maState,
- rState,
- rCanvas,
- rDstPoint,
- NULL,
- NULL );
-
- maLastSubset.mnSubsetBegin = 0;
- maLastSubset.mnSubsetEnd = -1;
- }
- SAL_WNODEPRECATED_DECLARATIONS_POP
-
- SAL_WNODEPRECATED_DECLARATIONS_PUSH
- TransparencyGroupAction::TransparencyGroupAction( MtfAutoPtr& rGroupMtf,
GradientAutoPtr& rAlphaGradient,
const Renderer::Parameters& rParms,
const ::basegfx::B2DPoint& rDstPoint,
diff --git a/fpicker/source/office/PlacesListBox.cxx b/fpicker/source/office/PlacesListBox.cxx
index 31bb125..3c15879 100644
--- a/fpicker/source/office/PlacesListBox.cxx
+++ b/fpicker/source/office/PlacesListBox.cxx
@@ -97,10 +97,6 @@ void PlacesListBox::AppendPlace( PlacePtr pPlace )
}
}
-sal_Int32 PlacesListBox::GetNbPlaces() {
- return maPlaces.size();
-}
-
sal_Int32 PlacesListBox::GetNbEditablePlaces() {
return mnNbEditables;
}
diff --git a/fpicker/source/office/PlacesListBox.hxx b/fpicker/source/office/PlacesListBox.hxx
index 0326be8..16ba19a 100644
--- a/fpicker/source/office/PlacesListBox.hxx
+++ b/fpicker/source/office/PlacesListBox.hxx
@@ -96,7 +96,6 @@ class PlacesListBox : public Control
void AppendPlace( PlacePtr pPlace );
void RemovePlace( sal_uInt16 nPos );
void RemoveSelectedPlace();
- sal_Int32 GetNbPlaces();
sal_Int32 GetNbEditablePlaces();
bool IsUpdated();
const std::vector<PlacePtr>& GetPlaces();
diff --git a/fpicker/source/office/iodlg.cxx b/fpicker/source/office/iodlg.cxx
index 3c9df7d..b3db697 100644
--- a/fpicker/source/office/iodlg.cxx
+++ b/fpicker/source/office/iodlg.cxx
@@ -325,41 +325,6 @@ namespace
}
//---------------------------------------------------------------------
- void convertStringListToUrls( const rtl::OUString& _rColonSeparatedList, ::std::vector< String >& _rTokens )
- {
- const sal_Unicode cSeparator =
-#if defined(WNT)
- ';'
-#else
- ':'
-#endif
- ;
- sal_Int32 nIndex = 0;
- do
- {
- // the current token in the list
- rtl::OUString sCurrentToken = _rColonSeparatedList.getToken( 0, cSeparator, nIndex );
- if ( !sCurrentToken.isEmpty() )
- {
- INetURLObject aCurrentURL;
-
- rtl::OUString sURL;
- if ( ::utl::LocalFileHelper::ConvertPhysicalNameToURL( sCurrentToken, sURL ) )
- aCurrentURL = INetURLObject( sURL );
- else
- {
- // smart URL parsing, assuming FILE protocol
- aCurrentURL = INetURLObject( sCurrentToken, INET_PROT_FILE );
- }
-
- aCurrentURL.removeFinalSlash( );
- _rTokens.push_back( aCurrentURL.GetMainURL( INetURLObject::NO_DECODE ) );
- }
- }
- while ( nIndex >= 0 );
- }
-
- //---------------------------------------------------------------------
struct RemoveFinalSlash : public ::std::unary_function< String, void >
{
void operator()( String& _rURL )
diff --git a/fpicker/source/office/iodlgimp.cxx b/fpicker/source/office/iodlgimp.cxx
index 7900ee1..f93b84d 100644
--- a/fpicker/source/office/iodlgimp.cxx
+++ b/fpicker/source/office/iodlgimp.cxx
@@ -264,76 +264,6 @@ void SvtUpButton_Impl::Click()
GetDialogParent()->PrevLevel_Impl();
}
-//=============================================================================
-//= SvtTravelButton_Impl
-//=============================================================================
-
-//-----------------------------------------------------------------------------
-SvtTravelButton_Impl::SvtTravelButton_Impl( SvtFileDialog* pParent, const ResId& rResId )
- :SvtFileDialogURLSelector ( pParent, rResId, IMG_FILEDLG_BTN_STD )
-{
- SetDropDown( 0 ); // by default, don't drop down, as we don't have favourites
-}
-
-//-----------------------------------------------------------------------------
-void SvtTravelButton_Impl::SetFavouriteLocations( const ::std::vector< String >& _rLocations )
-{
- m_aFavourites = _rLocations;
- // enable the drop down if and only if we have favourites
- SetDropDown( m_aFavourites.empty() ? 0 : PUSHBUTTON_DROPDOWN_TOOLBOX );
-}
-
-//-----------------------------------------------------------------------------
-SvtTravelButton_Impl::~SvtTravelButton_Impl()
-{
-}
-
-//-----------------------------------------------------------------------------
-void SvtTravelButton_Impl::FillURLMenu( PopupMenu* _pMenu )
-{
- if ( m_aFavourites.empty() )
- // though we claimed that we do not want to have a drop down button
- // in this case, VCL nevertheless behaves as if we had one .... :(
- return;
-
- _pMenu->Clear();
-
- sal_uInt16 nItemId = 1;
- String sDisplayName;
-
- ::std::vector< String >::const_iterator aLoop;
- for ( aLoop = m_aFavourites.begin(); aLoop != m_aFavourites.end(); ++aLoop, ++nItemId )
- {
- if ( GetDialogParent()->isUrlAllowed( *aLoop ) )
- {
- Image aImage = SvFileInformationManager::GetImage( INetURLObject(*aLoop) );
- if ( LocalFileHelper::ConvertURLToSystemPath(*aLoop, sDisplayName) )
- _pMenu->InsertItem( nItemId, sDisplayName, aImage );
- else
- _pMenu->InsertItem( nItemId, *aLoop, aImage );
- }
- }
-}
-
-//-----------------------------------------------------------------------------
-void SvtTravelButton_Impl::Select()
-{
- sal_uInt16 nId = GetCurItemId();
- if ( nId )
- {
- --nId;
- DBG_ASSERT( nId < m_aFavourites.size(), "SvtTravelButton_Impl::Select: invalid index!" );
- if ( nId < m_aFavourites.size() )
- OpenURL( m_aFavourites[ nId ] );
- }
-}
-
-//-----------------------------------------------------------------------------
-void SvtTravelButton_Impl::Click()
-{
- OpenURL( GetDialogParent()->GetStandardDir() );
-}
-
//*****************************************************************************
// SvtExpFileDlg_Impl
//*****************************************************************************
diff --git a/fpicker/source/office/iodlgimp.hxx b/fpicker/source/office/iodlgimp.hxx
index 3e5cd76..5478452 100644
--- a/fpicker/source/office/iodlgimp.hxx
+++ b/fpicker/source/office/iodlgimp.hxx
@@ -126,23 +126,6 @@ protected:
virtual void Click();
};
-class SvtTravelButton_Impl : public SvtFileDialogURLSelector
-{
-private:
- ::std::vector< String > m_aFavourites;
-
-public:
- SvtTravelButton_Impl( SvtFileDialog* pParent, const ResId& rResId );
- ~SvtTravelButton_Impl();
-
- void SetFavouriteLocations( const ::std::vector< String >& _rLocations );
-
-protected:
- virtual void FillURLMenu( PopupMenu* _pMenu );
- virtual void Select();
- virtual void Click();
-};
-
typedef sal_uInt8 SvtFileDlgState;
#define FILEDLG_STATE_NONE ((SvtFileDlgState)0x00)
diff --git a/sd/source/ui/slidesorter/view/SlsInsertAnimator.cxx b/sd/source/ui/slidesorter/view/SlsInsertAnimator.cxx
index 06ef5d2..7d2226a 100644
--- a/sd/source/ui/slidesorter/view/SlsInsertAnimator.cxx
+++ b/sd/source/ui/slidesorter/view/SlsInsertAnimator.cxx
@@ -110,9 +110,6 @@ private:
AnimatorAccess& mrAnimatorAccess;
::boost::function<double(double)> maAccelerationFunction;
- Rectangle GetInnerBoundingBox (
- const view::Layouter& rLayouter,
- const sal_Int32 nIndex) const;
void RestartAnimation (void);
};
typedef ::boost::shared_ptr<PageObjectRun> SharedPageObjectRun;
@@ -382,33 +379,6 @@ PageObjectRun::~PageObjectRun (void)
{
}
-
-
-
-Rectangle PageObjectRun::GetInnerBoundingBox (
- const view::Layouter& rLayouter,
- const sal_Int32 nIndex) const
-{
- model::SharedPageDescriptor pDescriptor (
- mrAnimatorAccess.GetModel().GetPageDescriptor(nIndex));
- if (pDescriptor)
- if (pDescriptor->HasState(model::PageDescriptor::ST_Selected))
- return rLayouter.GetPageObjectLayouter()->GetBoundingBox(
- pDescriptor,
- PageObjectLayouter::PageObject,
- PageObjectLayouter::ModelCoordinateSystem);
- else
- return rLayouter.GetPageObjectLayouter()->GetBoundingBox(
- pDescriptor,
- PageObjectLayouter::Preview,
- PageObjectLayouter::ModelCoordinateSystem);
- else
- return Rectangle();
-}
-
-
-
-
void PageObjectRun::UpdateOffsets(
const InsertPosition& rInsertPosition,
const view::Layouter& rLayouter)
diff --git a/svx/inc/svx/svdotable.hxx b/svx/inc/svx/svdotable.hxx
index 543b476..70dd0e7 100644
--- a/svx/inc/svx/svdotable.hxx
+++ b/svx/inc/svx/svdotable.hxx
@@ -156,8 +156,6 @@ public:
void setActiveCell( const sdr::table::CellPos& rPos );
void getActiveCellPos( sdr::table::CellPos& rPos ) const;
- sal_Int32 getRowCount() const;
- sal_Int32 getColumnCount() const;
void getCellBounds( const sdr::table::CellPos& rPos, ::Rectangle& rCellRect );
const SfxItemSet& GetActiveCellItemSet() const;
diff --git a/svx/source/table/cell.cxx b/svx/source/table/cell.cxx
index 0466c02..c3e010d 100644
--- a/svx/source/table/cell.cxx
+++ b/svx/source/table/cell.cxx
@@ -579,16 +579,6 @@ SfxStyleSheet* Cell::GetStyleSheet() const
// -----------------------------------------------------------------------------
-SfxStyleSheetPool* Cell::GetStyleSheetPool() const
-{
- if( mpProperties && mpProperties->GetStyleSheet() )
- return dynamic_cast< SfxStyleSheetPool* >( &mpProperties->GetStyleSheet()->GetPool() );
- else
- return 0;
-}
-
-// -----------------------------------------------------------------------------
-
const Rectangle& Cell::GetCurrentBoundRect() const
{
return maCellRect;
diff --git a/svx/source/table/cell.hxx b/svx/source/table/cell.hxx
index 689eea0..e9573f4 100644
--- a/svx/source/table/cell.hxx
+++ b/svx/source/table/cell.hxx
@@ -89,7 +89,6 @@ public:
OutlinerParaObject* GetEditOutlinerParaObject() const;
SVX_DLLPRIVATE void SetStyleSheet( SfxStyleSheet* pStyleSheet, sal_Bool bDontRemoveHardAttr );
SVX_DLLPRIVATE virtual SfxStyleSheet* GetStyleSheet() const;
- SfxStyleSheetPool* GetStyleSheetPool() const;
SVX_DLLPRIVATE virtual const Rectangle& GetCurrentBoundRect() const;
SVX_DLLPRIVATE virtual void TakeTextAnchorRect(Rectangle& rAnchorRect) const;
diff --git a/svx/source/table/svdotable.cxx b/svx/source/table/svdotable.cxx
index 3f7535f..92d18e4 100644
--- a/svx/source/table/svdotable.cxx
+++ b/svx/source/table/svdotable.cxx
@@ -1506,20 +1506,6 @@ const CellRef& SdrTableObj::getActiveCell() const
// --------------------------------------------------------------------
-sal_Int32 SdrTableObj::getRowCount() const
-{
- return mpImpl ? mpImpl->getRowCount() : 0;
-}
-
-// --------------------------------------------------------------------
-
-sal_Int32 SdrTableObj::getColumnCount() const
-{
- return mpImpl ? mpImpl->getColumnCount() : 0;
-}
-
-// --------------------------------------------------------------------
-
void SdrTableObj::setActiveCell( const CellPos& rPos )
{
if( mpImpl && mpImpl->mxTable.is() ) try
diff --git a/toolkit/source/controls/unocontrolmodel.cxx b/toolkit/source/controls/unocontrolmodel.cxx
index 8afc19e..c58a88a 100644
--- a/toolkit/source/controls/unocontrolmodel.cxx
+++ b/toolkit/source/controls/unocontrolmodel.cxx
@@ -1054,13 +1054,6 @@ sal_Bool UnoControlModel::supportsService( const ::rtl::OUString& rServiceName )
return Sequence< ::rtl::OUString >( &sName, 1 );
}
-// ::cppu::OPropertySetHelper
-::cppu::IPropertyArrayHelper& UnoControlModel::getInfoHelper()
-{
- OSL_FAIL( "UnoControlModel::getInfoHelper() not possible!" );
- return *(::cppu::IPropertyArrayHelper*) NULL;
-}
-
// ------------------------------------------------------------------
template <class TYPE>
sal_Bool convertType(Any& _rConvertedValue, const Any& _rNewValueTest, const TYPE* /* _pTypeDisambiguation */)
diff --git a/unusedcode.README b/unusedcode.README
new file mode 100644
index 0000000..08f51b7
--- /dev/null
+++ b/unusedcode.README
@@ -0,0 +1,39 @@
+unusedcode.easy is generated via callcatcher[1] and filtered to remove some
+tricky edge-cases (see Makefile), e.g. anything which could plausibly be
+dlsymed or any symbol defined in an external library bundled into LibreOffice
+which doesn't happen to get used by LibreOffice.
+
+unusedcode.easy is generated on an x86_64 --enable-debug --enable-dbgutil
+configuration.
+
+Code listed as unused is code that gcc outputs but that nothing calls
+(or takes the address of).
+
+a) It's possible that some other platform or configuration uses the code,
+ so manual inspection is always required.
+b) At the time of writing the majority of unused code now originates via
+ macros, mostly from pre-STL containers, see [2] for killing two birds
+ with one stone.
+c) callcatcher ignores virtuals. But implementations of "pure virtuals"
+ are not actually virtual methods. If something is declared pure virtual
+ and provides an impl and that base-class impl is not explicitly called
+ anywhere, then that impl can go away.
+d) gcc will only emit code for inlines if those inlines are used, so
+ sometimes something is listed correctly as unused but some inline
+ code takes a pointer or reference to something which cannot be
+ instantiated so removal of some method/class fails at build time because
+ gcc never emits any code for the the unused inline but trips over it at
+ compile time after an attempt at removal. i.e. generally the inline method
+ can go as well because nothing calls it either, a double win.
+e) if a constructor is listed as unused, and it's the *only* ctor in the class,
+ then no object of that class can be construsted, so the whole thing is
+ unused, which can lead to a whole cascade of tricky but logical fallout.
+f) there's more actually unused code then what's listed. The idea is that what's
+ listed is definitely unused under the generation configuration, not that
+ it's a list of all unused code. If the count of unused easy hits 0 then
+ we can have a look at the non-easy and if that hits 0, then strip out
+ code from the "release" binaries which only makes sense in debug/dbgutil
+ configurations, and then tackle unused virtual method slots :-)
+
+[1] http://www.skynet.ie/~caolan/Packages/callcatcher.html
+[2] https://bugs.freedesktop.org/show_bug.cgi?id=38832
diff --git a/unusedcode.easy b/unusedcode.easy
index c2a6e14..ed53d24 100755
--- a/unusedcode.easy
+++ b/unusedcode.easy
@@ -1,9 +1,5 @@
CertificateExtension_XmlSecImpl::setCertExtn(com::sun::star::uno::Sequence<signed char>, com::sun::star::uno::Sequence<signed char>, unsigned char)
CharAttribList::Clear()
-CharPosArray::Insert(CharPosArray const*, unsigned short, unsigned short, unsigned short)
-CharPosArray::Replace(int const&, unsigned short)
-CharPosArray::Replace(int const*, unsigned short, unsigned short)
-CharPosArray::_ForEach(unsigned short, unsigned short, unsigned char (*)(int const&, void*), void*)
Dialog::Dialog(Window*, ResId const&)
FmEntryDataArray::DeleteAndDestroy(unsigned short, unsigned short)
FmEntryDataArray::Insert(FmEntryData* const&, unsigned short&)
@@ -193,7 +189,6 @@ SwBlockNames::Insert(SwBlockName const**, unsigned short)
SwBlockNames::Insert(SwBlockNames const*, unsigned short, unsigned short)
SwBlockNames::Remove(SwBlockName const*&, unsigned short)
SwBlockNames::Remove(unsigned short, unsigned short)
-SwCellFrms::DeleteAndDestroy(unsigned short, unsigned short)
SwChartBoxes::DeleteAndDestroy(unsigned short, unsigned short)
SwContentArr::Insert(SwContent* const&, unsigned short&)
SwContentArr::Insert(SwContent* const*, unsigned short)
@@ -306,7 +301,6 @@ UnoControlBase::UnoControlBase()
UnoControlModel::Clone() const
UnoControlModel::GetImplementation(com::sun::star::uno::Reference<com::sun::star::uno::XInterface> const&)
UnoControlModel::UnoControlModel()
-UnoControlModel::getInfoHelper()
VCLUnoHelper::CreatePointer()
VCLXDevice::IsCreatedWithToolkit() const
VCLXPrinterServer::getImplementationId()
@@ -780,7 +774,6 @@ connectivity::mozab::OTable::OTable(connectivity::sdbcx::OCollection*, connectiv
connectivity::sdbcx::OGroup::OGroup(rtl::OUString const&, unsigned char)
connectivity::sdbcx::OGroup::OGroup(unsigned char)
connectivity::toString(com::sun::star::uno::Any const&)
-cppcanvas::internal::(anonymous namespace)::TransparencyGroupAction::TransparencyGroupAction(std::auto_ptr<GDIMetaFile>&, cppcanvas::Renderer::Parameters const&, basegfx::B2DPoint const&, basegfx::B2DVector const&, double, boost::shared_ptr<cppcanvas::Canvas> const&, cppcanvas::internal::OutDevState const&)
cppcanvas::internal::ImplSprite::ImplSprite(com::sun::star::uno::Reference<com::sun::star::rendering::XSpriteCanvas> const&, com::sun::star::uno::Reference<com::sun::star::rendering::XAnimatedSprite> const&, boost::shared_ptr<cppcanvas::internal::ImplSpriteCanvas::TransformationArbiter> const&)
cppcanvas::internal::ImplText::ImplText(boost::shared_ptr<cppcanvas::Canvas> const&, rtl::OUString const&)
dbaui::getKeyColumns(com::sun::star::uno::Reference<com::sun::star::container::XIndexAccess> const&, int)
@@ -814,7 +807,88 @@ 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::PropertyMap::dump(com::sun::star::uno::Reference<com::sun::star::beans::XPropertySet>)
+oox::core::BinaryFilterBase::BinaryFilterBase(com::sun::star::uno::Reference<com::sun::star::uno::XComponentContext> const&)
+oox::core::FilterBase::openSubStorage(rtl::OUString const&, bool) const
+oox::core::FilterBase::requestEncryptionData(comphelper::IDocPasswordVerifier&) const
+oox::dump::Output::writeAddress(oox::dump::Address const&)
+oox::dump::Output::writeColorABGR(int)
+oox::dump::Output::writeRange(oox::dump::Range const&)
+oox::dump::Output::writeRangeList(std::__debug::vector<oox::dump::Range, std::allocator<oox::dump::Range> > const&)
+oox::dump::OutputObjectBase::writeAddressItem(oox::dump::String const&, oox::dump::Address const&)
+oox::dump::OutputObjectBase::writeColIndexItem(oox::dump::String const&, int)
+oox::dump::OutputObjectBase::writeColRangeItem(oox::dump::String const&, int, int)
+oox::dump::OutputObjectBase::writeRangeItem(oox::dump::String const&, oox::dump::Range const&)
+oox::dump::OutputObjectBase::writeRangeListItem(oox::dump::String const&, std::__debug::vector<oox::dump::Range, std::allocator<oox::dump::Range> > const&)
+oox::dump::OutputObjectBase::writeRowIndexItem(oox::dump::String const&, int)
+oox::dump::OutputObjectBase::writeRowRangeItem(oox::dump::String const&, int, int)
+oox::dump::OutputObjectBase::writeTokenAddress3dItem(oox::dump::String const&, rtl::OUString const&, oox::dump::TokenAddress const&, bool)
+oox::dump::OutputObjectBase::writeTokenAddressItem(oox::dump::String const&, oox::dump::TokenAddress const&, bool)
+oox::dump::OutputObjectBase::writeTokenRange3dItem(oox::dump::String const&, rtl::OUString const&, oox::dump::TokenRange const&, bool)
+oox::dump::OutputObjectBase::writeTokenRangeItem(oox::dump::String const&, oox::dump::TokenRange const&, bool)
+oox::dump::SequenceRecordObjectBase::construct(oox::dump::OutputObjectBase const&, oox::dump::BinaryInputStreamRef const&, oox::dump::String const&, oox::dump::String const&)
+oox::dump::StdHlinkObject::StdHlinkObject(oox::dump::InputObjectBase const&)
+oox::dump::StringHelper::appendToken(rtl::OUStringBuffer&, long, unsigned short)
+oox::dump::TextStreamObjectBase::construct(oox::dump::InputObjectBase const&, unsigned short)
+oox::ole::OleHelper::importStdHlink(oox::ole::StdHlinkInfo&, oox::BinaryInputStream&, bool)
+oox::xls::BiffAutoFilterContext::BiffAutoFilterContext(oox::xls::WorksheetHelper const&, oox::xls::AutoFilter&)
+oox::xls::BiffCodecHelper::implReadFilePass(oox::xls::BiffInputStream&, oox::xls::BiffType)
+oox::xls::BiffDrawingBase::importObj(oox::xls::BiffInputStream&)
+oox::xls::BiffExternalSheetDataContext::BiffExternalSheetDataContext(oox::xls::WorkbookHelper const&, bool)
+oox::xls::BiffInputStream::tellBase() const
+oox::xls::BiffPivotTableContext::BiffPivotTableContext(oox::xls::WorksheetHelper const&)
+oox::xls::BiffQueryTableContext::BiffQueryTableContext(oox::xls::WorksheetHelper const&)
+oox::xls::BiffSheetDataContext::BiffSheetDataContext(oox::xls::WorksheetHelper const&)
+oox::xls::BiffWorksheetFragmentBase::BiffWorksheetFragmentBase(oox::xls::WorksheetHelper const&, oox::xls::BiffWorkbookFragmentBase const&)
oox::xls::CellBlock::CellBlock(oox::xls::WorksheetHelper const&, oox::ValueRange const&, int)
+oox::xls::CellStyleBuffer::importStyle(oox::xls::BiffInputStream&)
+oox::xls::ColorPalette::importPalette(oox::xls::BiffInputStream&)
+oox::xls::Comment::importNote(oox::xls::BiffInputStream&)
+oox::xls::CondFormatBuffer::importCfHeader(oox::xls::BiffInputStream&)
+oox::xls::Font::importFont(oox::xls::BiffInputStream&)
+oox::xls::NumberFormatsBuffer::importFormat(oox::xls::BiffInputStream&)
+oox::xls::PageSettings::importBottomMargin(oox::xls::BiffInputStream&)
+oox::xls::PageSettings::importFooter(oox::xls::BiffInputStream&)
+oox::xls::PageSettings::importHeader(oox::xls::BiffInputStream&)
+oox::xls::PageSettings::importHorCenter(oox::xls::BiffInputStream&)
+oox::xls::PageSettings::importLeftMargin(oox::xls::BiffInputStream&)
+oox::xls::PageSettings::importPageSetup(oox::xls::BiffInputStream&)
+oox::xls::PageSettings::importPicture(oox::xls::BiffInputStream&)
+oox::xls::PageSettings::importPrintGridLines(oox::xls::BiffInputStream&)
+oox::xls::PageSettings::importPrintHeaders(oox::xls::BiffInputStream&)
+oox::xls::PageSettings::importRightMargin(oox::xls::BiffInputStream&)
+oox::xls::PageSettings::importTopMargin(oox::xls::BiffInputStream&)
+oox::xls::PageSettings::importVerCenter(oox::xls::BiffInputStream&)
+oox::xls::PivotCache::importPCDSource(oox::xls::BiffInputStream&)
+oox::xls::SheetScenarios::importScenarios(oox::xls::BiffInputStream&)
+oox::xls::SheetViewSettings::importPane(oox::xls::BiffInputStream&)
+oox::xls::SheetViewSettings::importScl(oox::xls::BiffInputStream&)
+oox::xls::SheetViewSettings::importSelection(oox::xls::BiffInputStream&)
+oox::xls::SheetViewSettings::importWindow2(oox::xls::BiffInputStream&)
+oox::xls::WorkbookGlobals::createBuffersPerSheet(short)
+oox::xls::WorkbookGlobals::setCodePage(unsigned short)
+oox::xls::WorkbookGlobals::setIsWorkbookFile()
+oox::xls::WorkbookHelper::setAppFontEncoding(unsigned short)
+oox::xls::WorkbookSettings::importCalcCount(oox::xls::BiffInputStream&)
+oox::xls::WorkbookSettings::importCalcMode(oox::xls::BiffInputStream&)
+oox::xls::WorkbookSettings::importDelta(oox::xls::BiffInputStream&)
+oox::xls::WorkbookSettings::importIteration(oox::xls::BiffInputStream&)
+oox::xls::WorkbookSettings::importRefMode(oox::xls::BiffInputStream&)
+oox::xls::WorkbookSettings::importSaveRecalc(oox::xls::BiffInputStream&)
+oox::xls::WorkbookSettings::importUncalced(oox::xls::BiffInputStream&)
+oox::xls::WorksheetHelper::getBiffDrawing() const
+oox::xls::WorksheetHelper::setDefaultColumnFormat(int, int, int)
+oox::xls::WorksheetHelper::setLabelRanges(oox::xls::ApiCellRangeList const&, oox::xls::ApiCellRangeList const&)
+oox::xls::WorksheetSettings::importCodeName(oox::xls::BiffInputStream&)
+oox::xls::WorksheetSettings::importObjectProtect(oox::xls::BiffInputStream&)
+oox::xls::WorksheetSettings::importPassword(oox::xls::BiffInputStream&)
+oox::xls::WorksheetSettings::importPhoneticPr(oox::xls::BiffInputStream&)
+oox::xls::WorksheetSettings::importProtect(oox::xls::BiffInputStream&)
+oox::xls::WorksheetSettings::importScenProtect(oox::xls::BiffInputStream&)
+oox::xls::WorksheetSettings::importSheetExt(oox::xls::BiffInputStream&)
+oox::xls::WorksheetSettings::importSheetPr(oox::xls::BiffInputStream&)
+oox::xls::WorksheetSettings::importSheetProtection(oox::xls::BiffInputStream&)
+oox::xls::Xf::importXf(oox::xls::BiffInputStream&)
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&)
psp::PrinterGfx::GetGlyphBoundRect(unsigned short, Rectangle&)
@@ -833,7 +907,6 @@ sd::framework::ConfigurationTracer::TraceConfiguration(com::sun::star::uno::Refe
sd::slidesorter::cache::GenericPageCache::ReleasePreviewBitmap(SdrPage const*)
sd::slidesorter::controller::SelectionFunction::EventDescriptor::EventDescriptor(KeyEvent const&, sd::slidesorter::SlideSorter&)
sd::slidesorter::model::VisualState::SetVisualStateBlend(double)
-sd::slidesorter::view::(anonymous namespace)::PageObjectRun::GetInnerBoundingBox(sd::slidesorter::view::Layouter const&, int) const
sd::slidesorter::view::Button::IsDown() const
sd::slidesorter::view::FontProvider::GetFont(OutputDevice const&)
sdext::presenter::PresenterAnimation::PresenterAnimation(unsigned long, unsigned long, unsigned long)
@@ -841,9 +914,6 @@ sdr::animation::Scheduler::Reset(unsigned int)
sdr::contact::ViewContactOfPageObj::GetReferencedPage() const
sdr::contact::ViewContactOfSdrMediaObj::hasPreferredSize() const
sdr::contact::ViewObjectContactOfUnoControl::isControlVisible() const
-sdr::table::Cell::GetStyleSheetPool() const
-sdr::table::SdrTableObj::getColumnCount() const
-sdr::table::SdrTableObj::getRowCount() const
sfx2::TaskPaneWrapper::GetChildWindowId()
slideshow::internal::DrawShapeSubsetting::reset(slideshow::internal::DocTreeNode const&, boost::shared_ptr<GDIMetaFile> const&)
std::__cxx1998::multimap<_xmlNode*, com::sun::star::uno::Reference<com::sun::star::xml::dom::events::XEventListener>, std::less<_xmlNode*>, std::allocator<std::pair<_xmlNode* const, com::sun::star::uno::Reference<com::sun::star::xml::dom::events::XEventListener> > > >::~multimap()
commit 9c2dee67b56085ab8535a90810bf885fe0afd30c
Author: Caolán McNamara <caolanm at redhat.com>
Date: Wed Apr 4 10:11:31 2012 +0100
drop methods only used in svdem
diff --git a/svtools/inc/svtools/calendar.hxx b/svtools/inc/svtools/calendar.hxx
index c9df5a1..17dd52b 100644
--- a/svtools/inc/svtools/calendar.hxx
+++ b/svtools/inc/svtools/calendar.hxx
@@ -300,7 +300,6 @@ public:
void SetNoSelection();
sal_Bool IsDateSelected( const Date& rDate ) const;
Date GetFirstSelectedDate() const;
- Date GetLastSelectedDate() const;
void EnableCallEverySelect( sal_Bool bEvery = sal_True ) { mbAllSel = bEvery; }
sal_Bool IsCallEverySelectEnabled() const { return mbAllSel; }
diff --git a/svtools/source/control/calendar.cxx b/svtools/source/control/calendar.cxx
index 285e0d5..9732c76 100644
--- a/svtools/source/control/calendar.cxx
+++ b/svtools/source/control/calendar.cxx
@@ -1911,19 +1911,6 @@ Date Calendar::GetFirstSelectedDate() const
// -----------------------------------------------------------------------
-Date Calendar::GetLastSelectedDate() const
-{
- if ( !mpSelectTable->empty() )
- return Date( *mpSelectTable->rbegin() );
- else
- {
- Date aDate( 0, 0, 0 );
- return aDate;
- }
-}
-
-// -----------------------------------------------------------------------
-
void Calendar::SetCurDate( const Date& rNewDate )
{
if ( !rNewDate.IsValidAndGregorian() )
diff --git a/svtools/workben/svdem.cxx b/svtools/workben/svdem.cxx
index 7aede1c..be6ce3d 100644
--- a/svtools/workben/svdem.cxx
+++ b/svtools/workben/svdem.cxx
@@ -218,7 +218,6 @@ public:
DECL_LINK( Test, PushButton* );
DECL_LINK( SelectHdl, Window* );
- DECL_LINK( CalSelectHdl, CalendarField* );
void ContextMenu( const Point& rPos );
void Command( const CommandEvent& rCEvt );
@@ -819,8 +818,6 @@ MyWin::MyWin( Window* pParent, WinBits aWinStyle ) :
{
aCalendarField.EnableEmptyFieldValue( sal_True );
aCalendarField.SetCalendarStyle( aCalendarField.GetCalendarStyle() | WB_RANGESELECT );
- aCalendarField.SetSelectHdl( LINK( this, MyWin, CalSelectHdl ) );
-// aCalendarField.SetDate( Date() );
aCalendarField.SetEmptyDate();
aCalendarField.EnableToday();
aCalendarField.EnableNone();
@@ -1001,19 +998,6 @@ IMPL_LINK( MyWin, SelectHdl, Window*, pCtrl )
// -----------------------------------------------------------------------
-IMPL_LINK( MyWin, CalSelectHdl, CalendarField*, pCtrl )
-{
- if ( pCtrl == &aCalendarField )
- {
- Calendar* l_pCalendar = pCtrl->GetCalendar();
- aCalendarField2.SetDate( l_pCalendar->GetLastSelectDate() );
- }
-
- return 0;
-}
-
-// -----------------------------------------------------------------------
-
void MyWin::ContextMenu( const Point& rPos )
{
FontList aList( this );
commit 83b42cdccb797f1faf427b0beabc3806c5849592
Author: Caolán McNamara <caolanm at redhat.com>
Date: Tue Apr 3 23:18:43 2012 +0100
convert (ugly) WriteUniOrByteString to rtl::OUString
diff --git a/tools/inc/tools/stream.hxx b/tools/inc/tools/stream.hxx
index c2749ff..5b5c443 100644
--- a/tools/inc/tools/stream.hxx
+++ b/tools/inc/tools/stream.hxx
@@ -410,7 +410,7 @@ public:
rtl::OUString ReadUniOrByteString(rtl_TextEncoding eSrcCharSet);
/// Write a 32bit length prefixed sequence of utf-16 if eSrcCharSet==RTL_TEXTENCODING_UNICODE,
/// otherwise convert to eSrcCharSet and write a 16bit length prefixed sequence of bytes
- SvStream& WriteUniOrByteString( const UniString& rStr, rtl_TextEncoding eDestCharSet );
+ SvStream& WriteUniOrByteString( const rtl::OUString& rStr, rtl_TextEncoding eDestCharSet );
/// 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 );
diff --git a/tools/source/stream/stream.cxx b/tools/source/stream/stream.cxx
index ab3703b..1da4096 100644
--- a/tools/source/stream/stream.cxx
+++ b/tools/source/stream/stream.cxx
@@ -1414,18 +1414,18 @@ rtl::OUString SvStream::ReadUniOrByteString( rtl_TextEncoding eSrcCharSet )
// -----------------------------------------------------------------------
-SvStream& SvStream::WriteUniOrByteString( const UniString& rStr, rtl_TextEncoding eDestCharSet )
+SvStream& SvStream::WriteUniOrByteString( const rtl::OUString& rStr, rtl_TextEncoding eDestCharSet )
{
// write UTF-16 string directly into stream ?
if (eDestCharSet == RTL_TEXTENCODING_UNICODE)
{
- sal_uInt32 nLen = rStr.Len();
+ sal_Int32 nLen = rStr.getLength();
operator<< (nLen);
if (nLen)
{
if (bSwap)
{
- const sal_Unicode *pStr = rStr.GetBuffer();
+ const sal_Unicode *pStr = rStr.getStr();
const sal_Unicode *pEnd = pStr + nLen;
for (; pStr < pEnd; pStr++)
@@ -1436,7 +1436,7 @@ SvStream& SvStream::WriteUniOrByteString( const UniString& rStr, rtl_TextEncodin
}
}
else
- Write( rStr.GetBuffer(), nLen << 1 );
+ Write( rStr.getStr(), nLen << 1 );
}
return *this;
commit 5daa649c56250b60c35f58e11d245459067d7d83
Author: Caolán McNamara <caolanm at redhat.com>
Date: Tue Apr 3 23:10:43 2012 +0100
disabled for 11 years, not like to get fixed soon
diff --git a/toolkit/source/controls/stdtabcontroller.cxx b/toolkit/source/controls/stdtabcontroller.cxx
index 856287b..22c1f32 100644
--- a/toolkit/source/controls/stdtabcontroller.cxx
+++ b/toolkit/source/controls/stdtabcontroller.cxx
@@ -376,40 +376,6 @@ void StdTabController::activateLast( ) throw(RuntimeException)
Reference< XControl > StdTabController::FindControl( Sequence< Reference< XControl > >& rCtrls,
const Reference< XControlModel > & rxCtrlModel )
{
-
-/*
- // MT: Funktioniert nicht mehr, weil ich nicht mehr bei mir angemeldet bin,
- // weil DG das abfaengt.
-
- // #54677# Beim Laden eines HTML-Dokuments wird nach jedem Control ein
- // activateTabOrder gerufen und jede Menge Zeit in dieser Methode verbraten.
- // Die Anzahl dieser Schleifendurchlaufe steigt quadratisch, also versuchen
- // das Control direkt vom Model zu erhalten.
- // => Wenn genau ein Control als PropertyChangeListener angemeldet ist,
- // dann muss das auch das richtige sein.
-
- UnoControlModel* pUnoCtrlModel = UnoControlModel::GetImplementation( rxCtrlModel );
-
-
- if ( pUnoCtrlModel )
- {
- ListenerIterator aIt( pUnoCtrlModel->maPropertiesListeners );
- while( aIt.hasMoreElements() )
- {
- XEventListener* pL = aIt.next();
- Reference< XControl > xC( pL, UNO_QUERY );
- if ( xC.is() )
- {
- if( xC->getContext() == mxControlContainer )
- {
- xCtrl = xC;
- break;
- }
- }
- }
- }
- if ( !xCtrl.is() && rxCtrlModel.is())
-*/
DBG_ASSERT( rxCtrlModel.is(), "ImplFindControl - welches ?!" );
const Reference< XControl > * pCtrls = rCtrls.getConstArray();
commit c8ec81032478136c7e96d8df3b3536b90aee770d
Author: Caolán McNamara <caolanm at redhat.com>
Date: Tue Apr 3 23:03:15 2012 +0100
pure virtual with unused baseclass impl
diff --git a/editeng/source/items/svxfont.cxx b/editeng/source/items/svxfont.cxx
index 75954c9..02bca71 100644
--- a/editeng/source/items/svxfont.cxx
+++ b/editeng/source/items/svxfont.cxx
@@ -217,9 +217,6 @@ void SvxDoCapitals::DoSpace( const sal_Bool /*bDraw*/ ) { }
void SvxDoCapitals::SetSpace() { }
-void SvxDoCapitals::Do( const XubString &/*_rTxt*/, const xub_StrLen /*_nIdx*/,
- const xub_StrLen /*_nLen*/, const sal_Bool /*bUpper*/ ) { }
-
/*************************************************************************
* SvxFont::DoOnCapitals() const
* Decomposes the String into uppercase and lowercase letters and then
diff --git a/unusedcode.easy b/unusedcode.easy
index 4765225..c2a6e14 100755
--- a/unusedcode.easy
+++ b/unusedcode.easy
@@ -166,7 +166,6 @@ SvxAutocorrWordList::Insert(SvxAutocorrWord* const*, unsigned short)
SvxAutocorrWordList::Insert(SvxAutocorrWordList const*, unsigned short, unsigned short)
SvxAutocorrWordList::Remove(SvxAutocorrWord* const&, unsigned short)
SvxAutocorrWordList::Remove(unsigned short, unsigned short)
-SvxDoCapitals::Do(String const&, unsigned short, unsigned short, unsigned char)
SvxMSDffShapeInfos::Insert(SvxMSDffShapeInfo* const&, unsigned short&)
SvxMSDffShapeInfos::Insert(SvxMSDffShapeInfo* const*, unsigned short)
SvxMSDffShapeInfos::Insert(SvxMSDffShapeInfos const*, unsigned short, unsigned short)
commit 3c19ff4f8531067623c7033c3b8da0c75254622d
Author: Caolán McNamara <caolanm at redhat.com>
Date: Tue Apr 3 22:53:25 2012 +0100
DEFINE_CONST_UNICODE isn't needed here anymore
diff --git a/desktop/source/app/app.cxx b/desktop/source/app/app.cxx
index 7b83803..0a448c1 100644
--- a/desktop/source/app/app.cxx
+++ b/desktop/source/app/app.cxx
@@ -102,8 +102,6 @@
#include <sys/wait.h>
#endif
-#define DEFINE_CONST_UNICODE(CONSTASCII) UniString(RTL_CONSTASCII_USTRINGPARAM(CONSTASCII))
-
using rtl::OUString;
using rtl::OUStringBuffer;
@@ -1566,7 +1564,7 @@ int Desktop::Main()
#ifdef DBG_UTIL
//include version ID in non product builds
::rtl::OUString aDefault(RTL_CONSTASCII_USTRINGPARAM("development"));
- aTitle += DEFINE_CONST_UNICODE(" [");
+ aTitle += rtl::OUString(" [");
String aVerId( utl::Bootstrap::getProductSource(aDefault));
aTitle += aVerId;
aTitle += ']';
@@ -1597,7 +1595,7 @@ int Desktop::Main()
// create service for loadin SFX (still needed in startup)
pExecGlobals->xGlobalBroadcaster = Reference < css::document::XEventListener >
( xSMgr->createInstance(
- DEFINE_CONST_UNICODE( "com.sun.star.frame.GlobalEventBroadcaster" ) ), UNO_QUERY );
+ rtl::OUString( "com.sun.star.frame.GlobalEventBroadcaster" ) ), UNO_QUERY );
/* ensure existance of a default window that messages can be dispatched to
This is for the benefit of testtool which uses PostUserEvent extensively
@@ -2002,7 +2000,7 @@ sal_Bool Desktop::InitializeQuickstartMode( Reference< XMultiServiceFactory >& r
Sequence< Any > aSeq( 1 );
aSeq[0] <<= bQuickstart;
Reference < XComponent > xQuickstart( rSMgr->createInstanceWithArguments(
... etc. - the rest is truncated
More information about the Libreoffice-commits
mailing list