korganizer
multiagendaview.h00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019 #ifndef KORG_MULTIAGENDAVIEW_H_H
00020 #define KORG_MULTIAGENDAVIEW_H_H
00021
00022 #include "agendaview.h"
00023
00024 class QScrollView;
00025 class QHBox;
00026 class KOAgendaView;
00027
00028 namespace KCal {
00029 class ResourceCalendar;
00030 }
00031
00032 namespace KOrg {
00033
00037 class MultiAgendaView : public AgendaView
00038 {
00039 Q_OBJECT
00040 public:
00041 explicit MultiAgendaView( Calendar* cal, QWidget *parent = 0, const char *name = 0 );
00042 ~MultiAgendaView();
00043
00044 Incidence::List selectedIncidences();
00045 DateList selectedDates();
00046 int currentDateCount();
00047 int maxDatesHint();
00048
00049 bool eventDurationHint(QDateTime &startDt, QDateTime &endDt, bool &allDay);
00050
00051 void setTypeAheadReceiver( QObject *o );
00052
00053 public slots:
00054 void showDates( const QDate &start, const QDate &end );
00055 void showIncidences( const Incidence::List &incidenceList );
00056 void updateView();
00057 void changeIncidenceDisplay( Incidence *incidence, int mode );
00058
00059 void setIncidenceChanger( IncidenceChangerBase *changer );
00060
00061 void finishTypeAhead();
00062
00063 protected:
00064 void resizeEvent( QResizeEvent *ev );
00065
00066 private:
00067 void addView( const QString &label, KCal::ResourceCalendar *res, const QString &subRes = QString::null );
00068 void deleteViews();
00069 void recreateViews();
00070 void setupViews();
00071 void resizeScrollView( const QSize &size );
00072
00073 private slots:
00074 void slotSelectionChanged();
00075 void slotClearTimeSpanSelection();
00076
00077 private:
00078 QValueList<KOAgendaView*> mAgendaViews;
00079 QValueList<QWidget*> mAgendaWidgets;
00080 QHBox *mTopBox;
00081 QScrollView *mScrollView;
00082 };
00083
00084 }
00085
00086 #endif
|