equal
deleted
inserted
replaced
21 #include <f32file.h> |
21 #include <f32file.h> |
22 #include <bautils.h> |
22 #include <bautils.h> |
23 #include <e32const.h> |
23 #include <e32const.h> |
24 |
24 |
25 #include <mtp/mmtpdataproviderframework.h> |
25 #include <mtp/mmtpdataproviderframework.h> |
26 |
|
27 #include <mtp/cmtpobjectmetadata.h> |
26 #include <mtp/cmtpobjectmetadata.h> |
28 #include <mtp/cmtptypefile.h> |
27 #include <mtp/cmtptypefile.h> |
29 #include <mtp/cmtptypeobjectinfo.h> |
28 #include <mtp/cmtptypeobjectinfo.h> |
30 #include <mtp/cmtptypeobjectproplist.h> |
29 #include <mtp/cmtptypeobjectproplist.h> |
31 #include <mtp/cmtptypestring.h> |
30 #include <mtp/cmtptypestring.h> |
513 { |
512 { |
514 __FLOG(_L8("CMTPImageDpSendObjectInfo::ServiceSendObjectL - Entry")); |
513 __FLOG(_L8("CMTPImageDpSendObjectInfo::ServiceSendObjectL - Entry")); |
515 |
514 |
516 iFramework.ObjectMgr().CommitReservedObjectHandleL(*iReceivedObject); |
515 iFramework.ObjectMgr().CommitReservedObjectHandleL(*iReceivedObject); |
517 //prepare for rollback |
516 //prepare for rollback |
518 iRollbackList.Append(RemoveObjectFromDb); |
517 iRollbackList.AppendL(RemoveObjectFromDb); |
519 |
518 |
520 ReceiveDataL(*iFileReceived); |
519 ReceiveDataL(*iFileReceived); |
521 |
520 |
522 __FLOG(_L8("CMTPImageDpSendObjectInfo::ServiceSendObjectL - Exit")); |
521 __FLOG(_L8("CMTPImageDpSendObjectInfo::ServiceSendObjectL - Exit")); |
523 return ETrue; |
522 return ETrue; |
1194 iReceivedObject->SetUint(CMTPObjectMetaData::EFormatSubCode, objectStatusBitmask);//mark object imported due to it sent by PC |
1193 iReceivedObject->SetUint(CMTPObjectMetaData::EFormatSubCode, objectStatusBitmask);//mark object imported due to it sent by PC |
1195 iReceivedObject->SetUint(CMTPObjectMetaData::EStorageId, iStorageId); |
1194 iReceivedObject->SetUint(CMTPObjectMetaData::EStorageId, iStorageId); |
1196 iFramework.ObjectMgr().ReserveObjectHandleL(*iReceivedObject, iObjectSize); |
1195 iFramework.ObjectMgr().ReserveObjectHandleL(*iReceivedObject, iObjectSize); |
1197 |
1196 |
1198 // prepare for rollback |
1197 // prepare for rollback |
1199 iRollbackList.Append(UnreserveObject); |
1198 iRollbackList.AppendL(UnreserveObject); |
1200 __FLOG(_L8("CMTPImageDpSendObjectInfo::ReserveObjectL - Exit")); |
1199 __FLOG(_L8("CMTPImageDpSendObjectInfo::ReserveObjectL - Exit")); |
1201 } |
1200 } |
1202 |
1201 |
1203 /** |
1202 /** |
1204 Sets the read only status on the current file to match the sent object. |
1203 Sets the read only status on the current file to match the sent object. |
1255 void CMTPImageDpSendObjectInfo::CreateFsObjectL() |
1254 void CMTPImageDpSendObjectInfo::CreateFsObjectL() |
1256 { |
1255 { |
1257 delete iFileReceived; |
1256 delete iFileReceived; |
1258 iFileReceived = NULL; |
1257 iFileReceived = NULL; |
1259 //prepare for rollback |
1258 //prepare for rollback |
1260 iRollbackList.Append(RemoveObjectFromFs); |
1259 iRollbackList.AppendL(RemoveObjectFromFs); |
1261 |
1260 |
1262 iFileReceived = CMTPTypeFile::NewL(iFramework.Fs(), iFullPath, EFileWrite); |
1261 iFileReceived = CMTPTypeFile::NewL(iFramework.Fs(), iFullPath, EFileWrite); |
1263 iFileReceived->SetSizeL(iObjectSize); |
1262 iFileReceived->SetSizeL(iObjectSize); |
1264 } |
1263 } |
1265 |
1264 |