mtpdataproviders/mtpimagedp/src/cmtpimagedpsendobjectinfo.cpp
changeset 17 aabe5387f5ce
parent 0 d0791faffa3f
child 14 60a94a45d437
--- a/mtpdataproviders/mtpimagedp/src/cmtpimagedpsendobjectinfo.cpp	Tue Feb 02 01:11:40 2010 +0200
+++ b/mtpdataproviders/mtpimagedp/src/cmtpimagedpsendobjectinfo.cpp	Fri Mar 19 09:40:39 2010 +0200
@@ -848,7 +848,7 @@
     if (err != KErrNone)
         {
         //add Suid to deleteobjectlist
-        iDataProvider.AppendDeleteObjectsArrayL(iFullPath);
+        TRAP_IGNORE(iDataProvider.AppendDeleteObjectsArrayL(iFullPath));
         }
     }
 
@@ -1166,6 +1166,12 @@
             responseCode = EMTPRespCodeInvalidObjectPropFormat;
             }
         break;
+    case EMTPObjectPropCodeRepresentativeSampleData:
+        if (aElement.Uint16L(CMTPTypeObjectPropListElement::EDatatype) != EMTPTypeAUINT8)
+            {
+            responseCode = EMTPRespCodeInvalidObjectPropFormat;
+            }        
+        break;
     case EMTPObjectPropCodeNonConsumable:
         if (aElement.Uint16L(CMTPTypeObjectPropListElement::EDatatype) != EMTPTypeUINT8)
             {
@@ -1188,7 +1194,9 @@
 void CMTPImageDpSendObjectInfo::ReserveObjectL()
     {
     __FLOG(_L8("CMTPImageDpSendObjectInfo::ReserveObjectL - Entry"));
-
+    const TInt objectStatusBitmask = 0x8000;//the most significant bit represents importing flag
+    
+    iReceivedObject->SetUint(CMTPObjectMetaData::EFormatSubCode, objectStatusBitmask);//mark object imported due to it sent by PC
     iReceivedObject->SetUint(CMTPObjectMetaData::EStorageId, iStorageId);    
     iFramework.ObjectMgr().ReserveObjectHandleL(*iReceivedObject, iObjectSize);