64 * Loads the persistent widget list from storage. |
65 * Loads the persistent widget list from storage. |
65 * This is typically done once after construction. |
66 * This is typically done once after construction. |
66 * The instance can now be used to sort widget data. |
67 * The instance can now be used to sort widget data. |
67 */ |
68 */ |
68 void LoadL(); |
69 void LoadL(); |
69 |
70 |
70 /** |
71 /** |
71 * Stores a sorted array of WmWidgetData types. Note that |
72 * Stores a sorted array of WmWidgetData types. Note that |
72 * the order will be directly stored and a copy will not |
73 * the order will be directly stored and a copy will not |
73 * be kept locally, so this instance can not be used to |
74 * be kept locally, so this instance can not be used to |
74 * sort widget data until LoadL() is called. |
75 * sort widget data until LoadL() is called. |
75 * |
76 * |
76 * @param aArray the array of widget daya types |
77 * @param aArray the array of widget daya types |
77 */ |
78 */ |
78 void StoreL( const RWidgetDataValues& aArray ); |
79 void StoreL( const ROrderArray& aArray ); |
79 |
80 |
80 /** |
81 /** |
81 * Retrieves an index of given widget data object within the list. |
82 * Retrieves an index of given widget data object within the list. |
82 * This index can be used to sort and organise. Note that LoadL() |
83 * This index can be used to sort and organise. Note that LoadL() |
83 * must be used prior to calling this method, and before that |
84 * must be used prior to calling this method, and before that |
86 * @param aWidgetData data to seek index of in the sorted order |
87 * @param aWidgetData data to seek index of in the sorted order |
87 * @return the index found, or KErrNotFound if widget is new |
88 * @return the index found, or KErrNotFound if widget is new |
88 */ |
89 */ |
89 TInt IndexOf( const CWmWidgetData& aWidgetData ) const; |
90 TInt IndexOf( const CWmWidgetData& aWidgetData ) const; |
90 |
91 |
|
92 /** |
|
93 * Retrieves an index of given widget order object within the order list. |
|
94 * This index can be used to sort and organise. Note that LoadL() |
|
95 * must be used prior to calling this method, and before that |
|
96 * there must be something persisted. |
|
97 * |
|
98 * @param aWidgetOrder data to seek index of in the sorted order |
|
99 * @return the index found, or KErrNotFound if widget is new |
|
100 */ |
|
101 TInt IndexOf( const CWmWidgetOrderData& aWidgetOrder ) const; |
|
102 |
91 /** |
103 /** |
92 * checks if the persistent widget order is empty. In this case it does |
104 * checks if the persistent widget order is empty. In this case it does |
93 * not make any sense to use the object to sort anything. |
105 * not make any sense to use the object to sort anything. |
94 * Note that before loading the object is always empty. |
106 * Note that before loading the object is always empty. |
95 */ |
107 */ |
119 Tag( TInt32 aUid, HBufC16* aPublisherId ); |
131 Tag( TInt32 aUid, HBufC16* aPublisherId ); |
120 |
132 |
121 /** compares a tag agains a widget data */ |
133 /** compares a tag agains a widget data */ |
122 TBool Matches( const CWmWidgetData& aWidgetData ) const; |
134 TBool Matches( const CWmWidgetData& aWidgetData ) const; |
123 |
135 |
|
136 /** compares a tag agains a widget order */ |
|
137 TBool Matches( const CWmWidgetOrderData& aWidgetOrder ) const; |
|
138 |
124 /** widget uid */ |
139 /** widget uid */ |
125 TInt32 iUid; |
140 TInt32 iUid; |
126 |
141 |
127 /** widget publisher id */ |
142 /** widget publisher id */ |
128 HBufC16* iPublisherId; |
143 HBufC16* iPublisherId; |