mpviewplugins/mpcollectionviewplugin/src/mpcollectionpopuphandler.cpp
changeset 43 0f32e550d9d8
parent 37 eb79a7c355bf
child 51 560ce2306a17
--- a/mpviewplugins/mpcollectionviewplugin/src/mpcollectionpopuphandler.cpp	Fri Jun 25 17:21:37 2010 -0500
+++ b/mpviewplugins/mpcollectionviewplugin/src/mpcollectionpopuphandler.cpp	Fri Jul 09 16:27:03 2010 -0500
@@ -54,6 +54,7 @@
 const QString KAdd = QString( "Add" );
 const QString KDelete = QString( "Delete" );
 const QString KRenamePlayList = QString( "RenamePlayList" );
+const QString KDetails = QString( "Details" );
 
 
 //------------------------------------------------------------------
@@ -197,6 +198,8 @@
                 action = contextMenu->addAction( hbTrId( "txt_common_menu_delete" ) );
                 action->setObjectName( KDelete );
                 action->setEnabled( !usbBlocked );
+                action = contextMenu->addAction( hbTrId( "txt_mus_menu_view_details" ) );
+                action->setObjectName( KDetails );
                 break;
             case ECollectionContextAlbums:
             case ECollectionContextArtists:
@@ -212,10 +215,10 @@
                 action->setEnabled( !usbBlocked );
                 break;
             case ECollectionContextPlaylists:
+                contextMenu = new HbMenu();
+                action = contextMenu->addAction( hbTrId( "txt_common_menu_open" ) );
+                action->setObjectName( KOpen );
                 if ( !mMpEngine->collectionData()->isAutoPlaylist( index ) ) {
-                    contextMenu = new HbMenu();
-                    action = contextMenu->addAction( hbTrId( "txt_common_menu_open" ) );
-                    action->setObjectName( KOpen );
                     action = contextMenu->addAction( hbTrId( "txt_common_menu_delete" ) );
                     action->setObjectName(KDelete);
                     action->setEnabled( !usbBlocked );
@@ -225,14 +228,16 @@
                 }
                 break;
             case ECollectionContextPlaylistSongs:
+                contextMenu = new HbMenu();
+                action = contextMenu->addAction( hbTrId( "txt_common_menu_play_music" ) );
+                action->setObjectName( KOpen );
                 if ( !mMpEngine->collectionData()->isAutoPlaylist() ) {
-                    contextMenu = new HbMenu();
-                    action = contextMenu->addAction( hbTrId( "txt_common_menu_play_music" ) );
-                    action->setObjectName( KOpen );
                     action = contextMenu->addAction( hbTrId( "txt_common_menu_remove" ) );
                     action->setObjectName( KDelete );
                     action->setEnabled( !usbBlocked );
                 }
+                action = contextMenu->addAction( hbTrId( "txt_mus_menu_view_details" ) );
+                action->setObjectName( KDetails );
                 break;
             default:
                 break;
@@ -449,6 +454,9 @@
                     mPermanentData->mContextMenuIndex, MpMpxCollectionData::Title );
             openRenamePlaylistItemDialog( currentName );
         }
+        else if ( objectName == KDetails ) {
+            mView->showItemDetails( mPermanentData->mContextMenuIndex );
+        }
     }
     TX_EXIT
 }