diff -r 896e9dbc5f19 -r 065198191975 qtinternetradio/ui/src/irmainview.cpp --- a/qtinternetradio/ui/src/irmainview.cpp Wed Aug 18 09:40:26 2010 +0300 +++ b/qtinternetradio/ui/src/irmainview.cpp Thu Sep 02 20:17:46 2010 +0300 @@ -39,11 +39,15 @@ setFlag(EViewFlag_ClearStackWhenActivate|EViewFlag_StickyViewEnabled); iLoader.load(ABSTRACT_LIST_VIEW_BASE_LAYOUT_FILENAME, ABSTRACT_LIST_VIEW_BASE_WITH_TOOLBAR_SECTION); - //if this view is not starting view, finish all initialization in constructor - if (getViewManager()->views().count() > 0) - { - normalInit(); - } + setCheckedAction(); + + connect(iNetworkController, SIGNAL(networkRequestNotified(IRQNetworkEvent)), + this, SLOT(networkRequestNotified(IRQNetworkEvent))); + + iMainModel = new IRMainModel(iApplication->getPlayList(), this); + iMainModel->checkUpdate(); + iListView->setModel(iMainModel); + } /* @@ -174,11 +178,6 @@ //from base class IRBaseView TIRHandleResult IRMainView::handleCommand(TIRViewCommand aCommand, TIRViewCommandReason aReason) { - if (!initCompleted()) - { - return EIR_DoDefault; - } - Q_UNUSED(aReason); TIRHandleResult ret = IrAbstractListViewBase::handleCommand(aCommand, aReason); @@ -195,33 +194,3 @@ return ret; } -void IRMainView::lazyInit() -{ - if (!initCompleted()) - { - normalInit(); - - //initialization from handleCommand() - handleCommand(EIR_ViewCommand_ACTIVATED, EIR_ViewCommandReason_Show); - emit applicationReady(); - } -} - -void IRMainView::normalInit() -{ - if (!initCompleted()) - { - IrAbstractListViewBase::lazyInit(); - - setCheckedAction(); - - connect(iNetworkController, SIGNAL(networkRequestNotified(IRQNetworkEvent)), - this, SLOT(networkRequestNotified(IRQNetworkEvent))); - - iMainModel = new IRMainModel(iApplication->getPlayList(), this); - iMainModel->checkUpdate(); - iListView->setModel(iMainModel); - - setInitCompleted(true); - } -}