1 /**************************************************************************** |
|
2 ** |
|
3 ** Copyright (C) 2008-2010 Nokia Corporation and/or its subsidiary(-ies). |
|
4 ** All rights reserved. |
|
5 ** Contact: Nokia Corporation (developer.feedback@nokia.com) |
|
6 ** |
|
7 ** This file is part of the HbCore module of the UI Extensions for Mobile. |
|
8 ** |
|
9 ** GNU Lesser General Public License Usage |
|
10 ** This file may be used under the terms of the GNU Lesser General Public |
|
11 ** License version 2.1 as published by the Free Software Foundation and |
|
12 ** appearing in the file LICENSE.LGPL included in the packaging of this file. |
|
13 ** Please review the following information to ensure the GNU Lesser General |
|
14 ** Public License version 2.1 requirements will be met: |
|
15 ** http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html. |
|
16 ** |
|
17 ** In addition, as a special exception, Nokia gives you certain additional |
|
18 ** rights. These rights are described in the Nokia Qt LGPL Exception |
|
19 ** version 1.1, included in the file LGPL_EXCEPTION.txt in this package. |
|
20 ** |
|
21 ** If you have questions regarding the use of this file, please contact |
|
22 ** Nokia at developer.feedback@nokia.com. |
|
23 ** |
|
24 ****************************************************************************/ |
|
25 |
|
26 #include "hbstyleoptionabstractviewitem_p.h" |
|
27 |
|
28 #include <hbnamespace.h> |
|
29 |
|
30 #include <QDebug> |
|
31 |
|
32 /* |
|
33 \class HbStyleOptionAbstractViewItem |
|
34 \brief HbStyleOptionAbstractViewItem has the style component for abstract view item primitives |
|
35 */ |
|
36 |
|
37 /* |
|
38 \var HbStyleOptionAbstractViewItem::checkState |
|
39 |
|
40 This variable holds what is the checkstate of the item. |
|
41 */ |
|
42 |
|
43 /* |
|
44 \var HbStyleOptionAbstractViewItem::background |
|
45 |
|
46 This variable holds content (if any) that is set as item's background. |
|
47 |
|
48 Default value is NULL variant. |
|
49 */ |
|
50 |
|
51 /* |
|
52 \var HbStyleOptionAbstractViewItem::itemName |
|
53 |
|
54 This variable holds content item name of the primitive item required by css/xml layouting. |
|
55 |
|
56 \sa HbStyleOptionListViewItem::itemNameIndex |
|
57 */ |
|
58 |
|
59 |
|
60 /* |
|
61 \var HbStyleOptionAbstractViewItem::modelItemType |
|
62 |
|
63 This variable holds what is the type of the model item that view item is representing. |
|
64 |
|
65 Default value is Hb::StandardItem. |
|
66 */ |
|
67 |
|
68 /* |
|
69 \var HbStyleOptionAbstractViewItem::viewItemType |
|
70 |
|
71 This variable holds what is the type of the view item. This is value returned by QGraphicsItem::type(). |
|
72 |
|
73 Default is Hb::ItemType_Last+1 |
|
74 */ |
|
75 |
|
76 /* |
|
77 \var HbStyleOptionAbstractViewItem::index |
|
78 |
|
79 The model index that the view item represents. |
|
80 */ |
|
81 |
|
82 /* |
|
83 \var HbStyleOptionAbstractViewItem::singleSelectionMode |
|
84 |
|
85 This variable holds information whether HbAbstractItemView::SelectionMode mode is used. If it is used, set this variable On. |
|
86 |
|
87 Default value is false, which is fine when either any selection mode is not selected or multi or contiguous selection |
|
88 mode is in use. |
|
89 */ |
|
90 |
|
91 /* \var HbStyleOptionAbstractViewItem::insidePopup |
|
92 Indicates whether widget and its children (classes derived from HbWidgetBase) are inside popup. |
|
93 */ |
|
94 |
|
95 |
|
96 HbStyleOptionAbstractViewItem::HbStyleOptionAbstractViewItem() : |
|
97 HbStyleOption(), |
|
98 modelItemType(Hb::StandardItem), |
|
99 viewItemType(Hb::ItemType_Last+1), |
|
100 singleSelectionMode(false), |
|
101 insidePopup(false) |
|
102 { |
|
103 type = Type; |
|
104 version = Version; |
|
105 } |
|
106 HbStyleOptionAbstractViewItem::HbStyleOptionAbstractViewItem(const HbStyleOptionAbstractViewItem &other) : |
|
107 HbStyleOption(other), |
|
108 checkState(other.checkState), |
|
109 background(other.background), |
|
110 modelItemType(other.modelItemType), |
|
111 viewItemType(other.viewItemType), |
|
112 singleSelectionMode(other.singleSelectionMode), |
|
113 insidePopup(other.insidePopup) |
|
114 { |
|
115 type = Type; |
|
116 version = Version; |
|
117 } |
|
118 |
|
119 HbStyleOptionAbstractViewItem::~HbStyleOptionAbstractViewItem() |
|
120 { |
|
121 } |
|