summaryrefslogtreecommitdiffabout
path: root/korganizer/koeditorgeneraltodo.h
Unidiff
Diffstat (limited to 'korganizer/koeditorgeneraltodo.h') (more/less context) (ignore whitespace changes)
-rw-r--r--korganizer/koeditorgeneraltodo.h105
1 files changed, 105 insertions, 0 deletions
diff --git a/korganizer/koeditorgeneraltodo.h b/korganizer/koeditorgeneraltodo.h
new file mode 100644
index 0000000..f6c30f8
--- a/dev/null
+++ b/korganizer/koeditorgeneraltodo.h
@@ -0,0 +1,105 @@
1/*
2 This file is part of KOrganizer.
3 Copyright (c) 2001 Cornelius Schumacher <schumacher@kde.org>
4
5 This program is free software; you can redistribute it and/or modify
6 it under the terms of the GNU General Public License as published by
7 the Free Software Foundation; either version 2 of the License, or
8 (at your option) any later version.
9
10 This program is distributed in the hope that it will be useful,
11 but WITHOUT ANY WARRANTY; without even the implied warranty of
12 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 GNU General Public License for more details.
14
15 You should have received a copy of the GNU General Public License
16 along with this program; if not, write to the Free Software
17 Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
18
19 As a special exception, permission is given to link this program
20 with any edition of Qt, and distribute the resulting executable,
21 without including the source code for Qt in the source distribution.
22*/
23#ifndef _KOEDITORGENERALTODO_H
24#define _KOEDITORGENERALTODO_H
25
26#include <qframe.h>
27#include <qlabel.h>
28#include <qcheckbox.h>
29#include <qpushbutton.h>
30#include <qgroupbox.h>
31#include <qlineedit.h>
32#include <qcombobox.h>
33#include <qmultilineedit.h>
34#include <qlistview.h>
35#include <qradiobutton.h>
36
37#include "koeditorgeneral.h"
38#include "koglobals.h"
39
40class KRestrictedLine;
41
42class KDateEdit;
43
44using namespace KCal;
45
46class KOEditorGeneralTodo : public KOEditorGeneral
47{
48 Q_OBJECT
49 public:
50 KOEditorGeneralTodo (QObject* parent=0,const char* name=0);
51 virtual ~KOEditorGeneralTodo();
52
53 void initTime(QWidget *, QBoxLayout *);
54 void initStatus(QWidget *, QBoxLayout *);
55 void initCompletion(QWidget *, QBoxLayout *);
56 void initPriority(QWidget *, QBoxLayout *);
57
58 void finishSetup();
59
60 /** Set widgets to default values */
61 void setDefaults(QDateTime due,bool allDay);
62 /** Read todo object and setup widgets accordingly */
63 void readTodo(Todo *);
64 /** Write todo settings to event object */
65 void writeTodo(Todo *);
66
67 /** Check if the input is valid. */
68 bool validateInput();
69
70 /** The todo has been modified externally */
71 void modified (Todo*, int);
72
73 signals:
74 void openCategoryDialog();
75
76 protected slots:
77 void completedChanged(int);
78
79 void enableDueEdit( bool enable );
80 void enableStartEdit( bool enable );
81 void enableTimeEdits( bool enable );
82 void showAlarm();
83
84 protected:
85 void setCompletedDate();
86
87 private:
88 KDateEdit *mStartDateEdit;
89 KOTimeEdit *mStartTimeEdit;
90 QCheckBox *mTimeButton;
91 QCheckBox *mDueCheck;
92 KDateEdit *mDueDateEdit;
93 KOTimeEdit *mDueTimeEdit;
94 QComboBox *mCompletedCombo;
95 QLabel *mCompletedLabel;
96 QLabel *mPriorityLabel;
97 QComboBox *mPriorityCombo;
98
99 QCheckBox *mStartCheck;
100
101 QDateTime mCompleted;
102};
103
104
105#endif