summaryrefslogtreecommitdiffabout
Side-by-side diff
Diffstat (more/less context) (ignore whitespace changes)
-rw-r--r--libkdepim/externalapphandler.cpp41
1 files changed, 30 insertions, 11 deletions
diff --git a/libkdepim/externalapphandler.cpp b/libkdepim/externalapphandler.cpp
index edefda4..59be506 100644
--- a/libkdepim/externalapphandler.cpp
+++ b/libkdepim/externalapphandler.cpp
@@ -720,4 +720,6 @@ bool ExternalAppHandler::mailToMultipleContacts( const QString& emails, const QS
channel = KPimGlobalPrefs::instance()->mEmailOtherChannel;
- message2 = KPimGlobalPrefs::instance()->mEmailOtherMessage;
- parameters2 = KPimGlobalPrefs::instance()->mEmailOtherMessageParameters;
+ message = KPimGlobalPrefs::instance()->mEmailOtherMessage;
+ message2 = KPimGlobalPrefs::instance()->mEmailOtherMessage2;
+ parameters = KPimGlobalPrefs::instance()->mEmailOtherMessageParameters;
+ parameters2 = KPimGlobalPrefs::instance()->mEmailOtherMessageParameters2;
}
@@ -747,10 +749,20 @@ bool ExternalAppHandler::mailToMultipleContacts( const QString& emails, const QS
QProcess * proc = new QProcess( this );
- QStringList list = QStringList::split( " ", message );
int i = 0;
proc->addArgument( channel );
- while ( i < list.count ( ) ) {
- //qDebug("add%sdd ",list[i].stripWhiteSpace().latin1() );
- proc->addArgument( list[i].stripWhiteSpace() );
+
+ if ( message.find (" " ) > 0 ) {
+ QStringList list = QStringList::split( " ", message );
+ int i = 0;
+ while ( i < list.count ( ) ) {
+ //qDebug("add%sdd ",list[i].latin1() );
+ proc->addArgument( list[i] );
+ //KMessageBox::sorry( 0,list[i]);
++i;
+ }
+ } else {
+ proc->addArgument(message );
+ //KMessageBox::sorry( 0, message );
+
}
+
parameters2 = translateMessage(parameters2, urls, "" );
@@ -759,2 +771,3 @@ bool ExternalAppHandler::mailToMultipleContacts( const QString& emails, const QS
+ //KMessageBox::sorry( 0,arg );
//qDebug("2add%sdd ",arg.latin1() );
@@ -819,11 +832,17 @@ bool ExternalAppHandler::mailToOneContact( const QString& name, const QString& e
- //KMessageBox::sorry( 0, message );
+ //KMessageBox::sorry( 0,channel );
QProcess * proc = new QProcess( this );
- QStringList list = QStringList::split( " ", message );
- int i = 0;
proc->addArgument( channel );
- while ( i < list.count ( ) ) {
+ if ( message.find (" " ) > 0 ) {
+ QStringList list = QStringList::split( " ", message );
+ int i = 0;
+ while ( i < list.count ( ) ) {
//qDebug("add%sdd ",list[i].latin1() );
proc->addArgument( list[i] );
+ //KMessageBox::sorry( 0,list[i]);
++i;
+ }
+ } else {
+ proc->addArgument(message );
+
}
@@ -905,3 +924,3 @@ bool ExternalAppHandler::callByPhone( const QString& phonenumber )
- passParameters(&e, parameters, phonenumber, "");
+ passParameters(&e, parameters, phonenumber, "");