equal
deleted
inserted
replaced
41 iLoader.load(ABSTRACT_LIST_VIEW_BASE_LAYOUT_FILENAME, ABSTRACT_LIST_VIEW_BASE_WITH_TOOLBAR_SECTION); |
41 iLoader.load(ABSTRACT_LIST_VIEW_BASE_LAYOUT_FILENAME, ABSTRACT_LIST_VIEW_BASE_WITH_TOOLBAR_SECTION); |
42 |
42 |
43 //if this view is not starting view, finish all initialization in constructor |
43 //if this view is not starting view, finish all initialization in constructor |
44 if (getViewManager()->views().count() > 0) |
44 if (getViewManager()->views().count() > 0) |
45 { |
45 { |
46 lazyInit(); |
46 normalInit(); |
47 } |
47 } |
48 } |
48 } |
49 |
49 |
50 /* |
50 /* |
51 * Description : destructor |
51 * Description : destructor |
170 { |
170 { |
171 IrAbstractListViewBase::updateView(); |
171 IrAbstractListViewBase::updateView(); |
172 iMainModel->checkUpdate(); |
172 iMainModel->checkUpdate(); |
173 } |
173 } |
174 |
174 |
|
175 //from base class IRBaseView |
|
176 TIRHandleResult IRMainView::handleCommand(TIRViewCommand aCommand, TIRViewCommandReason aReason) |
|
177 { |
|
178 if (!initCompleted()) |
|
179 { |
|
180 return EIR_DoDefault; |
|
181 } |
|
182 |
|
183 Q_UNUSED(aReason); |
|
184 TIRHandleResult ret = IrAbstractListViewBase::handleCommand(aCommand, aReason); |
|
185 |
|
186 switch (aCommand) |
|
187 { |
|
188 case EIR_ViewCommand_ACTIVATED: |
|
189 getViewManager()->saveScreenShot(); |
|
190 break; |
|
191 |
|
192 default: |
|
193 break; |
|
194 } |
|
195 |
|
196 return ret; |
|
197 } |
|
198 |
175 void IRMainView::lazyInit() |
199 void IRMainView::lazyInit() |
|
200 { |
|
201 if (!initCompleted()) |
|
202 { |
|
203 normalInit(); |
|
204 |
|
205 //initialization from handleCommand() |
|
206 handleCommand(EIR_ViewCommand_ACTIVATED, EIR_ViewCommandReason_Show); |
|
207 } |
|
208 } |
|
209 |
|
210 void IRMainView::normalInit() |
176 { |
211 { |
177 if (!initCompleted()) |
212 if (!initCompleted()) |
178 { |
213 { |
179 IrAbstractListViewBase::lazyInit(); |
214 IrAbstractListViewBase::lazyInit(); |
180 initToolBar(); |
215 initToolBar(); |