Revision: 201031 RCL_3
authorDremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
Thu, 19 Aug 2010 09:52:08 +0300
branchRCL_3
changeset 24 26a1709b9fec
parent 23 455f89b7fcc5
child 25 14979e23cb5e
Revision: 201031 Kit: 201033
mpxmusicplayer/Conf/mpxmusicplayer.confml
mpxmusicplayer/app/data/mpx.rss
mpxmusicplayer/app/loc/mpx.loc
mpxmusicplayer/commonui/group/mpxcommonui.mmp
mpxmusicplayer/commonui/loc/mpxcommonui.loc
mpxmusicplayer/commonui/src/mpxcommonuihelper.cpp
mpxmusicplayer/commonui/src/mpxfilenamequerydlg.cpp
mpxmusicplayer/group/bld.inf
mpxmusicplayer/help/data/xhtml.zip
mpxmusicplayer/mediakeyhandler/inc/mpxmediakeyhandlerimp.h
mpxmusicplayer/mediakeyhandler/src/mpxmediakeyhandlerimp.cpp
mpxplugins/serviceplugins/collectionplugins/mpxsqlitedbhgplugin/inc/mpxcollectiondbdef.h
mpxplugins/serviceplugins/collectionplugins/mpxsqlitedbhgplugin/inc/mpxcollectiondbstd.h
mpxplugins/serviceplugins/collectionplugins/mpxsqlitedbhgplugin/inc/mpxdbalbum.h
mpxplugins/serviceplugins/collectionplugins/mpxsqlitedbhgplugin/inc/mpxdbmusic.h
mpxplugins/serviceplugins/collectionplugins/mpxsqlitedbhgplugin/inc/mpxdbpluginqueries.h
mpxplugins/serviceplugins/collectionplugins/mpxsqlitedbhgplugin/src/mpxdbalbum.cpp
mpxplugins/serviceplugins/collectionplugins/mpxsqlitedbhgplugin/src/mpxdbmusic.cpp
mpxplugins/serviceplugins/playbackplugins/localaudio/src/mpxlocalaudioplayback.cpp
mpxplugins/serviceplugins/playbackplugins/progressdownloadsb/src/mpxprogressdownloadsb.cpp
mpxplugins/viewplugins/inc/mpxcommonplaybackviewimp.h
mpxplugins/viewplugins/inc/mpxmetadataeditordialog.h
mpxplugins/viewplugins/views/addtracksdialog/loc/mpxaddtracksdialog.loc
mpxplugins/viewplugins/views/collectionviewhg/inc/mpxcollectionviewhgcontainer.h
mpxplugins/viewplugins/views/collectionviewhg/inc/mpxcollectionviewhgimp.h
mpxplugins/viewplugins/views/collectionviewhg/src/mpxcollectionviewhgcontainer.cpp
mpxplugins/viewplugins/views/collectionviewhg/src/mpxcollectionviewhgimp.cpp
mpxplugins/viewplugins/views/collectionviewhg/src/mpxcollectionviewhgplaylisthelper.cpp
mpxplugins/viewplugins/views/commonplaybackview/src/mpxcommonplaybackviewimp.cpp
mpxplugins/viewplugins/views/embeddedplaybackview/inc/mpxembeddedplaybackview.hlp.hrh
mpxplugins/viewplugins/views/equalizerview/group/bld.inf
mpxplugins/viewplugins/views/metadataeditordialog/data/mpxmetadataeditordialog.rss
mpxplugins/viewplugins/views/metadataeditordialog/src/mpxmetadataeditordialog.cpp
mpxplugins/viewplugins/views/waitnotedialog/data/mpxwaitnotedialog.rss
mpxplugins/viewplugins/views/waitnotedialog/src/mpxmtpdialog.cpp
musichomescreen/data/themes/default/install/musicwidget/group/bld.inf
musichomescreen/group/bld.inf
musichomescreen/musiccontentpublisher/src/musiccontentpublisher.cpp
musichomescreen_multiview/mcpmusicplayer/src/aiplayerpluginengine.cpp
musichomescreen_multiview/mcpmusicplayer/src/mcpmusicplayer.cpp
musichomescreen_multiview/musiccontentpublisher/inc/musiccontentpublisher.h
musichomescreen_multiview/musiccontentpublisher/src/musiccontentpublisher.cpp
Binary file mpxmusicplayer/Conf/mpxmusicplayer.confml has changed
--- a/mpxmusicplayer/app/data/mpx.rss	Thu Jul 15 18:35:42 2010 +0300
+++ b/mpxmusicplayer/app/data/mpx.rss	Thu Aug 19 09:52:08 2010 +0300
@@ -265,4 +265,12 @@
     buf = qtn_nmp_note_cannot_proceed_with_operation;
     }
 
+// ---------------------------------------------------------------------------
+// r_mus_note_cancelled_due_to_mtp
+// ---------------------------------------------------------------------------
+//
+RESOURCE TBUF r_mus_note_cancelled_due_to_mtp
+    {
+    buf = qtn_mus_note_cancelled_due_to_mtp;
+    }
 // End of File
--- a/mpxmusicplayer/app/loc/mpx.loc	Thu Jul 15 18:35:42 2010 +0300
+++ b/mpxmusicplayer/app/loc/mpx.loc	Thu Aug 19 09:52:08 2010 +0300
@@ -107,4 +107,9 @@
 // r:3.2.3
 #define qtn_nmp_note_cannot_proceed_with_operation "Cannot proceed with operation during USB connection."
 
-// End of File
+// d:Dialog shown not to proceed with operation during Media Transfer operation.
+// l:popup_note_window
+// r:5.2
+#define qtn_mus_note_cancelled_due_to_mtp "Unable to perform operation during Media Transfer operation."
+
+// End of File
\ No newline at end of file
--- a/mpxmusicplayer/commonui/group/mpxcommonui.mmp	Thu Jul 15 18:35:42 2010 +0300
+++ b/mpxmusicplayer/commonui/group/mpxcommonui.mmp	Thu Aug 19 09:52:08 2010 +0300
@@ -88,6 +88,7 @@
 LIBRARY         aknnotify.lib 
 LIBRARY         iclextjpegapi.lib
 LIBRARY         thumbnailmanager.lib	// Album art
+LIBRARY         gfxtrans.lib //effects
 
 // CAMESE_IN_DRM_UTILITY
 LIBRARY         drmuihandling.lib
--- a/mpxmusicplayer/commonui/loc/mpxcommonui.loc	Thu Jul 15 18:35:42 2010 +0300
+++ b/mpxmusicplayer/commonui/loc/mpxcommonui.loc	Thu Aug 19 09:52:08 2010 +0300
@@ -352,4 +352,11 @@
 //
 #define qtn_nmp_note_no_media_key "Media key event not supported by player"
 
+// d:Text in navi pane label.
+// d:Shows total duration of tracks in days and 1 hour.
+// l:list_single_heading_pane_t1_cp2
+// r:5.2
+//
+#define qtn_mus_time_frmt_plural_day_single_hr "%N days, 1 hour"
+
 // End of File
--- a/mpxmusicplayer/commonui/src/mpxcommonuihelper.cpp	Thu Jul 15 18:35:42 2010 +0300
+++ b/mpxmusicplayer/commonui/src/mpxcommonuihelper.cpp	Thu Aug 19 09:52:08 2010 +0300
@@ -79,7 +79,7 @@
 #include "mpxdrmuihelper.h"
 #include "mpxinternalcrkeys.h"
 #include "mpxlog.h"
-
+#include <gfxtranseffect/gfxtranseffect.h>  // For transition effects
 
 // CONSTANTS
 const TInt KMPXOneSecInMicroSecs( 1000000 );
@@ -1309,6 +1309,7 @@
         case KErrCASizeNotDetermined:
         case KErrCANewFileHandleRequired:
             {
+            GfxTransEffect::AbortFullScreen();
             TRAPD(err, ret = iMpxDrmHelper->HandleDrmErrorL( aError, aMedia, aFile ));
             if (err)
                 {
@@ -1384,8 +1385,9 @@
                 }
             break;
             }
-        case KErrLocked:
-            errorText = StringLoader::LoadLC( R_MPX_CANNOT_PROCEED_WITH_OPERATION );
+        case KErrLocked: 
+            //KErrLocked only happen if MTP is connected but no active sync on going.        
+            errorText = StringLoader::LoadLC( R_MUS_NOTE_CANCELLED_DUE_TO_MTP );
             break;
         case KErrDisMounted:
         	break;
--- a/mpxmusicplayer/commonui/src/mpxfilenamequerydlg.cpp	Thu Jul 15 18:35:42 2010 +0300
+++ b/mpxmusicplayer/commonui/src/mpxfilenamequerydlg.cpp	Thu Aug 19 09:52:08 2010 +0300
@@ -236,7 +236,24 @@
     { 
     TKeyResponse response = EKeyWasNotConsumed;
     // consume 'enter' so it won't acknowledge the dialog
-    if ( aType == EEventKey && aKeyEvent.iCode == EKeyEnter ) 
+
+    TBool vkbOpen = EFalse;
+    CAknQueryControl* queryControl = QueryControl();
+    if ( queryControl )
+        {
+        CEikEdwin* edwin = static_cast< CEikEdwin* >(
+            queryControl->ControlByLayoutOrNull( EDataLayout ) );
+        if ( edwin )
+            {            
+            if ( edwin->AknEdwinFlags() & EAknEditorFlagTouchInputModeOpened )
+                {
+                // virtual keyboard is active.                
+                vkbOpen = ETrue;
+                }
+            }
+        }    
+    
+    if ( vkbOpen && aType == EEventKey && aKeyEvent.iCode == EKeyEnter ) 
         { 
         response = EKeyWasConsumed;
         } 
--- a/mpxmusicplayer/group/bld.inf	Thu Jul 15 18:35:42 2010 +0300
+++ b/mpxmusicplayer/group/bld.inf	Thu Aug 19 09:52:08 2010 +0300
@@ -46,6 +46,6 @@
 
 mpxmusicplayerstub.sis              /epoc32/data/z/system/install/mpxmusicplayerstub.sis
 // Secure backup & restore
-backup_registration.xml /epoc32/release/winscw/urel/z/private/102072c3/backup_registration.xml
-backup_registration.xml /epoc32/release/winscw/udeb/z/private/102072c3/backup_registration.xml
-backup_registration.xml /epoc32/data/z/private/102072c3/backup_registration.xml
+backup_registration.xml z:/private/102072c3/backup_registration.xml
+
+
Binary file mpxmusicplayer/help/data/xhtml.zip has changed
--- a/mpxmusicplayer/mediakeyhandler/inc/mpxmediakeyhandlerimp.h	Thu Jul 15 18:35:42 2010 +0300
+++ b/mpxmusicplayer/mediakeyhandler/inc/mpxmediakeyhandlerimp.h	Thu Aug 19 09:52:08 2010 +0300
@@ -343,10 +343,28 @@
      */
     TBool IsAppForeground();
     
-    static VolumePopupSynchTimerCallback( TAny* aPtr );
+    static TInt VolumePopupSynchTimerCallback( TAny* aPtr );
     void DoVolumePopupSynch();
     void StartVolumePopupSynchTimer();
     
+    
+    /**
+     * Callback function of Filter event timer
+     * 
+     * @param aPtr, Pointer to an instance of CMPXMediaKeyHandlerImp
+     * @return value is ignored and is irrelevant in that context
+     */
+    static  TInt FilterEventTimerCallback( TAny* aPtr );
+    
+    /**
+     * Do with the rest event of VolPopup
+     * 
+     * VolPopup CallBack functon is frequently called, 
+     * But Music Palyer deals with the event slowly.
+     * Thus VolPopup will not display smoothly.
+	 * So Music Player needs timer to filter some events.
+     */
+    void DoFilterEventTimer();
 
 private:    // Data
 
@@ -385,7 +403,9 @@
     CUpnpCopyCommand* iUpnpCopyCommand;
     #endif
     TInt iUpnpVolume; // absolute upnp volume value
+    TInt iPreviousVol;          //Last time volume
     CPeriodic* iVolumePopupSynchTimer;
+    CPeriodic* iFilterEventTimer;         //owned, filter volumePopup event
     };
 
 #endif  // C_CMPXMEDIAKEYHANDLERIMP_H
--- a/mpxmusicplayer/mediakeyhandler/src/mpxmediakeyhandlerimp.cpp	Thu Jul 15 18:35:42 2010 +0300
+++ b/mpxmusicplayer/mediakeyhandler/src/mpxmediakeyhandlerimp.cpp	Thu Aug 19 09:52:08 2010 +0300
@@ -69,6 +69,7 @@
 const TInt KTenStepsVolume = 10;   
 const TInt KTwentyStepsVolume = 20;
 const TInt KVolumePopupSynchInterval = 300000; // 300 ms
+const TInt KFilterEventInterval( 6000 ); //6ms
 const TRemConCoreApiOperationId KSupportedCoreFeatures[] = {
         ERemConCoreApiVolumeUp,
         ERemConCoreApiVolumeDown,
@@ -97,7 +98,8 @@
     iObserver( aObserver ),
     iEnable( ETrue ),
     iCurrentVol( KErrNotFound ),
-    iVolumeSteps(KMPXMaxVolume)
+    iVolumeSteps(KMPXMaxVolume),
+    iPreviousVol( KErrNotFound )
     {
     }
 
@@ -211,6 +213,7 @@
         }
 #endif
     iVolumePopupSynchTimer = CPeriodic::NewL( CActive::EPriorityStandard );
+    iFilterEventTimer = CPeriodic::NewL( CActive::EPriorityStandard );
     }
 
 // ---------------------------------------------------------------------------
@@ -236,6 +239,11 @@
 //
 CMPXMediaKeyHandlerImp::~CMPXMediaKeyHandlerImp()
     {
+	if ( iFilterEventTimer )
+		{
+	    iFilterEventTimer->Cancel();
+        delete iFilterEventTimer;
+		}
     if ( iVolumePopupSynchTimer )
         {
         iVolumePopupSynchTimer->Cancel();
@@ -346,6 +354,7 @@
         	else
         	    {
         	    volume = iCurrentVol * KPbPlaybackVolumeLevelMax/iVolumeSteps;
+                iPreviousVol = iCurrentVol;
         	    }
             
             if ( volume < KMPXMinVolume )
@@ -486,7 +495,11 @@
                         aValue = iVolumeSteps;
                         }
                     }
-
+                
+                //if aValue equal to iPreviousVol, MediaKey should not set Volume again.
+                TBool OkToSetVolume = ( aValue != iPreviousVol );
+                iPreviousVol = KErrNotFound;
+                
                 if( iMuted && aValue > 0  ) // unmute
                     {
                     iMuted = EFalse;
@@ -499,11 +512,11 @@
                         iMuted = ETrue;
                         }
                     }
-                    else if ( aValue != iCurrentVol )
+                else if ( aValue != iCurrentVol )
                     {
-                    if ( aValue != 0 && ( iResponseHandler->iCountOfVolumeCommands == 0 ) )
+                    if ( aValue != 0 && OkToSetVolume && ( iResponseHandler->iCountOfVolumeCommands == 0 ) )
                         {
-                        // if we are processing remcon events we shouldn't change the current volume value
+                        // if we are processing remcon events we shouldn't change the current volume value                      
                         iCurrentVol = aValue;
                         }
                     }
@@ -513,7 +526,10 @@
                     iCurrentVol = aValue;
                     }
                 
-                StartVolumePopupSynchTimer();
+                if ( OkToSetVolume )
+                	{
+                    StartVolumePopupSynchTimer();
+                	}
                 
                 // send a command to UI to display Volume bar on device when controlling volume via UPnP  
                 if ( IsUpnpVisibleL() && iPlayerState != EPbStateNotInitialised )
@@ -1287,7 +1303,16 @@
 			else
 				{
 				iCurrentVol = vol;
-				FilterAndSendCommand( EPbCmdSetVolume );
+				//VolPopup CallBack functon is frequently called, 
+				//But Music Palyer deals with the event slowly
+				//Thus VolPopup will not display smoothly.
+				//So Music Player needs timer to filter some events. 
+				if ( !iFilterEventTimer->IsActive() )
+					{
+				    iFilterEventTimer->Start( KFilterEventInterval, 
+				    		            KFilterEventInterval, 
+				                        TCallBack( FilterEventTimerCallback, this ) );
+					}
 				}
 			}
 		}
@@ -1373,4 +1398,25 @@
                                    TCallBack( VolumePopupSynchTimerCallback, this ) );
 
     }
+
+// ---------------------------------------------------------------------------
+// CMPXMediaKeyHandlerImp::FilterEventTimerCallback
+// ---------------------------------------------------------------------------
+//
+TInt CMPXMediaKeyHandlerImp::FilterEventTimerCallback( TAny* aPtr )
+	{
+	static_cast<CMPXMediaKeyHandlerImp*>( aPtr )->DoFilterEventTimer();
+	return KErrNone;
+	}
+
+// ---------------------------------------------------------------------------
+// CMPXMediaKeyHandlerImp::FilterEventTimerCallback
+// ---------------------------------------------------------------------------
+//
+void CMPXMediaKeyHandlerImp::DoFilterEventTimer()
+	{
+	MPX_FUNC("CMPXMediaKeyHandlerImp::DoFilterEventTimer");
+	iFilterEventTimer->Cancel();
+	FilterAndSendCommand( EPbCmdSetVolume );
+	}
 // End of File
--- a/mpxplugins/serviceplugins/collectionplugins/mpxsqlitedbhgplugin/inc/mpxcollectiondbdef.h	Thu Jul 15 18:35:42 2010 +0300
+++ b/mpxplugins/serviceplugins/collectionplugins/mpxsqlitedbhgplugin/inc/mpxcollectiondbdef.h	Thu Aug 19 09:52:08 2010 +0300
@@ -28,11 +28,11 @@
 
 // Db filename
 #ifdef ABSTRACTAUDIOALBUM_INCLUDED
-_LIT(KMCDbFile, "mpxv3_0.db");
-_LIT(KMCDbFileEMMC, "mpxv3_0i.db");
+_LIT(KMCDbFile, "mpxv3_1.db");
+_LIT(KMCDbFileEMMC, "mpxv3_1i.db");
 #else 
-_LIT(KMCDbFile, "mpxv3_0n.db");
-_LIT(KMCDbFileEMMC, "mpxv3_0in.db");
+_LIT(KMCDbFile, "mpxv3_1n.db");
+_LIT(KMCDbFileEMMC, "mpxv3_1in.db");
 #endif // ABSTRACTAUDIOALBUM_INCLUDED
 // Collection Db resource file
 _LIT(KMPXCollectionDbResourceFile,  "mpxcollectiondbhgres.rsc");
--- a/mpxplugins/serviceplugins/collectionplugins/mpxsqlitedbhgplugin/inc/mpxcollectiondbstd.h	Thu Jul 15 18:35:42 2010 +0300
+++ b/mpxplugins/serviceplugins/collectionplugins/mpxsqlitedbhgplugin/inc/mpxcollectiondbstd.h	Thu Aug 19 09:52:08 2010 +0300
@@ -32,8 +32,8 @@
 
 const TInt KDBPluginUid = 0x101FFC3A;
 
-const TInt KMPXMaxRecentlyPlayedSongs = 20;
-const TInt KMPXMaxMostPlayedSongs = 20;
+const TInt KMPXMaxRecentlyPlayedSongs = 40;
+const TInt KMPXMaxMostPlayedSongs = 40;
 const TInt KMPXRecentlyAddedInterval = 7;
 
 const TInt KMCMaxTextLen          = 255; // Maximum field size for categories is 255
--- a/mpxplugins/serviceplugins/collectionplugins/mpxsqlitedbhgplugin/inc/mpxdbalbum.h	Thu Jul 15 18:35:42 2010 +0300
+++ b/mpxplugins/serviceplugins/collectionplugins/mpxsqlitedbhgplugin/inc/mpxdbalbum.h	Thu Aug 19 09:52:08 2010 +0300
@@ -176,6 +176,16 @@
         * @returns alternative albumart retrieved in the specified Album.
         */
         HBufC* AlbumartForAlbumL(const TUint32 aId, TPtrC aArt);
+        
+        /**
+        * Processes a recordset by constructing media instances and adding them
+        * to the specified array.
+        * @param aAttrs attributes to be returned
+        * @param aRecordset recordset to be processed
+        * @param aMediaArray returns the media instances
+        */
+        void ProcessAlbumRecordSetL(const TArray<TMPXAttribute>& aAttrs,
+            RSqlStatement& aRecordset, CMPXMediaArray& aMediaArray);
 
     private:    // from MMPXTable
 
--- a/mpxplugins/serviceplugins/collectionplugins/mpxsqlitedbhgplugin/inc/mpxdbmusic.h	Thu Jul 15 18:35:42 2010 +0300
+++ b/mpxplugins/serviceplugins/collectionplugins/mpxsqlitedbhgplugin/inc/mpxdbmusic.h	Thu Aug 19 09:52:08 2010 +0300
@@ -686,7 +686,7 @@
         */
         TBool UpdateCategoryFieldL(TMPXGeneralCategory aCategory, const CMPXMedia& aMedia,
             const TMPXAttribute& aAttribute, TUint32 aOldId, TInt aDriveId,
-            CMPXMessageArray* aItemChangedMessages, TUint32& aItemId);
+            CMPXMessageArray* aItemChangedMessages, TUint32& aItemId, const TDesC& aArt = KNullDesC);
 
         /**
         * Checks if extra attributes are required. The "standard attribute set includes:
--- a/mpxplugins/serviceplugins/collectionplugins/mpxsqlitedbhgplugin/inc/mpxdbpluginqueries.h	Thu Jul 15 18:35:42 2010 +0300
+++ b/mpxplugins/serviceplugins/collectionplugins/mpxsqlitedbhgplugin/inc/mpxdbpluginqueries.h	Thu Aug 19 09:52:08 2010 +0300
@@ -144,6 +144,15 @@
 _LIT(KQueryMusicGetMostPlayed, "SELECT Music.*,Artist.Name,Album.Name,Genre.Name,Composer.Name FROM :dbname.Music,:dbname.Artist,:dbname.Album,:dbname.Genre,:dbname.Composer WHERE Music.Deleted=0 AND Music.PlayCount<>0 AND Music.Album=Album.UniqueId AND Music.Artist=Artist.UniqueId AND Music.Genre=Genre.UniqueId AND Music.Composer=Composer.UniqueId ORDER BY PlayCount DESC, TimePlayed DESC LIMIT %u");
 _LIT(KQueryMusicGetRecentlyAdded, "SELECT Music.*,Artist.Name,Album.Name,Genre.Name,Composer.Name FROM :dbname.Music,:dbname.Artist,:dbname.Album,:dbname.Genre,:dbname.Composer WHERE Music.Deleted=0 AND (julianday(Music.TimeAdded)>julianday('now','-7 days')) AND Music.Album=Album.UniqueId AND Music.Artist=Artist.UniqueId AND Music.Genre=Genre.UniqueId AND Music.Composer=Composer.UniqueId ORDER BY Music.TimeAdded DESC");
 */
+
+
+#ifdef ABSTRACTAUDIOALBUM_INCLUDED
+_LIT(KQueryMusicGetAllSongsMinimum, "SELECT Music.UniqueId,Music.DbFlag,Music.VolumeId,Music.Title,0,Music.Art,Music.Deleted,Music.Location,0,0,'','',0,0,0,0,0,0,0,0,'','','',0,0,0,0,0,0,'',0,'',0,0,Artist.Name FROM :dbname.Music,:dbname.Artist WHERE Deleted=0 AND Music.Artist=Artist.UniqueId ORDER BY MUSIC.Title");                                  
+#else
+_LIT(KQueryMusicGetAllSongsMinimum, "SELECT Music.UniqueId,Music.DbFlag,Music.VolumeId,Music.Title,0,Music.Art,Music.Deleted,Music.Location,0,0,'','',0,0,0,0,0,0,0,0,'','','',0,0,0,0,0,0,'',0,Artist.Name FROM :dbname.Music,:dbname.Artist WHERE Deleted=0 AND Music.Artist=Artist.UniqueId ORDER BY MUSIC.Title");                                
+#endif  
+
+
 _LIT(KQueryMusicGetAllSongs, "SELECT Music.*,Artist.Name,Album.Name,Genre.Name,Composer.Name FROM :dbname.Music,:dbname.Artist,:dbname.Album,:dbname.Genre,:dbname.Composer WHERE Music.Deleted=0 AND Music.Album=Album.UniqueId AND Music.Artist=Artist.UniqueId AND Music.Genre=Genre.UniqueId AND Music.Composer=Composer.UniqueId ORDER BY 4");
 _LIT(KQueryMusicGetSongsForArtist, "SELECT Music.*,Artist.Name,Album.Name,Genre.Name,Composer.Name FROM :dbname.Music,:dbname.Artist,:dbname.Album,:dbname.Genre,:dbname.Composer WHERE Music.Deleted=0 AND Music.Artist=%u AND Music.Album=Album.UniqueId AND Music.Artist=Artist.UniqueId AND Music.Genre=Genre.UniqueId AND Music.Composer=Composer.UniqueId ORDER BY 4");
 _LIT(KQueryMusicGetSongsForAlbum, "SELECT Music.*,Artist.Name,Album.Name,Genre.Name,Composer.Name FROM :dbname.Music,:dbname.Artist,:dbname.Album,:dbname.Genre,:dbname.Composer WHERE Music.Deleted=0 AND Music.Album=%u AND Music.Album=Album.UniqueId AND Music.Artist=Artist.UniqueId AND Music.Genre=Genre.UniqueId AND Music.Composer=Composer.UniqueId ORDER BY 9, 4");
@@ -270,9 +279,9 @@
 _LIT(KAuxiliaryDropTable,"DROP TABLE Auxiliary");
 _LIT(KAuxiliaryCheckTable, "SELECT Id,Version,TimeRefreshed,TimeSynced,Corrupt,SaveDeletedRecordCount FROM AUXILIARY");
 #ifdef ABSTRACTAUDIOALBUM_INCLUDED
-_LIT(KQueryAuxiliaryInsert, "INSERT INTO Auxiliary(Id,Version,Corrupt) VALUES(0,'6.6.0',%u)");
+_LIT(KQueryAuxiliaryInsert, "INSERT INTO Auxiliary(Id,Version,Corrupt) VALUES(0,'6.7.0',%u)");
 #else
-_LIT(KQueryAuxiliaryInsert, "INSERT INTO Auxiliary(Id,Version,Corrupt) VALUES(0,'6.6.1',%u)");
+_LIT(KQueryAuxiliaryInsert, "INSERT INTO Auxiliary(Id,Version,Corrupt) VALUES(0,'6.7.1',%u)");
 #endif // ABSTRACTAUDIOALBUM_INCLUDED
 _LIT(KQueryAuxiliarySetTime, "UPDATE :dbname.Auxiliary SET TimeRefreshed='%S', Corrupt=0");
 _LIT(KQueryAuxiliaryGetTime, "SELECT TimeRefreshed FROM :dbname.Auxiliary");
--- a/mpxplugins/serviceplugins/collectionplugins/mpxsqlitedbhgplugin/src/mpxdbalbum.cpp	Thu Jul 15 18:35:42 2010 +0300
+++ b/mpxplugins/serviceplugins/collectionplugins/mpxsqlitedbhgplugin/src/mpxdbalbum.cpp	Thu Aug 19 09:52:08 2010 +0300
@@ -350,7 +350,7 @@
     CleanupStack::PopAndDestroy(query);
 
     CleanupClosePushL(recordset);
-    ProcessRecordsetL(aAttrs, recordset, aMediaArray);
+    ProcessAlbumRecordSetL(aAttrs, recordset, aMediaArray);
     CleanupStack::PopAndDestroy(&recordset);
     }
 
@@ -617,4 +617,108 @@
     return check;
     }
 
+// ----------------------------------------------------------------------------
+// CMPXDbAlbum::ProcessAlbumRecordSetL
+// Unknown album is stored in the database as NULL (name field). 
+// The first available unknown album is saved for later and will be appended to the array 
+// as the last item and rest available unknown album will be ignored. 
+//
+// NOTE: putting unknown album to the end of the array only takes place when title
+//       field is requested. normal sorting algorithm occurs if title isn't
+//       requested.
+// ----------------------------------------------------------------------------
+//
+void CMPXDbAlbum::ProcessAlbumRecordSetL(
+    const TArray<TMPXAttribute>& aAttrs,
+    RSqlStatement& aRecordset,
+    CMPXMediaArray& aMediaArray)
+    {
+    // populate the array
+    TBool unknownRecord(EFalse);
+    TBool firstUnknownRecord(EFalse);
+    CMPXMedia* unknownMedia(NULL);
+    TInt prevId(0);
+    TInt err(KErrNone);
+
+    TInt pPath(0);
+    if (aMediaArray.Count())
+        {
+        CMPXMedia* pMedia = aMediaArray[0];
+        if (pMedia->IsSupported(KMPXMediaGeneralValue))
+            { // Query excuted by OpenL
+            pPath = pMedia->ValueTObjectL<TInt>(KMPXMediaGeneralValue);
+            MPX_ASSERT(pPath);
+            }
+        }
+    RArray<TMPXItemId> ids;
+    CleanupClosePushL(ids);
+
+    while ((err = aRecordset.Next()) == KSqlAtRow)
+        {
+        TUint32 rowId(aRecordset.ColumnInt64(EAlbumUniqueId));
+        if (prevId == rowId)
+            {
+            continue;
+            }
+
+        prevId = rowId;
+        CMPXMedia* media = CMPXMedia::NewL();
+        CleanupStack::PushL(media);
+
+        UpdateMediaL(aRecordset, aAttrs, *media);
+
+        if (MPXDbCommonUtil::GetColumnTextL(aRecordset, EAlbumName).Length() == 0)
+            {
+            if (!unknownMedia)
+                {
+                unknownMedia = media;
+                firstUnknownRecord = ETrue;
+                }
+            unknownRecord = ETrue;
+            }
+        
+        if (!unknownRecord)
+            {
+            if (media->IsSupported(KMPXMediaGeneralId) && pPath)
+                {
+                ids.AppendL(media->ValueTObjectL<TMPXItemId>(KMPXMediaGeneralId));
+                }
+            aMediaArray.AppendL(*media);
+            }
+        
+        if (!firstUnknownRecord)
+            {
+            CleanupStack::PopAndDestroy(media);
+            }
+        else
+            {
+            firstUnknownRecord = EFalse;
+            }
+        
+        unknownRecord = EFalse;
+        } // end while
+
+    if (err != KSqlAtEnd)
+        {
+        User::LeaveIfError(err);
+        }
+
+    if (unknownMedia)
+        {
+        if (unknownMedia->IsSupported(KMPXMediaGeneralId) && pPath)
+            {
+            ids.AppendL(unknownMedia->ValueTObjectL<TMPXItemId>(KMPXMediaGeneralId));
+            }
+        aMediaArray.AppendL(*unknownMedia);
+        CleanupStack::PopAndDestroy(unknownMedia);
+        }
+
+    // Append ids to the returned path
+    if (pPath)
+        {
+        ((CMPXCollectionPath*)pPath)->AppendL(ids.Array());
+        }
+    CleanupStack::PopAndDestroy(&ids);
+    }
+
 // End of File
--- a/mpxplugins/serviceplugins/collectionplugins/mpxsqlitedbhgplugin/src/mpxdbmusic.cpp	Thu Jul 15 18:35:42 2010 +0300
+++ b/mpxplugins/serviceplugins/collectionplugins/mpxsqlitedbhgplugin/src/mpxdbmusic.cpp	Thu Aug 19 09:52:08 2010 +0300
@@ -712,7 +712,7 @@
     // Run query and add result media objects to the cache array.
     MPX_FUNC("CMPXDbMusic::ExecuteQueryAllSongsL");
 
-    RSqlStatement recordset(iDbManager.ExecuteSelectQueryL(KQueryMusicGetAllSongs));
+    RSqlStatement recordset(iDbManager.ExecuteSelectQueryL(KQueryMusicGetAllSongsMinimum));
     CleanupClosePushL(recordset);
 
     TInt err(KErrNone);
@@ -2118,6 +2118,8 @@
 #ifdef ABSTRACTAUDIOALBUM_INCLUDED
     TUint32 abstractAlbumId(0);
 #endif // ABSTRACTAUDIOALBUM_INCLUDED
+    //need to get song art for updating art field in Album and Artist tables
+    TPtrC art(KNullDesC);
     if (aMusicTable)
         {
         artistId = aMusicTable->ColumnInt64(EMusicArtist);
@@ -2127,13 +2129,14 @@
 #ifdef ABSTRACTAUDIOALBUM_INCLUDED
         abstractAlbumId = aMusicTable->ColumnInt64(EMusicAbstractAlbum);
 #endif // ABSTRACTAUDIOALBUM_INCLUDED        
+        art.Set(MPXDbCommonUtil::GetColumnTextL(*aMusicTable, EMusicArt));
         }
 
     // update the artist field
     TUint32 id(0);
     TUint32 artistIdForAlbum(artistId);
     if (UpdateCategoryFieldL(EMPXArtist, aMedia, KMPXMediaMusicArtist, artistId,
-        aDrive, aItemChangedMessages, id))
+        aDrive, aItemChangedMessages, id, art))
         {
         MPXDbCommonUtil::AppendValueL(aFields, aValues, KMCMusicArtist, id);
         metaDataModified = (aMusicTable != NULL);
@@ -2143,7 +2146,7 @@
 
     // update the album field
     if (UpdateCategoryFieldL(EMPXAlbum, aMedia, KMPXMediaMusicAlbum, albumId,
-        aDrive, aItemChangedMessages, id))
+        aDrive, aItemChangedMessages, id, art))
         {
         MPXDbCommonUtil::AppendValueL(aFields, aValues, KMCMusicAlbum, id);
         metaDataModified = (aMusicTable != NULL);
@@ -2429,6 +2432,7 @@
 
     // Do not create any other indexes than the one on UniqueId
     // as they only slow down the database overall
+    User::LeaveIfError(aDatabase.Exec(KMusicDeletedTitleIndex));
     }
 
 // ----------------------------------------------------------------------------
@@ -2464,7 +2468,7 @@
     TUint32 aOldId,
     TInt aDriveId,
     CMPXMessageArray* aItemChangedMessages,
-    TUint32& aItemId)
+    TUint32& aItemId, const TDesC& aArt)
     {
     TBool updated(EFalse);
     TBool itemNotRemoved( EFalse );
@@ -2549,7 +2553,15 @@
                             artistname.Set(aMedia.ValueText(KMPXMediaMusicArtist).Left(KMCMaxTextLen));
                             }
                         }
-                    iObserver.AddCategoryItemL(aCategory, name, artistname, art, aDriveId, aItemChangedMessages, itemAdded);
+                    //for the update case, need to maitain art field for Artist/Album table.
+                    if (aOldId && (aOldId != aItemId))
+                       {
+                       iObserver.AddCategoryItemL(aCategory, name, artistname, aArt, aDriveId, aItemChangedMessages, itemAdded);  
+                       } 
+                    else
+                       {      
+                       iObserver.AddCategoryItemL(aCategory, name, artistname, art, aDriveId, aItemChangedMessages, itemAdded);
+                       }
                     }
                 else
                     {
--- a/mpxplugins/serviceplugins/playbackplugins/localaudio/src/mpxlocalaudioplayback.cpp	Thu Jul 15 18:35:42 2010 +0300
+++ b/mpxplugins/serviceplugins/playbackplugins/localaudio/src/mpxlocalaudioplayback.cpp	Thu Aug 19 09:52:08 2010 +0300
@@ -327,6 +327,7 @@
                     else
                         {
                         MPX_TRAPD( AEErr,  ConsumeRightsL( ContentAccess::EPlay ) );
+                        iState = EStateInitialised;
                         if (AEErr == KErrDiskFull)
                         	{
                         	iDrmMediaUtility->Close();
--- a/mpxplugins/serviceplugins/playbackplugins/progressdownloadsb/src/mpxprogressdownloadsb.cpp	Thu Jul 15 18:35:42 2010 +0300
+++ b/mpxplugins/serviceplugins/playbackplugins/progressdownloadsb/src/mpxprogressdownloadsb.cpp	Thu Aug 19 09:52:08 2010 +0300
@@ -338,7 +338,6 @@
                     if ( iConsumeStarted )
                         {
                         ConsumeRights( ContentAccess::EStop );
-                        iConsumeStarted = EFalse;
                         }
                     if ( !iFileSaved )
                         {
@@ -354,7 +353,6 @@
                     if ( iConsumeStarted )
                         {
                         ConsumeRights( ContentAccess::EStop );
-                        iConsumeStarted = EFalse;
                         }
                     if ( !iFileSaved )
                         {
@@ -1021,17 +1019,15 @@
                         else if ( event->GetErrorCode() == KErrEof ) // Playback Complete
                             {
                             MPX_DEBUG2("CMPXProgressDownloadSB::Event:EStateChanged[PlaybackComplete] errorcode=%d",event->GetErrorCode());
-                            if ( iDownloadState == EPbDlStateDownloadCompleted && !iFileSaved )
+                            if ( iDownloadState == EPbDlStateDownloadCompleted )
                                 {
-                                if ( event->GetErrorCode() == KErrEof )
+                                ConsumeRights( ContentAccess::EStop );
+								if (!iFileSaved)
                                     {
-                                    ConsumeRights( ContentAccess::EStop );
-                                    }
-                                else
-                                    {
-                                    ConsumeRights( ContentAccess::EPause );
-                                    }
-                                MoveDownloadedFileToMusicFolder();
+									iDrmMediaUtility->Close(); 
+									MoveDownloadedFileToMusicFolder();
+									}
+                                iObs->HandlePluginEvent( MMPXPlaybackPluginObserver::EPPlayComplete, 0, KErrNone);
                                 }
                             }
                         else if ( event->GetErrorCode() == KErrDied || event->GetErrorCode() == KErrInUse ||
@@ -1094,11 +1090,7 @@
                     case MStreamControl::BUFFERING:
                         MPX_DEBUG2("CMPXProgressDownloadSB::Event:EStateChanged[Buffering] errorcode= %d",event->GetErrorCode());
                         iStreamBuffering = ETrue;
-                        if ( iDownloadState != EPbDlStateDownloadPaused ||
-                                iDownloadState != EPbDlStateDownloadCanceled ||
-                                iDownloadState != EPbDlStateDownloadError ||
-                                iDownloadState != EPbDlStateNotDownloading
-                        )
+                        if ( iDownloadState == EPbDlStateDownloading)
                             {
                             iDownloadState = EPbDlStateBuffering;
                             }
@@ -1276,7 +1268,7 @@
                 }
 
             TRAP_IGNORE( iDrmMediaUtility->InitL( *iPdPath ));
-            iObs->HandlePluginEvent( MMPXPlaybackPluginObserver::EPPlayComplete, 0, KErrNone);
+//            iObs->HandlePluginEvent( MMPXPlaybackPluginObserver::EPPlayComplete, 0, KErrNone);
 
             if ( !fileMoveError || fileMoveError == KErrAlreadyExists )
                 {
@@ -1499,6 +1491,9 @@
 //
 void CMPXProgressDownloadSB::MoveDownloadedFileToMusicFolder()
     {
+    
+    MPX_DEBUG1("CMPXProgressDownloadSB::MoveDownloadedFileToMusicFolder() entering");
+
     if ( iFileSaved || iPdPath == NULL ||
          ( (*iPdPath).Length() == 0 ) ||
          iMAudioProgDLSource->GetDownloadStatus() == MProgDLSource::EDeleted )
@@ -1506,7 +1501,6 @@
         return;
         }
 
-    MPX_DEBUG1("CMPXProgressDownloadSB::MoveDownloadedFileToMusicFolder() entering");
     TParse parse;
     parse.Set(*iPdPath,NULL,NULL);
     TPtrC drive = parse.Drive();
@@ -1538,8 +1532,17 @@
         {
         switch ( aIntent )
             {
+            case ContentAccess::EStop:
+                {
+                iPlaying = EFalse;
+                iConsumeStarted = EFalse;
+                break;
+                }
             case ContentAccess::EPlay:
-            case ContentAccess::EStop:
+                {
+                iPlaying = ETrue;
+                break;
+                }
             case ContentAccess::EPause:
             case ContentAccess::EContinue:
                 {
@@ -1552,8 +1555,12 @@
                 break;
                 }
             }
-        MPX_DEBUG2("-->CMPXProgressDownloadSB::ConsumeRights(): Executing intent %d", aIntent);
-        iDrmCustomCommand->ExecuteIntent(aIntent);
+        MPX_DEBUG2("-->CMPXProgressDownloadSB::ConsumeRights(): EvaluateIntent intent %d", aIntent);
+        if (iDrmCustomCommand->EvaluateIntent(aIntent) == KErrNone)
+            {
+            MPX_DEBUG2("-->CMPXProgressDownloadSB::ConsumeRights(): Executing intent %d", aIntent);
+            iDrmCustomCommand->ExecuteIntent(aIntent);
+            }
         }
     MPX_DEBUG2("<--CMPXProgressDownloadSB::ConsumeRights(%d)", aIntent);
     }
--- a/mpxplugins/viewplugins/inc/mpxcommonplaybackviewimp.h	Thu Jul 15 18:35:42 2010 +0300
+++ b/mpxplugins/viewplugins/inc/mpxcommonplaybackviewimp.h	Thu Aug 19 09:52:08 2010 +0300
@@ -12,7 +12,7 @@
 * Contributors:
 *
 * Description:  MPX common playback view implementation
-*  Version     : %version: e003sa33#41.1.6.1.1.1.13 % << Don't touch! Updated by Synergy at check-out.
+*  Version     : %version: da1mmcf#41.1.6.1.1.1.14 % << Don't touch! Updated by Synergy at check-out.
 *
 */
 
@@ -759,6 +759,7 @@
     // Indicate FF button pressed or not
     TBool iIsffButtonPressed;
     TBool iBacking;
+    TBool iErrorOccured;
 #ifdef IAD_INCLUDE_UPNP    
 	CUpnpCopyCommand* iUpnpCopyCommand;
 #endif
--- a/mpxplugins/viewplugins/inc/mpxmetadataeditordialog.h	Thu Jul 15 18:35:42 2010 +0300
+++ b/mpxplugins/viewplugins/inc/mpxmetadataeditordialog.h	Thu Aug 19 09:52:08 2010 +0300
@@ -80,7 +80,8 @@
                                                 public MMPXCollectionObserver,
                                                 public MMPXCollectionFindObserver,
                                                 public MMPXPlaybackCallback,
-                                                public MMPXCHelperObserver
+                                                public MMPXCHelperObserver,
+                                                public MMPXPlaybackObserver
     {
 public:
     // File Details headings
@@ -201,7 +202,26 @@
         const CMPXMedia& aMedia,
         TInt aError);
 
+private:
+
+    /**
+     * From MMPXPlaybackObserver
+     * Handle playback message
+     *
+     * @param aMessage playback message
+     * @param aErr system error code.
+     */
+    void HandlePlaybackMessage( CMPXMessage* aMessage, TInt aError );
+  
+    /**
+     *  Handle playback message
+     *
+     *  @param aMessage playback message
+     */
+    void DoHandlePlaybackMessageL( const CMPXMessage& aMessage );
+    
 private:  // Constructor
+
     /**
      * Default constructor.
      */
--- a/mpxplugins/viewplugins/views/addtracksdialog/loc/mpxaddtracksdialog.loc	Thu Jul 15 18:35:42 2010 +0300
+++ b/mpxplugins/viewplugins/views/addtracksdialog/loc/mpxaddtracksdialog.loc	Thu Aug 19 09:52:08 2010 +0300
@@ -57,7 +57,7 @@
 // LOCALISATION STRINGS
 
 // d:Title for Add songs view
-// l:title_pane_t2/opt9
+// l:title_pane_t1/opt3
 // r:3.1
 //
 #define qtn_nmp_title_add_songs     "Add Songs"
--- a/mpxplugins/viewplugins/views/collectionviewhg/inc/mpxcollectionviewhgcontainer.h	Thu Jul 15 18:35:42 2010 +0300
+++ b/mpxplugins/viewplugins/views/collectionviewhg/inc/mpxcollectionviewhgcontainer.h	Thu Aug 19 09:52:08 2010 +0300
@@ -208,6 +208,13 @@
      * @since 3.1
      */
     TInt TopLbxItemIndex() const;
+    /**
+     * Gets first listbox item index on screen(relative to the original listbox).
+     * @return first listbox item index on screen
+     *
+     * 
+     */
+    TInt FirstIndexOnScreen() const;
 
     /**
      * Gets bottom listbox item index (relative to the original listbox).
@@ -1022,6 +1029,7 @@
     TUid iPreviousViewId;
     TBool iPreviousOrientation;
     TBool iDrawBackGround;
+    TBool iIsNowPlayingView;
     };
 
 #endif  // CMPXCOLLECTIONVIEWHGCONTAINER_H
--- a/mpxplugins/viewplugins/views/collectionviewhg/inc/mpxcollectionviewhgimp.h	Thu Jul 15 18:35:42 2010 +0300
+++ b/mpxplugins/viewplugins/views/collectionviewhg/inc/mpxcollectionviewhgimp.h	Thu Aug 19 09:52:08 2010 +0300
@@ -885,7 +885,12 @@
     TBool NeedToShowEducatingDialog(); 
     void LaunchEducatingURL();
     static TInt LinkCallback(TAny* aPtr);
-
+	
+	/*
+ 	 * Internal functions to Dim all options
+ 	 */
+    void DimAllOptions( TInt aResourceId, CEikMenuPane* aMenuPane );
+	
 private:    // Data
 
     MMPXCollectionUtility*      iCollectionUtility;
@@ -925,7 +930,7 @@
     TInt                        iCurrentPlaylistOp;
     TInt                        iNumSongAddedToPlaylist;
     TMPXItemId                  iPlaylistId;
-
+    TInt                        iFirstIndexOnScreen;
     TInt                        iCurrentMediaLOp;   // current mediaL operation
     TInt                        iCurrentFindAllLOp; // current FindAllL operation
     TInt                        iLastDepth;
--- a/mpxplugins/viewplugins/views/collectionviewhg/src/mpxcollectionviewhgcontainer.cpp	Thu Jul 15 18:35:42 2010 +0300
+++ b/mpxplugins/viewplugins/views/collectionviewhg/src/mpxcollectionviewhgcontainer.cpp	Thu Aug 19 09:52:08 2010 +0300
@@ -107,6 +107,7 @@
 const TInt KThumbLoadingPauseForTransition(500000);
 const TInt KMPXInterviewTransition = 0;
 const TInt KMPXIntraviewTransition = 1;
+const TInt KMPXNoTransition = 2;
 
 _LIT( KMPXDash, " - " );
 #ifdef HG_MP_LOC_AVAILABLE
@@ -163,7 +164,8 @@
 	iSetEmptyTextNeeded(EFalse),
 	iPopupListRect(TRect(0,0,0,0)),
 	iPreviousViewId(TUid::Uid(0)),
-	iDrawBackGround(EFalse)
+	iDrawBackGround(EFalse),
+	iIsNowPlayingView(EFalse)
     {
     }
 
@@ -1004,6 +1006,22 @@
 
 
 // -----------------------------------------------------------------------------
+// Gets first listbox item index on screen(relative to the original listbox).
+// -----------------------------------------------------------------------------
+//
+TInt CMPXCollectionViewHgContainer::FirstIndexOnScreen() const
+    {
+    MPX_FUNC( "CMPXCollectionViewHgContainer::FirstIndexOnScreen" );
+    TInt index = 0;
+    if ( iListWidget )
+        {
+        index = iListWidget->FirstIndexOnScreen();
+        }
+    return index;
+    }
+
+
+// -----------------------------------------------------------------------------
 // Gets bottom listbox item index (relative to the original listbox).
 // -----------------------------------------------------------------------------
 //
@@ -1258,6 +1276,7 @@
             TBool pbv = (iPreviousViewId == TUid::Uid(KMPXPluginTypePlaybackUid)) ? ETrue : EFalse;
             if ( pbv )
                 {
+                iIsNowPlayingView = ETrue;
             	iPreviousViewId = TUid::Uid(0);
             	SetupTransitionType(KMPXInterviewTransition, pbv);
                 }
@@ -1499,7 +1518,7 @@
     {
     MPX_FUNC( "CMPXCollectionViewHgContainer::ResizeListL" );
     TInt mediaCount = aMediaArray.Count();
-
+    SetupTransitionType( KMPXNoTransition );
     if( iListWidget )
         {
         TRect clientRect = ((CAknView*)iView)->ClientRect();
@@ -1621,7 +1640,14 @@
         // TODO. check if this is correct for all lists
         iListWidget->ClearFlags( CHgScroller::EHgScrollerKeyMarkingDisabled );
         iListWidget->SetFocus(ETrue);
-        iListWidget->SetScrollBarTypeL( CHgScroller::EHgScrollerLetterStripLite );
+        if( iContext == EContextItemPlaylist )
+            {
+            iListWidget->SetScrollBarTypeL( CHgScroller::EHgScrollerScrollBar);
+            }   
+        else
+            {
+            iListWidget->SetScrollBarTypeL( CHgScroller::EHgScrollerLetterStripLite );
+            }
         iListWidget->DrawableWindow()->SetOrdinalPosition( -1 );
         iListWidget->DrawableWindow()->SetFaded(((CAknAppUi*)iCoeEnv->AppUi())->IsFaded(), RWindowTreeNode::EFadeIncludeChildren);
         ProvideDataWithoutThumbnailsL(aMediaArray);
@@ -1631,6 +1657,14 @@
         iListWidget->Reset();
         iListWidget->ResizeL( aCount );
         iListWidget->SetFocus(ETrue);
+        if( iContext == EContextItemPlaylist )
+            {
+            iListWidget->SetScrollBarTypeL( CHgScroller::EHgScrollerScrollBar);
+            }   
+        else
+            {
+            iListWidget->SetScrollBarTypeL( CHgScroller::EHgScrollerLetterStripLite );
+            }
         ProvideDataWithoutThumbnailsL(aMediaArray);
         iListWidget->MakeVisible(ETrue);
         iListWidget->InitScreenL(clientRect);
@@ -1822,7 +1856,10 @@
     else if ( iMediaWall && iPrevViewType == EMPXViewTBone )
         {
         switchBuffer = CMPXCollectionViewHgSwitchBuffer::CreateBufferLC( *iMediaWall );
-        switchBuffer->SetIndexOffset(1);
+        if (aMediaArray.Count()>1)
+            {
+            switchBuffer->SetIndexOffset(1);
+            }
         }
     if( iMediaWall )
         {
@@ -1834,14 +1871,28 @@
 
 	if (!iMediaWall)
 	    {
-        iMediaWall = CHgVgMediaWall::NewL(
-                appRect,
-                aCount,
-                CHgVgMediaWall::EHgVgMediaWallStyleCoverflowFullScreen,
-                ETrue,
-                this,
-                DefaultIconL() );
-
+	    if ( iIsNowPlayingView )
+	        {
+			// back from now playing view, create mediawall with empty albumart icon to avoid flickering
+	        iMediaWall = CHgVgMediaWall::NewL(
+	                appRect,
+	                aCount,
+	                CHgVgMediaWall::EHgVgMediaWallStyleCoverflowFullScreen,
+	                ETrue,
+	                this,
+	                CGulIcon::NewL( new CFbsBitmap()) );
+	        }
+	    else
+	        {
+	        iMediaWall = CHgVgMediaWall::NewL(
+	                appRect,
+	                aCount,
+	                CHgVgMediaWall::EHgVgMediaWallStyleCoverflowFullScreen,
+	                ETrue,
+	                this,
+	                DefaultIconL() );
+	        }
+    
         if( !iIsForeground )
             iMediaWall->HandleLosingForeground();
 
@@ -1919,7 +1970,16 @@
         CleanupStack::PopAndDestroy( switchBuffer );
         switchBuffer = NULL;
         }
-	iDefaultIconSet = ETrue;
+	
+	if ( iIsNowPlayingView )
+	    {
+        iDefaultIconSet = EFalse;
+        iIsNowPlayingView = EFalse;
+	    }
+	else
+	    {
+        iDefaultIconSet = ETrue;
+	    }
 	CleanPrevView();
     }
 
@@ -4815,23 +4875,30 @@
 	const CMPXMedia* restoredAlbum = iSelectedAlbumHandler->RestoreSelectedAlbum();
 	iRestoredAlbumIndex = 0;
 	iSelectedAlbumIndex = 0;
-	if ( restoredAlbum )
-		{
-	    TMPXItemId id=restoredAlbum->ValueTObjectL<TMPXItemId>(KMPXMediaGeneralId);
-
-	    for ( TInt i = 0; i < aMediaArray.Count() ; i++ )
-	        {
-	        CMPXMedia* currentMedia( aMediaArray.AtL( i ) );
-
-	        if ( (currentMedia->ValueTObjectL<TMPXItemId>( KMPXMediaGeneralId ) == id) ||
-	             (id.iId1 == 0 && currentMedia->ValueText(KMPXMediaGeneralTitle).Compare( restoredAlbum->ValueText(KMPXMediaGeneralTitle) ) == 0 )  )
-	            {
-	            iRestoredAlbumIndex = i;
-	            iSelectedAlbumIndex = i;
-	            break;
-	            }
-	        }
-		}
+	TMPXItemId id(0);
+	if (!restoredAlbum)
+	    {        
+	    CMPXCollectionPath* cpath = iCollectionUtility->Collection().PathL();
+		CleanupStack::PushL( cpath );
+		id = (cpath->Id());  
+		CleanupStack::PopAndDestroy( cpath ); 
+	    }
+    else
+        {
+        id=restoredAlbum->ValueTObjectL<TMPXItemId>(KMPXMediaGeneralId);   
+        }
+    for ( TInt i = 0; i < aMediaArray.Count() ; i++ )
+        {
+        CMPXMedia* currentMedia( aMediaArray.AtL( i ) );
+
+        if ( (currentMedia->ValueTObjectL<TMPXItemId>( KMPXMediaGeneralId ) == id) ||
+             (id.iId1 == 0 && currentMedia->ValueText(KMPXMediaGeneralTitle).Compare( restoredAlbum->ValueText(KMPXMediaGeneralTitle) ) == 0 )  )
+            {
+            iRestoredAlbumIndex = i;
+            iSelectedAlbumIndex = i;
+            break;
+            }
+        } 
     }
 
 // ----------------------------------------------------------------------------
@@ -5199,6 +5266,10 @@
 			iMediaWall->DrawNow();
 			}
 		}
+	else if ( aType == KMPXNoTransition )  // No transition  
+	    {
+	    iTranstionType = EMPXTranstionNotDefined;
+	    }
 	else // interview transition
 		{
 
--- a/mpxplugins/viewplugins/views/collectionviewhg/src/mpxcollectionviewhgimp.cpp	Thu Jul 15 18:35:42 2010 +0300
+++ b/mpxplugins/viewplugins/views/collectionviewhg/src/mpxcollectionviewhgimp.cpp	Thu Aug 19 09:52:08 2010 +0300
@@ -1094,6 +1094,7 @@
                     {
                     iIsDeleting = ETrue;
                     iCollectionUiHelper->DeleteL( *path, this );
+                    iFirstIndexOnScreen = iContainer->FirstIndexOnScreen();               
                     }
                 else if( iContainer )
                     {
@@ -1270,7 +1271,7 @@
             else if ( ( aIndex > 0 )
                 && ( aIndex < iContainer->CurrentListItemCount() ) )
                 {
-                // No need to do anything here
+				iContainer->SetLbxCurrentItemIndexAndDraw( aIndex );
                 }
             else
                 {
@@ -4287,7 +4288,16 @@
             }
         else
             {
-            UpdateListBoxL( aEntries, aIndex, aComplete );
+            TInt topIndex = aIndex;
+            if ( iFirstIndexOnScreen > 0 )
+                {
+                topIndex = iFirstIndexOnScreen;
+                if ( aComplete )
+                    {
+                    iFirstIndexOnScreen = 0;
+                    }
+                }
+            UpdateListBoxL( aEntries, topIndex, aComplete );            
             }
 #else
         UpdateListBoxL( aEntries, aIndex, aComplete );
@@ -6974,6 +6984,14 @@
         static_cast<CMPXCollectionViewListBoxArray*>(
         iContainer->ListBoxArray() );
 	const CMPXMedia& containerMedia = array->ContainerMedia();
+
+    if ( &containerMedia == NULL )
+        {
+        // If containerMedia is NULL, Dim all options 
+        DimAllOptions(aResourceId, aMenuPane);
+        return; 
+        } 
+		
 	TMPXGeneralType containerType(
 		containerMedia.ValueTObjectL<TMPXGeneralType>( KMPXMediaGeneralType ) );
 	TMPXGeneralCategory containerCategory(
@@ -8476,4 +8494,51 @@
     else
         return EFalse;
     }
+
+void CMPXCollectionViewHgImp::DimAllOptions(TInt aResourceId, CEikMenuPane* aMenuPane)
+    {
+    switch ( aResourceId )
+        {
+        case R_MPX_COLLECTION_VIEW_MENU_1:
+            {
+            aMenuPane->SetItemDimmed( EMPXCmdGoToNowPlaying, ETrue );
+            aMenuPane->SetItemDimmed( EMPXCmdGoToArtistAlbums, ETrue );
+            aMenuPane->SetItemDimmed( EMPXCmdGoToAllSongs, ETrue );
+            aMenuPane->SetItemDimmed( EMPXCmdGoToPlaylists, ETrue );
+            aMenuPane->SetItemDimmed( EMPXCmdGoToGenre, ETrue );
+            aMenuPane->SetItemDimmed( EMPXCmdGoToPodcasts, ETrue );
+            aMenuPane->SetItemDimmed( EMPXCmdGoToMusicShop, ETrue );
+            aMenuPane->SetItemDimmed( EMPXCmdGoToMultipleMusicShop, ETrue );
+            aMenuPane->SetItemDimmed( EMPXCmdMusicLibraryDetails, ETrue );
+            aMenuPane->SetItemDimmed( EMPXCmdRefreshLibrary, ETrue );
+            aMenuPane->SetItemDimmed( EMPXCmdAbout, ETrue );
+            aMenuPane->SetItemDimmed( EMPXCmdFind, ETrue );
+            aMenuPane->SetItemDimmed( EMPXCmdUpnpPlayVia, ETrue );
+            aMenuPane->SetItemDimmed( EMPXCmdUPnPAiwCmdCopyToExternalCriteria, ETrue );
+            aMenuPane->SetItemDimmed( EMPXCmdCreatePlaylist, ETrue );
+            aMenuPane->SetItemDimmed( EMPXCmdAddToPlaylist, ETrue );
+            aMenuPane->SetItemDimmed( EMPXCmdAddSongs, ETrue );
+            aMenuPane->SetItemDimmed( EMPXCmdReorder, ETrue );
+            aMenuPane->SetItemDimmed( EMPXCmdSend, ETrue );
+            aMenuPane->SetItemDimmed( EMPXCmdDelete, ETrue );
+            aMenuPane->SetItemDimmed( EMPXCmdRemove, ETrue );
+            aMenuPane->SetItemDimmed( EMPXCmdPlayItem, ETrue );
+            break;
+            }
+        case R_MPX_COLLECTION_VIEW_MENU_2:
+            {
+            aMenuPane->SetItemDimmed( EMPXCmdRename, ETrue );
+            aMenuPane->SetItemDimmed( EMPXCmdAlbumArt, ETrue );
+            aMenuPane->SetItemDimmed( EMPXCmdFindInMusicShop, ETrue );
+            aMenuPane->SetItemDimmed( EMPXCmdSongDetails, ETrue );
+            aMenuPane->SetItemDimmed( EMPXCmdPlaylistDetails, ETrue );
+            break;
+            }
+        case R_AVKON_MENUPANE_MARKABLE_LIST:
+            {
+            aMenuPane->SetItemDimmed(EAknCmdEditListMenu, ETrue);
+            break;
+            }
+        }    
+    }
 //  End of File
--- a/mpxplugins/viewplugins/views/collectionviewhg/src/mpxcollectionviewhgplaylisthelper.cpp	Thu Jul 15 18:35:42 2010 +0300
+++ b/mpxplugins/viewplugins/views/collectionviewhg/src/mpxcollectionviewhgplaylisthelper.cpp	Thu Aug 19 09:52:08 2010 +0300
@@ -184,7 +184,6 @@
         CMPXCollectionPlaylist* playlist = CMPXCollectionPlaylist::NewL( aPath );
         CleanupStack::PushL( playlist );
 
-        playlist->SetShuffleEnabledL( aEnableShuffle );
         iPlaybackUtility->SetL( EPbPropertyRandomMode, aEnableShuffle );
         iPlaybackUtility->InitL( *playlist, ETrue );
         CleanupStack::PopAndDestroy( playlist );
--- a/mpxplugins/viewplugins/views/commonplaybackview/src/mpxcommonplaybackviewimp.cpp	Thu Jul 15 18:35:42 2010 +0300
+++ b/mpxplugins/viewplugins/views/commonplaybackview/src/mpxcommonplaybackviewimp.cpp	Thu Aug 19 09:52:08 2010 +0300
@@ -113,6 +113,7 @@
 // CONSTANTS
 const TInt KMPXOneSecInMilliSecs( 1000 );
 const TUid KMPXEqualizerViewImplementationId = { 0x101FFC77 };
+const TUid KMPXMetadataEditorDialogImplementationId  = { 0x101FFC83 };
 const TInt KMPXPostponeForHandleDelayedError( 1000000 ); // 1S
 const TInt KMPXPlaybackViewWindowBackground = -1;
 const TInt KMPXDelayForTNRequest( 3000000 ); // 3S
@@ -1632,7 +1633,7 @@
     MPX_DEBUG1("CMPXPlaybackViewImp::HandleErrorL()");
     MPX_DEBUG1("    > Reset New Item Opened Flag");
     iNewItemOpened = EFalse;
-
+    iErrorOccured = EFalse;
     MPX_DEBUG1( "CMPXCommonPlaybackViewImp::HandleErrorL: Exiting");
     }
 
@@ -1981,6 +1982,7 @@
         }
     else if ( aError != KErrNone && iLastPBViewActivated )
         {
+        iErrorOccured = ETrue;
         TRAP_IGNORE( DoHandleErrorPlaybackMessageL( aError ) );
         }
     MPX_DEBUG2("<--CMPXCommonPlaybackViewImp::HandlePlaybackMessage(): aError = %d", aError);
@@ -2172,7 +2174,11 @@
             }
         case EMPXPbvCmdSongDetails:
             {
-            LaunchFileDetailsDialogL();
+            if( !iErrorOccured )
+                {
+                LaunchFileDetailsDialogL();
+                }
+            
             break;
             }
         case EMPXPbvCmdPlay:
@@ -2717,7 +2723,6 @@
                                 {
                                 MPX_DEBUG1( "CMPXCommonPlaybackViewImp::HandleForegroundEventL requesting media" );
                                 RequestMediaL();
-                                UpdateTitlePaneL();
                                 }
                             }
                         }
@@ -2761,6 +2766,12 @@
         {
         case R_MPX_PLAYBACK_VIEW_MENU:
             {
+            if( iErrorOccured ) 
+                {
+                MPX_DEBUG2( "iErrorOccured %d" , iErrorOccured);
+                aMenuPane->SetItemDimmed( EMPXPbvCmdSongDetails, ETrue );
+                }
+            
             if ( iIsffButtonPressed )
                 {
                 iIsffButtonPressed = EFalse;
@@ -3008,7 +3019,8 @@
             // since it'll mess up equilizer's screen
             if ( StatusPane()->CurrentLayoutResId() !=
                  R_AVKON_STATUS_PANE_LAYOUT_USUAL_FLAT &&
-                 activeView != KMPXEqualizerViewImplementationId )
+                 activeView != KMPXEqualizerViewImplementationId && 
+				 activeView != KMPXMetadataEditorDialogImplementationId )
                 {
                 TRAP_IGNORE(
                     StatusPane()->SwitchLayoutL( R_AVKON_STATUS_PANE_LAYOUT_USUAL_FLAT ));
@@ -3067,6 +3079,10 @@
     {
     MPX_FUNC_EX( "CMPXCommonPlaybackViewImp::HandleViewActivation VF" );
     iPBViewToBeActivated = ( KMPXPluginTypePlaybackUid == aCurrentViewType.iUid );
+	if(iPBViewToBeActivated)
+		{
+		HandleLayoutChange();
+		}
     MPX_DEBUG2( "CMPXCommonPlaybackViewImp::HandleViewActivation iPBViewToBeActivated %d", iPBViewToBeActivated );
     }
 // ---------------------------------------------------------------------------
@@ -3926,11 +3942,13 @@
                         if( pausePlayControl )
                         	{
 	                        TMPXPlaybackState state = iPlaybackUtility->StateL();
-	                        if ((state == EPbStateInitialising) || (state == EPbStatePlaying))
+	                        if ( state == EPbStatePlaying )
 	                           {
 	                           pausePlayControl->SetCurrentState(0, ETrue);
 	                           }
-	                        else
+	                        //get EPbStateInitialising when skipping to next, ignore it to remove play/pause key flicker 
+	                        //It is showing the state that was previously shown when EPbStateInitializing
+	                        else if ( state != EPbStateInitialising )
 	                           {
 	                           pausePlayControl->SetCurrentState(1, ETrue);
 	                           }
--- a/mpxplugins/viewplugins/views/embeddedplaybackview/inc/mpxembeddedplaybackview.hlp.hrh	Thu Jul 15 18:35:42 2010 +0300
+++ b/mpxplugins/viewplugins/views/embeddedplaybackview/inc/mpxembeddedplaybackview.hlp.hrh	Thu Aug 19 09:52:08 2010 +0300
@@ -20,8 +20,8 @@
 #ifndef MPXEMBEDDEDPLAYBACKVIEW_HLP_HRH
 #define MPXEMBEDDEDPLAYBACKVIEW_HLP_HRH
 
-_LIT( KMUS_HLP_EMBED_GENERAL, "MUS_HLP_EMBED_GENERAL" );
-_LIT( KMUS_HLP_EMBED_BROWSER, "MUS_HLP_EMBED_BROWSER" );
+_LIT( KMUS_HLP_EMBED_GENERAL, "MUS_HLP_PLAYBACK_VIEW" );
+_LIT( KMUS_HLP_EMBED_BROWSER, "MUS_HLP_PLAYBACK_VIEW" );
 _LIT( KMUS_HLP_EMBED_MESSAGING, "MUS_HLP_PLAYBACK_VIEW" );
 
 #endif  // MPXEMBEDDEDPLAYBACKVIEW_HLP_HRH
--- a/mpxplugins/viewplugins/views/equalizerview/group/bld.inf	Thu Jul 15 18:35:42 2010 +0300
+++ b/mpxplugins/viewplugins/views/equalizerview/group/bld.inf	Thu Aug 19 09:52:08 2010 +0300
@@ -10,6 +10,7 @@
 * Nokia Corporation - initial contribution.
 *
 * Contributors:
+* NTT DOCOMO, INC - BUG 2358
 *
 * Description:  Build information file for project mpxequalizerview.
 *
@@ -22,8 +23,7 @@
 
 PRJ_EXPORTS
 // Empty sound file
-../data/nullsound.mp3 /epoc32/release/winscw/udeb/z/system/data/nullsound.mp3
-../data/nullsound.mp3 /epoc32/data/z/system/data/nullsound.mp3
+../data/nullsound.mp3 z:/system/data/nullsound.mp3
 
 PRJ_MMPFILES
 mpxequalizerview.mmp
--- a/mpxplugins/viewplugins/views/metadataeditordialog/data/mpxmetadataeditordialog.rss	Thu Jul 15 18:35:42 2010 +0300
+++ b/mpxplugins/viewplugins/views/metadataeditordialog/data/mpxmetadataeditordialog.rss	Thu Aug 19 09:52:08 2010 +0300
@@ -313,17 +313,24 @@
             },
         DLG_LINE
             {
-            type = EAknCtPopupField;
+            type = EEikCtEdwin;
             prompt = qtn_nmp_song_details_genre;
             id = EMPXMetadataEditorDlgCtrlIdGenre;
             itemflags = EEikDlgItemTakesEnterKey | EEikDlgItemOfferAllHotKeys;
-            control = POPUP_FIELD
+            control = EDWIN
                 {
-                width = KMPXSongDetailsTextMaxLen;
-               // other = qtn_aknexpopfield_list_other;
+                flags = EEikEdwinNoHorizScrolling | EEikEdwinResizable;
+                width = KMPXSongDetailsTextWidth;
+                lines = KMPXSongDetailsTextLines;
+                maxlength = KMPXSongDetailsTextMaxLen;
+                // added to limit expanding in forms.
+                // If you want full screen use 6 here
+                max_view_height_in_lines = 6;
+                // if you have the line above, you must have this. 
+                // It is calculable from LAF
+                base_line_delta = 21;
                 };
-            tooltip = qtn_aknexpopfield_hint_text;
-            },
+             },
         DLG_LINE
             {
             type = EEikCtEdwin;
@@ -364,20 +371,7 @@
                 base_line_delta = 21;
                 };
             },
-        DLG_LINE
-            {
-            type = EAknCtPopupField;
-            prompt = qtn_nmp_episode_details_library;
-            id = EMPXMetadataEditorDlgCtrlIdLibrary;
-            itemflags = EEikDlgItemTakesEnterKey | EEikDlgItemOfferAllHotKeys;
-            control = POPUP_FIELD
-                {
-                width = KMPXSongDetailsTextMaxLen;
-                // other = qtn_aknexpopfield_list_other;
-                };
-            tooltip = qtn_aknexpopfield_hint_text;
-            },
-	DLG_LINE
+    DLG_LINE
             {
             type = EEikCtEdwin;
             prompt = qtn_nmp_song_details_licences;
@@ -874,16 +868,23 @@
             },
         DLG_LINE
             {
-            type = EAknCtPopupField;
+            type = EEikCtEdwin;
             prompt = qtn_nmp_episode_details_genre;
             id = EMPXMetadataEditorDlgCtrlIdGenre;
             itemflags = EEikDlgItemTakesEnterKey | EEikDlgItemOfferAllHotKeys;
-            control = POPUP_FIELD
+            control = EDWIN
                 {
-                width = KMPXSongDetailsTextMaxLen;
-               // other = qtn_aknexpopfield_list_other;
+                flags = EEikEdwinNoHorizScrolling | EEikEdwinResizable;
+                width = KMPXSongDetailsTextWidth;
+                lines = KMPXSongDetailsTextLines;
+                maxlength = KMPXSongDetailsTextMaxLen;
+                // added to limit expanding in forms.
+                // If you want full screen use 6 here
+                max_view_height_in_lines = 6;
+                // if you have the line above, you must have this. 
+                // It is calculable from LAF
+                base_line_delta = 21;
                 };
-            tooltip = qtn_aknexpopfield_hint_text;
             },                    
         DLG_LINE
             {
@@ -905,19 +906,6 @@
                 base_line_delta = 21;
                 };
             },
-        DLG_LINE
-            {
-            type = EAknCtPopupField;
-            prompt = qtn_nmp_episode_details_library;
-            id = EMPXMetadataEditorDlgCtrlIdLibrary;
-            itemflags = EEikDlgItemTakesEnterKey | EEikDlgItemOfferAllHotKeys;
-            control = POPUP_FIELD
-                {
-                width = KMPXSongDetailsTextMaxLen;
-                // other = qtn_aknexpopfield_list_other;
-                };
-            tooltip = qtn_aknexpopfield_hint_text;
-            },
 	DLG_LINE
             {
             type = EEikCtEdwin;
--- a/mpxplugins/viewplugins/views/metadataeditordialog/src/mpxmetadataeditordialog.cpp	Thu Jul 15 18:35:42 2010 +0300
+++ b/mpxplugins/viewplugins/views/metadataeditordialog/src/mpxmetadataeditordialog.cpp	Thu Aug 19 09:52:08 2010 +0300
@@ -69,13 +69,17 @@
 #include <mpxcollectionplugin.hrh>
 #include <mpxinternalcrkeys.h>
 #include <mpxuser.h>
+#include <drmuihandling.h>
+#include <mpxplaybackutility.h>
+
 #include "mpxcommonuihelper.h"
 #include "mpxmetadataeditordialog.h"
 #include "mpxmetadataeditordialog.hrh"
 #include "mpxmetadataeditordialog.hlp.hrh"
 #include "mpxlog.h"
-#include <drmuihandling.h>
-#include <mpxplaybackutility.h>
+#include <mpxmessagegeneraldefs.h>
+#include <mpxplaybackmessage.h>
+#include <caf/caferr.h>
 
 // CONSTANTS
 const TInt KMPXFileDetailsMaxTitleLen = 32;
@@ -193,6 +197,7 @@
     delete iDrmInfo;
     if ( iPlaybackUtility ) 
         { 
+        iPlaybackUtility->RemoveObserverL( *this ); 
         iPlaybackUtility->CancelRequest(); 
         iPlaybackUtility->Close(); 
         } 
@@ -615,6 +620,10 @@
             SetControlNumberL( EMPXMetadataEditorDlgCtrlIdTrackNumber,
                 iMedia->ValueText( KMPXMediaMusicAlbumTrack ),
                 KMPXSongDetailsTrackNumMin, KMPXSongDetailsTrackNumMax );
+				
+           // Fetch the genre
+           SetControlTextL( EMPXMetadataEditorDlgCtrlIdGenre,
+              iMedia->ValueText( KMPXMediaMusicGenre ), KNullDesC );  
 
             // Fetch the year
             TInt64 year(0);
@@ -625,14 +634,15 @@
             TTime yearTime( year);
             iYear = yearTime.DateTime().Year ( );
             HBufC* yearBuf = HBufC::NewLC ( KMPXMaxTimeLength );
-            yearBuf->Des().AppendNum ( iYear );
+            if ( iYear > 0)
+                {    
+                yearBuf->Des().AppendNum ( iYear );
+                }
             SetControlNumberL ( EMPXMetadataEditorDlgCtrlIdYear, *yearBuf,
                     KMPXSongDetailsYearMin, KMPXSongDetailsYearMax );
             CleanupStack::PopAndDestroy ( yearBuf );
 
-            // Fetch genre
-            FetchGenreL();
-
+           
             // Fetch the comment
             SetControlTextL( EMPXMetadataEditorDlgCtrlIdComment,
                 iMedia->ValueText( KMPXMediaGeneralComment ), KNullDesC );
@@ -2452,6 +2462,7 @@
         {
         // Get the playback utility instance from engine.
         iPlaybackUtility = MMPXPlaybackUtility::UtilityL( KPbModeDefault );
+        iPlaybackUtility->AddObserverL( *this );
         MMPXSource* s = iPlaybackUtility->Source();
         if ( s )
             {
@@ -2471,28 +2482,6 @@
                 CleanupStack::PopAndDestroy( &attrs );
             }  
         }
-    
-
-    // Podcasting is enabled
-    if ( !iDisablePodcasting )
-        {
-        iPopup = static_cast<CAknPopupField*>
-            ( ControlOrNull( EMPXMetadataEditorDlgCtrlIdLibrary ) );
-        iLibraryArr = new (ELeave) CDesCArrayFlat( 1 );
-        HBufC* custTxt = StringLoader::LoadLC( R_MPX_CUI_GENRE_SELECTION_MUSIC_TEXT );
-        iLibraryArr->AppendL( *custTxt );
-        CleanupStack::PopAndDestroy( custTxt );
-        custTxt = StringLoader::LoadLC( R_MPX_CUI_GENRE_SELECTION_PODCAST_TEXT );
-        iLibraryArr->AppendL( *custTxt );
-        CleanupStack::PopAndDestroy( custTxt );
-        iLibraryValueTextArray = CAknQueryValueTextArray::NewL();
-        iLibraryValueTextArray->SetArray( *iLibraryArr );
-        iLibraryTextValues = CAknQueryValueText::NewL();
-        iLibraryTextValues->SetArrayL( iLibraryValueTextArray );
-        iLibraryTextValues->SetCurrentValueIndex( iCurrentLibrary );
-        // Set values into popup fields
-        iPopup->SetQueryValueL( iLibraryTextValues ); // Moved up from below
-        }
     }
 
 // ----------------------------------------------------------------------------
@@ -2508,6 +2497,46 @@
     }
 
 // -----------------------------------------------------------------------------
+// CMPXMetadataEditorDialog::HandlePlaybackMessage
+// Handle playback message.
+// ---------------------------------------------------------------------------
+//
+void CMPXMetadataEditorDialog::HandlePlaybackMessage(
+    CMPXMessage* aMessage, TInt aError )
+    {
+    MPX_DEBUG2 ( "CMPXMetadataEditorDialog::HandlePlaybackMessage aError %d " ,aError );
+    if ( aError == KErrNone && aMessage )
+        {
+        TRAP_IGNORE( DoHandlePlaybackMessageL( *aMessage ) );
+        }
+    else if ( aError != KErrNone )
+        {
+        TryExitL( EAknSoftkeyExit );
+        }
+    }
+
+
+// ---------------------------------------------------------------------------
+// CMPXMetadataEditorDialog::HandlePlaybackMessage
+// Handle playback message.
+// ---------------------------------------------------------------------------
+//
+void CMPXMetadataEditorDialog::DoHandlePlaybackMessageL(
+    const CMPXMessage& aMessage )
+    {
+    MPX_FUNC( "CMPXMetadataEditorDialog::DoHandlePlaybackMessageL(CMPXMessage)" );
+
+    TMPXMessageId id( aMessage.ValueTObjectL<TMPXMessageId>( KMPXMessageGeneralId ) );
+    TInt value = aMessage.ValueTObjectL<TInt>( KMPXMessageGeneralEvent );
+    if ( KMPXMessageGeneral == id && 
+        ( ( value  == TMPXPlaybackMessage::EMediaChanged ) || ( value  == TMPXPlaybackMessage::ESkipping ) ) )
+        {
+        MPX_DEBUG1( "CMPXMetadataEditorDialog::DoHandlePlaybackMessageL Dismissing Details view - change in playing media" );
+        TryExitL( EAknSoftkeyExit );
+        }
+    }
+
+// -----------------------------------------------------------------------------
 // CMPXMetadataEditorDialog::SaveMediaPropertiesL
 // Saves media back to collection engine
 // -----------------------------------------------------------------------------
--- a/mpxplugins/viewplugins/views/waitnotedialog/data/mpxwaitnotedialog.rss	Thu Jul 15 18:35:42 2010 +0300
+++ b/mpxplugins/viewplugins/views/waitnotedialog/data/mpxwaitnotedialog.rss	Thu Aug 19 09:52:08 2010 +0300
@@ -177,6 +177,19 @@
     buf = qtn_nmp_note_usb_connection_in_progress;
     }
 
+
+// -----------------------------------------------------------------------------
+//
+//  r_mpx_mtp_transfer_in_progress
+//  Text for MTP transfer wait note  
+//
+// -----------------------------------------------------------------------------
+//
+RESOURCE TBUF r_mpx_mtp_transfer_in_progress
+    {
+    buf = qtn_mus_note_media_transfer_in_progress;
+    }
+
 // -----------------------------------------------------------------------------
 //
 //  r_mpx_repairing_corrupt_db
--- a/mpxplugins/viewplugins/views/waitnotedialog/src/mpxmtpdialog.cpp	Thu Jul 15 18:35:42 2010 +0300
+++ b/mpxplugins/viewplugins/views/waitnotedialog/src/mpxmtpdialog.cpp	Thu Aug 19 09:52:08 2010 +0300
@@ -82,7 +82,7 @@
     SetCBAL( R_AVKON_SOFTKEYS_EMPTY );
 
     // Text
-    HBufC* text = StringLoader::LoadLC( R_MPX_USB_CONNECTION_IN_PROGRESS );
+    HBufC* text = StringLoader::LoadLC( R_MPX_MTP_TRANSFER_IN_PROGRESS );
     SetTextL( *text );
     CleanupStack::PopAndDestroy( text );
 
--- a/musichomescreen/data/themes/default/install/musicwidget/group/bld.inf	Thu Jul 15 18:35:42 2010 +0300
+++ b/musichomescreen/data/themes/default/install/musicwidget/group/bld.inf	Thu Aug 19 09:52:08 2010 +0300
@@ -10,6 +10,7 @@
 * Nokia Corporation - initial contribution.
 *
 * Contributors:
+* NTT DOCOMO, INC - BUG 2358
 *
 * Description:  The information required for building
 *
@@ -25,23 +26,14 @@
 PRJ_EXPORTS
 // Support for R&D builds
 //***********************
-// For WINSCW UDEB emulator
-../hsps/00/manifest.dat /epoc32/release/winscw/udeb/Z/private/200159c0/install/musicwidget/hsps/00/manifest.dat
-../hsps/00/widgetconfiguration.xml /epoc32/release/winscw/udeb/Z/private/200159c0/install/musicwidget/hsps/00/widgetconfiguration.xml
-../hsps/00/musicwidgetconfiguration.dtd /epoc32/release/winscw/udeb/Z/private/200159c0/install/musicwidget/hsps/00/musicwidgetconfiguration.dtd
-../xuikon/00/musicwidget.o0000 /epoc32/release/winscw/udeb/Z/private/200159c0/install/musicwidget/xuikon/00/musicwidget.o0000
-../xuikon/00/MusicWidget.dat /epoc32/release/winscw/udeb/Z/private/200159c0/install/musicwidget/xuikon/00/MusicWidget.dat
-../xuikon/00/MusicWidget.css /epoc32/release/winscw/udeb/Z/private/200159c0/install/musicwidget/xuikon/00/MusicWidget.css
-../xuikon/00/MusicWidget.xml /epoc32/release/winscw/udeb/Z/private/200159c0/install/musicwidget/xuikon/00/MusicWidget.xml
-
-// For IBY exports (engineering versions)
-../hsps/00/manifest.dat /epoc32/data/Z/private/200159c0/install/musicwidget/hsps/00/manifest.dat
-../hsps/00/widgetconfiguration.xml /epoc32/data/Z/private/200159c0/install/musicwidget/hsps/00/widgetconfiguration.xml
-../hsps/00/musicwidgetconfiguration.dtd /epoc32/data/Z/private/200159c0/install/musicwidget/hsps/00/musicwidgetconfiguration.dtd
-../xuikon/00/musicwidget.o0000 /epoc32/data/Z/private/200159c0/install/musicwidget/xuikon/00/musicwidget.o0000
-../xuikon/00/MusicWidget.dat /epoc32/data/Z/private/200159c0/install/musicwidget/xuikon/00/MusicWidget.dat
-../xuikon/00/MusicWidget.css /epoc32/data/Z/private/200159c0/install/musicwidget/xuikon/00/MusicWidget.css
-../xuikon/00/MusicWidget.xml /epoc32/data/Z/private/200159c0/install/musicwidget/xuikon/00/MusicWidget.xml
+// For WINSCW UDEB emulator & IBY exports (engineering versions)
+../hsps/00/manifest.dat Z:/private/200159c0/install/musicwidget/hsps/00/manifest.dat
+../hsps/00/widgetconfiguration.xml Z:/private/200159c0/install/musicwidget/hsps/00/widgetconfiguration.xml
+../hsps/00/musicwidgetconfiguration.dtd Z:/private/200159c0/install/musicwidget/hsps/00/musicwidgetconfiguration.dtd
+../xuikon/00/musicwidget.o0000 Z:/private/200159c0/install/musicwidget/xuikon/00/musicwidget.o0000
+../xuikon/00/MusicWidget.dat Z:/private/200159c0/install/musicwidget/xuikon/00/MusicWidget.dat
+../xuikon/00/MusicWidget.css Z:/private/200159c0/install/musicwidget/xuikon/00/MusicWidget.css
+../xuikon/00/MusicWidget.xml Z:/private/200159c0/install/musicwidget/xuikon/00/MusicWidget.xml
 
 // Support for productization and Carbide.Ui customization
 //********************************************************
--- a/musichomescreen/group/bld.inf	Thu Jul 15 18:35:42 2010 +0300
+++ b/musichomescreen/group/bld.inf	Thu Aug 19 09:52:08 2010 +0300
@@ -10,6 +10,7 @@
 * Nokia Corporation - initial contribution.
 *
 * Contributors:
+* NTT DOCOMO, INC - BUG 2358
 *
 * Description:  Build information file for MusicHomeScreen.
 *
@@ -30,11 +31,11 @@
 
 
 
-../data/suite.xml /epoc32/release/winscw/udeb/z/private/101F4CD2/import/suites/musicsuite/suite.xml
-../data/music_matrix_items.xml /epoc32/release/winscw/udeb/z/private/101F4CD2/import/suites/musicsuite/music_matrix_items.xml
+../data/suite.xml z:/private/101F4CD2/import/suites/musicsuite/suite.xml
+../data/music_matrix_items.xml z:/private/101F4CD2/import/suites/musicsuite/music_matrix_items.xml
 
-../data/suite.xml /epoc32/data/z/private/101F4CD2/import/suites/musicsuite/suite.xml
-../data/music_matrix_items.xml /epoc32/data/z/private/101F4CD2/import/suites/musicsuite/music_matrix_items.xml
+
+
 
 PRJ_EXTENSIONS
 
--- a/musichomescreen/musiccontentpublisher/src/musiccontentpublisher.cpp	Thu Jul 15 18:35:42 2010 +0300
+++ b/musichomescreen/musiccontentpublisher/src/musiccontentpublisher.cpp	Thu Aug 19 09:52:08 2010 +0300
@@ -140,7 +140,7 @@
     MPX_DEBUG1("CMusicContentPublisher::ConstructL resources loaded");
     
     // connect to the skin server, to receive skin changed event.
-    iAknsSrvSession.Connect(this);
+    User::LeaveIfError(iAknsSrvSession.Connect(this));
     
     // enable skin.
     AknsUtils::InitSkinSupportL();
--- a/musichomescreen_multiview/mcpmusicplayer/src/aiplayerpluginengine.cpp	Thu Jul 15 18:35:42 2010 +0300
+++ b/musichomescreen_multiview/mcpmusicplayer/src/aiplayerpluginengine.cpp	Thu Aug 19 09:52:08 2010 +0300
@@ -382,9 +382,15 @@
             case TMPXPlaybackMessage::EMediaChanged:
             case TMPXPlaybackMessage::EPlaylistUpdated:
                 {
-                iPlaybackUtility->PropertyL( *this, EPbPropertyPosition );
-                iPlaybackUtility->PropertyL( *this, EPbPropertyDuration );
-                RequestMediaL();
+                MMPXSource* s = iPlaybackUtility->Source();
+                if ( s )
+                    {
+                    RequestMediaL();
+                    }
+                else
+                    {
+                    iObserver->PlaylisIsEmpty();
+                    }
                 break;
                 }
             case TMPXPlaybackMessage::ECommandReceived:
@@ -540,9 +546,5 @@
         s->MediaL( attrs.Array(), *this );
         CleanupStack::PopAndDestroy( &attrs );
         }
-    else 
-        {
-        iObserver->PlaylisIsEmpty();
-        }
     }
 //  End of File
--- a/musichomescreen_multiview/mcpmusicplayer/src/mcpmusicplayer.cpp	Thu Jul 15 18:35:42 2010 +0300
+++ b/musichomescreen_multiview/mcpmusicplayer/src/mcpmusicplayer.cpp	Thu Aug 19 09:52:08 2010 +0300
@@ -1085,7 +1085,7 @@
 //  
 void CMCPMusicPlayer::PlaylisIsEmpty()
     {
-    //TRAP_IGNORE( DoHandlePlaylisIsEmptyL() );
+    TRAP_IGNORE( DoHandlePlaylisIsEmptyL() );
     }
 // ---------------------------------------------------------------------------
 // From MAiPlayerPluginEngineObserver
--- a/musichomescreen_multiview/musiccontentpublisher/inc/musiccontentpublisher.h	Thu Jul 15 18:35:42 2010 +0300
+++ b/musichomescreen_multiview/musiccontentpublisher/inc/musiccontentpublisher.h	Thu Aug 19 09:52:08 2010 +0300
@@ -321,6 +321,17 @@
     void DoPublishCmdL(const TDesC8& aCmd, const TDesC8& aKey, const CLiwMap * aValue);
 
     
+	/**
+    * Callback function for CPeriodic.
+    * Defer the creation of MCP plugin to allow the rest of homescreen plugins to be loaded and updated.
+    * This is a temporary solution which shall be replaced with HarvesterServer in Starterlist. 
+	* HarvesterServer shall then do the time consuming initialization of MPX Collection and Playback 
+	* and Harvester servers instead.
+    */
+
+    static TInt UpdateCallback(TAny* aContentPublisher);
+    
+	void DoUpdate();
 
 private: // data
 
@@ -390,6 +401,9 @@
     TBool iWidgetForeground;
 
     HBufC* iInstanceId;
+    
+	// timer to start creating mcpplugin
+    CPeriodic* iUpdateIdle;    
    
     };
 
--- a/musichomescreen_multiview/musiccontentpublisher/src/musiccontentpublisher.cpp	Thu Jul 15 18:35:42 2010 +0300
+++ b/musichomescreen_multiview/musiccontentpublisher/src/musiccontentpublisher.cpp	Thu Aug 19 09:52:08 2010 +0300
@@ -51,6 +51,8 @@
 _LIT8( KMyDeActive, "deactive");
 _LIT8( KMySuspend, "suspend");
 _LIT8( KMyResume, "resume");
+_LIT8( KMyPluginshutdown, "pluginshutdown");
+_LIT8( KMySystemshutdown, "systemshutdown");
 _LIT8( KMyActionMap, "action_map" );
 _LIT8( KMyItem, "item" );
 _LIT8( KMyAdd, "Add" );
@@ -68,6 +70,7 @@
 //for application launcher AHPlugin
 const TInt KMmUid3AsTInt( 0x101f4cd2 );
 const TInt KMSGUidAsTInt( 0x10003A39 );
+const TInt KDelayTime( 6000000 ); // CPeriodic timer
 _LIT8( KAdditionalData, "additional_data" );
 _LIT( KLaunchApp, "launch_application" );
 _LIT( KMessageWithTail, "message_with_tail" );
@@ -147,7 +150,7 @@
     MPX_DEBUG1("CMusicContentPublisher::ConstructL resources loaded");
     
     // connect to the skin server, to receive skin changed event.
-    iAknsSrvSession.Connect(this);
+    User::LeaveIfError(iAknsSrvSession.Connect(this));
     
     // enable skin.
     AknsUtils::InitSkinSupportL();
@@ -178,6 +181,7 @@
     
     MPX_DEBUG1("CMusicContentPublisher::ConstructL initializing content");
     PublishDefaultL();
+    iUpdateIdle = CPeriodic::NewL(CActive::EPriorityStandard);
     
     MPX_DEBUG1("CMusicContentPublisher::ConstructL --->");
     }
@@ -229,6 +233,12 @@
     	{
     	delete iInstanceId;
     	}
+    
+    if ( iUpdateIdle )
+        {
+        iUpdateIdle->Cancel();
+        delete iUpdateIdle;
+        }    
     }
 
 // ---------------------------------------------------------------------------
@@ -801,6 +811,37 @@
         iActivePlugin = aPlugin;
         }
     }
+
+// ---------------------------------------------------------------------------
+// Callback function for CPeriodic.
+// ---------------------------------------------------------------------------
+//   
+TInt CMusicContentPublisher::UpdateCallback(TAny* aContentPublisher)
+    {
+    MPX_FUNC("CMusicContentPublisher::UpdateCallback");
+    
+    CMusicContentPublisher* self = 
+            reinterpret_cast<CMusicContentPublisher*> (aContentPublisher);
+    self->DoUpdate();
+    
+    return EFalse;
+    }
+
+// ---------------------------------------------------------------------------
+// Create plugin manager.
+// ---------------------------------------------------------------------------
+//   
+void CMusicContentPublisher::DoUpdate()
+    {
+    MPX_FUNC("CMusicContentPublisher::DoUpdate")
+    
+    TRAP_IGNORE( iPluginManager = CPluginManager::NewL(
+            TUid::Uid( KMCPPluginUid ), 
+            static_cast<MMCPPluginObserver*>( this ),
+            this ));    
+    iUpdateIdle->Cancel();
+    }
+
 // ---------------------------------------------------------------------------
 // From CContentHarvesterPlugin
 // This function updates information in CPS storage
@@ -809,13 +850,14 @@
 void CMusicContentPublisher::UpdateL() 
     {
     MPX_FUNC("CMusicContentPublisher::UpdateL");
-    if ( !iPluginManager )
+        
+    // Construct plugin manager asynchronously for not to block the caller
+    // thread
+    if ( !iPluginManager && !iUpdateIdle->IsActive())
         {
         MPX_DEBUG1("CMusicContentPublisher::UpdateL creating the plugin manager");
-        iPluginManager = CPluginManager::NewL(
-                TUid::Uid( KMCPPluginUid ), 
-                static_cast<MMCPPluginObserver*>( this ),
-                this );
+        
+        iUpdateIdle->Start(KDelayTime, KDelayTime, TCallBack(UpdateCallback,this));
         }
     }
 
@@ -849,8 +891,7 @@
         }
     else if ( aTrigger ==  KMyDeActive )
         {
-        DoPublishDeleteAllL();
-        delete iInstanceId;
+        delete iInstanceId;  
         iInstanceId = NULL;
         }
     else if ( aTrigger ==  KMySuspend && iWidgetForeground)
@@ -862,6 +903,11 @@
         iWidgetForeground = ETrue;
         DoPublishModifiedL();
         }
+    else if ( aTrigger == KMyPluginshutdown || aTrigger == KMySystemshutdown )
+        {
+        DoPublishDeleteAllL();   // Delete the data only if widget is removed or Phone is shutting down.
+		}
+
     MPX_DEBUG1("<--CMusicContentPublisher::HandlePublisherNotificationL");
     }