diff -r ecf06a08d4d9 -r 2c5162224003 mpserviceplugins/mpxsqlitedbhgplugin/src/mpxdbartist.cpp --- a/mpserviceplugins/mpxsqlitedbhgplugin/src/mpxdbartist.cpp Mon May 03 12:29:20 2010 +0300 +++ b/mpserviceplugins/mpxsqlitedbhgplugin/src/mpxdbartist.cpp Fri Apr 30 19:33:32 2010 -0500 @@ -86,7 +86,7 @@ CMPXDbManager& aDbManager, TMPXGeneralCategory aCategory, MMPXDbArtistObserver& aObserver) : - CMPXDbCategory(aDbManager, aCategory), + CMPXDbCategory(aDbManager, aCategory), iObserver(aObserver) { MPX_FUNC("CMPXDbArtist::CMPXDbArtist"); @@ -122,7 +122,7 @@ aNewRecord = !CategoryItemExistsL(aDriveId, rowId); if (aNewRecord) - { + { // insert new HBufC* query = PreProcessStringLC(KQueryArtistInsert); HBufC* name = MPXDbCommonUtil::ProcessSingleQuotesLC(aName); @@ -141,18 +141,18 @@ query = PreProcessStringLC(KQueryCategoryItem); RSqlStatement recordset(iDbManager.ExecuteSelectQueryL(*query, rowId)); CleanupStack::PopAndDestroy(query); - + CleanupClosePushL(recordset); - + if (recordset.Next() != KSqlAtRow) { User::Leave(KErrNotFound); } - + // Album Art TPtrC art(KNullDesC); art.Set(MPXDbCommonUtil::GetColumnTextL(recordset, EArtistArt)); - + // the current one is Unknown and the new one is Not Unknown if ( art == KNullDesC && aArt != KNullDesC ) { @@ -166,9 +166,9 @@ CleanupStack::PopAndDestroy(setStr); CleanupStack::PopAndDestroy(artReplaceSingleQuote); } - + CleanupStack::PopAndDestroy(&recordset); - + // increment the number of songs for the category query = PreProcessStringLC(KQueryCategoryIncrementSongCount); iDbManager.ExecuteQueryL(aDriveId, *query, rowId); @@ -185,16 +185,16 @@ TBool CMPXDbArtist::IsUnknownArtistL(TUint32 aId) { MPX_FUNC("CMPXDbArtist::IsUnknownArtistL"); - + HBufC* name = GetNameL(aId); - + TInt ret = EFalse; if (*name == KNullDesC) { ret = ETrue; } delete name; - + return ret; } @@ -220,7 +220,7 @@ if (attributeId & EMPXMediaGeneralId) { MPX_DEBUG1(" EMPXMediaGeneralId"); - + aMedia.SetTObjectValueL(KMPXMediaGeneralId, aRecord.ColumnInt64(EArtistUniqueId)); MPX_DEBUG2(" Id[%d]", aRecord.ColumnInt64(EArtistUniqueId)); @@ -228,7 +228,7 @@ if (attributeId & EMPXMediaGeneralTitle) { MPX_DEBUG1(" EMPXMediaGeneralTitle"); - + TPtrC artist( MPXDbCommonUtil::GetColumnTextL(aRecord, EArtistName) ); aMedia.SetTextValueL(KMPXMediaGeneralTitle, MPXDbCommonUtil::GetColumnTextL(aRecord, EArtistName)); @@ -245,7 +245,7 @@ TInt songCount = GetSongsCountL( KDbManagerAllDrives, aRecord.ColumnInt64( EArtistUniqueId ) ); aMedia.SetTObjectValueL(KMPXMediaGeneralCount, songCount); // mod by anjokela - + MPX_DEBUG1(" EMPXMediaGeneralCount"); MPX_DEBUG2(" SongCount[%d]", songCount); } @@ -255,7 +255,7 @@ if (attributeId & EMPXMediaMusicAlbumArtFileName) { MPX_DEBUG1(" EMPXMediaMusicAlbumArtFileName"); - TPtrC art(KNullDesC); + TPtrC art(KNullDesC); art.Set(MPXDbCommonUtil::GetColumnTextL(aRecord, EArtistArt)); aMedia.SetTextValueL(KMPXMediaMusicAlbumArtFileName, art); MPX_DEBUG2(" Art[%S]", &art); @@ -279,7 +279,7 @@ MPXDbCommonUtil::AppendValueL(aFields, aValues, KMCMusicArt, albumArtFilename); } } - + // ---------------------------------------------------------------------------- // CMPXDbArtist::GetAlbumsCountL // ---------------------------------------------------------------------------- @@ -287,14 +287,14 @@ TInt CMPXDbArtist::GetAlbumsCountL(TUint32 aId) { MPX_FUNC("CMPXDbArtist::GetAlbumsCountL"); - + return iObserver.HandleGetAlbumsCountForArtistL(aId); } - + // ---------------------------------------------------------------------------- // CMPXDbArtist::GetAllCategoryItemsL // ---------------------------------------------------------------------------- -// +// void CMPXDbArtist::GetAllCategoryItemsL( const TArray& aAttrs, CMPXMediaArray& aMediaArray) @@ -313,9 +313,9 @@ // ---------------------------------------------------------------------------- // void CMPXDbArtist::UpdateItemL( - TUint32 aId, - const CMPXMedia& aMedia, - TInt aDriveId, + TUint32 aId, + const CMPXMedia& aMedia, + TInt aDriveId, CMPXMessageArray* aItemChangedMessages) { MPX_FUNC("CMPXDbAlbum::UpdateItemL");