summaryrefslogtreecommitdiff
path: root/noncore/net/mailit/emailhandler.cpp
authorllornkcor <llornkcor>2003-05-24 01:20:33 (UTC)
committer llornkcor <llornkcor>2003-05-24 01:20:33 (UTC)
commit62d2ddfb5cd77e2637cdf7fe16d76aac04975984 (patch) (side-by-side diff)
tree2157d57bab2d6e491226f5bc8468a4c2527e1456 /noncore/net/mailit/emailhandler.cpp
parent0c4b5288ccd4bcd1668816a0c4e12ce0a76b4e6e (diff)
downloadopie-62d2ddfb5cd77e2637cdf7fe16d76aac04975984.zip
opie-62d2ddfb5cd77e2637cdf7fe16d76aac04975984.tar.gz
opie-62d2ddfb5cd77e2637cdf7fe16d76aac04975984.tar.bz2
QString to const QString
Diffstat (limited to 'noncore/net/mailit/emailhandler.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r--noncore/net/mailit/emailhandler.cpp28
1 files changed, 14 insertions, 14 deletions
diff --git a/noncore/net/mailit/emailhandler.cpp b/noncore/net/mailit/emailhandler.cpp
index 62fa64f..59ccd90 100644
--- a/noncore/net/mailit/emailhandler.cpp
+++ b/noncore/net/mailit/emailhandler.cpp
@@ -39,7 +39,7 @@ Enclosure* EnclosureList::dupl(Enclosure *in)
EmailHandler::EmailHandler()
{
- qDebug("EMailHandler::EmailHandler");
+ qDebug("EMailHandler::EmailHandler");
smtpClient = new SmtpClient();
popClient = new PopClient();
@@ -148,7 +148,7 @@ void EmailHandler::messageArrived(const QString &message, int id, uint size, boo
emit mailArrived(mail, FALSE);
}
-bool EmailHandler::parse(QString in, QString lineShift, Email *mail)
+bool EmailHandler::parse(const QString &in, const QString &lineShift, Email *mail)
{
QString temp, boundary;
int pos;
@@ -204,21 +204,21 @@ bool EmailHandler::parse(QString in, QString lineShift, Email *mail)
//Search for To: after the FROM: attribute to prevent hitting the Delivered-To:
while((pos = p.find("TO",':', pos+1, TRUE))!=-1)
{
- QString rec;
-
- if (p.separatorAt(pos-1)!='-') //The - separator means that this is a Delivered-To: or Reply-To:
- {
- pos++;
- mail->recipients.append(p.getString(&pos, '\r', TRUE));
- }
+ QString rec;
+
+ if (p.separatorAt(pos-1)!='-') //The - separator means that this is a Delivered-To: or Reply-To:
+ {
+ pos++;
+ mail->recipients.append(p.getString(&pos, '\r', TRUE));
+ }
}
//
//if (pos==-1) mail->recipients.append (tr("undisclosed recipients") );
if ((pos = p.find("CC",':', 0, TRUE)) != -1)
{
- pos++;
- mail->carbonCopies.append (p.getString(&pos, 'z', TRUE) );
+ pos++;
+ mail->carbonCopies.append (p.getString(&pos, 'z', TRUE) );
}
if ((pos = p.find("SUBJECT",':', 0, TRUE)) != -1) {
@@ -440,8 +440,8 @@ int EmailHandler::encodeMime(Email *mail)
Enclosure *ePtr;
QString userName = mailAccount.name;
- if (userName.length()>0) //only embrace it if there is a user name
- userName += " <" + mailAccount.emailAddress + ">";
+ if (userName.length()>0) //only embrace it if there is a user name
+ userName += " <" + mailAccount.emailAddress + ">";
//add standard headers
newBody = "From: " + userName + "\r\nTo: ";
@@ -510,7 +510,7 @@ int EmailHandler::encodeMime(Email *mail)
return 0;
}
-int EmailHandler::encodeFile(QString fileName, QString *toBody)
+int EmailHandler::encodeFile(const QString &fileName, QString *toBody)
{
char *fileData;
char *dataPtr;