korganizer
koeditorgeneralevent.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 _KOEDITORGENERALEVENT_H
00025 #define _KOEDITORGENERALEVENT_H
00026
00027 #include "koeditorgeneral.h"
00028 #include <tqdatetime.h>
00029
00030 class TQLabel;
00031 class KDateEdit;
00032 class KTimeEdit;
00033 class TQCheckBox;
00034 class TQComboBox;
00035 class TQBoxLayout;
00036
00037 namespace KCal {
00038 class Event;
00039 }
00040 using namespace KCal;
00041
00042 class KOEditorGeneralEvent : public KOEditorGeneral
00043 {
00044 Q_OBJECT
00045 public:
00046 KOEditorGeneralEvent (TQObject* parent=0,const char* name=0);
00047 virtual ~KOEditorGeneralEvent();
00048
00049 void initTime(TQWidget *,TQBoxLayout *);
00050 void initClass(TQWidget *,TQBoxLayout *);
00051 void initInvitationBar( TQWidget* parent, TQBoxLayout *layout );
00052
00053 void finishSetup();
00054
00056 void setDefaults( const TQDateTime &from, const TQDateTime &to, bool allDay );
00061 void readEvent( Event *event, Calendar *calendar, const TQDate &date, bool tmpl = false );
00063 void writeEvent( Event * );
00064
00066 bool validateInput();
00067
00068 void updateRecurrenceSummary( Event *event );
00069
00070 TQFrame* invitationBar() const { return mInvitationBar; }
00071
00072 public slots:
00073 void setDateTimes( const TQDateTime &start, const TQDateTime &end );
00074 void setDuration();
00075
00076 protected slots:
00077 void timeStuffDisable( bool disable );
00078 void associateTime( bool time );
00079
00080 void startTimeChanged( TQTime );
00081 void startDateChanged( const TQDate& );
00082 void endTimeChanged( TQTime );
00083 void endDateChanged( const TQDate& );
00084
00085 void emitDateTimeStr();
00086
00087 signals:
00088 void allDayChanged(bool);
00089 void dateTimeStrChanged( const TQString & );
00090 void dateTimesChanged( const TQDateTime &start, const TQDateTime &end );
00091 void editRecurrence();
00092 void acceptInvitation();
00093 void declineInvitation();
00094
00095 private:
00096 TQLabel *mStartDateLabel;
00097 TQLabel *mEndDateLabel;
00098 KDateEdit *mStartDateEdit;
00099 KDateEdit *mEndDateEdit;
00100 KTimeEdit *mStartTimeEdit;
00101 KTimeEdit *mEndTimeEdit;
00102 TQLabel *mDurationLabel;
00103 TQCheckBox *mAlldayEventCheckbox;
00104 TQComboBox *mFreeTimeCombo;
00105 TQFrame *mInvitationBar;
00106
00107
00108 TQDateTime mCurrStartDateTime;
00109 TQDateTime mCurrEndDateTime;
00110 };
00111
00112 #endif
|