ipsservices/ipssosplugin/inc/ipsplgeventhandler.h
changeset 20 ecc8def7944a
parent 18 578830873419
child 23 2dc6caa42ec3
equal deleted inserted replaced
18:578830873419 20:ecc8def7944a
    88  *  @since
    88  *  @since
    89  */
    89  */
    90 NONSHARABLE_CLASS ( CIpsPlgEventHandler ) : public CBase,
    90 NONSHARABLE_CLASS ( CIpsPlgEventHandler ) : public CBase,
    91                             public MMsvSessionObserver,
    91                             public MMsvSessionObserver,
    92                             public MIpsPlgSettingsObserverCallback,
    92                             public MIpsPlgSettingsObserverCallback,
    93                             public MIpsPlgPropertyObserver,
    93                             public MIpsPlgPropertyObserver
    94                             public MFSMailExceptionEventCallback
    94 // <qmail> not needed       public MFSMailExceptionEventCallback
    95     {
    95     {
    96 
    96 //public://from MFSMailExceptionEventCallback
    97 public://from MFSMailExceptionEventCallback
    97 //
    98 
    98 //    void ExceptionEventCallbackL( TFSMailMsgId aMailboxId, TInt aEventType, TBool aResponse );
    99     void ExceptionEventCallbackL( TFSMailMsgId aMailboxId, TInt aEventType, TBool aResponse );
    99 // </qmail>
   100 
   100 
   101 public: //from MIpsPlgPropertyObserver
   101 public: //from MIpsPlgPropertyObserver
   102     void HandlePropertyEventL(
   102     void HandlePropertyEventL(
   103             TInt aEvent, TInt aMailbox, TInt aPluginId, TInt aError );
   103             TInt aEvent, TInt aMailbox, TInt aPluginId, TInt aError );
   104 
   104 
   194      * Used by CIpsPlgPropetyWatcher active object
   194      * Used by CIpsPlgPropetyWatcher active object
   195      * @param aEvent property event
   195      * @param aEvent property event
   196      */
   196      */
   197     void NotifyPropertyEventL( TIpsPlgPropertyEvent aEvent );
   197     void NotifyPropertyEventL( TIpsPlgPropertyEvent aEvent );
   198 
   198 
   199     /**
   199     // <qmail> removing unused functions
   200      * used to inform ui offline state if connection attempt
   200     //    void SignalMailboxOfflineStateL( const TFSMailMsgId& aAccount );
   201      * was not successfull
   201     //    void QueryUsrPassL( TMsvId aMbox, MIpsPlgConnectOpCallback* aCallback=NULL );
   202      * @param aAccount FS mailbox id
   202     //    void SignalCredientialsSetL( TInt aMailboxId, TBool aCancelled );
   203      */
   203     // </qmail>
   204     void SignalMailboxOfflineStateL( const TFSMailMsgId& aAccount );
       
   205 
       
   206     /**
       
   207      * Send user password query request to fs email ui
       
   208      * @param aMbox entry id of mailbox service
       
   209      * @param aCallback callback interface to connection operation, defaut NULL
       
   210      */
       
   211     void QueryUsrPassL( TMsvId aMbox, MIpsPlgConnectOpCallback* aCallback=NULL );
       
   212 
       
   213     /**
       
   214      * Send user password (=credentials) set signal to all plugin
       
   215      * instances via p&s (property) mechanism
       
   216      * @param aMailboxId entry id of mailbox
       
   217      * @param aCancelled indicates is user cancelled password dialog
       
   218      */
       
   219     void SignalCredientialsSetL( TInt aMailboxId, TBool aCancelled );
       
   220 
       
   221 private:
   204 private:
   222 
   205 
   223     /**
   206     /**
   224     * Checks the source type of event and also
   207     * Checks the source type of event and also
   225     * checks is the event from IPS type  ( imap/pop ) entry
   208     * checks is the event from IPS type  ( imap/pop ) entry
   358         const TMsvEmailEntry& aParent,
   341         const TMsvEmailEntry& aParent,
   359         const CMsvEntrySelection& aDeletedIds,
   342         const CMsvEntrySelection& aDeletedIds,
   360         TFSMailMsgId& aFSParent,
   343         TFSMailMsgId& aFSParent,
   361         RArray<TFSMailMsgId>& aFSDeletedArray );
   344         RArray<TFSMailMsgId>& aFSDeletedArray );
   362 
   345 
   363 
   346     // <qmail> does nothing; removing
   364     /**
   347     //    void SaveSyncStatusL( TMsvId aMailboxId, TInt aState );
   365     * Saves last signalled sync status to settings
       
   366     */
       
   367     void SaveSyncStatusL( TMsvId aMailboxId, TInt aState );
       
   368 
   348 
   369     /**
   349     /**
   370     * Appends folder id to array if not already in there
   350     * Appends folder id to array if not already in there
   371     */
   351     */
   372     void SetFolderIdToArrayL( TMsvId aNewId );
   352     void SetFolderIdToArrayL( TMsvId aNewId );
   410     inline void FillFSMessageArray(
   390     inline void FillFSMessageArray(
   411             RArray<TFSMailMsgId>& aFSArray,
   391             RArray<TFSMailMsgId>& aFSArray,
   412             const CMsvEntrySelection* aSelection,
   392             const CMsvEntrySelection* aSelection,
   413             TUint aMtmUid );
   393             TUint aMtmUid );
   414 
   394 
       
   395     // <qmail> new function
       
   396     /**
       
   397      * Convert sync operation completion code to email framework's syncState
       
   398      * @param aStatus
       
   399      * @return syncstate
       
   400      */
       
   401     TSSMailSyncState ConvertCompletionCode( TInt aCompletionCode );
       
   402     // </qmail>
       
   403     
   415     CRepository*                            iCenRep;
   404     CRepository*                            iCenRep;
   416 
   405 
   417     // not owned
   406     // not owned
   418     CMsvSession*                            iSession;
   407     CMsvSession*                            iSession;
   419 
   408 
   439     TPckgBuf<TIpsPlgPropertyEvent>          iPropertyBuf;
   428     TPckgBuf<TIpsPlgPropertyEvent>          iPropertyBuf;
   440 
   429 
   441     // base plugin id
   430     // base plugin id
   442     TUint                                   iPluginId;
   431     TUint                                   iPluginId;
   443 
   432 
   444     //not owned
   433     // <qmail> MIpsPlgConnectOpCallback not used any more
   445     MIpsPlgConnectOpCallback*               iConnOpCallback;
       
   446 
   434 
   447     RArray<TMsvId>                          iImapFolderIds;
   435     RArray<TMsvId>                          iImapFolderIds;
   448 
   436 
   449     };
   437     };
   450 
   438