koeditordetails.h
00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023 #ifndef _KOEDITORDETAILS_H
00024 #define _KOEDITORDETAILS_H
00025
00026 #include <klistview.h>
00027 #include "customlistviewitem.h"
00028
00029 class QPushButton;
00030 class QCheckBox;
00031 class QLineEdit;
00032 class QLabel;
00033 class QComboBox;
00034 class QHBox;
00035 class KDateEdit;
00036 class KOEditorFreeBusy;
00037
00038 namespace KCal {
00039 class Attendee;
00040 class Incidence;
00041 }
00042 using namespace KCal;
00043
00044 namespace KPIM {
00045 class AddresseeLineEdit;
00046 }
00047
00048 namespace KABC {
00049 class Addressee;
00050 }
00051
00052 typedef CustomListViewItem<Attendee *> AttendeeListItem;
00053
00054
00060 class KOAttendeeListView : public KListView
00061 {
00062 Q_OBJECT
00063 public:
00064 KOAttendeeListView (QWidget *parent=0, const char *name=0);
00065 virtual ~KOAttendeeListView();
00066 virtual void addAttendee( const QString& newAttendee );
00067 public slots:
00068 virtual void contentsDragEnterEvent( QDragEnterEvent *e );
00069 virtual void dragEnterEvent( QDragEnterEvent *e );
00070 virtual void contentsDropEvent( QDropEvent *e );
00071 virtual void dropEvent( QDropEvent *e );
00072 virtual void contentsDragMoveEvent(QDragMoveEvent *e);
00073 signals:
00074 void dropped(Attendee*);
00075 };
00076
00077
00078 class KOEditorDetails : public QWidget
00079 {
00080 Q_OBJECT
00081 public:
00082 KOEditorDetails (int spacing = 8,QWidget* parent = 0, const char* name = 0);
00083 virtual ~KOEditorDetails();
00084
00086 void setDefaults();
00088 void readEvent(Incidence *);
00090 void writeEvent(Incidence *);
00091
00093 void cancelAttendeeEvent(Incidence *);
00095 bool validateInput();
00096
00098 void setFreeBusyWidget( KOEditorFreeBusy * );
00099
00100 public slots:
00101 void insertAttendee(Attendee *);
00102
00103 protected slots:
00104 void addNewAttendee();
00105 void removeAttendee();
00106 void openAddressBook();
00107 void updateAttendeeInput();
00108 void clearAttendeeInput();
00109 void fillAttendeeInput(AttendeeListItem *);
00110 void updateAttendeeItem();
00111 void setEnableAttendeeInput(bool);
00112
00113 protected:
00114 virtual bool eventFilter( QObject *, QEvent *);
00115 void fillOrganizerCombo();
00116
00117 void insertAttendee( Attendee*, bool goodEmailAddress );
00118
00124 void insertAttendeeFromAddressee( const KABC::Addressee& , const Attendee* at=0 );
00125
00126 private:
00127 bool mDisableItemUpdate;
00128
00129 KPIM::AddresseeLineEdit *mNameEdit;
00130 QLineEdit *mUidEdit;
00131 KListView *mListView;
00132 QComboBox* mRoleCombo;
00133 QCheckBox* mRsvpButton;
00134 QComboBox* mStatusCombo;
00135 QHBox* mOrganizerHBox;
00136 QComboBox *mOrganizerCombo;
00137 QLabel *mOrganizerLabel;
00138
00139 QPushButton* mAddButton;
00140 QPushButton* mRemoveButton;
00141 QPushButton* mAddressBookButton;
00142
00143 QPtrList<Attendee> mdelAttendees;
00144
00145 KOEditorFreeBusy *mFreeBusy;
00146 };
00147
00148 #endif
This file is part of the documentation for korganizer Library Version 3.3.2.