Changeset View
Changeset View
Standalone View
Standalone View
src/freebusymodel/freebusycalendar.h
Show All 20 Lines | |||||
21 | 21 | | |||
22 | #ifndef FREEBUSYCALENDAR_H | 22 | #ifndef FREEBUSYCALENDAR_H | ||
23 | #define FREEBUSYCALENDAR_H | 23 | #define FREEBUSYCALENDAR_H | ||
24 | 24 | | |||
25 | #include "calendarsupport_export.h" | 25 | #include "calendarsupport_export.h" | ||
26 | 26 | | |||
27 | #include "freebusyitemmodel.h" | 27 | #include "freebusyitemmodel.h" | ||
28 | 28 | | |||
29 | #include <KCalCore/Calendar> | 29 | #include <KCalendarCore/Calendar> | ||
30 | #include <KCalCore/Event> | 30 | #include <KCalendarCore/Event> | ||
31 | 31 | | |||
32 | namespace CalendarSupport { | 32 | namespace CalendarSupport { | ||
33 | class FreeBusyCalendarPrivate; | 33 | class FreeBusyCalendarPrivate; | ||
34 | class CALENDARSUPPORT_EXPORT FreeBusyCalendar : public QObject | 34 | class CALENDARSUPPORT_EXPORT FreeBusyCalendar : public QObject | ||
35 | { | 35 | { | ||
36 | Q_OBJECT | 36 | Q_OBJECT | ||
37 | public: | 37 | public: | ||
38 | explicit FreeBusyCalendar(QObject *parent = nullptr); | 38 | explicit FreeBusyCalendar(QObject *parent = nullptr); | ||
39 | 39 | | |||
40 | ~FreeBusyCalendar() override; | 40 | ~FreeBusyCalendar() override; | ||
41 | 41 | | |||
42 | void setModel(FreeBusyItemModel *model); | 42 | void setModel(FreeBusyItemModel *model); | ||
43 | FreeBusyItemModel *model() const; | 43 | FreeBusyItemModel *model() const; | ||
44 | KCalCore::Calendar::Ptr calendar() const; | 44 | KCalendarCore::Calendar::Ptr calendar() const; | ||
45 | 45 | | |||
46 | private: | 46 | private: | ||
47 | void onRowsChanged(const QModelIndex &, const QModelIndex &); | 47 | void onRowsChanged(const QModelIndex &, const QModelIndex &); | ||
48 | void onRowsInserted(const QModelIndex &, int, int); | 48 | void onRowsInserted(const QModelIndex &, int, int); | ||
49 | void onRowsRemoved(const QModelIndex &, int, int); | 49 | void onRowsRemoved(const QModelIndex &, int, int); | ||
50 | void onLayoutChanged(); | 50 | void onLayoutChanged(); | ||
51 | void deleteAllEvents(); | 51 | void deleteAllEvents(); | ||
52 | FreeBusyCalendarPrivate *const d; | 52 | FreeBusyCalendarPrivate *const d; | ||
53 | }; | 53 | }; | ||
54 | } | 54 | } | ||
55 | #endif // FREEBUSYCALENDAR_H | 55 | #endif // FREEBUSYCALENDAR_H |