mtpdataproviders/mtpimagedp/src/mtpimagedputilits.cpp
branchRCL_3
changeset 19 ef55b168cedb
parent 11 4843bb5893b6
child 23 f5809cfbf6d5
equal deleted inserted replaced
16:3673b591050c 19:ef55b168cedb
    62     aFramework.Fs().CharToDrive(drive[0], driveNumber);
    62     aFramework.Fs().CharToDrive(drive[0], driveNumber);
    63     
    63     
    64     return aFramework.StorageMgr().FrameworkStorageId(static_cast<TDriveNumber>(driveNumber));
    64     return aFramework.StorageMgr().FrameworkStorageId(static_cast<TDriveNumber>(driveNumber));
    65     }
    65     }
    66 
    66 
    67 TUint32 MTPImageDpUtilits::FindParentHandleL(MMTPDataProviderFramework& aFramework, CMTPImageDataProvider& aDataProvider, const TDesC& aFullPath)
    67 TUint32 MTPImageDpUtilits::FindParentHandleL(MMTPDataProviderFramework& aFramework, CMTPImageDataProvider& /*aDataProvider*/, const TDesC& aFullPath)
    68     {
    68     {
    69     TUint32 parentHandle = KMTPHandleNoParent;
    69     TUint32 parentHandle = KMTPHandleNoParent;
    70     TParsePtrC parse(aFullPath);
    70     TParsePtrC parse(aFullPath);
    71     
    71     
    72     if(!parse.IsRoot())
    72     if(!parse.IsRoot())
    73         {   
    73         {
    74         if (!aDataProvider.GetCacheParentHandle(parse.DriveAndPath(), parentHandle))
    74         parentHandle = aFramework.ObjectMgr().HandleL(parse.DriveAndPath());
    75             {
       
    76             parentHandle = aFramework.ObjectMgr().HandleL(parse.DriveAndPath());
       
    77             if (parentHandle != KMTPHandleNone)
       
    78                 {
       
    79                 aDataProvider.SetCacheParentHandle(parse.DriveAndPath(), parentHandle);                
       
    80                 }
       
    81             }
       
    82         }
    75         }
    83     
    76     
    84     return parentHandle;    
    77     return parentHandle;
    85     }
    78     }
    86 
    79 
    87 TBool MTPImageDpUtilits::IsNewPicture(const CMTPObjectMetaData& aMetadata)
    80 TBool MTPImageDpUtilits::IsNewPicture(const CMTPObjectMetaData& aMetadata)
    88     {
    81     {
    89     /**
    82     /**