korganizer
koeventeditor.h00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025 #ifndef KOEVENTEDITOR_H
00026 #define KOEVENTEDITOR_H
00027
00028 #include "koincidenceeditor.h"
00029
00030 class KOEditorGeneralEvent;
00031 class KOEditorRecurrence;
00032 class KOEditorFreeBusy;
00033
00034 class SaveTemplateDialog;
00035
00036 class KOEditorFreeBusy;
00037
00038 namespace KCal {
00039 class Calendar;
00040 class Event;
00041 }
00042 using namespace KCal;
00043
00047 class KOEventEditor : public KOIncidenceEditor
00048 {
00049 Q_OBJECT
00050 public:
00054 KOEventEditor( Calendar *calendar, QWidget *parent );
00055 virtual ~KOEventEditor(void);
00056
00057 void init();
00059 void modified (int change=0);
00060 void reload();
00061
00065 void newEvent( const QDateTime &from, const QDateTime &to, bool allDay = false );
00069 void newEvent( const QString & );
00073 void newEvent( const QString &summary, const QString &description,
00074 const QString &attachment );
00078 void newEvent( const QString &summary, const QString &description,
00079 const QString &attachment, const QStringList &attendees );
00083 void editIncidence( Incidence * );
00084
00088 void setDefaults( const QDateTime &from, const QDateTime &to, bool allDay );
00089
00094 void readEvent( Event *, bool tmpl = false );
00098 void writeEvent( Event * );
00099
00100 QObject *typeAheadReceiver() const;
00101
00102 signals:
00103 void focusReceivedSignal();
00104
00105 protected slots:
00106 void loadDefaults();
00107 void deleteEvent();
00108
00109 void slotSaveTemplate( const QString & );
00110
00111 protected:
00112 QString type() { return "Event"; }
00113 void setupGeneral();
00114 void setupRecurrence();
00115 void setupFreeBusy();
00116
00118 bool validateInput();
00121 bool processInput();
00122 void processCancel();
00123 int msgItemDelete();
00124 void loadTemplate( CalendarLocal& );
00125 QStringList& templates() const;
00126
00127 private:
00128 Event *mEvent;
00129
00130 KOEditorGeneralEvent *mGeneral;
00131 KOEditorRecurrence *mRecurrence;
00132 KOEditorFreeBusy *mFreeBusy;
00133 };
00134
00135 #endif
|