summaryrefslogtreecommitdiff
Unidiff
Diffstat (more/less context) (ignore whitespace changes)
-rw-r--r--core/pim/today/changelog6
-rw-r--r--core/pim/today/opie-today.control2
-rw-r--r--core/pim/today/today.cpp45
-rw-r--r--core/pim/today/today.h2
4 files changed, 41 insertions, 14 deletions
diff --git a/core/pim/today/changelog b/core/pim/today/changelog
index ded4458..d0dd966 100644
--- a/core/pim/today/changelog
+++ b/core/pim/today/changelog
@@ -1 +1,7 @@
10.2.9
2
3* Many bugfixes.
4* Today now apparently sorts the dates _allways_ right, i would assume it
5to be a qt bug
6
10.2.8 70.2.8
diff --git a/core/pim/today/opie-today.control b/core/pim/today/opie-today.control
index 5ad8f01..f875624 100644
--- a/core/pim/today/opie-today.control
+++ b/core/pim/today/opie-today.control
@@ -5,3 +5,3 @@ Maintainer: Maximilian Reiß <max.reiss@gmx.de>
5Architecture: arm 5Architecture: arm
6Version: 0.2.8-$SUB_VERSION 6Version: 0.2.9-$SUB_VERSION
7Depends: opie-base ($QPE_VERSION) 7Depends: opie-base ($QPE_VERSION)
diff --git a/core/pim/today/today.cpp b/core/pim/today/today.cpp
index 1cdc6b4..81d4d36 100644
--- a/core/pim/today/today.cpp
+++ b/core/pim/today/today.cpp
@@ -42,9 +42,8 @@
42#include <qlayout.h> 42#include <qlayout.h>
43#include <qtl.h>
43 44
44//#include <iostream.h> 45//#include <iostream.h>
45//#include <unistd.h> 46#include <unistd.h>
46#include <stdlib.h> 47#include <stdlib.h>
47 48
48
49
50int MAX_LINES_TASK; 49int MAX_LINES_TASK;
@@ -64,3 +63,3 @@ int NEW_START=1;
64Today::Today( QWidget* parent, const char* name, WFlags fl ) 63Today::Today( QWidget* parent, const char* name, WFlags fl )
65 : TodayBase( parent, name, fl ) { 64 : TodayBase( parent, name, fl ), AllDateBookEvents(NULL) {
66 QObject::connect( (QObject*)PushButton1, SIGNAL( clicked() ), this, SLOT(startConfig() ) ); 65 QObject::connect( (QObject*)PushButton1, SIGNAL( clicked() ), this, SLOT(startConfig() ) );
@@ -197,2 +196,3 @@ void Today::startConfig() {
197 cfg.write(); 196 cfg.write();
197 NEW_START=1;
198 draw(); 198 draw();
@@ -207,3 +207,5 @@ void Today::getDates() {
207 QDate date = QDate::currentDate(); 207 QDate date = QDate::currentDate();
208 QWidget* AllDateBookEvents = new QWidget( ); 208
209 if (AllDateBookEvents) delete AllDateBookEvents;
210 AllDateBookEvents = new QWidget( );
209 QVBoxLayout* layoutDates = new QVBoxLayout(AllDateBookEvents); 211 QVBoxLayout* layoutDates = new QVBoxLayout(AllDateBookEvents);
@@ -212,2 +214,5 @@ void Today::getDates() {
212 214
215 qBubbleSort(list);
216 // printf("Get dates\n");
217
213 Config config( "qpe" ); 218 Config config( "qpe" );
@@ -223,3 +228,2 @@ void Today::getDates() {
223 228
224 count++;
225 229
@@ -230,2 +234,3 @@ void Today::getDates() {
230 if (!ONLY_LATER) { 234 if (!ONLY_LATER) {
235 count++;
231 DateBookEvent *l=new DateBookEvent(*it, AllDateBookEvents); 236 DateBookEvent *l=new DateBookEvent(*it, AllDateBookEvents);
@@ -233,4 +238,6 @@ void Today::getDates() {
233 connect (l, SIGNAL(editEvent(const Event &)), 238 connect (l, SIGNAL(editEvent(const Event &)),
234 this, SIGNAL(editEvent(const Event &))); 239 this, SLOT(editEvent(const Event &)));
235 } else if ((time.toString() <= TimeString::dateString((*it).event().end())) ) { 240 } else if ((time.toString() <= TimeString::dateString((*it).event().end())) ) {
241 count++;
242
236 // show only later appointments 243 // show only later appointments
@@ -239,9 +246,10 @@ void Today::getDates() {
239 connect (l, SIGNAL(editEvent(const Event &)), 246 connect (l, SIGNAL(editEvent(const Event &)),
240 this, SIGNAL(editEvent(const Event &))); 247 this, SLOT(editEvent(const Event &)));
241 } else { 248 }
242 QLabel* noMoreEvents = new QLabel(AllDateBookEvents);
243 noMoreEvents->setText("No more appointments today");
244 layoutDates->addWidget(noMoreEvents);
245 }
246 } 249 }
250 }
251 if (ONLY_LATER && count==0) {
252 QLabel* noMoreEvents = new QLabel(AllDateBookEvents);
253 noMoreEvents->setText("No more appointments today");
254 layoutDates->addWidget(noMoreEvents);
247 } 255 }
@@ -255,2 +263,3 @@ void Today::getDates() {
255 sv1->addChild(AllDateBookEvents); 263 sv1->addChild(AllDateBookEvents);
264 AllDateBookEvents->show();
256 265
@@ -395,2 +404,12 @@ void Today::startDatebook() {
395} 404}
405void Today::editEvent(const Event &e) {
406 startDatebook();
407
408 //Dissabled for now as uid's not working properly
409 /*
410 while(!QCopChannel::isRegistered("QPE/Datebook")) sleep(1);
411 QCopEnvelope env("QPE/Datebook", "editEvent(int)");
412 env << e.uid();
413 */
414}
396 415
diff --git a/core/pim/today/today.h b/core/pim/today/today.h
index b3f0654..0b4356c 100644
--- a/core/pim/today/today.h
+++ b/core/pim/today/today.h
@@ -49,2 +49,3 @@ class Today : public TodayBase {
49 void draw(); 49 void draw();
50 void editEvent(const Event &e);
50 private: 51 private:
@@ -60,2 +61,3 @@ class Today : public TodayBase {
60 todayconfig *conf; 61 todayconfig *conf;
62 QWidget* AllDateBookEvents;
61 //Config cfg; 63 //Config cfg;