00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026 #ifndef KOJOURNALEDITOR_H
00027 #define KOJOURNALEDITOR_H
00028
00029 #include "koincidenceeditor.h"
00030
00031 #include <tqdatetime.h>
00032
00033 class TQDateTime;
00034 namespace KCal {
00035 class Calendar;
00036 class Journal;
00037 class Incidence;
00038 }
00039 using namespace KCal;
00040
00041 class KOEditorGeneralJournal;
00042
00046 class KOJournalEditor : public KOIncidenceEditor
00047 {
00048 Q_OBJECT
00049 TQ_OBJECT
00050 public:
00054 KOJournalEditor( Calendar *calendar, TQWidget *parent );
00055 virtual ~KOJournalEditor();
00056
00057 void init();
00058
00059 void reload();
00060
00064 void newJournal();
00065
00071 void setTexts( const TQString &summary, const TQString &description = TQString() );
00073 void editIncidence(Incidence *, const TQDate &date, Calendar *);
00074
00076 void setDate( const TQDate &date );
00078 void readJournal( Journal *, const TQDate &date );
00080 void writeJournal( Journal * );
00081
00082 int msgItemDelete();
00084 bool validateInput();
00087 bool processInput();
00088
00090 void modified();
00091
00092 protected slots:
00093 void loadDefaults();
00094 void deleteJournal();
00095
00096 void slotSaveTemplate( const TQString & );
00097
00098 protected:
00099 TQString type() { return "Journal"; }
00100 void setupGeneral();
00101
00102
00103 void loadTemplate( CalendarLocal& );
00104 TQStringList& templates() const;
00105 private:
00106 Journal *mJournal;
00107 KOEditorGeneralJournal *mGeneral;
00108 };
00109
00110 #endif