diff options
author | Olivier Hallot <olivier.hallot@alta.org.br> | 2011-12-25 19:31:22 -0200 |
---|---|---|
committer | Ivan Timofeev <timofeev.i.s@gmail.com> | 2011-12-26 14:26:08 +0400 |
commit | 3e4f51f112248b4e586f5bd86388099737ed17e9 (patch) | |
tree | f17f47a54446c5a1260aecd64202dca85ad08c2d | |
parent | e7bddf732798508e347221590110486e97bb45e6 (diff) |
Fix for fdo43460 Part XIX getLength() to isEmpty()
Part XIX
Module
formula and fpicker
-rw-r--r-- | formula/source/core/api/FormulaCompiler.cxx | 4 | ||||
-rw-r--r-- | formula/source/ui/dlg/formula.cxx | 18 | ||||
-rw-r--r-- | formula/source/ui/dlg/funcpage.cxx | 2 | ||||
-rw-r--r-- | formula/source/ui/dlg/parawin.cxx | 2 | ||||
-rw-r--r-- | fpicker/source/office/OfficeControlAccess.cxx | 2 | ||||
-rw-r--r-- | fpicker/source/office/OfficeFilePicker.cxx | 16 | ||||
-rw-r--r-- | fpicker/source/office/OfficeFolderPicker.cxx | 2 | ||||
-rw-r--r-- | fpicker/source/office/commonpicker.cxx | 8 | ||||
-rw-r--r-- | fpicker/source/office/fpsmartcontent.cxx | 2 | ||||
-rw-r--r-- | fpicker/source/office/iodlg.cxx | 2 |
10 files changed, 29 insertions, 29 deletions
diff --git a/formula/source/core/api/FormulaCompiler.cxx b/formula/source/core/api/FormulaCompiler.cxx index b721c3ba71db..ee6530c2ac32 100644 --- a/formula/source/core/api/FormulaCompiler.cxx +++ b/formula/source/core/api/FormulaCompiler.cxx @@ -296,9 +296,9 @@ uno::Sequence< sheet::FormulaToken > FormulaCompiler::OpCodeMap::createSequenceO // Check for existence not needed here, only name-mapping is of // interest. } - if (!aIntName.getLength()) + if (aIntName.isEmpty()) aIntName = _rCompiler.FindAddInFunction(*pName, !isEnglish()); // bLocalFirst=false for english - if (!aIntName.getLength()) + if (aIntName.isEmpty()) pToken->OpCode = getOpCodeUnknown(); else { diff --git a/formula/source/ui/dlg/formula.cxx b/formula/source/ui/dlg/formula.cxx index d2987951f7db..4197ae46909a 100644 --- a/formula/source/ui/dlg/formula.cxx +++ b/formula/source/ui/dlg/formula.cxx @@ -404,19 +404,19 @@ void FormulaDlg_Impl::PreNotify( NotifyEvent& rNEvt ) if(pWin!=NULL) { aActivWinId = pWin->GetUniqueId(); - if(aActivWinId.getLength()==0) + if(aActivWinId.isEmpty()) { Window* pParent=pWin->GetParent(); while(pParent!=NULL) { aActivWinId=pParent->GetUniqueId(); - if(aActivWinId.getLength()!=0) break; + if(!aActivWinId.isEmpty()) break; pParent=pParent->GetParent(); } } - if(aActivWinId.getLength()) + if(!aActivWinId.isEmpty()) { FormEditData* pData = m_pHelper->getFormEditData(); @@ -861,7 +861,7 @@ void FormulaDlg_Impl::FillControls(sal_Bool &rbNext, sal_Bool &rbPrev) aFtEditName.Show(); pParaWin->Show(); const rtl::OString aHelpId = pFuncDesc->getHelpId(); - if ( aHelpId.getLength() ) + if ( !aHelpId.isEmpty() ) pMEdit->SetHelpId(aHelpId); } @@ -1284,7 +1284,7 @@ void FormulaDlg_Impl::SaveArg( sal_uInt16 nEd ) sal_uInt16 i; for(i=0;i<=nEd;i++) { - if ( m_aArguments[i].getLength() == 0 ) + if ( m_aArguments[i].isEmpty() ) m_aArguments[i] = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(" ")); } if(pParaWin->GetArgument(nEd).Len()!=0) @@ -1744,14 +1744,14 @@ rtl::OString FormulaDlg_Impl::FindFocusWin(Window *pWin) if(pWin->HasFocus()) { aUniqueId=pWin->GetUniqueId(); - if(aUniqueId.getLength()==0) + if(aUniqueId.isEmpty()) { Window* pParent=pWin->GetParent(); while(pParent!=NULL) { aUniqueId=pParent->GetUniqueId(); - if(aUniqueId.getLength()!=0) break; + if(!aUniqueId.isEmpty()) break; pParent=pParent->GetParent(); } @@ -1765,7 +1765,7 @@ rtl::OString FormulaDlg_Impl::FindFocusWin(Window *pWin) { Window* pChild=pWin->GetChild(i); aUniqueId=FindFocusWin(pChild); - if(aUniqueId.getLength()>0) break; + if(!aUniqueId.isEmpty()) break; } } return aUniqueId; @@ -1885,7 +1885,7 @@ FormulaDlg::FormulaDlg( SfxBindings* pB, SfxChildWindow* pCW, ,_pHelper,_pFunctionMgr,_pDlg)) { FreeResource(); - if(!GetHelpId().getLength()) //Hack which hides the HelpId for a model Dialog in SfxModelessDialog + if(GetHelpId().isEmpty()) //Hack which hides the HelpId for a model Dialog in SfxModelessDialog SetHelpId(GetUniqueId()); //and will be changed in a UniqueId, //at this point we reverse it. SetText(m_pImpl->aTitle1); diff --git a/formula/source/ui/dlg/funcpage.cxx b/formula/source/ui/dlg/funcpage.cxx index ea3bbaa59bf0..22ea529b5003 100644 --- a/formula/source/ui/dlg/funcpage.cxx +++ b/formula/source/ui/dlg/funcpage.cxx @@ -188,7 +188,7 @@ IMPL_LINK( FuncPage, SelHdl, ListBox*, pLb ) if ( pDesc ) { const rtl::OString sHelpId = pDesc->getHelpId(); - if ( sHelpId.getLength() ) + if ( !sHelpId.isEmpty() ) aLbFunction.SetHelpId(sHelpId); } aSelectionLink.Call(this); diff --git a/formula/source/ui/dlg/parawin.cxx b/formula/source/ui/dlg/parawin.cxx index 5311aa5ba0ef..7eeaf21c8597 100644 --- a/formula/source/ui/dlg/parawin.cxx +++ b/formula/source/ui/dlg/parawin.cxx @@ -277,7 +277,7 @@ void ParaWin::SetFunctionDesc(const IFunctionDescription* pFDesc) nArgs = 0; if ( pFuncDesc!=NULL) { - if ( pFuncDesc->getDescription().getLength() ) + if ( !pFuncDesc->getDescription().isEmpty() ) { SetEditDesc(pFuncDesc->getDescription()); } diff --git a/fpicker/source/office/OfficeControlAccess.cxx b/fpicker/source/office/OfficeControlAccess.cxx index 7b2d15951d9e..8b8288db36c1 100644 --- a/fpicker/source/office/OfficeControlAccess.cxx +++ b/fpicker/source/office/OfficeControlAccess.cxx @@ -515,7 +515,7 @@ namespace svt { ::rtl::OUString aEntry; _rValue >>= aEntry; - if ( aEntry.getLength() ) + if ( !aEntry.isEmpty() ) _pListbox->InsertEntry( aEntry ); } break; diff --git a/fpicker/source/office/OfficeFilePicker.cxx b/fpicker/source/office/OfficeFilePicker.cxx index 75fba5aed80a..3df9f11f7e5f 100644 --- a/fpicker/source/office/OfficeFilePicker.cxx +++ b/fpicker/source/office/OfficeFilePicker.cxx @@ -166,13 +166,13 @@ void SvtFilePicker::prepareExecute() { // set the default directory // --**-- doesn't match the spec yet - if ( m_aDisplayDirectory.getLength() > 0 || m_aDefaultName.getLength() > 0 ) + if ( !m_aDisplayDirectory.isEmpty() || !m_aDefaultName.isEmpty() ) { - if ( m_aDisplayDirectory.getLength() > 0 ) + if ( !m_aDisplayDirectory.isEmpty() ) { INetURLObject aPath( m_aDisplayDirectory ); - if ( m_aDefaultName.getLength() > 0 ) + if ( !m_aDefaultName.isEmpty() ) { aPath.insertName( m_aDefaultName ); getDialog()->SetHasFilename( true ); @@ -180,7 +180,7 @@ void SvtFilePicker::prepareExecute() String sPath = aPath.GetMainURL( INetURLObject::NO_DECODE ); getDialog()->SetPath( aPath.GetMainURL( INetURLObject::NO_DECODE ) ); } - else if ( m_aDefaultName.getLength() > 0 ) + else if ( !m_aDefaultName.isEmpty() ) { getDialog()->SetPath( m_aDefaultName ); getDialog()->SetHasFilename( true ); @@ -235,7 +235,7 @@ void SvtFilePicker::prepareExecute() } // set the default filter - if ( m_aCurrentFilter.getLength() > 0 ) + if ( !m_aCurrentFilter.isEmpty() ) getDialog()->SetCurFilter( m_aCurrentFilter ); } @@ -435,7 +435,7 @@ void SvtFilePicker::ensureFilterList( const ::rtl::OUString& _rInitialCurrentFil m_pFilterList = new FilterList; // set the first filter to the current filter - if ( ! m_aCurrentFilter.getLength() ) + if ( m_aCurrentFilter.isEmpty() ) m_aCurrentFilter = _rInitialCurrentFilter; } } @@ -490,7 +490,7 @@ SvtFileDialog* SvtFilePicker::implCreateDialog( Window* _pParent ) SvtFileDialog* dialog = new SvtFileDialog( _pParent, nBits, nExtraBits ); // Set StandardDir if present - if ( m_aStandardDir.getLength() > 0) + if ( !m_aStandardDir.isEmpty()) { String sStandardDir = String( m_aStandardDir ); dialog->SetStandardDir( sStandardDir ); @@ -1081,7 +1081,7 @@ void SAL_CALL SvtFilePicker::initialize( const Sequence< Any >& _rArguments ) namedValue.Value >>= sStandardDir; // Set the directory for the "back to the default dir" button - if ( sStandardDir.getLength() > 0 ) + if ( !sStandardDir.isEmpty() ) { m_aStandardDir = sStandardDir; } diff --git a/fpicker/source/office/OfficeFolderPicker.cxx b/fpicker/source/office/OfficeFolderPicker.cxx index a43311b43b12..74dd3168c9d6 100644 --- a/fpicker/source/office/OfficeFolderPicker.cxx +++ b/fpicker/source/office/OfficeFolderPicker.cxx @@ -133,7 +133,7 @@ sal_Int16 SvtFolderPicker::implExecutePicker( ) void SvtFolderPicker::prepareExecute() { // set the default directory - if ( m_aDisplayDirectory.getLength() > 0 ) + if ( !m_aDisplayDirectory.isEmpty() ) getDialog()->SetPath( m_aDisplayDirectory ); else { diff --git a/fpicker/source/office/commonpicker.cxx b/fpicker/source/office/commonpicker.cxx index e6a5f227d7fe..df317e47a1f1 100644 --- a/fpicker/source/office/commonpicker.cxx +++ b/fpicker/source/office/commonpicker.cxx @@ -112,7 +112,7 @@ namespace svt createPicker(); // set the title - if ( m_aTitle.getLength() > 0 ) + if ( !m_aTitle.isEmpty() ) getDialog()->SetText( m_aTitle ); } @@ -218,7 +218,7 @@ namespace svt if ( m_pDlg ) { // synchronize the help id of the dialog with out help URL property - if ( m_sHelpURL.getLength() ) + if ( !m_sHelpURL.isEmpty() ) { // somebody already set the help URL while we had no dialog yet OControlAccess::setHelpURL( m_pDlg, m_sHelpURL, sal_False ); } @@ -445,7 +445,7 @@ namespace svt { if ( *pArgument >>= aPropArg ) { - if ( aPropArg.Name.getLength() <= 0) + if ( aPropArg.Name.isEmpty()) continue; sSettingName = aPropArg.Name; @@ -453,7 +453,7 @@ namespace svt } else if ( *pArgument >>= aPairArg ) { - if ( aPairArg.Name.getLength() <= 0) + if ( aPairArg.Name.isEmpty()) continue; sSettingName = aPairArg.Name; diff --git a/fpicker/source/office/fpsmartcontent.cxx b/fpicker/source/office/fpsmartcontent.cxx index 8fe9eaf1d598..49692ac37dc8 100644 --- a/fpicker/source/office/fpsmartcontent.cxx +++ b/fpicker/source/office/fpsmartcontent.cxx @@ -158,7 +158,7 @@ namespace svt m_eState = INVALID; // default to INVALID m_sURL = _rURL; - if ( m_sURL.getLength() ) + if ( !m_sURL.isEmpty() ) { try { diff --git a/fpicker/source/office/iodlg.cxx b/fpicker/source/office/iodlg.cxx index 9f093530949b..e1c4c2acaada 100644 --- a/fpicker/source/office/iodlg.cxx +++ b/fpicker/source/office/iodlg.cxx @@ -384,7 +384,7 @@ namespace _rValue = ::rtl::OUString(); ::rtl::OUString sEnvName = ::rtl::OUString::createFromAscii( _pAsciiEnvName ); osl_getEnvironment( sEnvName.pData, &_rValue.pData ); - return _rValue.getLength() != 0; + return !_rValue.isEmpty(); } } |