summaryrefslogtreecommitdiff
Unidiff
Diffstat (more/less context) (ignore whitespace changes)
-rw-r--r--core/pim/today/changelog7
-rw-r--r--core/pim/today/clickablelabel.cpp31
-rw-r--r--core/pim/today/clickablelabel.h20
-rw-r--r--core/pim/today/opie-today.control2
-rw-r--r--core/pim/today/today.cpp4
-rw-r--r--core/pim/today/today.h6
-rw-r--r--core/pim/today/today.pro4
7 files changed, 15 insertions, 59 deletions
diff --git a/core/pim/today/changelog b/core/pim/today/changelog
index 0bc5fe0..c687cea 100644
--- a/core/pim/today/changelog
+++ b/core/pim/today/changelog
@@ -1,12 +1,19 @@
10.3.3
2
3* Changed the logo so it better scales to bigger display and also
4 made the "Today" string translatable.
5* some am/pm fixes
6* clickable labels now in libopie
7
10.3.2 80.3.2
2 9
3* Autostart is now more configurable. You can decide how long 10* Autostart is now more configurable. You can decide how long
4 the ipaq has to has been suspended, before autostart is triggered.(Opie 11 the ipaq has to has been suspended, before autostart is triggered.(Opie
5 only) 12 only)
6* am/pm time optinal (autodetect) 13* am/pm time optinal (autodetect)
7 14
80.3.1 150.3.1
9 16
10* fixed the wrong color of the buttons 17* fixed the wrong color of the buttons
11* better translation (thanks carsten and others) 18* better translation (thanks carsten and others)
12* fixes memory leaks 19* fixes memory leaks
diff --git a/core/pim/today/clickablelabel.cpp b/core/pim/today/clickablelabel.cpp
deleted file mode 100644
index e11cef6..0000000
--- a/core/pim/today/clickablelabel.cpp
+++ b/dev/null
@@ -1,31 +0,0 @@
1#include "clickablelabel.h"
2
3ClickableLabel::ClickableLabel(QWidget* parent,
4 const char* name,
5 WFlags fl) :
6 QLabel(parent,name,fl)
7{
8 setFrameShape(NoFrame);
9 setFrameShadow(Sunken);
10}
11
12void ClickableLabel::mousePressEvent( QMouseEvent *e ) {
13 setFrameShape(Panel);
14 repaint();
15}
16
17void ClickableLabel::mouseReleaseEvent( QMouseEvent *e ) {
18 setFrameShape(NoFrame);
19 repaint();
20 if (rect().contains(e->pos())) {
21 emit clicked();
22 }
23}
24
25void ClickableLabel::mouseMoveEvent( QMouseEvent *e ) {
26 if (rect().contains(e->pos())) {
27 setFrameShape(Panel);
28 } else {
29 setFrameShape(NoFrame);
30 }
31}
diff --git a/core/pim/today/clickablelabel.h b/core/pim/today/clickablelabel.h
deleted file mode 100644
index b6d33ad..0000000
--- a/core/pim/today/clickablelabel.h
+++ b/dev/null
@@ -1,20 +0,0 @@
1#ifndef CLICKABLELABEL
2#define CLICKABLELABEL
3
4#include <qlabel.h>
5
6class ClickableLabel: public QLabel
7{
8 Q_OBJECT
9public:
10 ClickableLabel(QWidget* parent = 0, const char* name = 0,
11 WFlags fl = 0);
12 protected:
13 void mousePressEvent( QMouseEvent *e );
14 void mouseReleaseEvent( QMouseEvent *e );
15 void mouseMoveEvent( QMouseEvent *e );
16 signals:
17 void clicked();
18};
19
20#endif
diff --git a/core/pim/today/opie-today.control b/core/pim/today/opie-today.control
index cf982fd..da9d9fa 100644
--- a/core/pim/today/opie-today.control
+++ b/core/pim/today/opie-today.control
@@ -1,16 +1,16 @@
1Files: bin/today apps/Applications/today.desktop pics/today/* 1Files: bin/today apps/Applications/today.desktop pics/today/*
2Priority: optional 2Priority: optional
3Section: opie/applications 3Section: opie/applications
4Maintainer: Maximilian Reiß <max.reiss@gmx.de> 4Maintainer: Maximilian Reiß <max.reiss@gmx.de>
5Architecture: arm 5Architecture: arm
6Version: 0.3.2-$SUB_VERSION 6Version: 0.3.3-$SUB_VERSION
7Depends: opie-base ($QPE_VERSION), libopie ($QPE_VERSION) 7Depends: opie-base ($QPE_VERSION), libopie ($QPE_VERSION)
8License: GPL 8License: GPL
9Description: today screen 9Description: today screen
10 This today screen app gives an overview of appointments 10 This today screen app gives an overview of appointments
11 and todos. 11 and todos.
12 It also shows incoming and outgoing mails from opiemail. 12 It also shows incoming and outgoing mails from opiemail.
13 When using Opie (opie.handhelds.org) today can be autostarted 13 When using Opie (opie.handhelds.org) today can be autostarted
14 on resume. 14 on resume.
15 It is highly configurable. 15 It is highly configurable.
16 16
diff --git a/core/pim/today/today.cpp b/core/pim/today/today.cpp
index 1b4408c..0f4cbdb 100644
--- a/core/pim/today/today.cpp
+++ b/core/pim/today/today.cpp
@@ -464,25 +464,25 @@ void Today::startMail() {
464Today::~Today() { 464Today::~Today() {
465} 465}
466 466
467/* 467/*
468 * Gets the events for the current day, if it should get all dates 468 * Gets the events for the current day, if it should get all dates
469 */ 469 */
470DateBookEvent::DateBookEvent(const EffectiveEvent &ev, 470DateBookEvent::DateBookEvent(const EffectiveEvent &ev,
471 QWidget* parent, 471 QWidget* parent,
472 int SHOW_LOCATION, 472 int SHOW_LOCATION,
473 int SHOW_NOTES, 473 int SHOW_NOTES,
474 const char* name, 474 const char* name,
475 WFlags fl) : 475 WFlags fl) :
476 ClickableLabel(parent,name,fl), event(ev) { 476 OClickableLabel(parent,name,fl), event(ev) {
477 477
478 QString msg; 478 QString msg;
479 //QTime time = QTime::currentTime(); 479 //QTime time = QTime::currentTime();
480 480
481 Config config( "qpe" ); 481 Config config( "qpe" );
482 config.setGroup( "Time" ); 482 config.setGroup( "Time" );
483 // if 24 h format 483 // if 24 h format
484 ampm = config.readBoolEntry( "AMPM", TRUE ); 484 ampm = config.readBoolEntry( "AMPM", TRUE );
485 485
486 486
487 if (!ONLY_LATER) { 487 if (!ONLY_LATER) {
488 msg += "<B>" + (ev).description() + "</B>"; 488 msg += "<B>" + (ev).description() + "</B>";
@@ -531,25 +531,25 @@ QString DateBookEvent::ampmTime(QTime tm) {
531 return s; 531 return s;
532 } 532 }
533 533
534} 534}
535 535
536 536
537DateBookEventLater::DateBookEventLater(const EffectiveEvent &ev, 537DateBookEventLater::DateBookEventLater(const EffectiveEvent &ev,
538 QWidget* parent, 538 QWidget* parent,
539 int SHOW_LOCATION, 539 int SHOW_LOCATION,
540 int SHOW_NOTES, 540 int SHOW_NOTES,
541 const char* name, 541 const char* name,
542 WFlags fl) : 542 WFlags fl) :
543 ClickableLabel(parent,name,fl), event(ev) { 543 OClickableLabel(parent,name,fl), event(ev) {
544 544
545 QString msg; 545 QString msg;
546 QTime time = QTime::currentTime(); 546 QTime time = QTime::currentTime();
547 547
548 Config config( "qpe" ); 548 Config config( "qpe" );
549 config.setGroup( "Time" ); 549 config.setGroup( "Time" );
550 // if 24 h format 550 // if 24 h format
551 ampm = config.readBoolEntry( "AMPM", TRUE ); 551 ampm = config.readBoolEntry( "AMPM", TRUE );
552 552
553 553
554 if ((time.toString() <= TimeString::dateString((ev).event().end())) ) { 554 if ((time.toString() <= TimeString::dateString((ev).event().end())) ) {
555 // show only later appointments 555 // show only later appointments
diff --git a/core/pim/today/today.h b/core/pim/today/today.h
index d265d67..32bb4a3 100644
--- a/core/pim/today/today.h
+++ b/core/pim/today/today.h
@@ -16,31 +16,31 @@
16 * (at your option) any later version. * 16 * (at your option) any later version. *
17 * * 17 * *
18 ***************************************************************************/ 18 ***************************************************************************/
19 19
20 20
21#ifndef TODAY_H 21#ifndef TODAY_H
22#define TODAY_H 22#define TODAY_H
23 23
24#include <qpe/datebookdb.h> 24#include <qpe/datebookdb.h>
25#include <qpe/event.h> 25#include <qpe/event.h>
26 26
27#include <opie/tododb.h> 27#include <opie/tododb.h>
28#include <opie/oclickablelabel.h>
28 29
29#include <qdatetime.h> 30#include <qdatetime.h>
30#include <qlist.h> 31#include <qlist.h>
31 32
32#include "todayconfig.h" 33#include "todayconfig.h"
33#include "todaybase.h" 34#include "todaybase.h"
34#include "clickablelabel.h"
35 35
36class QVBoxLayout; 36class QVBoxLayout;
37 37
38class Today : public TodayBase { 38class Today : public TodayBase {
39 Q_OBJECT 39 Q_OBJECT
40 40
41 public: 41 public:
42 Today( QWidget* parent = 0, const char* name = 0, WFlags fl = 0 ); 42 Today( QWidget* parent = 0, const char* name = 0, WFlags fl = 0 );
43 ~Today(); 43 ~Today();
44 44
45 private slots: 45 private slots:
46 void startConfig(); 46 void startConfig();
@@ -65,44 +65,44 @@ class Today : public TodayBase {
65 DateBookDB *db; 65 DateBookDB *db;
66 ToDoDB *todo; 66 ToDoDB *todo;
67 todayconfig *conf; 67 todayconfig *conf;
68 QWidget* AllDateBookEvents; 68 QWidget* AllDateBookEvents;
69 //Config cfg; 69 //Config cfg;
70 int MAX_LINES_TASK; 70 int MAX_LINES_TASK;
71 int MAX_CHAR_CLIP; 71 int MAX_CHAR_CLIP;
72 int MAX_LINES_MEET; 72 int MAX_LINES_MEET;
73 int SHOW_LOCATION; 73 int SHOW_LOCATION;
74 int SHOW_NOTES; 74 int SHOW_NOTES;
75}; 75};
76 76
77class DateBookEvent: public ClickableLabel { 77class DateBookEvent: public OClickableLabel {
78 Q_OBJECT 78 Q_OBJECT
79public: 79public:
80 DateBookEvent(const EffectiveEvent &ev, 80 DateBookEvent(const EffectiveEvent &ev,
81 QWidget* parent = 0, 81 QWidget* parent = 0,
82 int SHOW_LOCATION = 0, 82 int SHOW_LOCATION = 0,
83 int SHOW_NOTES = 0, 83 int SHOW_NOTES = 0,
84 const char* name = 0, 84 const char* name = 0,
85 WFlags fl = 0); 85 WFlags fl = 0);
86signals: 86signals:
87 void editEvent(const Event &e); 87 void editEvent(const Event &e);
88private slots: 88private slots:
89 void editMe(); 89 void editMe();
90private: 90private:
91 QString ampmTime(QTime); 91 QString ampmTime(QTime);
92 const EffectiveEvent event; 92 const EffectiveEvent event;
93 bool ampm; 93 bool ampm;
94}; 94};
95 95
96class DateBookEventLater: public ClickableLabel { 96class DateBookEventLater: public OClickableLabel {
97 Q_OBJECT 97 Q_OBJECT
98public: 98public:
99 DateBookEventLater(const EffectiveEvent &ev, 99 DateBookEventLater(const EffectiveEvent &ev,
100 QWidget* parent = 0, 100 QWidget* parent = 0,
101 int SHOW_LOCATION = 0, 101 int SHOW_LOCATION = 0,
102 int SHOW_NOTES = 0, 102 int SHOW_NOTES = 0,
103 const char* name = 0, 103 const char* name = 0,
104 WFlags fl = 0); 104 WFlags fl = 0);
105signals: 105signals:
106 void editEvent(const Event &e); 106 void editEvent(const Event &e);
107private slots: 107private slots:
108 void editMe(); 108 void editMe();
diff --git a/core/pim/today/today.pro b/core/pim/today/today.pro
index 2d37b5d..f40edca 100644
--- a/core/pim/today/today.pro
+++ b/core/pim/today/today.pro
@@ -1,17 +1,17 @@
1 TEMPLATE= app 1 TEMPLATE= app
2 #CONFIG = qt warn_on debug 2 #CONFIG = qt warn_on debug
3 CONFIG = qt warn_on release 3 CONFIG = qt warn_on release
4 HEADERS = today.h todaybase.h todayconfig.h clickablelabel.h 4 HEADERS = today.h todaybase.h todayconfig.h
5 SOURCES = main.cpp today.cpp todaybase.cpp todayconfig.cpp clickablelabel.cpp 5 SOURCES = main.cpp today.cpp todaybase.cpp todayconfig.cpp
6 6
7 INCLUDEPATH+= $(OPIEDIR)/include 7 INCLUDEPATH+= $(OPIEDIR)/include
8 DEPENDPATH+= $(OPIEDIR)/include 8 DEPENDPATH+= $(OPIEDIR)/include
9LIBS += -lqpe -lopie 9LIBS += -lqpe -lopie
10 INTERFACES= 10 INTERFACES=
11 TARGET = today 11 TARGET = today
12 DESTDIR = $(OPIEDIR)/bin 12 DESTDIR = $(OPIEDIR)/bin
13TRANSLATIONS = ../i18n/pt_BR/today.ts 13TRANSLATIONS = ../i18n/pt_BR/today.ts
14TRANSLATIONS += ../i18n/de/today.ts 14TRANSLATIONS += ../i18n/de/today.ts
15TRANSLATIONS += ../i18n/en/today.ts 15TRANSLATIONS += ../i18n/en/today.ts
16TRANSLATIONS += ../i18n/hu/today.ts 16TRANSLATIONS += ../i18n/hu/today.ts
17TRANSLATIONS += ../i18n/sl/today.ts 17TRANSLATIONS += ../i18n/sl/today.ts