summaryrefslogtreecommitdiffabout
path: root/libkdepim
authorulf69 <ulf69>2004-11-07 01:13:59 (UTC)
committer ulf69 <ulf69>2004-11-07 01:13:59 (UTC)
commitc3168210fffc83fbab58f44ce456fd241d44716d (patch) (side-by-side diff)
treec93de33dd16e9b0f1e0752d6006aa75bd003fccf /libkdepim
parent023e0e82dd8bf6421d12492a2dd25534fc43ad31 (diff)
downloadkdepimpi-c3168210fffc83fbab58f44ce456fd241d44716d.zip
kdepimpi-c3168210fffc83fbab58f44ce456fd241d44716d.tar.gz
kdepimpi-c3168210fffc83fbab58f44ce456fd241d44716d.tar.bz2
added support for mailit opie mailer,
now we check for applications in QTDIR, QPEDIR and OPIEDIR
Diffstat (limited to 'libkdepim') (more/less context) (ignore whitespace changes)
-rw-r--r--libkdepim/externalapphandler.cpp17
-rw-r--r--libkdepim/kpimglobalprefs.h3
2 files changed, 17 insertions, 3 deletions
diff --git a/libkdepim/externalapphandler.cpp b/libkdepim/externalapphandler.cpp
index 9f12152..3079141 100644
--- a/libkdepim/externalapphandler.cpp
+++ b/libkdepim/externalapphandler.cpp
@@ -412,10 +412,18 @@ void ExternalAppHandler::loadConfig()
QString opiepath = QString::fromLatin1( getenv("OPIEDIR") );
QString qtopiapath = QString::fromLatin1( getenv("QPEDIR") );
+ QString qtpath = QString::fromLatin1( getenv("QTDIR") );
+ //if qtopiapath is not set, fallback to qt
+ if (qtopiapath.isEmpty())
+ qtopiapath = qtpath;
+
+ //if opiepath is not set, fallback to qtopia
if (opiepath.isEmpty())
opiepath = qtopiapath;
+
+
//mailclients
QString mailmsg1 = "writeMail(QString,QString)";
QString mailmsg2 = "writeMail(QMap(QString,QString))";
@@ -426,15 +434,20 @@ void ExternalAppHandler::loadConfig()
addDefaultAppItem(ExternalAppHandler::EMAIL, KPimGlobalPrefs::OTHER_EMC, "Userdefined email client", undefined, undefined, undefined, undefined, undefined);
if (( QFile::exists( qtopiapath + "/bin/ompi" )) ||
- ( QFile::exists( opiepath + "/bin/ompi" )))
+ ( QFile::exists( opiepath + "/bin/ompi" )) ||
+ ( QFile::exists( qtpath + "/bin/ompi" )))
addDefaultAppItem(ExternalAppHandler::EMAIL, KPimGlobalPrefs::OMPI_EMC, "OM/Pi email client", "QPE/Application/ompi", mailmsg1, "%1;%2", mailmsg2, "TO=%1;ATTACHMENT=%2");
- if ( QFile::exists( qtopiapath + "/bin/qtmail" ))
+ if (( QFile::exists( qtopiapath + "/bin/qtmail" )) ||
+ ( QFile::exists( qtpath + "/bin/qtmail" )))
addDefaultAppItem(ExternalAppHandler::EMAIL, KPimGlobalPrefs::QTOPIA_EMC, "Qtopia email client", "QPE/Application/qtmail", mailmsg1, "%1;%2", mailmsg2, "TO=%1;ATTACHMENT=%2");
if ( QFile::exists( opiepath + "/bin/opiemail" ))
addDefaultAppItem(ExternalAppHandler::EMAIL, KPimGlobalPrefs::OPIE_EMC, "Opie email client", "QPE/Application/opiemail", mailmsg1, "%1;%2", mailmsg2, "TO=%1;ATTACHMENT=%2");
+ if ( QFile::exists( opiepath + "/bin/mailit" ))
+ addDefaultAppItem(ExternalAppHandler::EMAIL, KPimGlobalPrefs::OPIE_MAILIT_EMC, "Opie mailit email client", "QPE/Application/mailit", mailmsg1, "%1;%2", mailmsg2, "TO=%1;ATTACHMENT=%2");
+
//phoneclients
diff --git a/libkdepim/kpimglobalprefs.h b/libkdepim/kpimglobalprefs.h
index 11c534a..5e27e85 100644
--- a/libkdepim/kpimglobalprefs.h
+++ b/libkdepim/kpimglobalprefs.h
@@ -50,7 +50,8 @@ class KPimGlobalPrefs : public KPrefs
OTHER_EMC = 1,
OMPI_EMC = 2,
QTOPIA_EMC = 3,
- OPIE_EMC = 4
+ OPIE_EMC = 4,
+ OPIE_MAILIT_EMC = 5
};
enum PhoneClients {