korganizer
koeditorgeneraltodo.h00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024 #ifndef _KOEDITORGENERALTODO_H
00025 #define _KOEDITORGENERALTODO_H
00026
00027 #include "koeditorgeneral.h"
00028 #include "koglobals.h"
00029
00030 #include <qdatetime.h>
00031
00032 class KRestrictedLine;
00033
00034 class KDateEdit;
00035 class KTimeEdit;
00036
00037 namespace KCal {
00038 class Todo;
00039 }
00040 using namespace KCal;
00041
00042 class KOEditorGeneralTodo : public KOEditorGeneral
00043 {
00044 Q_OBJECT
00045 public:
00046 KOEditorGeneralTodo (QObject* parent=0,const char* name=0);
00047 virtual ~KOEditorGeneralTodo();
00048
00049 void initTime(QWidget *, QBoxLayout *);
00050 void initStatus(QWidget *, QBoxLayout *);
00051 void initCompletion(QWidget *, QBoxLayout *);
00052 void initPriority(QWidget *, QBoxLayout *);
00053
00054 void finishSetup();
00055
00057 void setDefaults( const QDateTime &due, bool allDay );
00059 void readTodo( Todo *todo, Calendar *calendar, const QDate &date );
00061 void writeTodo(Todo *);
00062
00064 bool validateInput();
00065
00067 void modified( Todo *todo, KOGlobals::HowChanged modification );
00068
00069 signals:
00070 void dueDateEditToggle( bool );
00071 void dateTimeStrChanged( const QString & );
00072 void signalDateTimeChanged( const QDateTime &, const QDateTime & );
00073
00074 protected slots:
00075 void completedChanged(int);
00076 void dateChanged();
00077 void startDateModified();
00078
00079 void enableDueEdit( bool enable );
00080 void enableStartEdit( bool enable );
00081 void enableTimeEdits( bool enable );
00082 void showAlarm();
00083
00084 protected:
00085 void setCompletedDate();
00086
00087 private:
00088 bool mAlreadyComplete;
00089 bool mStartDateModified;
00090
00091 KDateEdit *mStartDateEdit;
00092 KTimeEdit *mStartTimeEdit;
00093 QCheckBox *mTimeButton;
00094 QCheckBox *mDueCheck;
00095 KDateEdit *mDueDateEdit;
00096 KTimeEdit *mDueTimeEdit;
00097 QComboBox *mCompletedCombo;
00098 QLabel *mCompletedLabel;
00099 QLabel *mPriorityLabel;
00100 QComboBox *mPriorityCombo;
00101
00102 KDateEdit *mCompletionDateEdit;
00103 KTimeEdit *mCompletionTimeEdit;
00104
00105 QCheckBox *mStartCheck;
00106
00107 QDateTime mCompleted;
00108 };
00109
00110
00111 #endif
|