diff options
author | Noel Grandin <noel@peralex.com> | 2013-10-07 13:16:12 +0200 |
---|---|---|
committer | Noel Grandin <noel@peralex.com> | 2013-10-08 10:03:12 +0200 |
commit | e4c4280b276d38e111064bda00049d04c8fe6e39 (patch) | |
tree | 8f760a1ac0ef7603a04fbadd9894afd0128cd986 /sc | |
parent | 0d9da3da43ded0172252e017e309164cd744b76c (diff) |
convert sc/source/ui/formdlg/*.cxx from String to OUString
Change-Id: Ibfd35b218ed5afb304f777e030df220ef25b6ee4
Diffstat (limited to 'sc')
-rw-r--r-- | sc/source/ui/formdlg/dwfunctr.cxx | 26 | ||||
-rw-r--r-- | sc/source/ui/formdlg/formula.cxx | 18 |
2 files changed, 22 insertions, 22 deletions
diff --git a/sc/source/ui/formdlg/dwfunctr.cxx b/sc/source/ui/formdlg/dwfunctr.cxx index 933a9ef30357..6bec2ebc4071 100644 --- a/sc/source/ui/formdlg/dwfunctr.cxx +++ b/sc/source/ui/formdlg/dwfunctr.cxx @@ -661,7 +661,7 @@ sal_Bool ScFunctionDockWin::Close() SfxChildAlignment ScFunctionDockWin::CheckAlignment(SfxChildAlignment /* abla */, SfxChildAlignment aChildAlign) { - String aString = OUString("ww"); + OUString aString("ww"); Size aTxtSize( aFiFuncDesc.GetTextWidth(aString), aFiFuncDesc.GetTextHeight() ); if(!bInit) { @@ -693,7 +693,7 @@ SfxChildAlignment ScFunctionDockWin::CheckAlignment(SfxChildAlignment /* abla */ case SFX_ALIGN_NOALIGNMENT: aString = aCatBox.GetEntry(0); - aString.AppendAscii(RTL_CONSTASCII_STRINGPARAM("www")); + aString += "www"; aTxtSize = Size( aFiFuncDesc.GetTextWidth(aString), aFiFuncDesc.GetTextHeight() ); @@ -833,13 +833,13 @@ void ScFunctionDockWin::UpdateFunctionList() void ScFunctionDockWin::DoEnter(sal_Bool /* bOk */) //@@ ??? { - String aFirstArgStr; - String aArgStr; - String aString=pAllFuncList->GetSelectEntry(); + OUString aFirstArgStr; + OUString aArgStr; + OUString aString=pAllFuncList->GetSelectEntry(); SfxViewShell* pCurSh = SfxViewShell::Current(); nArgs=0; - if(aString.Len()>0) + if(!aString.isEmpty()) { ScModule* pScMod = SC_MOD(); @@ -848,7 +848,7 @@ void ScFunctionDockWin::DoEnter(sal_Bool /* bOk */) //@@ ??? if(!pScMod->IsEditMode()) { pScMod->SetInputMode(SC_INPUT_TABLE); - aString = '='; + aString = "="; aString += pAllFuncList->GetSelectEntry(); if (pHdl) pHdl->ClearText(); @@ -867,7 +867,7 @@ void ScFunctionDockWin::DoEnter(sal_Bool /* bOk */) //@@ ??? // suppress flag as well, but practically it doesn't. aFirstArgStr = *(pDesc->ppDefArgNames[0]); aFirstArgStr = comphelper::string::strip(aFirstArgStr, ' '); - aFirstArgStr.SearchAndReplaceAll(' ', '_'); + aFirstArgStr = aFirstArgStr.replaceAll(" ", "_"); aArgStr = aFirstArgStr; if ( nArgs != VAR_ARGS && nArgs != PAIRED_VAR_ARGS ) { // no VarArgs or Fix plus VarArgs, but not VarArgs only @@ -885,9 +885,9 @@ void ScFunctionDockWin::DoEnter(sal_Bool /* bOk */) //@@ ??? if (!pDesc->pDefArgFlags[nArg].bSuppress) { aArgStr += aArgSep; - String sTmp(*(pDesc->ppDefArgNames[nArg])); + OUString sTmp(*(pDesc->ppDefArgNames[nArg])); sTmp = comphelper::string::strip(sTmp, ' '); - sTmp.SearchAndReplaceAll(' ', '_'); + sTmp = sTmp.replaceAll(" ", "_"); aArgStr += sTmp; } } @@ -898,7 +898,7 @@ void ScFunctionDockWin::DoEnter(sal_Bool /* bOk */) //@@ ??? { if (pHdl->GetEditString().isEmpty()) { - aString = '='; + aString = "="; aString += pAllFuncList->GetSelectEntry(); } EditView *pEdView=pHdl->GetActiveView(); @@ -909,13 +909,13 @@ void ScFunctionDockWin::DoEnter(sal_Bool /* bOk */) //@@ ??? pHdl->InsertFunction(aString); pEdView->InsertText(aArgStr,sal_True); ESelection aESel=pEdView->GetSelection(); - aESel.nEndPos=aESel.nStartPos+aFirstArgStr.Len(); + aESel.nEndPos = aESel.nStartPos + aFirstArgStr.getLength(); pEdView->SetSelection(aESel); pHdl->DataChanged(); } else { - aString.AppendAscii(RTL_CONSTASCII_STRINGPARAM( "()" )); + aString += "()"; pEdView->InsertText(aString,false); pHdl->DataChanged(); } diff --git a/sc/source/ui/formdlg/formula.cxx b/sc/source/ui/formdlg/formula.cxx index cd71adbf9501..f5bfc003cdb3 100644 --- a/sc/source/ui/formdlg/formula.cxx +++ b/sc/source/ui/formdlg/formula.cxx @@ -182,7 +182,7 @@ ScFormulaDlg::ScFormulaDlg( SfxBindings* pB, SfxChildWindow* pCW, } pData->SetMode( (sal_uInt16) eMode ); - String rStrExp = GetMeText(); + OUString rStrExp = GetMeText(); Update(rStrExp); } @@ -203,7 +203,7 @@ void ScFormulaDlg::fill() ScModule* pScMod = SC_MOD(); ScFormEditData* pData = pScMod->GetFormEditData(); notifyChange(); - String rStrExp; + OUString rStrExp; if (pData) { // Daten schon vorhanden -> Zustand wiederherstellen (nach Umschalten) @@ -231,8 +231,8 @@ void ScFormulaDlg::fill() pData->SetInputHandler(pInputHdl); } - String aOldFormulaTmp(pScMod->InputGetFormulaStr()); - pScMod->InputSetSelection( 0, aOldFormulaTmp.Len()); + OUString aOldFormulaTmp(pScMod->InputGetFormulaStr()); + pScMod->InputSetSelection( 0, aOldFormulaTmp.getLength()); rStrExp=pData->GetUndoStr(); pScMod->InputReplaceSelection(rStrExp); @@ -400,7 +400,7 @@ void ScFormulaDlg::SetReference( const ScRange& rRef, ScDocument* pRefDoc ) RefInputStart(GetActiveEdit()); } - String aRefStr; + OUString aRefStr; sal_Bool bOtherDoc = ( pRefDoc != pDoc && pRefDoc->GetDocumentShell()->HasName() ); if ( bOtherDoc ) { @@ -413,12 +413,12 @@ void ScFormulaDlg::SetReference( const ScRange& rRef, ScDocument* pRefDoc ) SfxObjectShell* pObjSh = pRefDoc->GetDocumentShell(); // #i75893# convert escaped URL of the document to something user friendly -// String aFileName = pObjSh->GetMedium()->GetName(); - String aFileName = pObjSh->GetMedium()->GetURLObject().GetMainURL( INetURLObject::DECODE_UNAMBIGUOUS ); +// OUString aFileName = pObjSh->GetMedium()->GetName(); + OUString aFileName = pObjSh->GetMedium()->GetURLObject().GetMainURL( INetURLObject::DECODE_UNAMBIGUOUS ); - aRefStr = '\''; + aRefStr = "'"; aRefStr += aFileName; - aRefStr.AppendAscii(RTL_CONSTASCII_STRINGPARAM( "'#" )); + aRefStr += "'#"; aRefStr += aTmp; } else |