diff options
author | Olivier Hallot <olivier.hallot@alta.org.br> | 2012-01-11 11:37:33 -0200 |
---|---|---|
committer | Olivier Hallot <olivier.hallot@alta.org.br> | 2012-01-11 18:43:07 -0200 |
commit | 806dce17d6631738c7388d8d68d8b5ac2e4c11a8 (patch) | |
tree | 0759954593c2fa8a85b94e5d3a4b4f40e913f091 /shell/source/cmdmail | |
parent | e33702442a22a72f96a093fbfdf8bfac217f416f (diff) |
Fix for fdo43460 Part XXXIV getLength() to isEmpty()
Part XXXIV
Modules
shell, slideshow, sot, starmath
Diffstat (limited to 'shell/source/cmdmail')
-rw-r--r-- | shell/source/cmdmail/cmdmailmsg.cxx | 18 | ||||
-rw-r--r-- | shell/source/cmdmail/cmdmailsuppl.cxx | 8 |
2 files changed, 13 insertions, 13 deletions
diff --git a/shell/source/cmdmail/cmdmailmsg.cxx b/shell/source/cmdmail/cmdmailmsg.cxx index 1a33afd343af..2a2bb8a8bd6f 100644 --- a/shell/source/cmdmail/cmdmailmsg.cxx +++ b/shell/source/cmdmail/cmdmailmsg.cxx @@ -167,10 +167,10 @@ Any SAL_CALL CmdMailMsg::getByName( const OUString& aName ) { MutexGuard aGuard( m_aMutex ); - if( 0 == aName.compareToAscii( "from" ) && m_aOriginator.getLength() ) + if( 0 == aName.compareToAscii( "from" ) && !m_aOriginator.isEmpty() ) return makeAny( m_aOriginator ); - else if( 0 == aName.compareToAscii( "to" ) && m_aRecipient.getLength() ) + else if( 0 == aName.compareToAscii( "to" ) && !m_aRecipient.isEmpty() ) return makeAny( m_aRecipient ); else if( 0 == aName.compareToAscii( "cc" ) && m_CcRecipients.getLength() ) @@ -179,7 +179,7 @@ Any SAL_CALL CmdMailMsg::getByName( const OUString& aName ) else if( 0 == aName.compareToAscii( "bcc" ) && m_BccRecipients.getLength() ) return makeAny( m_BccRecipients ); - else if( 0 == aName.compareToAscii( "subject" ) && m_aSubject.getLength() ) + else if( 0 == aName.compareToAscii( "subject" ) && !m_aSubject.isEmpty() ) return makeAny( m_aSubject ); else if( 0 == aName.compareToAscii( "attachment" ) && m_Attachments.getLength() ) @@ -199,10 +199,10 @@ Sequence< OUString > SAL_CALL CmdMailMsg::getElementNames( ) sal_Int32 nItems = 0; Sequence< OUString > aRet( 6 ); - if( m_aOriginator.getLength() ) + if( !m_aOriginator.isEmpty() ) aRet[nItems++] = OUString(RTL_CONSTASCII_USTRINGPARAM("from")); - if( m_aRecipient.getLength() ) + if( !m_aRecipient.isEmpty() ) aRet[nItems++] = OUString(RTL_CONSTASCII_USTRINGPARAM("to")); if( m_CcRecipients.getLength() ) @@ -211,7 +211,7 @@ Sequence< OUString > SAL_CALL CmdMailMsg::getElementNames( ) if( m_BccRecipients.getLength() ) aRet[nItems++] = OUString(RTL_CONSTASCII_USTRINGPARAM("bcc")); - if( m_aSubject.getLength() ) + if( !m_aSubject.isEmpty() ) aRet[nItems++] = OUString(RTL_CONSTASCII_USTRINGPARAM("subject")); if( m_Attachments.getLength() ) @@ -228,10 +228,10 @@ Sequence< OUString > SAL_CALL CmdMailMsg::getElementNames( ) { MutexGuard aGuard( m_aMutex ); - if( 0 == aName.compareToAscii( "from" ) && m_aOriginator.getLength() ) + if( 0 == aName.compareToAscii( "from" ) && !m_aOriginator.isEmpty() ) return sal_True; - else if( 0 == aName.compareToAscii( "to" ) && m_aRecipient.getLength() ) + else if( 0 == aName.compareToAscii( "to" ) && !m_aRecipient.isEmpty() ) return sal_True; else if( 0 == aName.compareToAscii( "cc" ) && m_CcRecipients.getLength() ) @@ -240,7 +240,7 @@ Sequence< OUString > SAL_CALL CmdMailMsg::getElementNames( ) else if( 0 == aName.compareToAscii( "bcc" ) && m_BccRecipients.getLength() ) return sal_True; - else if( 0 == aName.compareToAscii( "subject" ) && m_aSubject.getLength() ) + else if( 0 == aName.compareToAscii( "subject" ) && !m_aSubject.isEmpty() ) return sal_True; else if( 0 == aName.compareToAscii( "attachment" ) && m_Attachments.getLength() ) diff --git a/shell/source/cmdmail/cmdmailsuppl.cxx b/shell/source/cmdmail/cmdmailsuppl.cxx index 3af65c8bac35..c0531e3f887e 100644 --- a/shell/source/cmdmail/cmdmailsuppl.cxx +++ b/shell/source/cmdmail/cmdmailsuppl.cxx @@ -195,7 +195,7 @@ void SAL_CALL CmdMailSuppl::sendSimpleMailMessage( const Reference< XSimpleMailM // using the (undocumented) --mailclient switch xNameAccess->getByName( OUString(RTL_CONSTASCII_USTRINGPARAM("Program")) ) >>= aMailer; - if( aMailer.getLength() ) + if( !aMailer.isEmpty() ) { // make sure we have a system path FileBase::getSystemPathFromFileURL( aMailer, aMailer ); @@ -221,7 +221,7 @@ void SAL_CALL CmdMailSuppl::sendSimpleMailMessage( const Reference< XSimpleMailM } // Append originator if set in the message - if ( xSimpleMailMessage->getOriginator().getLength() > 0 ) + if ( !xSimpleMailMessage->getOriginator().isEmpty() ) { aBuffer.append("--from \""); aBuffer.append(OUStringToOString(xSimpleMailMessage->getOriginator(), osl_getThreadTextEncoding())); @@ -229,7 +229,7 @@ void SAL_CALL CmdMailSuppl::sendSimpleMailMessage( const Reference< XSimpleMailM } // Append receipient if set in the message - if ( xSimpleMailMessage->getRecipient().getLength() > 0 ) + if ( !xSimpleMailMessage->getRecipient().isEmpty() ) { aBuffer.append("--to \""); aBuffer.append(OUStringToOString(xSimpleMailMessage->getRecipient(), osl_getThreadTextEncoding())); @@ -257,7 +257,7 @@ void SAL_CALL CmdMailSuppl::sendSimpleMailMessage( const Reference< XSimpleMailM } // Append subject if set in the message - if ( xSimpleMailMessage->getSubject().getLength() > 0 ) + if ( !xSimpleMailMessage->getSubject().isEmpty() ) { aBuffer.append("--subject \""); aBuffer.append(OUStringToOString(xSimpleMailMessage->getSubject(), osl_getThreadTextEncoding())); |