ui/views/listview/src/glxlistview.cpp
changeset 54 0f0f3f26f787
parent 50 a0f57508af73
child 71 27f2d7aec52a
equal deleted inserted replaced
52:a3a4c0de738e 54:0f0f3f26f787
    55  }
    55  }
    56 
    56 
    57 void GlxListView::deActivate()
    57 void GlxListView::deActivate()
    58 {
    58 {
    59     qDebug("GlxListView::deActivate()");
    59     qDebug("GlxListView::deActivate()");
    60     disconnect(mWindow, SIGNAL(orientationChanged(Qt::Orientation)), this, SLOT(orientationChanged(Qt::Orientation)));
       
    61 }
    60 }
    62 
    61 
    63 void GlxListView::setModel(QAbstractItemModel *model) 
    62 void GlxListView::setModel(QAbstractItemModel *model) 
    64 {
    63 {
    65     qDebug("GlxListView::setModel()");
    64     qDebug("GlxListView::setModel()");
   204         return ;
   203         return ;
   205     }
   204     }
   206     if ( mModel ) {
   205     if ( mModel ) {
   207         mModel->setData( index, index.row(), GlxFocusIndexRole );
   206         mModel->setData( index, index.row(), GlxFocusIndexRole );
   208     }
   207     }
   209     emit actionTriggered( EGlxCmdAlbumGridOpen );
   208     
       
   209     int curstate = NO_LIST_S; 
       
   210     qDebug() << "GlxListView::itemSelected READING STATE ";
       
   211     QVariant variant = mModel->data( mModel->index(0,0), GlxSubStateRole );    
       
   212     if ( variant.isValid() &&  variant.canConvert<int> () ) {
       
   213         curstate = variant.value<int>();
       
   214     }
       
   215     qDebug() << "GlxMenuManager::viewSubState = " << curstate ;
       
   216     if(curstate == FETCHER_ALBUM_S ){
       
   217         emit actionTriggered( EGlxCmdFetcherAlbumGridOpen );
       
   218     }else {        
       
   219         emit actionTriggered( EGlxCmdAlbumGridOpen );
       
   220     }
   210 }
   221 }
   211 
   222 
   212 
   223 
   213 void GlxListView::indicateLongPress(HbAbstractViewItem *item, QPointF coords)
   224 void GlxListView::indicateLongPress(HbAbstractViewItem *item, QPointF coords)
   214 {
   225 {