summaryrefslogtreecommitdiff
path: root/sw
diff options
context:
space:
mode:
authorNoel Grandin <noel@peralex.com>2014-03-17 09:14:55 +0200
committerNoel Grandin <noel@peralex.com>2014-03-17 13:30:51 +0200
commit769a6c20c4eb9e081cdc46dd638f67927fc7bc25 (patch)
treeef7c0e04c12897d8b73a2b2e3de3df477f83f37c /sw
parent006df8a7f77d79d5ab2d8da053552a0ccc3dcd7a (diff)
sw: prefer passing OUString by reference
Change-Id: Iaa846ec8f19567f0a9f30154d74cc53df93eff16
Diffstat (limited to 'sw')
-rw-r--r--sw/inc/PostItMgr.hxx2
-rw-r--r--sw/inc/acmplwrd.hxx2
-rw-r--r--sw/inc/ddefld.hxx2
-rw-r--r--sw/inc/doc.hxx6
-rw-r--r--sw/inc/docsh.hxx2
-rw-r--r--sw/inc/editsh.hxx2
-rw-r--r--sw/inc/expfld.hxx2
-rw-r--r--sw/inc/list.hxx2
-rw-r--r--sw/inc/numrule.hxx2
-rw-r--r--sw/inc/section.hxx2
-rw-r--r--sw/inc/swabstdlg.hxx6
-rw-r--r--sw/inc/unotxdoc.hxx4
-rw-r--r--sw/qa/extras/inc/swmodeltestbase.hxx16
-rw-r--r--sw/qa/extras/rtfimport/rtfimport.cxx2
-rw-r--r--sw/source/core/access/acccell.cxx28
-rw-r--r--sw/source/core/access/acctable.hxx2
-rw-r--r--sw/source/core/doc/acmplwrd.cxx2
-rw-r--r--sw/source/core/doc/docdesc.cxx2
-rw-r--r--sw/source/core/doc/docnum.cxx4
-rw-r--r--sw/source/core/doc/doctxm.cxx2
-rw-r--r--sw/source/core/doc/list.cxx6
-rw-r--r--sw/source/core/docnode/section.cxx2
-rw-r--r--sw/source/core/edit/ednumber.cxx2
-rw-r--r--sw/source/core/fields/cellfml.cxx13
-rw-r--r--sw/source/core/fields/chpfld.cxx2
-rw-r--r--sw/source/core/fields/ddefld.cxx3
-rw-r--r--sw/source/core/fields/expfld.cxx2
-rw-r--r--sw/source/core/graphic/ndgrf.cxx2
-rw-r--r--sw/source/core/inc/txmsrt.hxx4
-rw-r--r--sw/source/core/inc/txtfrm.hxx2
-rw-r--r--sw/source/core/inc/unoflatpara.hxx2
-rw-r--r--sw/source/core/tox/txmsrt.cxx2
-rw-r--r--sw/source/core/uibase/app/docst.cxx2
-rw-r--r--sw/source/core/uibase/dbui/mmconfigitem.cxx4
-rw-r--r--sw/source/core/uibase/docvw/PostItMgr.cxx2
-rw-r--r--sw/source/core/uibase/inc/frmdlg.hxx4
-rw-r--r--sw/source/core/uibase/inc/initui.hxx10
-rw-r--r--sw/source/core/uibase/inc/mmconfigitem.hxx4
-rw-r--r--sw/source/core/uibase/inc/swuipardlg.hxx2
-rw-r--r--sw/source/core/uibase/inc/tmpdlg.hxx2
-rw-r--r--sw/source/core/uibase/misc/glosdoc.cxx2
-rw-r--r--sw/source/core/uibase/uiview/srcview.cxx31
-rw-r--r--sw/source/core/uibase/uno/unotxdoc.cxx7
-rw-r--r--sw/source/core/uibase/utlui/initui.cxx12
-rw-r--r--sw/source/core/undo/undel.cxx2
-rw-r--r--sw/source/core/unocore/unoflatpara.cxx2
-rw-r--r--sw/source/filter/html/htmlbas.cxx2
-rw-r--r--sw/source/filter/html/swhtml.hxx2
-rw-r--r--sw/source/filter/ww8/docxexport.cxx2
-rw-r--r--sw/source/filter/ww8/docxexport.hxx2
-rw-r--r--sw/source/filter/ww8/docxsdrexport.cxx2
-rw-r--r--sw/source/filter/ww8/docxsdrexport.hxx2
-rw-r--r--sw/source/filter/ww8/docxtablestyleexport.cxx4
-rw-r--r--sw/source/filter/ww8/ww8par.hxx10
-rw-r--r--sw/source/filter/ww8/ww8par3.cxx2
-rw-r--r--sw/source/filter/ww8/ww8par5.cxx8
-rw-r--r--sw/source/filter/xml/xmltbli.cxx2
-rw-r--r--sw/source/ui/chrdlg/pardlg.cxx2
-rw-r--r--sw/source/ui/dbui/mmaddressblockpage.cxx2
-rw-r--r--sw/source/ui/dbui/mmaddressblockpage.hxx2
-rw-r--r--sw/source/ui/dialog/swdlgfact.cxx6
-rw-r--r--sw/source/ui/dialog/swdlgfact.hxx6
-rw-r--r--sw/source/ui/fmtui/tmpdlg.cxx2
-rw-r--r--sw/source/ui/frmdlg/frmdlg.cxx4
-rw-r--r--sw/source/ui/table/tautofmt.cxx2
-rw-r--r--sw/source/ui/vba/vbafield.cxx4
-rw-r--r--sw/source/ui/vba/vbafield.hxx4
67 files changed, 148 insertions, 144 deletions
diff --git a/sw/inc/PostItMgr.hxx b/sw/inc/PostItMgr.hxx
index 1467beddc312..0355ae569ebe 100644
--- a/sw/inc/PostItMgr.hxx
+++ b/sw/inc/PostItMgr.hxx
@@ -214,7 +214,7 @@ class SwPostItMgr: public SfxListener
void CorrectPositions();
void SetLayout() { mbLayout = true; };
- void Delete(OUString aAuthor);
+ void Delete(const OUString& aAuthor);
void Delete();
void Hide( const OUString& rAuthor );
diff --git a/sw/inc/acmplwrd.hxx b/sw/inc/acmplwrd.hxx
index dde48539bf37..1f78fea460c7 100644
--- a/sw/inc/acmplwrd.hxx
+++ b/sw/inc/acmplwrd.hxx
@@ -70,7 +70,7 @@ public:
void CheckChangedList(const editeng::SortedAutoCompleteStrings& rNewLst);
// Returns all words matching a given prefix aMatch.
- bool GetWordsMatching(OUString aMatch, std::vector<OUString>& aWords) const;
+ bool GetWordsMatching(const OUString& aMatch, std::vector<OUString>& aWords) const;
};
#endif
diff --git a/sw/inc/ddefld.hxx b/sw/inc/ddefld.hxx
index 3fa8df5cb08c..bb2343e23fc9 100644
--- a/sw/inc/ddefld.hxx
+++ b/sw/inc/ddefld.hxx
@@ -59,7 +59,7 @@ public:
virtual bool PutValue( const com::sun::star::uno::Any& rVal, sal_uInt16 nWhich );
OUString GetCmd() const;
- void SetCmd( OUString aStr );
+ void SetCmd( const OUString& aStr );
sal_uInt16 GetType() const { return refLink->GetUpdateMode(); }
void SetType( sal_uInt16 nType ) { refLink->SetUpdateMode( nType ); }
diff --git a/sw/inc/doc.hxx b/sw/inc/doc.hxx
index 2f030ba3613c..034dbd57c962 100644
--- a/sw/inc/doc.hxx
+++ b/sw/inc/doc.hxx
@@ -1367,7 +1367,7 @@ public:
sal_uInt16 MakePageDesc( const OUString &rName, const SwPageDesc* pCpy = 0,
bool bRegardLanguage = true,
bool bBroadcast = false);
- void BroadcastStyleOperation(OUString rName, SfxStyleFamily eFamily,
+ void BroadcastStyleOperation(const OUString& rName, SfxStyleFamily eFamily,
sal_uInt16 nOp);
/** The html import sometimes overwrites the
@@ -1394,7 +1394,7 @@ public:
bool DeleteTOX( const SwTOXBase& rTOXBase, bool bDelNodes = false );
OUString GetUniqueTOXBaseName( const SwTOXType& rType,
- const OUString sChkStr ) const;
+ const OUString& sChkStr ) const;
bool SetTOXBaseName(const SwTOXBase& rTOXBase, const OUString& rName);
void SetTOXBaseProtection(const SwTOXBase& rTOXBase, sal_Bool bProtect);
@@ -1496,7 +1496,7 @@ public:
void SetNumRule( const SwPaM&,
const SwNumRule&,
const bool bCreateNewList,
- const OUString sContinuedListId = OUString(),
+ const OUString& sContinuedListId = OUString(),
bool bSetItem = true,
const bool bResetIndentAttrs = false );
void SetCounted( const SwPaM&, bool bCounted);
diff --git a/sw/inc/docsh.hxx b/sw/inc/docsh.hxx
index 61d354678e26..30c2ecfbf42f 100644
--- a/sw/inc/docsh.hxx
+++ b/sw/inc/docsh.hxx
@@ -113,7 +113,7 @@ class SW_DLLPUBLIC SwDocShell: public SfxObjectShell, public SfxListener
const sal_uInt16 nFamily,
sal_uInt16 nMask,
const sal_Bool bNew,
- const OString sPageId = OString(),
+ const OString& sPageId = OString(),
SwWrtShell* pActShell = 0,
const sal_Bool bBasic = sal_False );
diff --git a/sw/inc/editsh.hxx b/sw/inc/editsh.hxx
index 7d5dd387b7d7..f2d11c4eb23d 100644
--- a/sw/inc/editsh.hxx
+++ b/sw/inc/editsh.hxx
@@ -472,7 +472,7 @@ public:
list Id of a list, which has to be continued by applying the given list style. */
void SetCurNumRule( const SwNumRule&,
const bool bCreateNewList /*= false*/,
- const OUString sContinuedListId = OUString(),
+ const OUString& sContinuedListId = OUString(),
const bool bResetIndentAttrs = false );
/// Paragraphs without enumeration but with indents.
diff --git a/sw/inc/expfld.hxx b/sw/inc/expfld.hxx
index 6a47e0627075..8aaf12e04abc 100644
--- a/sw/inc/expfld.hxx
+++ b/sw/inc/expfld.hxx
@@ -39,7 +39,7 @@ class SwEditShell;
const SwTxtNode* GetBodyTxtNode( const SwDoc& pDoc, SwPosition& rPos,
const SwFrm& rFrm );
-OUString ReplacePoint(OUString sTmpName, bool bWithCommandType = false);
+OUString ReplacePoint(const OUString& sTmpName, bool bWithCommandType = false);
struct _SeqFldLstElem
{
diff --git a/sw/inc/list.hxx b/sw/inc/list.hxx
index 19662538e7ba..dfa6eaafa5f6 100644
--- a/sw/inc/list.hxx
+++ b/sw/inc/list.hxx
@@ -31,7 +31,7 @@ class SwListImpl;
class SwList
{
public:
- SwList( const OUString sListId,
+ SwList( const OUString& sListId,
SwNumRule& rDefaultListStyle,
const SwNodes& rNodes );
~SwList();
diff --git a/sw/inc/numrule.hxx b/sw/inc/numrule.hxx
index 68c9f282832b..27827250acd4 100644
--- a/sw/inc/numrule.hxx
+++ b/sw/inc/numrule.hxx
@@ -193,7 +193,7 @@ public:
void AddParagraphStyle( SwTxtFmtColl& rTxtFmtColl );
void RemoveParagraphStyle( SwTxtFmtColl& rTxtFmtColl );
- inline void SetDefaultListId( const OUString sDefaultListId )
+ inline void SetDefaultListId( const OUString& sDefaultListId )
{
msDefaultListId = sDefaultListId;
}
diff --git a/sw/inc/section.hxx b/sw/inc/section.hxx
index 539918cfd4d2..40eba2acbd60 100644
--- a/sw/inc/section.hxx
+++ b/sw/inc/section.hxx
@@ -139,7 +139,7 @@ public:
bool IsConnectFlag() const { return m_bConnectFlag; }
void SetConnectFlag(bool const bFlag = true){ m_bConnectFlag = bFlag; }
- static OUString CollapseWhiteSpaces(const OUString sName);
+ static OUString CollapseWhiteSpaces(const OUString& sName);
};
class SW_DLLPUBLIC SwSection
diff --git a/sw/inc/swabstdlg.hxx b/sw/inc/swabstdlg.hxx
index 925da1bfb578..c5f7c745e7cd 100644
--- a/sw/inc/swabstdlg.hxx
+++ b/sw/inc/swabstdlg.hxx
@@ -363,7 +363,7 @@ public:
sal_uInt8 nDialogMode,
const OUString *pCollName = 0,
sal_Bool bDraw = sal_False,
- OString sDefPage = OString() ) = 0;
+ const OString& sDefPage = OString() ) = 0;
virtual AbstractSwSelGlossaryDlg * CreateSwSelGlossaryDlg(Window * pParent, const OUString &rShortName) = 0;
@@ -393,7 +393,7 @@ public:
const SfxItemSet& rCoreSet,
bool bNewFrm = true,
bool bFmt = false,
- OString sDefPage = OString(),
+ const OString& sDefPage = OString(),
const OUString* pFmtStr = 0) = 0;
// @param nSlot
// Identifies optional Slot by which the creation of the Template (Style) dialog is triggered.
@@ -402,7 +402,7 @@ public:
Window* pParent,
SfxStyleSheetBase& rBase,
sal_uInt16 nRegion,
- OString sPage = OString(),
+ const OString& sPage = OString(),
SwWrtShell* pActShell = 0,
bool bNew = false) = 0;
virtual AbstractGlossaryDlg* CreateGlossaryDlg(SfxViewFrame* pViewFrame,
diff --git a/sw/inc/unotxdoc.hxx b/sw/inc/unotxdoc.hxx
index 742e493d4715..f9bc195dd0bc 100644
--- a/sw/inc/unotxdoc.hxx
+++ b/sw/inc/unotxdoc.hxx
@@ -502,9 +502,9 @@ class SwXLinkNameAccessWrapper : public cppu::WeakImplHelper4
public:
SwXLinkNameAccessWrapper(css::uno::Reference< css::container::XNameAccess > xAccess,
- const OUString& rLinkDisplayName, OUString sSuffix);
+ const OUString& rLinkDisplayName, const OUString& sSuffix);
SwXLinkNameAccessWrapper(SwXTextDocument& rxDoc,
- const OUString& rLinkDisplayName, OUString sSuffix);
+ const OUString& rLinkDisplayName, const OUString& sSuffix);
~SwXLinkNameAccessWrapper();
//XNameAccess
diff --git a/sw/qa/extras/inc/swmodeltestbase.hxx b/sw/qa/extras/inc/swmodeltestbase.hxx
index dde4a453d5bb..c82ae7c3e07c 100644
--- a/sw/qa/extras/inc/swmodeltestbase.hxx
+++ b/sw/qa/extras/inc/swmodeltestbase.hxx
@@ -242,7 +242,7 @@ protected:
}
/// Get a family of styles, see com.sun.star.style.StyleFamilies for possible values.
- uno::Reference<container::XNameAccess> getStyles(OUString aFamily)
+ uno::Reference<container::XNameAccess> getStyles(const OUString& aFamily)
{
uno::Reference<style::XStyleFamiliesSupplier> xStyleFamiliesSupplier(mxComponent, uno::UNO_QUERY);
uno::Reference<container::XNameAccess> xStyleFamilies(xStyleFamiliesSupplier->getStyleFamilies(), uno::UNO_QUERY);
@@ -251,7 +251,7 @@ protected:
}
/// Get a family of auto styles, see com.sun.star.style.StyleFamilies for possible values.
- uno::Reference<style::XAutoStyleFamily> getAutoStyles(OUString aFamily)
+ uno::Reference<style::XAutoStyleFamily> getAutoStyles(const OUString& aFamily)
{
uno::Reference< style::XAutoStylesSupplier > xAutoStylesSupplier(mxComponent, uno::UNO_QUERY);
uno::Reference< style::XAutoStyles > xAutoStyles(xAutoStylesSupplier->getAutoStyles());
@@ -264,7 +264,7 @@ protected:
*
* If the attribute is omitted, the text of the node is returned.
*/
- OUString parseDump(OString aXPath, OString aAttribute = OString())
+ OUString parseDump(const OString& aXPath, const OString& aAttribute = OString())
{
if (!mpXmlBuffer)
dumpLayout();
@@ -347,7 +347,7 @@ protected:
}
// Get paragraph (counted from 1), optionally check it contains the given text.
- uno::Reference< text::XTextRange > getParagraph( int number, OUString content = OUString() ) const
+ uno::Reference< text::XTextRange > getParagraph( int number, const OUString& content = OUString() ) const
{
uno::Reference<text::XTextRange> const xParagraph(
getParagraphOrTable(number), uno::UNO_QUERY_THROW);
@@ -356,7 +356,7 @@ protected:
return xParagraph;
}
- uno::Reference<text::XTextRange> getParagraphOfText(int number, uno::Reference<text::XText> xText, OUString content = OUString()) const
+ uno::Reference<text::XTextRange> getParagraphOfText(int number, uno::Reference<text::XText> xText, const OUString& content = OUString()) const
{
uno::Reference<text::XTextRange> const xParagraph(getParagraphOrTable(number, xText), uno::UNO_QUERY_THROW);
if (!content.isEmpty())
@@ -365,7 +365,7 @@ protected:
}
/// Get run (counted from 1) of a paragraph, optionally check it contains the given text.
- uno::Reference<text::XTextRange> getRun(uno::Reference<text::XTextRange> xParagraph, int number, OUString content = OUString()) const
+ uno::Reference<text::XTextRange> getRun(uno::Reference<text::XTextRange> xParagraph, int number, const OUString& content = OUString()) const
{
uno::Reference<container::XEnumerationAccess> xRunEnumAccess(xParagraph, uno::UNO_QUERY);
uno::Reference<container::XEnumeration> xRunEnum = xRunEnumAccess->createEnumeration();
@@ -414,7 +414,7 @@ protected:
}
/// Get TextFrame by name
- uno::Reference<drawing::XShape> getTextFrameByName(OUString aName)
+ uno::Reference<drawing::XShape> getTextFrameByName(const OUString& aName)
{
uno::Reference<text::XTextFramesSupplier> xTextFramesSupplier(mxComponent, uno::UNO_QUERY);
uno::Reference<container::XNameAccess> xNameAccess(xTextFramesSupplier->getTextFrames(), uno::UNO_QUERY);
@@ -473,7 +473,7 @@ protected:
}
/// Save the loaded document to a tempfile. Can be used to check the resulting docx/odt directly as a ZIP file.
- void save(OUString aFilter, utl::TempFile& rTempFile)
+ void save(const OUString& aFilter, utl::TempFile& rTempFile)
{
rTempFile.EnableKillingFile();
uno::Reference<frame::XStorable> xStorable(mxComponent, uno::UNO_QUERY);
diff --git a/sw/qa/extras/rtfimport/rtfimport.cxx b/sw/qa/extras/rtfimport/rtfimport.cxx
index a48f976a02d8..cb19476e9d64 100644
--- a/sw/qa/extras/rtfimport/rtfimport.cxx
+++ b/sw/qa/extras/rtfimport/rtfimport.cxx
@@ -84,7 +84,7 @@ public:
protected:
/// Copy&paste helper.
- void paste(OUString aFilename, uno::Reference<text::XTextRange> xTextRange = uno::Reference<text::XTextRange>())
+ void paste(const OUString& aFilename, uno::Reference<text::XTextRange> xTextRange = uno::Reference<text::XTextRange>())
{
uno::Reference<document::XFilter> xFilter(m_xSFactory->createInstance("com.sun.star.comp.Writer.RtfFilter"), uno::UNO_QUERY_THROW);
uno::Reference<document::XImporter> xImporter(xFilter, uno::UNO_QUERY_THROW);
diff --git a/sw/source/core/access/acccell.cxx b/sw/source/core/access/acccell.cxx
index 1eea4f7ed413..29933cd307fd 100644
--- a/sw/source/core/access/acccell.cxx
+++ b/sw/source/core/access/acccell.cxx
@@ -391,28 +391,26 @@ uno::Any SwAccessibleCell::getMinimumValue( )
return aAny;
}
-static OUString ReplaceOneChar(OUString oldOUString, OUString replacedChar, OUString replaceStr)
+static OUString ReplaceOneChar(const OUString& oldOUString, const OUString& replacedChar, const OUString& replaceStr)
{
int iReplace = oldOUString.lastIndexOf(replacedChar);
- if (iReplace > -1)
+ OUString aRet = oldOUString;
+ while(iReplace > -1)
{
- for(;iReplace>-1;)
- {
- oldOUString = oldOUString.replaceAt(iReplace,1, replaceStr);
- iReplace=oldOUString.lastIndexOf(replacedChar,iReplace);
- }
+ aRet = aRet.replaceAt(iReplace,1, replaceStr);
+ iReplace = aRet.lastIndexOf(replacedChar,iReplace);
}
- return oldOUString;
+ return aRet;
}
-static OUString ReplaceFourChar(OUString oldOUString)
+static OUString ReplaceFourChar(const OUString& oldOUString)
{
- oldOUString = ReplaceOneChar(oldOUString,OUString("\\"),OUString("\\\\"));
- oldOUString = ReplaceOneChar(oldOUString,OUString(";"),OUString("\\;"));
- oldOUString = ReplaceOneChar(oldOUString,OUString("="),OUString("\\="));
- oldOUString = ReplaceOneChar(oldOUString,OUString(","),OUString("\\,"));
- oldOUString = ReplaceOneChar(oldOUString,OUString(":"),OUString("\\:"));
- return oldOUString;
+ OUString aRet = ReplaceOneChar(oldOUString,OUString("\\"),OUString("\\\\"));
+ aRet = ReplaceOneChar(aRet,OUString(";"),OUString("\\;"));
+ aRet = ReplaceOneChar(aRet,OUString("="),OUString("\\="));
+ aRet = ReplaceOneChar(aRet,OUString(","),OUString("\\,"));
+ aRet = ReplaceOneChar(aRet,OUString(":"),OUString("\\:"));
+ return aRet;
}
::com::sun::star::uno::Any SAL_CALL SwAccessibleCell::getExtendedAttributes()
diff --git a/sw/source/core/access/acctable.hxx b/sw/source/core/access/acctable.hxx
index 703363350011..f70e15c54ace 100644
--- a/sw/source/core/access/acctable.hxx
+++ b/sw/source/core/access/acctable.hxx
@@ -64,7 +64,7 @@ protected:
virtual ~SwAccessibleTable();
// #i77106#
- inline void SetDesc( OUString sNewDesc )
+ inline void SetDesc( const OUString& sNewDesc )
{
sDesc = sNewDesc;
}
diff --git a/sw/source/core/doc/acmplwrd.cxx b/sw/source/core/doc/acmplwrd.cxx
index d895ae9f8e4b..3bbcdf1bc2de 100644
--- a/sw/source/core/doc/acmplwrd.cxx
+++ b/sw/source/core/doc/acmplwrd.cxx
@@ -348,7 +348,7 @@ void SwAutoCompleteWord::SetMinWordLen( sal_uInt16 n )
* @param aMatch the prefix to search for
* @param aWords the words to search in
*/
-bool SwAutoCompleteWord::GetWordsMatching(OUString aMatch, std::vector<OUString>& aWords) const
+bool SwAutoCompleteWord::GetWordsMatching(const OUString& aMatch, std::vector<OUString>& aWords) const
{
OUString aStringRoot = aMatch;
diff --git a/sw/source/core/doc/docdesc.cxx b/sw/source/core/doc/docdesc.cxx
index 0bd6a01ec411..0d0172cedd3a 100644
--- a/sw/source/core/doc/docdesc.cxx
+++ b/sw/source/core/doc/docdesc.cxx
@@ -543,7 +543,7 @@ void SwDoc::PreDelPageDesc(SwPageDesc * pDel)
}
}
-void SwDoc::BroadcastStyleOperation(OUString rName, SfxStyleFamily eFamily,
+void SwDoc::BroadcastStyleOperation(const OUString& rName, SfxStyleFamily eFamily,
sal_uInt16 nOp)
{
if (mpDocShell)
diff --git a/sw/source/core/doc/docnum.cxx b/sw/source/core/doc/docnum.cxx
index 55f585c81fe0..f66b8e6832c3 100644
--- a/sw/source/core/doc/docnum.cxx
+++ b/sw/source/core/doc/docnum.cxx
@@ -822,7 +822,7 @@ static void lcl_ChgNumRule( SwDoc& rDoc, const SwNumRule& rRule )
void SwDoc::SetNumRule( const SwPaM& rPam,
const SwNumRule& rRule,
const bool bCreateNewList,
- const OUString sContinuedListId,
+ const OUString& sContinuedListId,
bool bSetItem,
const bool bResetIndentAttrs )
{
@@ -2583,7 +2583,7 @@ void SwDoc::trackChangeOfListStyleName( const OUString& sListStyleName,
namespace listfunc
{
const OUString MakeListIdUnique( const SwDoc& rDoc,
- const OUString aSuggestedUniqueListId )
+ const OUString& aSuggestedUniqueListId )
{
long nHitCount = 0;
OUString aTmpStr = aSuggestedUniqueListId;
diff --git a/sw/source/core/doc/doctxm.cxx b/sw/source/core/doc/doctxm.cxx
index 8de2cacbe872..486a597cf31e 100644
--- a/sw/source/core/doc/doctxm.cxx
+++ b/sw/source/core/doc/doctxm.cxx
@@ -610,7 +610,7 @@ const SwTOXType* SwDoc::InsertTOXType( const SwTOXType& rTyp )
}
OUString SwDoc::GetUniqueTOXBaseName( const SwTOXType& rType,
- const OUString sChkStr ) const
+ const OUString& sChkStr ) const
{
bool bUseChkStr = !sChkStr.isEmpty();
const OUString aName( rType.GetTypeName() );
diff --git a/sw/source/core/doc/list.cxx b/sw/source/core/doc/list.cxx
index a37778aa7bd4..71c7cee112ae 100644
--- a/sw/source/core/doc/list.cxx
+++ b/sw/source/core/doc/list.cxx
@@ -30,7 +30,7 @@
class SwListImpl
{
public:
- SwListImpl( const OUString sListId,
+ SwListImpl( const OUString& sListId,
SwNumRule& rDefaultListStyle,
const SwNodes& rNodes );
~SwListImpl();
@@ -67,7 +67,7 @@ class SwListImpl
void NotifyItemsOnListLevel( const int nLevel );
};
-SwListImpl::SwListImpl( const OUString sListId,
+SwListImpl::SwListImpl( const OUString& sListId,
SwNumRule& rDefaultListStyle,
const SwNodes& rNodes )
: msListId( sListId ),
@@ -220,7 +220,7 @@ void SwListImpl::NotifyItemsOnListLevel( const int nLevel )
}
// SwList ---------------------------------------------------------------------
-SwList::SwList( const OUString sListId,
+SwList::SwList( const OUString& sListId,
SwNumRule& rDefaultListStyle,
const SwNodes& rNodes )
: mpListImpl( new SwListImpl( sListId, rDefaultListStyle, rNodes ) )
diff --git a/sw/source/core/docnode/section.cxx b/sw/source/core/docnode/section.cxx
index 0b859064e8de..f452d9fda2cb 100644
--- a/sw/source/core/docnode/section.cxx
+++ b/sw/source/core/docnode/section.cxx
@@ -174,7 +174,7 @@ bool SwSectionData::operator==(SwSectionData const& rOther) const
// FIXME: old code ignored m_bCondHiddenFlag m_bHiddenFlag m_bConnectFlag
}
-OUString SwSectionData::CollapseWhiteSpaces(const OUString sName)
+OUString SwSectionData::CollapseWhiteSpaces(const OUString& sName)
{
const sal_Int32 nLen = sName.getLength();
const sal_Unicode cRef = ' ';
diff --git a/sw/source/core/edit/ednumber.cxx b/sw/source/core/edit/ednumber.cxx
index 04a3ef8011f9..a534e616165e 100644
--- a/sw/source/core/edit/ednumber.cxx
+++ b/sw/source/core/edit/ednumber.cxx
@@ -715,7 +715,7 @@ const SwNumRule* SwEditShell::GetCurNumRule() const
void SwEditShell::SetCurNumRule( const SwNumRule& rRule,
const bool bCreateNewList,
- const OUString sContinuedListId,
+ const OUString& sContinuedListId,
const bool bResetIndentAttrs )
{
StartAllAction();
diff --git a/sw/source/core/fields/cellfml.cxx b/sw/source/core/fields/cellfml.cxx
index d693139dfd1f..3f142e5ed5bd 100644
--- a/sw/source/core/fields/cellfml.cxx
+++ b/sw/source/core/fields/cellfml.cxx
@@ -57,11 +57,11 @@ static const SwFrm* lcl_GetBoxFrm( const SwTableBox& rBox );
static sal_Int32 lcl_GetLongBoxNum( OUString& rStr );
static const SwTableBox* lcl_RelToBox( const SwTable& rTbl,
const SwTableBox* pRefBox,
- OUString sGetName);
+ const OUString& sGetName);
static OUString lcl_BoxNmToRel( const SwTable& rTbl,
const SwTableNode& rTblNd,
- OUString sRefBoxNm,
- OUString sGetStr,
+ const OUString& sRefBoxNm,
+ const OUString& sGetStr,
bool bExtrnlNm);
/** Get value of this box.
@@ -738,10 +738,11 @@ static sal_Int32 lcl_GetLongBoxNum( OUString& rStr )
static const SwTableBox* lcl_RelToBox( const SwTable& rTbl,
const SwTableBox* pRefBox,
- OUString sGetName )
+ const OUString& _sGetName )
{
// get line
const SwTableBox* pBox = 0;
+ OUString sGetName = _sGetName;
// Is it really a relative value?
if ( cRelIdentifier == sGetName[0] ) // yes
@@ -822,8 +823,10 @@ static const SwTableBox* lcl_RelToBox( const SwTable& rTbl,
}
static OUString lcl_BoxNmToRel( const SwTable& rTbl, const SwTableNode& rTblNd,
- OUString sRefBoxNm, OUString sTmp, bool bExtrnlNm )
+ const OUString& _sRefBoxNm, const OUString& _sTmp, bool bExtrnlNm )
{
+ OUString sTmp = _sTmp;
+ OUString sRefBoxNm = _sRefBoxNm;
if( !bExtrnlNm )
{
// convert into external presentation
diff --git a/sw/source/core/fields/chpfld.cxx b/sw/source/core/fields/chpfld.cxx
index 7e687e1943bb..d001deb3b357 100644
--- a/sw/source/core/fields/chpfld.cxx
+++ b/sw/source/core/fields/chpfld.cxx
@@ -32,7 +32,7 @@ using namespace ::com::sun::star;
namespace
{
-OUString removeControlChars(OUString sIn)
+OUString removeControlChars(const OUString& sIn)
{
OUStringBuffer aBuf(sIn.replace('\n', ' '));
sal_Int32 nLen = aBuf.getLength();
diff --git a/sw/source/core/fields/ddefld.cxx b/sw/source/core/fields/ddefld.cxx
index e79729c8b3c6..ff8956cc37e7 100644
--- a/sw/source/core/fields/ddefld.cxx
+++ b/sw/source/core/fields/ddefld.cxx
@@ -259,8 +259,9 @@ OUString SwDDEFieldType::GetName() const
return aName;
}
-void SwDDEFieldType::SetCmd( OUString aStr )
+void SwDDEFieldType::SetCmd( const OUString& _aStr )
{
+ OUString aStr = _aStr;
sal_Int32 nIndex = 0;
do
{
diff --git a/sw/source/core/fields/expfld.cxx b/sw/source/core/fields/expfld.cxx
index 32302b3a4e5a..f1f95487b804 100644
--- a/sw/source/core/fields/expfld.cxx
+++ b/sw/source/core/fields/expfld.cxx
@@ -96,7 +96,7 @@ static sal_Int32 lcl_APIToSubType(const uno::Any& rAny)
return nSet;
}
-OUString ReplacePoint( OUString rTmpName, bool bWithCommandType )
+OUString ReplacePoint( const OUString& rTmpName, bool bWithCommandType )
{
// replace first and last (if bWithCommandType: last two) dot
// since table names may contain dots
diff --git a/sw/source/core/graphic/ndgrf.cxx b/sw/source/core/graphic/ndgrf.cxx
index aca1675ec68d..f593a3e0ea7b 100644
--- a/sw/source/core/graphic/ndgrf.cxx
+++ b/sw/source/core/graphic/ndgrf.cxx
@@ -484,7 +484,7 @@ struct StreamAndStorageNames
OUString sStorage;
};
-StreamAndStorageNames lcl_GetStreamStorageNames( const OUString sUserData )
+StreamAndStorageNames lcl_GetStreamStorageNames( const OUString& sUserData )
{
StreamAndStorageNames aNames;
if( sUserData.isEmpty() )
diff --git a/sw/source/core/inc/txmsrt.hxx b/sw/source/core/inc/txmsrt.hxx
index 306943f5b745..557e7da4ee33 100644
--- a/sw/source/core/inc/txmsrt.hxx
+++ b/sw/source/core/inc/txmsrt.hxx
@@ -63,7 +63,7 @@ struct TextAndReading
TextAndReading() {}
- TextAndReading(OUString sTxt, OUString sRdng)
+ TextAndReading(const OUString& sTxt, const OUString& sRdng)
: sText(sTxt)
, sReading(sRdng)
{}
@@ -234,7 +234,7 @@ private:
struct SwTOXPara : public SwTOXSortTabBase
{
- SwTOXPara( const SwCntntNode&, SwTOXElement, sal_uInt16 nLevel = FORM_ALPHA_DELIMITTER, OUString sSeqName = OUString() );
+ SwTOXPara( const SwCntntNode&, SwTOXElement, sal_uInt16 nLevel = FORM_ALPHA_DELIMITTER, const OUString& sSeqName = OUString() );
virtual ~SwTOXPara() {}
void SetStartIndex(sal_Int32 nSet) { nStartIndex = nSet; }
diff --git a/sw/source/core/inc/txtfrm.hxx b/sw/source/core/inc/txtfrm.hxx
index b23ba02b91f1..e5a856efb5cd 100644
--- a/sw/source/core/inc/txtfrm.hxx
+++ b/sw/source/core/inc/txtfrm.hxx
@@ -202,7 +202,7 @@ class SwTxtFrm: public SwCntntFrm
void _CalcHeightOfLastLine( const bool _bUseFont = false );
// ST2
- SwWrongList* _SmartTagScan ( OUString aTxtToScan, SwWrongList *pSmartTagList,
+ SwWrongList* _SmartTagScan ( const OUString& aTxtToScan, SwWrongList *pSmartTagList,
sal_Int32 nBegin,sal_Int32 nEnd,
sal_Int32 nInsertPos, sal_Int32 nActPos,
sal_Int32 &nChgStart, sal_Int32 &nChgEnd,
diff --git a/sw/source/core/inc/unoflatpara.hxx b/sw/source/core/inc/unoflatpara.hxx
index 7a60a8591f29..4eae5ee007cd 100644
--- a/sw/source/core/inc/unoflatpara.hxx
+++ b/sw/source/core/inc/unoflatpara.hxx
@@ -54,7 +54,7 @@ class SwXFlatParagraph:
public SwXTextMarkup
{
public:
- SwXFlatParagraph( SwTxtNode& rTxtNode, OUString aExpandText, const ModelToViewHelper& rConversionMap );
+ SwXFlatParagraph( SwTxtNode& rTxtNode, const OUString& aExpandText, const ModelToViewHelper& rConversionMap );
virtual ~SwXFlatParagraph();
virtual ::com::sun::star::uno::Any SAL_CALL queryInterface( const ::com::sun::star::uno::Type& aType ) throw(::com::sun::star::uno::RuntimeException, std::exception);
diff --git a/sw/source/core/tox/txmsrt.cxx b/sw/source/core/tox/txmsrt.cxx
index 3c9de9a9f86b..a26f4bbf7070 100644
--- a/sw/source/core/tox/txmsrt.cxx
+++ b/sw/source/core/tox/txmsrt.cxx
@@ -498,7 +498,7 @@ sal_uInt16 SwTOXContent::GetLevel() const
The position must not come from the document, but from the "anchor"!
--------------------------------------------------------------------*/
-SwTOXPara::SwTOXPara( const SwCntntNode& rNd, SwTOXElement eT, sal_uInt16 nLevel, OUString sSeqName )
+SwTOXPara::SwTOXPara( const SwCntntNode& rNd, SwTOXElement eT, sal_uInt16 nLevel, const OUString& sSeqName )
: SwTOXSortTabBase( TOX_SORT_PARA, &rNd, 0, 0 ),
eType( eT ),
m_nLevel(nLevel),
diff --git a/sw/source/core/uibase/app/docst.cxx b/sw/source/core/uibase/app/docst.cxx
index 896062714055..c2efe1ec4c35 100644
--- a/sw/source/core/uibase/app/docst.cxx
+++ b/sw/source/core/uibase/app/docst.cxx
@@ -596,7 +596,7 @@ sal_uInt16 SwDocShell::Edit(
const sal_uInt16 nFamily,
sal_uInt16 nMask,
const sal_Bool bNew,
- const OString sPage,
+ const OString& sPage,
SwWrtShell* pActShell,
const sal_Bool bBasic )
{
diff --git a/sw/source/core/uibase/dbui/mmconfigitem.cxx b/sw/source/core/uibase/dbui/mmconfigitem.cxx
index ad8a2393adec..80e8048a809d 100644
--- a/sw/source/core/uibase/dbui/mmconfigitem.cxx
+++ b/sw/source/core/uibase/dbui/mmconfigitem.cxx
@@ -1097,7 +1097,7 @@ const uno::Sequence< OUString>&
return m_pImpl->aSavedDocuments;
}
-void SwMailMergeConfigItem::AddSavedDocument(OUString rName)
+void SwMailMergeConfigItem::AddSavedDocument(const OUString& rName)
{
const OUString* pDocs = m_pImpl->aSavedDocuments.getConstArray();
bool bFound = false;
@@ -1212,7 +1212,7 @@ const OUString& SwMailMergeConfigItem::GetFemaleGenderValue() const
return m_pImpl->sFemaleGenderValue;
}
-void SwMailMergeConfigItem::SetFemaleGenderValue(const OUString rValue)
+void SwMailMergeConfigItem::SetFemaleGenderValue(const OUString& rValue)
{
if( m_pImpl->sFemaleGenderValue != rValue )
{
diff --git a/sw/source/core/uibase/docvw/PostItMgr.cxx b/sw/source/core/uibase/docvw/PostItMgr.cxx
index 82f078c445db..4193ad61c7e3 100644
--- a/sw/source/core/uibase/docvw/PostItMgr.cxx
+++ b/sw/source/core/uibase/docvw/PostItMgr.cxx
@@ -1168,7 +1168,7 @@ void SwPostItMgr::RemoveSidebarWin()
// copy to new vector, otherwise RemoveItem would operate and delete stuff on mvPostItFlds as well
// RemoveItem will clean up the core field and visible postit if necessary
// we cannot just delete everything as before, as postits could move into change tracking
-void SwPostItMgr::Delete(OUString aAuthor)
+void SwPostItMgr::Delete(const OUString& aAuthor)
{
mpWrtShell->StartAllAction();
if ( HasActiveSidebarWin() && (GetActiveSidebarWin()->GetAuthor()==aAuthor) )
diff --git a/sw/source/core/uibase/inc/frmdlg.hxx b/sw/source/core/uibase/inc/frmdlg.hxx
index 6a985691da16..09ae2b06eef5 100644
--- a/sw/source/core/uibase/inc/frmdlg.hxx
+++ b/sw/source/core/uibase/inc/frmdlg.hxx
@@ -53,9 +53,9 @@ public:
SwFrmDlg( SfxViewFrame *pFrame, Window *pParent,
const SfxItemSet& rCoreSet,
bool bNewFrm = false,
- OString sResType = OString("FrameDialog"),
+ const OString& sResType = OString("FrameDialog"),
bool bFmt = false,
- OString sDefPage = OString(),
+ const OString& sDefPage = OString(),
const OUString* pFmtStr = 0);
~SwFrmDlg();
diff --git a/sw/source/core/uibase/inc/initui.hxx b/sw/source/core/uibase/inc/initui.hxx
index 9d95043d3a19..ff4178487166 100644
--- a/sw/source/core/uibase/inc/initui.hxx
+++ b/sw/source/core/uibase/inc/initui.hxx
@@ -36,16 +36,16 @@ class SwThesaurus;
extern SwThesaurus* pThes;
SW_DLLPUBLIC OUString GetOldGrfCat();
-SW_DLLPUBLIC void SetOldGrfCat(OUString sStr);
+SW_DLLPUBLIC void SetOldGrfCat(const OUString& sStr);
SW_DLLPUBLIC OUString GetOldTabCat();
-SW_DLLPUBLIC void SetOldTabCat(OUString sStr);
+SW_DLLPUBLIC void SetOldTabCat(const OUString& sStr);
SW_DLLPUBLIC OUString GetOldFrmCat();
-SW_DLLPUBLIC void SetOldFrmCat(OUString sStr);
+SW_DLLPUBLIC void SetOldFrmCat(const OUString& sStr);
SW_DLLPUBLIC OUString GetOldDrwCat();
-SW_DLLPUBLIC void SetOldDrwCat(OUString sStr);
+SW_DLLPUBLIC void SetOldDrwCat(const OUString& sStr);
SW_DLLPUBLIC OUString GetCurrGlosGroup();
-SW_DLLPUBLIC void SetCurrGlosGroup(OUString sStr);
+SW_DLLPUBLIC void SetCurrGlosGroup(const OUString& sStr);
// provides textblock management
class SwGlossaries;
diff --git a/sw/source/core/uibase/inc/mmconfigitem.hxx b/sw/source/core/uibase/inc/mmconfigitem.hxx
index 8e53939f4bf8..8880cf610bd1 100644
--- a/sw/source/core/uibase/inc/mmconfigitem.hxx
+++ b/sw/source/core/uibase/inc/mmconfigitem.hxx
@@ -119,7 +119,7 @@ public:
const com::sun::star::uno::Sequence< OUString>&
GetSavedDocuments() const;
- void AddSavedDocument(OUString rName);
+ void AddSavedDocument(const OUString& rName);
sal_Bool IsOutputToLetter()const;
void SetOutputToLetter(sal_Bool bSet);
@@ -156,7 +156,7 @@ public:
//the content of the gender column that marks it as female
const OUString& GetFemaleGenderValue() const;
- void SetFemaleGenderValue(const OUString rValue);
+ void SetFemaleGenderValue(const OUString& rValue);
//returns the assignment in the order of the default headers (GetDefaultAddressHeaders())
com::sun::star::uno::Sequence< OUString >
diff --git a/sw/source/core/uibase/inc/swuipardlg.hxx b/sw/source/core/uibase/inc/swuipardlg.hxx
index 103cc99deb53..7552b53a1a59 100644
--- a/sw/source/core/uibase/inc/swuipardlg.hxx
+++ b/sw/source/core/uibase/inc/swuipardlg.hxx
@@ -44,7 +44,7 @@ public:
sal_uInt8 nDialogMode,
const OUString *pCollName = 0,
sal_Bool bDraw = sal_False,
- OString sDefPage = OString());
+ const OString& sDefPage = OString());
~SwParaDlg();
};
diff --git a/sw/source/core/uibase/inc/tmpdlg.hxx b/sw/source/core/uibase/inc/tmpdlg.hxx
index ac990146c80d..54c57484336a 100644
--- a/sw/source/core/uibase/inc/tmpdlg.hxx
+++ b/sw/source/core/uibase/inc/tmpdlg.hxx
@@ -74,7 +74,7 @@ public:
SwTemplateDlg( Window* pParent,
SfxStyleSheetBase& rBase,
sal_uInt16 nRegion,
- OString sPage = OString(),
+ const OString& sPage = OString(),
SwWrtShell* pActShell = 0,
bool bNew = false );
diff --git a/sw/source/core/uibase/misc/glosdoc.cxx b/sw/source/core/uibase/misc/glosdoc.cxx
index 4236067c95a8..575e17a9a1ce 100644
--- a/sw/source/core/uibase/misc/glosdoc.cxx
+++ b/sw/source/core/uibase/misc/glosdoc.cxx
@@ -50,7 +50,7 @@ using namespace ::com::sun::star::uno;
namespace
{
-inline OUString lcl_FullPathName(const OUString sPath, const OUString sName)
+inline OUString lcl_FullPathName(const OUString& sPath, const OUString& sName)
{
return sPath + OUString(INET_PATH_TOKEN) + sName + SwGlossaries::GetExtension();
}
diff --git a/sw/source/core/uibase/uiview/srcview.cxx b/sw/source/core/uibase/uiview/srcview.cxx
index 0c9931120376..87ac68ff2330 100644
--- a/sw/source/core/uibase/uiview/srcview.cxx
+++ b/sw/source/core/uibase/uiview/srcview.cxx
@@ -188,26 +188,27 @@ static rtl_TextEncoding lcl_GetStreamCharSet(rtl_TextEncoding eLoadEncoding)
return eRet;
}
-static OUString lcl_ConvertTabsToSpaces( OUString sLine )
+static OUString lcl_ConvertTabsToSpaces( const OUString& sLine )
{
- if (!sLine.isEmpty())
+ if (sLine.isEmpty())
+ return sLine;
+
+ OUString aRet = sLine;
+ const sal_Unicode aPadSpaces[4] = {' ', ' ', ' ', ' '};
+ sal_Int32 nPos = 0;
+ for (;;)
{
- const sal_Unicode aPadSpaces[4] = {' ', ' ', ' ', ' '};
- sal_Int32 nPos = 0;
- for (;;)
+ nPos = aRet.indexOf('\t', nPos);
+ if (nPos<0)
{
- nPos = sLine.indexOf('\t', nPos);
- if (nPos<0)
- {
- break;
- }
- // Not 4 blanks, but on 4th TabPos:
- const sal_Int32 nPadLen = 4 - (nPos % 4);
- sLine = sLine.replaceAt(nPos, 1, OUString(aPadSpaces, nPadLen));
- nPos += nPadLen;
+ break;
}
+ // Not 4 blanks, but on 4th TabPos:
+ const sal_Int32 nPadLen = 4 - (nPos % 4);
+ aRet = aRet.replaceAt(nPos, 1, OUString(aPadSpaces, nPadLen));
+ nPos += nPadLen;
}
- return sLine;
+ return aRet;
}
SwSrcView::SwSrcView(SfxViewFrame* pViewFrame, SfxViewShell*) :
diff --git a/sw/source/core/uibase/uno/unotxdoc.cxx b/sw/source/core/uibase/uno/unotxdoc.cxx
index 10fdac83c260..d5aabc5dad66 100644
--- a/sw/source/core/uibase/uno/unotxdoc.cxx
+++ b/sw/source/core/uibase/uno/unotxdoc.cxx
@@ -3477,7 +3477,7 @@ Sequence< OUString > SwXLinkTargetSupplier::getSupportedServiceNames(void)
}
SwXLinkNameAccessWrapper::SwXLinkNameAccessWrapper(
- Reference< XNameAccess > xAccess, const OUString& rLinkDisplayName, OUString sSuffix ) :
+ Reference< XNameAccess > xAccess, const OUString& rLinkDisplayName, const OUString& sSuffix ) :
xRealAccess(xAccess),
pPropSet(aSwMapProvider.GetPropertySet(PROPERTY_MAP_LINK_TARGET)),
sLinkSuffix(sSuffix),
@@ -3487,7 +3487,7 @@ SwXLinkNameAccessWrapper::SwXLinkNameAccessWrapper(
}
SwXLinkNameAccessWrapper::SwXLinkNameAccessWrapper(SwXTextDocument& rxDoc,
- const OUString& rLinkDisplayName, OUString sSuffix) :
+ const OUString& rLinkDisplayName, const OUString& sSuffix) :
pPropSet(aSwMapProvider.GetPropertySet(PROPERTY_MAP_LINK_TARGET)),
sLinkSuffix(sSuffix),
sLinkDisplayName(rLinkDisplayName),
@@ -3666,9 +3666,10 @@ void SwXLinkNameAccessWrapper::setPropertyValue(
throw UnknownPropertyException();
}
-static Any lcl_GetDisplayBitmap(OUString sLinkSuffix)
+static Any lcl_GetDisplayBitmap(const OUString& _sLinkSuffix)
{
Any aRet;
+ OUString sLinkSuffix = _sLinkSuffix;
if(!sLinkSuffix.isEmpty())
sLinkSuffix = sLinkSuffix.copy(1);
sal_uInt16 nImgId = USHRT_MAX;
diff --git a/sw/source/core/uibase/utlui/initui.cxx b/sw/source/core/uibase/utlui/initui.cxx
index d59e0bea3f16..11d6cafed6f7 100644
--- a/sw/source/core/uibase/utlui/initui.cxx
+++ b/sw/source/core/uibase/utlui/initui.cxx
@@ -62,7 +62,7 @@ inline OUString GetCachedString(CachedStringID id)
return StringCache[id] ? *StringCache[id] : OUString();
}
-inline void SetCachedString(CachedStringID id, OUString sStr)
+inline void SetCachedString(CachedStringID id, const OUString& sStr)
{
if (StringCache[id])
{
@@ -89,7 +89,7 @@ OUString GetOldGrfCat()
return GetCachedString(OldGrfCat);
}
-void SetOldGrfCat(OUString sStr)
+void SetOldGrfCat(const OUString& sStr)
{
SetCachedString(OldGrfCat, sStr);
}
@@ -99,7 +99,7 @@ OUString GetOldTabCat()
return GetCachedString(OldTabCat);
}
-void SetOldTabCat(OUString sStr)
+void SetOldTabCat(const OUString& sStr)
{
SetCachedString(OldTabCat, sStr);
}
@@ -109,7 +109,7 @@ OUString GetOldFrmCat()
return GetCachedString(OldFrmCat);
}
-void SetOldFrmCat(OUString sStr)
+void SetOldFrmCat(const OUString& sStr)
{
SetCachedString(OldFrmCat, sStr);
}
@@ -119,7 +119,7 @@ OUString GetOldDrwCat()
return GetCachedString(OldDrwCat);
}
-void SetOldDrwCat(OUString sStr)
+void SetOldDrwCat(const OUString& sStr)
{
SetCachedString(OldDrwCat, sStr);
}
@@ -129,7 +129,7 @@ OUString GetCurrGlosGroup()
return GetCachedString(CurrGlosGroup);
}
-void SetCurrGlosGroup(OUString sStr)
+void SetCurrGlosGroup(const OUString& sStr)
{
SetCachedString(CurrGlosGroup, sStr);
}
diff --git a/sw/source/core/undo/undel.cxx b/sw/source/core/undo/undel.cxx
index 8a57372441fc..92ae81962a3a 100644
--- a/sw/source/core/undo/undel.cxx
+++ b/sw/source/core/undo/undel.cxx
@@ -568,7 +568,7 @@ static bool lcl_IsSpecialCharacter(sal_Unicode nChar)
return false;
}
-static OUString lcl_DenotedPortion(OUString rStr, sal_Int32 nStart, sal_Int32 nEnd)
+static OUString lcl_DenotedPortion(const OUString& rStr, sal_Int32 nStart, sal_Int32 nEnd)
{
OUString aResult;
diff --git a/sw/source/core/unocore/unoflatpara.cxx b/sw/source/core/unocore/unoflatpara.cxx
index ec70dad0c05b..0304d7cda7db 100644
--- a/sw/source/core/unocore/unoflatpara.cxx
+++ b/sw/source/core/unocore/unoflatpara.cxx
@@ -63,7 +63,7 @@ CreateFlatParagraphIterator(SwDoc & rDoc, sal_Int32 const nTextMarkupType,
* SwXFlatParagraph
******************************************************************************/
-SwXFlatParagraph::SwXFlatParagraph( SwTxtNode& rTxtNode, OUString aExpandText, const ModelToViewHelper& rMap ) :
+SwXFlatParagraph::SwXFlatParagraph( SwTxtNode& rTxtNode, const OUString& aExpandText, const ModelToViewHelper& rMap ) :
SwXTextMarkup( rTxtNode, rMap ),
maExpandText( aExpandText )
{
diff --git a/sw/source/filter/html/htmlbas.cxx b/sw/source/filter/html/htmlbas.cxx
index b54789245d8c..8841a4c414cd 100644
--- a/sw/source/filter/html/htmlbas.cxx
+++ b/sw/source/filter/html/htmlbas.cxx
@@ -229,7 +229,7 @@ void SwHTMLParser::AddScriptSource()
}
}
-void SwHTMLParser::InsertBasicDocEvent( OUString aEvent, const OUString& rName,
+void SwHTMLParser::InsertBasicDocEvent( const OUString& aEvent, const OUString& rName,
ScriptType eScrType,
const OUString& rScrType )
{
diff --git a/sw/source/filter/html/swhtml.hxx b/sw/source/filter/html/swhtml.hxx
index 52e48712868f..e7d75e976762 100644
--- a/sw/source/filter/html/swhtml.hxx
+++ b/sw/source/filter/html/swhtml.hxx
@@ -745,7 +745,7 @@ private:
void AddScriptSource();
// ein Event in die SFX-Konfiguation eintragen (htmlbas.cxx)
- void InsertBasicDocEvent( OUString aEventName, const OUString& rName,
+ void InsertBasicDocEvent( const OUString& aEventName, const OUString& rName,
ScriptType eScrType, const OUString& rScrType );
// ein Event an ein VC-Control anhaengen (htmlform.cxx)
diff --git a/sw/source/filter/ww8/docxexport.cxx b/sw/source/filter/ww8/docxexport.cxx
index 50eb592b8e2b..5e20cc31c2e2 100644
--- a/sw/source/filter/ww8/docxexport.cxx
+++ b/sw/source/filter/ww8/docxexport.cxx
@@ -358,7 +358,7 @@ OString DocxExport::OutputChart( uno::Reference< frame::XModel >& xModel, sal_In
return OUStringToOString( sId, RTL_TEXTENCODING_UTF8 );
}
-OString DocxExport::WriteOLEObject( SwOLEObj& rObject, OUString sMediaType, OUString sRelationType )
+OString DocxExport::WriteOLEObject( SwOLEObj& rObject, const OUString& sMediaType, const OUString& sRelationType )
{
uno::Reference <embed::XEmbeddedObject> xObj( rObject.GetOleRef() );
comphelper::EmbeddedObjectContainer* aContainer = rObject.GetObject().GetContainer();
diff --git a/sw/source/filter/ww8/docxexport.hxx b/sw/source/filter/ww8/docxexport.hxx
index e8ef5c038ad8..c4d5a77a80fe 100644
--- a/sw/source/filter/ww8/docxexport.hxx
+++ b/sw/source/filter/ww8/docxexport.hxx
@@ -168,7 +168,7 @@ public:
/// Returns the relationd id
OString OutputChart( com::sun::star::uno::Reference< com::sun::star::frame::XModel >& xModel, sal_Int32 nCount, ::sax_fastparser::FSHelperPtr m_pSerializer );
- OString WriteOLEObject( SwOLEObj& rObject, OUString sMediaType, OUString sRelationType );
+ OString WriteOLEObject( SwOLEObj& rObject, const OUString& sMediaType, const OUString& sRelationType );
bool lcl_CopyStream( css::uno::Reference< css::io::XInputStream> xIn, css::uno::Reference< css::io::XOutputStream > xOut );
/// Writes the shape using drawingML syntax.
diff --git a/sw/source/filter/ww8/docxsdrexport.cxx b/sw/source/filter/ww8/docxsdrexport.cxx
index bc3e5f007871..16e0a077d584 100644
--- a/sw/source/filter/ww8/docxsdrexport.cxx
+++ b/sw/source/filter/ww8/docxsdrexport.cxx
@@ -736,7 +736,7 @@ void DocxSdrExport::writeDMLEffectLst(const SwFrmFmt& rFrmFmt)
void DocxSdrExport::writeDiagramRels(uno::Reference<xml::dom::XDocument> xDom,
uno::Sequence< uno::Sequence< uno::Any > > xRelSeq,
- uno::Reference< io::XOutputStream > xOutStream, OUString sGrabBagProperyName)
+ uno::Reference< io::XOutputStream > xOutStream, const OUString& sGrabBagProperyName)
{
// add image relationships of OOXData, OOXDiagram
OUString sType("http://schemas.openxmlformats.org/officeDocument/2006/relationships/image");
diff --git a/sw/source/filter/ww8/docxsdrexport.hxx b/sw/source/filter/ww8/docxsdrexport.hxx
index 1fa7fe0e7cee..dced28cdcae6 100644
--- a/sw/source/filter/ww8/docxsdrexport.hxx
+++ b/sw/source/filter/ww8/docxsdrexport.hxx
@@ -87,7 +87,7 @@ public:
void writeDiagram(const SdrObject* sdrObject, const SwFrmFmt& rFrmFmt, int nAnchorId);
void writeDiagramRels(com::sun::star::uno::Reference< com::sun::star::xml::dom::XDocument> xDom,
com::sun::star::uno::Sequence< com::sun::star::uno::Sequence< com::sun::star::uno::Any > > xRelSeq,
- com::sun::star::uno::Reference< com::sun::star::io::XOutputStream > xOutStream, OUString sGrabBagProperyName);
+ com::sun::star::uno::Reference< com::sun::star::io::XOutputStream > xOutStream, const OUString& sGrabBagProperyName);
/// Writes text frame in DML format.
void writeDMLTextFrame(sw::Frame* pParentFrame, int nAnchorId);
/// Writes text frame in VML format.
diff --git a/sw/source/filter/ww8/docxtablestyleexport.cxx b/sw/source/filter/ww8/docxtablestyleexport.cxx
index 5cd154c354de..034123f53c68 100644
--- a/sw/source/filter/ww8/docxtablestyleexport.cxx
+++ b/sw/source/filter/ww8/docxtablestyleexport.cxx
@@ -33,7 +33,7 @@ struct DocxTableStyleExport::Impl
void TableStyle(uno::Sequence<beans::PropertyValue>& rStyle);
/// Handles a boolean value.
- void handleBoolean(OUString aValue, sal_Int32 nToken);
+ void handleBoolean(const OUString& aValue, sal_Int32 nToken);
/// Export of w:pPr.
void tableStylePPr(uno::Sequence<beans::PropertyValue>& rPPr);
@@ -327,7 +327,7 @@ void DocxTableStyleExport::Impl::tableStyleTblInd(uno::Sequence<beans::PropertyV
m_pSerializer->singleElementNS(XML_w, XML_tblInd, xAttributeList);
}
-void DocxTableStyleExport::Impl::handleBoolean(OUString aValue, sal_Int32 nToken)
+void DocxTableStyleExport::Impl::handleBoolean(const OUString& aValue, sal_Int32 nToken)
{
if (aValue.isEmpty())
return;
diff --git a/sw/source/filter/ww8/ww8par.hxx b/sw/source/filter/ww8/ww8par.hxx
index 8c324a730598..e25290c8c3bb 100644
--- a/sw/source/filter/ww8/ww8par.hxx
+++ b/sw/source/filter/ww8/ww8par.hxx
@@ -189,7 +189,7 @@ private:
void AdjustLVL(sal_uInt8 nLevel, SwNumRule& rNumRule, WW8aISet& rListItemSet,
WW8aCFmt& aCharFmt, bool& bNewCharFmtCreated,
- OUString aPrefix = OUString());
+ const OUString& aPrefix = OUString());
//No copying
WW8ListManager(const WW8ListManager&);
@@ -542,9 +542,9 @@ class WW8FieldEntry
OUString GetBookmarkName();
OUString GetBookmarkCode();
- void SetBookmarkName(OUString bookmarkName);
- void SetBookmarkType(OUString bookmarkType);
- void SetBookmarkCode(OUString bookmarkCode);
+ void SetBookmarkName(const OUString& bookmarkName);
+ void SetBookmarkType(const OUString& bookmarkType);
+ void SetBookmarkCode(const OUString& bookmarkCode);
::sw::mark::IFieldmark::parameter_map_t& getParameters();
};
@@ -1408,7 +1408,7 @@ private:
void Read_HdFtFtnText( const SwNodeIndex* pSttIdx, long nStartCp,
long nLen, ManTypes nType );
- void ImportTox( int nFldId, OUString aStr );
+ void ImportTox( int nFldId, const OUString& aStr );
void EndSprm( sal_uInt16 nId );
// #i103711#
diff --git a/sw/source/filter/ww8/ww8par3.cxx b/sw/source/filter/ww8/ww8par3.cxx
index 83c978a9b691..522e2bb6a52d 100644
--- a/sw/source/filter/ww8/ww8par3.cxx
+++ b/sw/source/filter/ww8/ww8par3.cxx
@@ -951,7 +951,7 @@ bool WW8ListManager::ReadLVL(SwNumFmt& rNumFmt, SfxItemSet*& rpItemSet,
void WW8ListManager::AdjustLVL( sal_uInt8 nLevel, SwNumRule& rNumRule,
WW8aISet& rListItemSet, WW8aCFmt& rCharFmt, bool& bNewCharFmtCreated,
- OUString sPrefix )
+ const OUString& sPrefix )
{
bNewCharFmtCreated = false;
SfxItemSet* pThisLevelItemSet;
diff --git a/sw/source/filter/ww8/ww8par5.cxx b/sw/source/filter/ww8/ww8par5.cxx
index 6d64a276a319..040e3e1f0404 100644
--- a/sw/source/filter/ww8/ww8par5.cxx
+++ b/sw/source/filter/ww8/ww8par5.cxx
@@ -662,17 +662,17 @@ OUString WW8FieldEntry::GetBookmarkCode()
return msMarkCode;
}
-void WW8FieldEntry::SetBookmarkName(OUString bookmarkName)
+void WW8FieldEntry::SetBookmarkName(const OUString& bookmarkName)
{
msBookmarkName=bookmarkName;
}
-void WW8FieldEntry::SetBookmarkType(OUString bookmarkType)
+void WW8FieldEntry::SetBookmarkType(const OUString& bookmarkType)
{
msMarkType=bookmarkType;
}
-void WW8FieldEntry::SetBookmarkCode(OUString bookmarkCode)
+void WW8FieldEntry::SetBookmarkCode(const OUString& bookmarkCode)
{
msMarkCode = bookmarkCode;
}
@@ -3536,7 +3536,7 @@ void sw::ms::ImportXE(SwDoc &rDoc, SwPaM &rPaM, const OUString &rStr)
lcl_ImportTox(rDoc, rPaM, rStr, true);
}
-void SwWW8ImplReader::ImportTox( int nFldId, OUString aStr )
+void SwWW8ImplReader::ImportTox( int nFldId, const OUString& aStr )
{
bool bIdx = (nFldId != 9);
lcl_ImportTox(rDoc, *pPaM, aStr, bIdx);
diff --git a/sw/source/filter/xml/xmltbli.cxx b/sw/source/filter/xml/xmltbli.cxx
index 14b7ffa27f2c..ced4c198cc75 100644
--- a/sw/source/filter/xml/xmltbli.cxx
+++ b/sw/source/filter/xml/xmltbli.cxx
@@ -1155,7 +1155,7 @@ void SwXMLDDETableContext_Impl::StartElement(
}
// generate a new name for DDE field type (called by lcl_GetDDEFieldType below)
-static OUString lcl_GenerateFldTypeName(OUString sPrefix, SwTableNode* pTableNode)
+static OUString lcl_GenerateFldTypeName(const OUString& sPrefix, SwTableNode* pTableNode)
{
OUString sPrefixStr(sPrefix);
diff --git a/sw/source/ui/chrdlg/pardlg.cxx b/sw/source/ui/chrdlg/pardlg.cxx
index 761e7f780e5d..505c251f9afe 100644
--- a/sw/source/ui/chrdlg/pardlg.cxx
+++ b/sw/source/ui/chrdlg/pardlg.cxx
@@ -50,7 +50,7 @@ SwParaDlg::SwParaDlg(Window *pParent,
sal_uInt8 nDialogMode,
const OUString *pTitle,
sal_Bool bDraw,
- OString sDefPage)
+ const OString& sDefPage)
: SfxTabDialog(pParent,
"ParagraphPropertiesDialog",
"modules/swriter/ui/paradialog.ui",
diff --git a/sw/source/ui/dbui/mmaddressblockpage.cxx b/sw/source/ui/dbui/mmaddressblockpage.cxx
index cd3cb79f4c0d..5511a25f5d52 100644
--- a/sw/source/ui/dbui/mmaddressblockpage.cxx
+++ b/sw/source/ui/dbui/mmaddressblockpage.cxx
@@ -394,7 +394,7 @@ const uno::Sequence< OUString >& SwSelectAddressBlockDialog::GetAddressBlocks
}
void SwSelectAddressBlockDialog::SetSettings(
- sal_Bool bIsCountry, OUString rCountry)
+ sal_Bool bIsCountry, const OUString& rCountry)
{
RadioButton *pActive = m_pNeverRB;
if(bIsCountry)
diff --git a/sw/source/ui/dbui/mmaddressblockpage.hxx b/sw/source/ui/dbui/mmaddressblockpage.hxx
index e46c1203d2e3..f4e96da1ccde 100644
--- a/sw/source/ui/dbui/mmaddressblockpage.hxx
+++ b/sw/source/ui/dbui/mmaddressblockpage.hxx
@@ -125,7 +125,7 @@ public:
sal_uInt16 nSelected);
const com::sun::star::uno::Sequence< OUString>& GetAddressBlocks();
- void SetSettings(sal_Bool bIsCountry, OUString sCountry);
+ void SetSettings(sal_Bool bIsCountry, const OUString& sCountry);
sal_Bool IsIncludeCountry() const {return !m_pNeverRB->IsChecked();}
OUString GetCountry() const;
};
diff --git a/sw/source/ui/dialog/swdlgfact.cxx b/sw/source/ui/dialog/swdlgfact.cxx
index b79122ca5405..6de37edc0b7c 100644
--- a/sw/source/ui/dialog/swdlgfact.cxx
+++ b/sw/source/ui/dialog/swdlgfact.cxx
@@ -798,7 +798,7 @@ SfxAbstractTabDialog* SwAbstractDialogFactory_Impl::CreateSwParaDlg ( Window *pP
sal_uInt8 nDialogMode,
const OUString *pCollName,
sal_Bool bDraw ,
- OString sDefPage)
+ const OString& sDefPage)
{
SfxTabDialog* pDlg = new SwParaDlg( pParent, rVw, rCoreSet,nDialogMode, pCollName, bDraw, sDefPage );
return new AbstractTabDialog_Impl( pDlg );
@@ -943,7 +943,7 @@ SfxAbstractTabDialog* SwAbstractDialogFactory_Impl::CreateFrmTabDialog(const OSt
const SfxItemSet& rCoreSet,
bool bNewFrm,
bool bFmt,
- OString sDefPage,
+ const OString& sDefPage,
const OUString* pFmtStr )
{
SfxTabDialog* pDlg = new SwFrmDlg(pFrame, pParent, rCoreSet, bNewFrm, rDialogType, bFmt, sDefPage, pFmtStr);
@@ -954,7 +954,7 @@ SfxAbstractApplyTabDialog* SwAbstractDialogFactory_Impl::CreateTemplateDialog(
Window* pParent,
SfxStyleSheetBase& rBase,
sal_uInt16 nRegion,
- OString sPage,
+ const OString& sPage,
SwWrtShell* pActShell,
bool bNew )
{
diff --git a/sw/source/ui/dialog/swdlgfact.hxx b/sw/source/ui/dialog/swdlgfact.hxx
index 55eb36eb93c1..55a3bdb60ff8 100644
--- a/sw/source/ui/dialog/swdlgfact.hxx
+++ b/sw/source/ui/dialog/swdlgfact.hxx
@@ -412,7 +412,7 @@ public:
sal_uInt8 nDialogMode,
const OUString *pCollName = 0,
sal_Bool bDraw = sal_False,
- OString sDefPage = OString() );
+ const OString& sDefPage = OString() );
virtual AbstractSwSelGlossaryDlg * CreateSwSelGlossaryDlg(Window * pParent, const OUString &rShortName);
virtual VclAbstractDialog * CreateVclAbstractDialog ( Window * pParent, SwWrtShell &rSh, int nResId );
@@ -440,13 +440,13 @@ public:
const SfxItemSet& rCoreSet,
bool bNewFrm = true,
bool bFmt = false,
- OString sDefPage = OString(),
+ const OString& sDefPage = OString(),
const OUString* pFmtStr = 0);
virtual SfxAbstractApplyTabDialog* CreateTemplateDialog(
Window* pParent,
SfxStyleSheetBase& rBase,
sal_uInt16 nRegion,
- OString sPage = OString(),
+ const OString& sPage = OString(),
SwWrtShell* pActShell = 0,
bool bNew = false);
virtual AbstractGlossaryDlg* CreateGlossaryDlg(SfxViewFrame* pViewFrame,
diff --git a/sw/source/ui/fmtui/tmpdlg.cxx b/sw/source/ui/fmtui/tmpdlg.cxx
index 6f737a91c678..cf9dd2c449a7 100644
--- a/sw/source/ui/fmtui/tmpdlg.cxx
+++ b/sw/source/ui/fmtui/tmpdlg.cxx
@@ -75,7 +75,7 @@ extern SW_DLLPUBLIC SwWrtShell* GetActiveWrtShell();
SwTemplateDlg::SwTemplateDlg(Window* pParent,
SfxStyleSheetBase& rBase,
sal_uInt16 nRegion,
- OString sPage,
+ const OString& sPage,
SwWrtShell* pActShell,
bool bNew)
: SfxStyleDialog(pParent,
diff --git a/sw/source/ui/frmdlg/frmdlg.cxx b/sw/source/ui/frmdlg/frmdlg.cxx
index bff0ab286aa9..cfc3f01fcbbf 100644
--- a/sw/source/ui/frmdlg/frmdlg.cxx
+++ b/sw/source/ui/frmdlg/frmdlg.cxx
@@ -50,9 +50,9 @@ SwFrmDlg::SwFrmDlg( SfxViewFrame* pViewFrame,
Window* pParent,
const SfxItemSet& rCoreSet,
bool bNewFrm,
- OString sResType,
+ const OString& sResType,
bool bFormat,
- OString sDefPage,
+ const OString& sDefPage,
const OUString* pStr)
: SfxTabDialog(pViewFrame, pParent, sResType,
diff --git a/sw/source/ui/table/tautofmt.cxx b/sw/source/ui/table/tautofmt.cxx
index 4ef7254dafdb..5b134fd5ea60 100644
--- a/sw/source/ui/table/tautofmt.cxx
+++ b/sw/source/ui/table/tautofmt.cxx
@@ -94,7 +94,7 @@ private:
void DrawBackground();
void MakeFonts ( sal_uInt8 nIndex, Font& rFont, Font& rCJKFont, Font& rCTLFont );
- OUString MakeNumberString( OUString cellString, sal_Bool bAddDec );
+ OUString MakeNumberString( const OUString& cellString, sal_Bool bAddDec );
};
class SwStringInputDlg : public ModalDialog
diff --git a/sw/source/ui/vba/vbafield.cxx b/sw/source/ui/vba/vbafield.cxx
index 5c7122d36ebe..9a39d9c3586d 100644
--- a/sw/source/ui/vba/vbafield.cxx
+++ b/sw/source/ui/vba/vbafield.cxx
@@ -347,7 +347,7 @@ SwVbaFields::Add( const css::uno::Reference< ::ooo::vba::word::XRange >& Range,
return uno::Reference< word::XField >( new SwVbaField( mxParent, mxContext, uno::Reference< text::XTextDocument >( mxModel, uno::UNO_QUERY_THROW ), uno::Reference< text::XTextField >( xTextField, uno::UNO_QUERY_THROW ) ) );
}
-uno::Reference< text::XTextField > SwVbaFields::Create_Field_FileName( const OUString _text ) throw (uno::RuntimeException)
+uno::Reference< text::XTextField > SwVbaFields::Create_Field_FileName( const OUString& _text ) throw (uno::RuntimeException)
{
uno::Reference< text::XTextField > xTextField( mxMSF->createInstance("com.sun.star.text.TextField.FileName"), uno::UNO_QUERY_THROW );
sal_Int16 nFileFormat = text::FilenameDisplayFormat::NAME_AND_EXT;
@@ -416,7 +416,7 @@ static const DocPropertyTable aDocPropertyTables[] =
{ NULL, NULL }
};
-uno::Reference< text::XTextField > SwVbaFields::Create_Field_DocProperty( const OUString _text ) throw (uno::RuntimeException)
+uno::Reference< text::XTextField > SwVbaFields::Create_Field_DocProperty( const OUString& _text ) throw (uno::RuntimeException)
{
OUString aDocProperty;
SwVbaReadFieldParams aReadParam( _text );
diff --git a/sw/source/ui/vba/vbafield.hxx b/sw/source/ui/vba/vbafield.hxx
index 9af4368e9d63..4bc82f8f4140 100644
--- a/sw/source/ui/vba/vbafield.hxx
+++ b/sw/source/ui/vba/vbafield.hxx
@@ -49,8 +49,8 @@ class SwVbaFields : public SwVbaFields_BASE
css::uno::Reference< css::frame::XModel > mxModel;
css::uno::Reference< css::lang::XMultiServiceFactory > mxMSF;
private:
- css::uno::Reference< css::text::XTextField > Create_Field_FileName( const OUString _text ) throw (css::uno::RuntimeException);
- css::uno::Reference< css::text::XTextField > Create_Field_DocProperty( const OUString _text ) throw (css::uno::RuntimeException);
+ css::uno::Reference< css::text::XTextField > Create_Field_FileName( const OUString& _text ) throw (css::uno::RuntimeException);
+ css::uno::Reference< css::text::XTextField > Create_Field_DocProperty( const OUString& _text ) throw (css::uno::RuntimeException);
public:
SwVbaFields( const css::uno::Reference< ov::XHelperInterface >& xParent, const css::uno::Reference< css::uno::XComponentContext > & xContext, const css::uno::Reference< css::frame::XModel >& xModel );