summaryrefslogtreecommitdiff
Unidiff
Diffstat (more/less context) (ignore whitespace changes)
-rw-r--r--core/pim/todo/otaskeditor.cpp2
-rw-r--r--core/pim/todo/otaskeditor.h11
-rw-r--r--core/pim/todo/todoeditor.cpp1
-rw-r--r--core/pim/todo/todoeditor.h6
4 files changed, 12 insertions, 8 deletions
diff --git a/core/pim/todo/otaskeditor.cpp b/core/pim/todo/otaskeditor.cpp
index f0128bc..a8349c1 100644
--- a/core/pim/todo/otaskeditor.cpp
+++ b/core/pim/todo/otaskeditor.cpp
@@ -1,33 +1,35 @@
1#include <qlayout.h> 1#include <qlayout.h>
2 2
3#include "taskeditoroverview.h" 3#include "taskeditoroverview.h"
4#include "taskeditorstatus.h" 4#include "taskeditorstatus.h"
5#include "taskeditoralarms.h" 5#include "taskeditoralarms.h"
6 6
7#include "otaskeditor.h" 7#include "otaskeditor.h"
8 8
9using namespace Opie::Ui; 9using namespace Opie::Ui;
10using namespace Opie;
11
10OTaskEditor::OTaskEditor(int cur) 12OTaskEditor::OTaskEditor(int cur)
11 : QDialog( 0, 0, TRUE, WStyle_ContextHelp ) { 13 : QDialog( 0, 0, TRUE, WStyle_ContextHelp ) {
12 init(); 14 init();
13 init( cur ); 15 init( cur );
14} 16}
15OTaskEditor::OTaskEditor( const OPimTodo& to) 17OTaskEditor::OTaskEditor( const OPimTodo& to)
16 : QDialog( 0, 0, TRUE, WStyle_ContextHelp ) { 18 : QDialog( 0, 0, TRUE, WStyle_ContextHelp ) {
17 init(); 19 init();
18 init( to ); 20 init( to );
19} 21}
20OTaskEditor::~OTaskEditor() { 22OTaskEditor::~OTaskEditor() {
21 23
22} 24}
23void OTaskEditor::init( int cur ) { 25void OTaskEditor::init( int cur ) {
24 OPimTodo to; 26 OPimTodo to;
25 to.setUid( 1 ); // generate a new uid 27 to.setUid( 1 ); // generate a new uid
26 if ( cur != 0 ) 28 if ( cur != 0 )
27 to.setCategories( cur ); 29 to.setCategories( cur );
28 load(to); 30 load(to);
29} 31}
30void OTaskEditor::init( const OPimTodo& to ) { 32void OTaskEditor::init( const OPimTodo& to ) {
31 load( to ); 33 load( to );
32} 34}
33OPimTodo OTaskEditor::todo()const{ 35OPimTodo OTaskEditor::todo()const{
diff --git a/core/pim/todo/otaskeditor.h b/core/pim/todo/otaskeditor.h
index 4a00018..65e7bda 100644
--- a/core/pim/todo/otaskeditor.h
+++ b/core/pim/todo/otaskeditor.h
@@ -1,43 +1,44 @@
1#ifndef OPIE_TASK_EDITOR_H 1#ifndef OPIE_TASK_EDITOR_H
2#define OPIE_TASK_EDITOR_H 2#define OPIE_TASK_EDITOR_H
3 3
4#include <qdialog.h> 4#include <qdialog.h>
5 5
6#include <opie2/opimtodo.h> 6#include <opie2/opimtodo.h>
7#include <opie2/otabwidget.h> 7#include <opie2/otabwidget.h>
8#include <opie2/opimrecurrencewidget.h> 8#include <opie2/opimrecurrencewidget.h>
9#include <opie2/opimrecurrencewidget.h>
9 10
10class TaskEditorOverView; 11class TaskEditorOverView;
11class TaskEditorStatus; 12class TaskEditorStatus;
12class TaskEditorAlarms; 13class TaskEditorAlarms;
13class QMultiLineEdit; 14class QMultiLineEdit;
14 15
15class OTaskEditor : public QDialog { 16class OTaskEditor : public QDialog {
16 Q_OBJECT 17 Q_OBJECT
17public: 18public:
18 OTaskEditor(int cur); 19 OTaskEditor(int cur);
19 OTaskEditor( const OPimTodo& todo ); 20 OTaskEditor( const Opie::OPimTodo& todo );
20 ~OTaskEditor(); 21 ~OTaskEditor();
21 22
22 /* 23 /*
23 * same as the c'tor but this gives us the 24 * same as the c'tor but this gives us the
24 * power to 'preload' the dialog 25 * power to 'preload' the dialog
25 */ 26 */
26 void init( int cur ); 27 void init( int cur );
27 void init( const OPimTodo& todo ); 28 void init( const Opie::OPimTodo& todo );
28 29
29 OPimTodo todo()const; 30 Opie::OPimTodo todo()const;
30private: 31private:
31 void load( const OPimTodo& ); 32 void load( const Opie::OPimTodo& );
32 void init(); 33 void init();
33 34
34 Opie::Ui::OTabWidget *m_tab; 35 Opie::Ui::OTabWidget *m_tab;
35 TaskEditorOverView *m_overView; 36 TaskEditorOverView *m_overView;
36 TaskEditorStatus *m_stat; 37 TaskEditorStatus *m_stat;
37 TaskEditorAlarms *m_alarm; 38 TaskEditorAlarms *m_alarm;
38 TaskEditorAlarms *m_remind; 39 TaskEditorAlarms *m_remind;
39 OPimRecurrenceWidget *m_rec; 40 OPimRecurrenceWidget *m_rec;
40 OPimTodo m_todo; 41 Opie::OPimTodo m_todo;
41}; 42};
42 43
43#endif 44#endif
diff --git a/core/pim/todo/todoeditor.cpp b/core/pim/todo/todoeditor.cpp
index 879d809..4b5ecb1 100644
--- a/core/pim/todo/todoeditor.cpp
+++ b/core/pim/todo/todoeditor.cpp
@@ -1,30 +1,31 @@
1 1
2#include <qpe/qpeapplication.h> 2#include <qpe/qpeapplication.h>
3 3
4#include "otaskeditor.h" 4#include "otaskeditor.h"
5#include "todoeditor.h" 5#include "todoeditor.h"
6 6
7using namespace Opie;
7using namespace Todo; 8using namespace Todo;
8 9
9Editor::Editor() { 10Editor::Editor() {
10 m_accepted = false; 11 m_accepted = false;
11 m_self = 0l; 12 m_self = 0l;
12} 13}
13Editor::~Editor() { 14Editor::~Editor() {
14 delete m_self; 15 delete m_self;
15 m_self = 0; 16 m_self = 0;
16} 17}
17OPimTodo Editor::newTodo( int cur, 18OPimTodo Editor::newTodo( int cur,
18 QWidget*) { 19 QWidget*) {
19 20
20 OTaskEditor *e = self(); 21 OTaskEditor *e = self();
21 e->setCaption( QObject::tr("Enter Task") ); 22 e->setCaption( QObject::tr("Enter Task") );
22 e->init( cur ); 23 e->init( cur );
23 24
24 int ret = QPEApplication::execDialog( e ); 25 int ret = QPEApplication::execDialog( e );
25 26
26 if ( QDialog::Accepted == ret ) { 27 if ( QDialog::Accepted == ret ) {
27 m_accepted = true; 28 m_accepted = true;
28 }else 29 }else
29 m_accepted = false; 30 m_accepted = false;
30 31
diff --git a/core/pim/todo/todoeditor.h b/core/pim/todo/todoeditor.h
index bcfd205..1ac7f8a 100644
--- a/core/pim/todo/todoeditor.h
+++ b/core/pim/todo/todoeditor.h
@@ -1,29 +1,29 @@
1#ifndef OPIE_TODO_EDITOR_H 1#ifndef OPIE_TODO_EDITOR_H
2#define OPIE_TODO_EDITOR_H 2#define OPIE_TODO_EDITOR_H
3 3
4#include <opie2/opimtodo.h> 4#include <opie2/opimtodo.h>
5 5
6 6
7class OTaskEditor; 7class OTaskEditor;
8namespace Todo { 8namespace Todo {
9 class Editor { 9 class Editor {
10 public: 10 public:
11 Editor(); 11 Editor();
12 ~Editor(); 12 ~Editor();
13 13
14 OPimTodo newTodo( int currentCatId, 14 Opie::OPimTodo newTodo( int currentCatId,
15 QWidget* par ); 15 QWidget* par );
16 OPimTodo edit( QWidget* par, 16 Opie::OPimTodo edit( QWidget* par,
17 const OPimTodo& ev = OPimTodo() ); 17 const Opie::OPimTodo& ev = Opie::OPimTodo() );
18 18
19 19
20 bool accepted()const; 20 bool accepted()const;
21 protected: 21 protected:
22 OTaskEditor* self(); 22 OTaskEditor* self();
23 private: 23 private:
24 bool m_accepted: 1; 24 bool m_accepted: 1;
25 OTaskEditor* m_self; 25 OTaskEditor* m_self;
26 }; 26 };
27}; 27};
28 28
29#endif 29#endif