diff -r 19bd632b5100 -r b72428996822 btobexprofiles/obexreceiveservices/bip/inc/BIPController.h --- a/btobexprofiles/obexreceiveservices/bip/inc/BIPController.h Fri May 28 17:03:06 2010 +0300 +++ b/btobexprofiles/obexreceiveservices/bip/inc/BIPController.h Mon Jul 12 18:51:05 2010 +0300 @@ -24,22 +24,33 @@ #include #include #include -#include -#include #include "obexutilspropertynotifier.h" #include "debug.h" #include #include -#include #include #include "btengdevman.h" #include +#include +#include // FORWARD DECLARATIONS class CBIPCapabilityHandler; class CBIPImageHandler; +/** +* Backup status. +* The value is controlled by FileManager +*/ +enum TFileManagerBkupStatusType + { + EFileManagerBkupStatusUnset = 0x00000000, + EFileManagerBkupStatusBackup = 0x00000001, + EFileManagerBkupStatusRestore = 0x00000002 + }; + +const TUid KUidMsgTypeBt = {0x10009ED5}; // CLASS DECLARATION @@ -48,8 +59,9 @@ */ NONSHARABLE_CLASS (CBIPController): public CSrcsInterface, public MObexServerNotify, public MObexUtilsPropertyNotifyHandler, - public MGlobalProgressCallback, public MGlobalNoteCallback, - public MBTEngDevManObserver + public MObexUtilsDialogObserver, + public MBTEngDevManObserver, + public MHbDeviceDialogObserver { public: static CBIPController* NewL(); @@ -78,15 +90,13 @@ private: // from MObexUtilsPropertyNotifyHandler void HandleNotifyL(TMemoryPropertyCheckType aCheckType); -private: // from MGlobalProgressCallback - void HandleGlobalProgressDialogL(TInt aSoftkey); - -private: // from MGlobalNoteCallback - void HandleGlobalNoteDialogL(TInt aSoftkey); private: // from MBTEngDevManObserver void HandleGetDevicesComplete(TInt aErr, CBTDeviceArray* aDeviceArray); +private: //from MObexUtilsDialogObserver + void DialogDismissed(TInt aButtonId); + private: CBIPController(); void ConstructL(); @@ -101,10 +111,16 @@ TBool CheckCapacityL(); void LaunchReceivingIndicatorL(); - inline TBool ReceivingIndicatorActive() const { return (iProgressDialog || iWaitDialog); } - void UpdateReceivingIndicator(); + inline TBool ReceivingIndicatorActive() const { return (iDialogActive); } + void UpdateReceivingIndicatorL(); void CloseReceivingIndicator(TBool aResetDisplayedState = ETrue); TInt GetDriveWithMaximumFreeSpaceL(); + TBool IsBackupRunning(); + TBool ProcessExists( const TSecureId& aSecureId ); + +private: + void DataReceived(CHbSymbianVariantMap& aData); + void DeviceDialogClosed(TInt aCompletionCode); private: enum TBipTransferState @@ -117,6 +133,7 @@ ETransferPutCancel, }; + private: // Data CBIPCapabilityHandler* iBIPCapabilityHandler; CObexBufObject* iBTObject; @@ -138,14 +155,16 @@ CBufFlat *iBuf; TBool iLengthHeaderReceived; TInt iTotalSizeByte; - CGlobalProgressDialog* iProgressDialog; - CGlobalDialog* iWaitDialog; TBool iNoteDisplayed; CBTEngDevMan* iDevMan; CBTDeviceArray* iResultArray; TBTDeviceName iRemoteDeviceName; TFileName iReceivingFileName; TFileName iCenRepFolder; + CObexUtilsDialog* iDialog; + CHbDeviceDialogSymbian* iProgressDialog; + TBool iDialogActive; + TInt iFileCount; }; _LIT(KBipPanicCategory, "BIP");