equal
deleted
inserted
replaced
|
1 /* |
|
2 * Copyright (c) 2010 Nokia Corporation and/or its subsidiary(-ies). |
|
3 * All rights reserved. |
|
4 * This component and the accompanying materials are made available |
|
5 * under the terms of "Eclipse Public License v1.0" |
|
6 * which accompanies this distribution, and is available |
|
7 * at the URL "http://www.eclipse.org/legal/epl-v10.html". |
|
8 * |
|
9 * Initial Contributors: |
|
10 * Nokia Corporation - initial contribution. |
|
11 * |
|
12 * Contributors: |
|
13 * |
|
14 * Description: Single day item view model |
|
15 * |
|
16 */ |
|
17 |
|
18 #ifndef CALENDAYMODEL_H |
|
19 #define CALENDAYMODEL_H |
|
20 |
|
21 //System includes |
|
22 #include <QAbstractItemModel> |
|
23 #include <QVariant> |
|
24 #include <QDateTime> |
|
25 |
|
26 #include <agendaentry.h> |
|
27 |
|
28 //User includes |
|
29 |
|
30 //Forward declarations |
|
31 class MCalenServices; |
|
32 |
|
33 //Constantss |
|
34 const int CalenDayEntry = Qt::UserRole + 1; |
|
35 |
|
36 Q_DECLARE_METATYPE(AgendaEntry) |
|
37 class CalenDayModel : public QAbstractListModel |
|
38 { |
|
39 Q_OBJECT |
|
40 public: |
|
41 CalenDayModel(const QDateTime &date, MCalenServices &services, |
|
42 QObject *parent = 0) |
|
43 { |
|
44 Q_UNUSED(date) |
|
45 Q_UNUSED(parent) |
|
46 Q_UNUSED(date) |
|
47 }; |
|
48 |
|
49 // from QAbstractListModel |
|
50 int rowCount(const QModelIndex &parent = QModelIndex()) const |
|
51 { |
|
52 return 0; |
|
53 } |
|
54 QVariant data(const QModelIndex &index, int role) const |
|
55 { |
|
56 Q_UNUSED(index) |
|
57 Q_UNUSED(role) |
|
58 return QVariant(); |
|
59 } |
|
60 |
|
61 void refreshModel(const QDateTime &date) |
|
62 { |
|
63 Q_UNUSED(date) |
|
64 }; |
|
65 |
|
66 QDateTime modelDate() const |
|
67 {return QDateTime();} |
|
68 |
|
69 }; |
|
70 |
|
71 #endif //CALENDAYMODEL_H |
|
72 |