author | zautrix <zautrix> | 2004-07-03 16:49:55 (UTC) |
---|---|---|
committer | zautrix <zautrix> | 2004-07-03 16:49:55 (UTC) |
commit | 1da48d95d970233f0d1ea9a7fba5c98cfcf24798 (patch) (unidiff) | |
tree | ae690b33cbe50291a610842e24de33f9d766f2f2 /korganizer/koeventviewer.cpp | |
parent | e3b89230f065c48c84b48c88edb6eb088374c487 (diff) | |
download | kdepimpi-1da48d95d970233f0d1ea9a7fba5c98cfcf24798.zip kdepimpi-1da48d95d970233f0d1ea9a7fba5c98cfcf24798.tar.gz kdepimpi-1da48d95d970233f0d1ea9a7fba5c98cfcf24798.tar.bz2 |
Alarm Bugfix. Added connection to KM. Cleaned up main.
-rw-r--r-- | korganizer/koeventviewer.cpp | 34 |
1 files changed, 33 insertions, 1 deletions
diff --git a/korganizer/koeventviewer.cpp b/korganizer/koeventviewer.cpp index bac66d3..1f69700 100644 --- a/korganizer/koeventviewer.cpp +++ b/korganizer/koeventviewer.cpp | |||
@@ -52,2 +52,6 @@ | |||
52 | #endif | 52 | #endif |
53 | #ifndef DESKTOP_VERSION | ||
54 | #include <qtopia/qcopenvelope_qws.h> | ||
55 | #endif | ||
56 | |||
53 | KOEventViewer::KOEventViewer(QWidget *parent,const char *name) | 57 | KOEventViewer::KOEventViewer(QWidget *parent,const char *name) |
@@ -65,2 +69,4 @@ void KOEventViewer::setSource(const QString& n) | |||
65 | { | 69 | { |
70 | |||
71 | if ( n.left(3) == "uid" ) { | ||
66 | KABC::StdAddressBook* AddressBook = KABC::StdAddressBook::self( true ); | 72 | KABC::StdAddressBook* AddressBook = KABC::StdAddressBook::self( true ); |
@@ -93,2 +99,12 @@ void KOEventViewer::setSource(const QString& n) | |||
93 | } | 99 | } |
100 | return; | ||
101 | } | ||
102 | if ( n.left(6) == "mailto" ) { | ||
103 | // qDebug("KOEventViewer::setSource %s ", n.mid(7).latin1()); | ||
104 | #ifndef DESKTOP_VERSION | ||
105 | QCopEnvelope e("QPE/Application/kmpi", "newMail(QString)" ); | ||
106 | e << n.mid(7); | ||
107 | #endif | ||
108 | |||
109 | } | ||
94 | 110 | ||
@@ -172,2 +188,3 @@ void KOEventViewer::appendEvent(Event *event, int mode ) | |||
172 | { | 188 | { |
189 | mMailSubject = ""; | ||
173 | mCurrentIncidence = event; | 190 | mCurrentIncidence = event; |
@@ -195,2 +212,3 @@ void KOEventViewer::appendEvent(Event *event, int mode ) | |||
195 | } | 212 | } |
213 | mMailSubject += i18n( "Meeting " )+ event->summary(); | ||
196 | if (event->cancelled ()) { | 214 | if (event->cancelled ()) { |
@@ -200,2 +218,3 @@ void KOEventViewer::appendEvent(Event *event, int mode ) | |||
200 | mText += "</font>"; | 218 | mText += "</font>"; |
219 | mMailSubject += i18n("(cancelled)"); | ||
201 | } | 220 | } |
@@ -204,2 +223,3 @@ void KOEventViewer::appendEvent(Event *event, int mode ) | |||
204 | mText.append(event->location()+"<br>"); | 223 | mText.append(event->location()+"<br>"); |
224 | mMailSubject += i18n(" at ") + event->location(); | ||
205 | } | 225 | } |
@@ -240,2 +260,5 @@ void KOEventViewer::appendEvent(Event *event, int mode ) | |||
240 | addTag("p", KGlobal::locale()->formatDate( next, shortDate )); | 260 | addTag("p", KGlobal::locale()->formatDate( next, shortDate )); |
261 | QDateTime nextdt = QDateTime( next, event->dtStart().time()); | ||
262 | mMailSubject += i18n(" - " )+ KGlobal::locale()->formatDateTime( nextdt, true ); | ||
263 | |||
241 | } else { | 264 | } else { |
@@ -244,2 +267,5 @@ void KOEventViewer::appendEvent(Event *event, int mode ) | |||
244 | } | 267 | } |
268 | } else { | ||
269 | mMailSubject += i18n(" - " )+event->dtStartStr( true ); | ||
270 | |||
245 | } | 271 | } |
@@ -276,2 +302,3 @@ void KOEventViewer::appendTodo(Todo *event, int mode ) | |||
276 | { | 302 | { |
303 | mMailSubject = ""; | ||
277 | mCurrentIncidence = event; | 304 | mCurrentIncidence = event; |
@@ -297,2 +324,3 @@ void KOEventViewer::appendTodo(Todo *event, int mode ) | |||
297 | } | 324 | } |
325 | mMailSubject += i18n( "Todo " )+ event->summary(); | ||
298 | if (event->cancelled ()) { | 326 | if (event->cancelled ()) { |
@@ -302,2 +330,3 @@ void KOEventViewer::appendTodo(Todo *event, int mode ) | |||
302 | mText += "</font>"; | 330 | mText += "</font>"; |
331 | mMailSubject += i18n("(cancelled)"); | ||
303 | } | 332 | } |
@@ -307,2 +336,3 @@ void KOEventViewer::appendTodo(Todo *event, int mode ) | |||
307 | mText.append(event->location()+"<br>"); | 336 | mText.append(event->location()+"<br>"); |
337 | mMailSubject += i18n(" at ") + event->location(); | ||
308 | } | 338 | } |
@@ -310,2 +340,3 @@ void KOEventViewer::appendTodo(Todo *event, int mode ) | |||
310 | mText.append(i18n("<p><b>Due on:</b> %1</p>").arg(event->dtDueStr(KOPrefs::instance()->mShortDateInViewer))); | 340 | mText.append(i18n("<p><b>Due on:</b> %1</p>").arg(event->dtDueStr(KOPrefs::instance()->mShortDateInViewer))); |
341 | mMailSubject += i18n(" - " )+event->dtDueStr( true ); | ||
311 | } | 342 | } |
@@ -407,5 +438,6 @@ void KOEventViewer::formatAttendees(Incidence *event) | |||
407 | 438 | ||
439 | |||
408 | if (!a->email().isEmpty()) { | 440 | if (!a->email().isEmpty()) { |
409 | if (iconPath) { | 441 | if (iconPath) { |
410 | mText += "<a href=\"mailto:" + a->name() +" "+ "<" + a->email() + ">" + "\">"; | 442 | mText += "<a href=\"mailto:" + a->name() +" <" + a->email() + ">:" + mMailSubject + "\">"; |
411 | mText += "<IMG src=\"" + iconPath + "\">"; | 443 | mText += "<IMG src=\"" + iconPath + "\">"; |