summaryrefslogtreecommitdiffabout
path: root/korganizer/timespanview.h
Side-by-side diff
Diffstat (limited to 'korganizer/timespanview.h') (more/less context) (show whitespace changes)
-rw-r--r--korganizer/timespanview.h60
1 files changed, 60 insertions, 0 deletions
diff --git a/korganizer/timespanview.h b/korganizer/timespanview.h
new file mode 100644
index 0000000..34cb1f7
--- a/dev/null
+++ b/korganizer/timespanview.h
@@ -0,0 +1,60 @@
+#ifndef TIMESPANVIEW_H
+#define TIMESPANVIEW_H
+
+#include <qwidget.h>
+
+#include <libkcal/event.h>
+
+//class QSplitter;
+#ifndef DESKTOP_VERSION
+class QKSplitter;
+#else
+class QSplitter;
+#define QKSplitter QSplitter
+#endif
+class QListView;
+class LineView;
+class TimeLine;
+
+
+class TimeSpanView : public QWidget
+{
+ Q_OBJECT
+ public:
+ TimeSpanView( QWidget *parent=0, const char *name=0 );
+ virtual ~TimeSpanView();
+
+ void addItem( KCal::Event * );
+
+ QValueList<int> splitterSizes();
+ void setSplitterSizes( QValueList<int> );
+
+ void clear();
+
+ void setDateRange( const QDateTime &start, const QDateTime &end );
+
+ QDateTime startDateTime();
+ QDateTime endDateTime();
+
+ public slots:
+ void updateView();
+
+ void zoomIn();
+ void zoomOut();
+ void centerView();
+
+ signals:
+ void dateRangeChanged();
+
+ private:
+ QKSplitter *mSplitter;
+ QListView *mList;
+ TimeLine *mTimeLine;
+ LineView *mLineView;
+
+ QDateTime mStartDate;
+ QDateTime mEndDate;
+ int mSecsPerPixel;
+};
+
+#endif