logsui/AppSrc/CLogsBaseView.h
changeset 0 e686773b3f54
child 21 9da50d567e3c
equal deleted inserted replaced
-1:000000000000 0:e686773b3f54
       
     1 /*
       
     2 * Copyright (c) 2002 Nokia Corporation and/or its subsidiary(-ies).
       
     3 * All rights reserved.
       
     4 * This component and the accompanying materials are made available
       
     5 * under the terms of "Eclipse Public License v1.0"
       
     6 * which accompanies this distribution, and is available
       
     7 * at the URL "http://www.eclipse.org/legal/epl-v10.html".
       
     8 *
       
     9 * Initial Contributors:
       
    10 * Nokia Corporation - initial contribution.
       
    11 *
       
    12 * Contributors:
       
    13 *
       
    14 * Description: 
       
    15 *     Logs Application view superclass
       
    16 *
       
    17 */
       
    18 
       
    19 
       
    20 #ifndef     __Logs_App_CLogsBaseView_H__
       
    21 #define     __Logs_App_CLogsBaseView_H__
       
    22 
       
    23 //  INCLUDES
       
    24 #include <aknview.h>
       
    25 #include <eiklbo.h>
       
    26 #include <AiwServiceHandler.h>      //For Application InterWorking
       
    27 #include <AiwPoCParameters.h>
       
    28 #include <MPhCltEmergencyCallObserver.h>
       
    29 #include <aiwdialdata.h>        //NEW, not yet available in wk46 bld
       
    30 #include <akntoolbarobserver.h>    
       
    31 #include <akntoolbar.h>    
       
    32 #include <akninputblock.h>
       
    33 
       
    34 #include "LogsEng.hrh"
       
    35 #include "Logs.hrh"
       
    36 #include "MLogsKeyProcessor.h"
       
    37 #include "MLogsTimer.h"
       
    38 #include "MLogsModel.h" 
       
    39 #include "MLogsObserver.h"
       
    40 
       
    41 #include <MVPbkContactStoreListObserver.h>
       
    42 
       
    43 #include <eikmenub.h>
       
    44 
       
    45 // CONSTANTS
       
    46 
       
    47 // MACROS
       
    48 
       
    49 // DATA TYPES
       
    50 
       
    51 // FUNCTION PROTOTYPES
       
    52 
       
    53 // FORWARD DECLARATIONS
       
    54 class CLogsAppUi;
       
    55 class CLogsEngine;
       
    56 class MLogsReaderConfig;
       
    57 class MLogsEventGetter;
       
    58 class MLogsModel;
       
    59 class CLogsTimer;
       
    60 class TAiwPocParameterData;
       
    61 class CPhCltEmergencyCall;
       
    62 class CSPEntry;
       
    63 
       
    64 // CLASS DECLARATION
       
    65 
       
    66 /**
       
    67  * Logs Application view superclass. Provides some common application view
       
    68  * functionality. Derive application views from this class to use the 
       
    69  * functionality.
       
    70  */
       
    71 class   CLogsBaseView:  public CAknView,
       
    72                         public MEikListBoxObserver,
       
    73                         public MLogsKeyProcessor,
       
    74                         public MAiwNotifyCallback,
       
    75                         public MLogsTimer,
       
    76                         public MAknToolbarObserver,
       
    77                         public MCoeControlObserver,
       
    78                         public MPhCltEmergencyCallObserver,
       
    79                         public MAknInputBlockCancelHandler,
       
    80                         public MCoeViewActivationObserver,
       
    81                         public MLogsObserver
       
    82     {
       
    83     public:
       
    84         /**
       
    85          * Destructor
       
    86          */
       
    87         virtual ~CLogsBaseView();
       
    88 
       
    89     protected:
       
    90         /**
       
    91          * Default constructor
       
    92          */
       
    93         CLogsBaseView();
       
    94         
       
    95         /**
       
    96          * Delayed constructor
       
    97          *
       
    98          * Performs time consuming construction operations once. Calling this is needed before anything
       
    99          * needing objects constructed here can be used (e.g. pressing Send key or launching a command from
       
   100          * ui's menu.        
       
   101          * @param aIdle EFalse: perform immediately, ETrue: perform using idle time
       
   102          */
       
   103         void ConstructDelayedL( TBool aIdle );
       
   104 
       
   105         /**
       
   106          * Hook to catch BaseConstructL calls from derived classes before/after call to super 
       
   107          * class BaseConstructL.
       
   108          *
       
   109          * @param aResId ResourceId of the view to be constructed.
       
   110          */
       
   111         void BaseConstructL(TInt aResId );
       
   112         
       
   113     private:  
       
   114     
       
   115         //Callback function for CIdle object that calls ConstructDelayedL()
       
   116         static TInt ConstructDelayedCallbackL( TAny* aContainer  );
       
   117         
       
   118         
       
   119     public: // From MLogsTimer
       
   120         //Callback function for CLogsTimer 
       
   121         void HandleLogsTimerL( TAny* aPtr );
       
   122             
       
   123     public: // From MAknInputBlockCancelHandler        
       
   124         void AknInputBlockCancel();
       
   125    
       
   126     public: // From MCoeViewActivationObserver
       
   127         
       
   128        /**
       
   129         * The MCoeViewActivationObserver is set when save to pbk AiW command is called.
       
   130         * If then another Logs view is activated while the AiW call is still active, we can 
       
   131         * cancel the AiW call here. 
       
   132         * 
       
   133         * @param aNewlyActivatedViewId      the view that is being activated
       
   134         * @param aViewIdToBeDeactivated     the view that is being deactivated
       
   135         */
       
   136         void HandleViewActivation(const TVwsViewId& aNewlyActivatedViewId,
       
   137                                   const TVwsViewId& aViewIdToBeDeactivated);
       
   138      
       
   139     public: // from MLogsModelObserver
       
   140         void StateChangedL( MLogsStateHolder* aHolder );
       
   141     
       
   142     protected:     
       
   143         
       
   144        /**
       
   145         * Sets the avkon provided input blocker
       
   146         */
       
   147         void SetInputBlockerL();
       
   148         
       
   149        /**
       
   150         * Removes the avkon provided input blocker
       
   151         */
       
   152         void RemoveInputBlocker();
       
   153                
       
   154         enum TLogsPbkFieldType  //Enum used to determine what kind of field to add to Phonebook
       
   155             {
       
   156             ELogsPbkNumberField,
       
   157             ELogsPbkVoipField,
       
   158             ELogsPbkPocField
       
   159             };
       
   160 
       
   161     public:       
       
   162 // Safwish VoIP changes  >>>
       
   163         /**
       
   164          * Returns the SendUi command text.         
       
   165          *
       
   166          * @return SendUi command text.         
       
   167          */
       
   168         const TDesC& SendUiTextL();
       
   169 // <<<  Safwish VoIP changes
       
   170         
       
   171         /**
       
   172          * Returns the Logs Application UI object.
       
   173          *
       
   174          * @return The Logs Application UI
       
   175          */
       
   176         CLogsAppUi* LogsAppUi();
       
   177    
       
   178         /**
       
   179          *  Returns the Logs application's model.
       
   180          *
       
   181          *  @return The current application model.
       
   182          */
       
   183         CLogsEngine* Engine();
       
   184 
       
   185         /**
       
   186          *  Creates a pop up menubar of aResourceId. Runs DoLaunchPopupL
       
   187          *  inside a TRAP.
       
   188          *
       
   189          *  @param aResourceId Resource ID.
       
   190          */
       
   191         void LaunchPopupMenuL( TInt aResourceId );
       
   192         
       
   193 
       
   194         /**
       
   195          * List current index getter
       
   196          *
       
   197          * @return current index
       
   198          */
       
   199         TInt EventListCurrent() const;
       
   200 
       
   201         /**
       
   202          * List top index getter
       
   203          *
       
   204          * @return top index
       
   205          */
       
   206         TInt EventListTop() const;
       
   207 
       
   208         /**
       
   209          * List current index setter
       
   210          *
       
   211          * @param aIndex current index
       
   212          */
       
   213         void SetEventListCurrent( TInt aIndex );
       
   214 
       
   215         /**
       
   216          * List top index setter
       
   217          *
       
   218          * @param aIndex top index
       
   219          */
       
   220         void SetEventListTop( TInt aIndex );
       
   221         
       
   222 	    /**
       
   223          * Getter for recent model
       
   224          *
       
   225          * @return pointer to model
       
   226          */ 
       
   227         MLogsModel* CurrentModel();
       
   228         
       
   229         /**
       
   230           * Checks whether phone number and sip of the log event are equal
       
   231           * 
       
   232           * @return true/false of the above conditional
       
   233           * @param aEvent   
       
   234           */ 
       
   235         TBool PhoneNumberAndSipAreEqual(const MLogsEventGetter* aEvent);
       
   236         
       
   237 	    /**
       
   238          * Checks whether phone number is available
       
   239          *
       
   240          * @param aEvent   
       
   241          */ 
       
   242         TBool PhoneNumberAvailable( const MLogsEventGetter* aEvent );
       
   243 
       
   244 	    /**
       
   245          * Checks whether sip uri is available
       
   246          *
       
   247          * @param aEvent   
       
   248          */ 
       
   249         TBool SipUriAvailable( const MLogsEventGetter* aEvent );
       
   250         
       
   251         /**
       
   252          * Checks wether the options menu needs to be refreshed.
       
   253          */ 
       
   254         void HandleMenuRefreshL(const MLogsEventGetter* aCurrentEvent);
       
   255         
       
   256         /**
       
   257          *  Setter for iRefreshMenubarOnUpdate
       
   258          *
       
   259          *  @param aRefreshMenubar wether the options menu should be refreshed
       
   260          */
       
   261         void SetRefreshMenuOnUpdate(const MLogsEventGetter* aCurrentEvent );
       
   262         
       
   263         /**
       
   264          *  Getter for iRefreshMenubarOnUpdate
       
   265          *
       
   266          *  @return iRefreshMenubarOnUpdate 
       
   267          */
       
   268         TBool RefreshMenuOnUpdate(const MLogsEventGetter* aCurrentEvent);
       
   269         
       
   270        /**
       
   271         *  Change title pane text back to what it was. Base class has no implementation
       
   272         *  child classes override this.
       
   273         */
       
   274         virtual void ChangeTitlePaneTextToDefaultL();
       
   275 
       
   276     public: // From MAiwNotifyCallback
       
   277         TInt HandleNotifyL(
       
   278 		        TInt aCmdId,
       
   279 		        TInt aEventId,
       
   280 		        CAiwGenericParamList& aEventParamList,
       
   281 		        const CAiwGenericParamList& aInParamList);
       
   282 
       
   283     public: // from CAknView
       
   284         void ProcessCommandL( TInt aCommand );
       
   285         void HandleCommandL( TInt aCommandId );
       
   286         
       
   287         /**
       
   288          *  Process send key press when menu is open. For call commands, send key works as 
       
   289          *  if the menu option would have been selected. Default behaviour is not to consume the
       
   290          *  key which causes send key to open dialler. 
       
   291          *
       
   292          *  @param aType         type of key event
       
   293          *  @param aEvent        current event
       
   294          *  
       
   295          *  return ETrue\EFalse  wether the key event was consumed
       
   296          */
       
   297         TBool ProcessSendKeyEventInMenuL(TEventCode aType, const MLogsEventGetter* aEvent);
       
   298         
       
   299     protected: 
       
   300         void DoActivateL(const TVwsViewId& aPrevViewId,TUid aCustomMessageId,const TDesC8& aCustomMessage);
       
   301         void DoDeactivate();
       
   302 
       
   303         // for subclasses to handle commands needing LogEvent data
       
   304         void HandleCommandEventL( TInt aCommandId, const MLogsEventGetter* aEvent );
       
   305 
       
   306     public: // from MLogsKeyProcessor
       
   307         TBool ProcessKeyEventL(const TKeyEvent& aKeyEvent,TEventCode aType);
       
   308         MAknTabObserver* TabObserver();
       
   309         
       
   310     public: // from MCoeForegroundObserver
       
   311 		void HandleGainingForeground();
       
   312 		void HandleLosingForeground();
       
   313 		
       
   314 	public: // from MPhCltEmergencyCallObserver
       
   315         /**
       
   316         * This is called whenever client's dial request is completed.
       
   317         *
       
   318         * @param aStatus error code of the success of the operation.
       
   319         */       
       
   320         void HandleEmergencyDialL( const TInt aStatus );
       
   321         
       
   322 		/**
       
   323          * Default pointer event handler. Called when the current 
       
   324          * focused listbox item is tapped or after a double tap. 
       
   325          * Subclasses override this if needed.
       
   326          *
       
   327          * @param aIndex to the current listbox item  
       
   328          */ 
       
   329         virtual void ProcessPointerEventL( TInt aIndex);
       
   330         // void FocusChangedL();
       
   331         
       
   332     protected: // From MAknToolbarObserver
       
   333         void DynInitToolbarL(TInt aResourceId,
       
   334                 CAknToolbar* aToolbar );
       
   335         void OfferToolbarEventL(TInt aCommand);
       
   336        
       
   337        /**
       
   338         * Wrapper for the leaving version of this function
       
   339         * 
       
   340         * @param aShowToolbar toolbar on/off.
       
   341         */
       
   342         void SetToolbarState(TLogsShowToolbar aShowToolbar, TBool aSetRect);
       
   343         
       
   344        /**
       
   345         * Called from recent lists, details and event list views to
       
   346         * switch toolbar on/off.
       
   347         * 
       
   348         * @param aShowToolbar toolbar on/off.
       
   349         */  
       
   350         void SetToolbarStateL(TLogsShowToolbar aShowToolbar, TBool aSetRect);
       
   351         
       
   352     protected:         
       
   353         void SetToolbarItems( const MLogsEventGetter* aEvent );
       
   354                 
       
   355         //from MCoeControlObserver        
       
   356         void HandleControlEventL(CCoeControl* aControl,TCoeEvent aEventType);        
       
   357         
       
   358     protected: // for subclasses to handle key events needing LogEvent data
       
   359         TBool ProcessKeyEventEventL( const TKeyEvent& aKeyEvent,
       
   360                                      TEventCode aType, 
       
   361                                      const MLogsEventGetter* aEvent );    
       
   362 
       
   363     public: // from MEikMenuObserver
       
   364         void DynInitMenuPaneL( TInt aResourceId, CEikMenuPane* aMenuPane );
       
   365         
       
   366     protected: // for subclasses to call initing parts of menus needing LogEvent data
       
   367         void DynInitMenuPaneEventL( TInt aResourceId,CEikMenuPane* aMenuPane, const MLogsEventGetter* aEvent );
       
   368 
       
   369     protected: 
       
   370         // from MEikListBoxObserver
       
   371         void HandleListBoxEventL( CEikListBox* aListBox, TListBoxEvent aEventType );
       
   372        
       
   373     protected: 
       
   374         TBool IsOkToShowContextMenu( const MLogsEventGetter* aEvent );
       
   375         
       
   376        /**
       
   377         * Update the view rect. Base class implementation empty.
       
   378         */
       
   379         virtual void HandleClientRectChange();
       
   380         
       
   381        /**
       
   382         * Draw the components. Base class implementation empty.
       
   383         */
       
   384         virtual void DrawComponents();
       
   385         
       
   386     private:  // functions
       
   387     
       
   388         //(NEW IMPLEMENTATION) To save some data to Phonebook
       
   389         
       
   390         /**
       
   391          * Save to phonebook function using AIW
       
   392          * 
       
   393          * @param  aCommandId
       
   394          * Command to execute
       
   395          *
       
   396          * @param  aCalledForMenu   
       
   397          * ETrue, if we are ececuting call based on Logs 
       
   398          * menu option. EFalse, if we want the CallUI itself to
       
   399          * display a query (pop-up menu) to user and then act 
       
   400          * accordingly.
       
   401          * 
       
   402          * @param aEvent 
       
   403          * The corresponding log event for the call. 
       
   404          * Provides access to the event data.                  
       
   405          */
       
   406         void CmdSaveToVirtualPhonebookL( TInt aCommandId, 
       
   407                                          TBool aCalledForMenu, 
       
   408                                          const MLogsEventGetter* aEvent );
       
   409     
       
   410         /**
       
   411          * Launch the popup.
       
   412          *
       
   413          * @param aResourceId Resource ID.
       
   414          */
       
   415         void DoLaunchPopupL( TInt aResourceId );
       
   416         
       
   417         /**
       
   418          * Checks if valid service settings for the service id 
       
   419          * are stored in the service table 
       
   420          *
       
   421          * @param aEvent the current logs event
       
   422          */
       
   423         CSPEntry* FindXSPServiceSettingsLC(const MLogsEventGetter* aEvent);
       
   424         
       
   425         
       
   426 ///////////////////////////////////////////////////////////////////////////////////////////////////////////
       
   427 ///////////////////////////////////////////////////////////////////////////////////////////////////////////
       
   428 
       
   429 
       
   430     protected:
       
   431         
       
   432         /**
       
   433          * Clears missed call notifications (Voice, poc...)
       
   434          */
       
   435         void ClearMissedCallNotifications();   //non-leaving wrapper
       
   436         void ClearMissedCallNotificationsL();        
       
   437         
       
   438         void DynInitAiwSaveToPbkMenuPaneL(TInt aResourceId, 
       
   439                                           CEikMenuPane* aMenuPane, 
       
   440                                           const MLogsEventGetter* aEvent,
       
   441                                           TBool aPhoneNumberAvailable,
       
   442                                           TBool aSipUriAvailable );
       
   443 
       
   444     private:          
       
   445         /**
       
   446          * Save AiW call params. Needed if the AiW call is later cancelled, see CancelSaveToPbkL.
       
   447          */
       
   448         void SaveAiwCallParamsL( TInt aCommandId,
       
   449                                  TBool  aCalledForMenu,
       
   450                                  CAiwGenericParamList*  aInParamList);
       
   451         /**
       
   452          * Clear the stored AiW call params when AiW call is finished or cancelled.
       
   453          */
       
   454         void ClearAiwCallParams();
       
   455         
       
   456         /**
       
   457          * Cancel the save to pbk command. Called for example when another Logs view is activated.
       
   458          */
       
   459         void CancelSaveToPbkL();
       
   460                 
       
   461         /**
       
   462          * Initialisation of CallUI menupane (AIW) 
       
   463          * 
       
   464          * @param aResourceId   As in DynInitMenuPaneL
       
   465          * @param aMenuPane     As in DynInitMenuPaneL
       
   466          * @param aVideo,       ETrue: video call selectable, EFalse: voice call only
       
   467          */
       
   468         void DynInitAiwCallUiMenuPaneL( TInt aResourceId, 
       
   469                                         CEikMenuPane* aMenuPane, 
       
   470                                         TBool aVideo,
       
   471                                         const MLogsEventGetter* aEvent );
       
   472                                         
       
   473        /**
       
   474          * Handles runtime variation of __VIDEOCALL_MENU_VISIBILITY feature flag.
       
   475          * Disables or keeps the cascade feature from the menu pane. 
       
   476          * 
       
   477          * @param aMenuPane     As in DynInitMenuPaneL
       
   478          */                                
       
   479         void VideoCallMenuVisibilityL ( CEikMenuPane& aMenuPane ) const;
       
   480 
       
   481         /**
       
   482          * Initialisation of AIW menu contents to menupanes (PoC items to menus) 
       
   483          * 
       
   484          * @param aResourceId   As in DynInitMenuPaneL
       
   485          * @param aMenuPane     As in DynInitMenuPaneL
       
   486          * @param aEvent        Event data         
       
   487          */
       
   488         void DynInitAiwPocMenuPaneL( TInt aResourceId, 
       
   489                                      CEikMenuPane* aMenuPane, 
       
   490                                      const MLogsEventGetter* aEvent );
       
   491                                      
       
   492         /**
       
   493          * Send message 
       
   494          * 
       
   495          * @param aCommandId, sms or mms
       
   496          * @param aEvent
       
   497          */
       
   498         void SendMessageCmdHandlerL( TInt aCommandId, const MLogsEventGetter* aEvent  );
       
   499 
       
   500         /**
       
   501          * Performs Aiw menu command 
       
   502          * 
       
   503          * @param aCommandId     AIW provider's menu command id. 
       
   504          * @param aEvent         
       
   505          */
       
   506         void CmdAiwMenuCmdL( TInt aCommandId, const MLogsEventGetter* aEvent );
       
   507         
       
   508         /**
       
   509          * Performs Aiw service command 
       
   510          * 
       
   511          * @param aCommandId     Logs application's command id.
       
   512          * @param aEvent         
       
   513          */
       
   514         void CmdAiwSrvCmdL( TInt aCommandId, const MLogsEventGetter* aEvent );        
       
   515 
       
   516         /**
       
   517          * Prepares for a PoC call.
       
   518          * 
       
   519          * @param aCommandId 
       
   520          * The selected PoC command from PoC AIW menu (see: AiwPoCParameters.hrh). 
       
   521          * If the call is initiated with PTT-key, KErrNotFound can be used; the 
       
   522          * correct PoC call type is checked automatically from log event data.
       
   523          * (see: MLogsEventData::Type()).
       
   524          *
       
   525          * @param aCalledFromMenu 
       
   526          * ETrue when the PoC command is selected from PoC AIW menu. In case 
       
   527          * the call is made with PTT-key use EFalse and the AIW request is 
       
   528          * made as direct request.
       
   529          *
       
   530          * @param aEvent 
       
   531          * The corresponding log event for the call. 
       
   532          * Provides access to the event data.                  
       
   533          */
       
   534         void PreparePocCallL( TInt aCommandId, 
       
   535                               TBool aCalledForMenu,         
       
   536                               const MLogsEventGetter* aEvent );                  
       
   537 
       
   538         /**
       
   539          * Initialises TAiwPocParameterData
       
   540          */
       
   541         TAiwPocParameterData& InitPocParameterL( TAiwPocParameterData& aPocParameter, 
       
   542                                                  const MLogsEventGetter* aEvent );
       
   543             
       
   544         /**
       
   545          * Performs PoC call.
       
   546          * @param aCommandId 
       
   547          * @param aCalledFromMenu 
       
   548          * @param aParamList 
       
   549          */
       
   550         void CmdPocCallL( TInt aCommandId, 
       
   551                           TBool aCalledForMenu,
       
   552                           CAiwGenericParamList& aParamList );
       
   553             
       
   554         /**
       
   555          * Call function. Performs call using AIW
       
   556          * 
       
   557          * @param  aCommandId       Command to execute
       
   558          * 
       
   559          * @param  aCalledForMenu   
       
   560          * ETrue, if we are executing a call based on Logs 
       
   561          * menu option. EFalse, if we want the CallUI itself to
       
   562          * display a query (pop-up menu, e.g. when Send key pressed) 
       
   563          * to user and then act accordingly.
       
   564          * @param aEvent 
       
   565          * The corresponding log event for the call. 
       
   566          * Provides access to the event data.                  
       
   567          * @param aForceVideo
       
   568          * Forces video call for non-voip events
       
   569          */
       
   570         void PrepareCallL( TInt aCommandId, 
       
   571                            TBool aCalledForMenu,
       
   572                            const MLogsEventGetter* aEvent,
       
   573                            TBool aForceVideo = EFalse );                  
       
   574 
       
   575         /**
       
   576          * Call function. Performs call using AIW
       
   577          * 
       
   578          * @param  aCommandId
       
   579          * Command to execute
       
   580          *
       
   581          * @param  aCalledForMenu   
       
   582          * ETrue, if we are ececuting call based on Logs 
       
   583          * menu option. EFalse, if we want the CallUI itself to
       
   584          * display a query (pop-up menu) to user and then act 
       
   585          * accordingly.
       
   586          * 
       
   587          * @param  aNumberOrUrl 
       
   588          * MSISDN or SIP URI to make call to.
       
   589          * 
       
   590          * @param  aCallType 
       
   591          * Default calltype (voice, video or voip; however 
       
   592          * CallUI can change this).
       
   593          *
       
   594          * @param aEvent 
       
   595          * Used to retrieve the service id from the data field
       
   596          * of the log event.
       
   597          */
       
   598         void CmdCallL( TInt aCommandId, 
       
   599                        TBool aCalledForMenu, 
       
   600                        TPtrC aNumberOrUrl, 
       
   601                        CAiwDialData::TCallType aCallType,                        
       
   602                        const MLogsEventGetter* aEvent );
       
   603 
       
   604         /**
       
   605          * Attempts to initialise AiwGenericParamList for Poc menu and Poc call functions
       
   606          *
       
   607          * @param aEvent,                        In:  Event containing source data
       
   608          * @param aPocParameter,                 In:  PocParameter data 
       
   609          * @param aIsParamListForPocOk,          Out: Retuns ETrue if parameter can be used    
       
   610          * @param aOverrideUsingThis = KNullDesC In:  Use this number/uri preferred instead of what is in aEvent
       
   611          * @param aOverrideIsNumber = EFalse     In:  Type of string in aOverrideUsingThis
       
   612          *
       
   613          * @return CAiwGenericParamList& 
       
   614          */
       
   615         CAiwGenericParamList& GetAiwGenericParamListForPocL(
       
   616             const MLogsEventGetter* aEvent,             //In:  Event containing source data
       
   617             TAiwPocParameterData& aPocParameter,        //In:  PocParameter data 
       
   618             TBool& aIsParamListForPocOk,                //Out: Retuns ETrue if parameter can be used    
       
   619         	const TDesC& aOverrideUsingThis = KNullDesC,//In:  Use this number/uri preferred instead of what is in aEvent
       
   620         	TBool aOverrideIsNumber = EFalse );         //In:  Type of string in aOverrideUsingThis
       
   621                        
       
   622         /**
       
   623          * Copy number / address to clipboard.
       
   624          */
       
   625         void CmdCopyNumberL( const MLogsEventGetter* aEvent );  
       
   626         void CmdCopyAddressL( const MLogsEventGetter* aEvent );        
       
   627 
       
   628         /**
       
   629          * Show sip address
       
   630          */
       
   631         void CmdShowMyAddressL( const MLogsEventGetter* aEvent );
       
   632         
       
   633         /**
       
   634          * Use number / address
       
   635          *  @param    aPreferNumber: If there are both sip-uri and phone number available, prefer number 
       
   636          *                           instead of sip-uri
       
   637          */
       
   638         void CmdPrependCallL( TBool aPreferNumber, const MLogsEventGetter* aEvent );
       
   639 	
       
   640         /**
       
   641          * Performs time consuming construction operations once. 
       
   642          */
       
   643         void DoConstructDelayedL();
       
   644         
       
   645          /**
       
   646          * Get the current menu type 
       
   647          *
       
   648          * @return  the menu type, CEikMenuBar::EMenuOptions or CEikMenuBar::EMenuContext
       
   649          */      
       
   650         CEikMenuBar::TMenuType CurrentMenuType() const;
       
   651         
       
   652          /**
       
   653          * Set the current menu type
       
   654          *
       
   655          * @param   aMenuType the current menu type
       
   656          */
       
   657         void SetCurrentMenuType(CEikMenuBar::TMenuType aMenuType);
       
   658         
       
   659     private:    // data
       
   660 
       
   661         CEikMenuBar* iPopup;
       
   662         
       
   663         /// Ref: reference to singleton instance of CallUI and PoC provider owned by LogsAppUi
       
   664         CAiwServiceHandler* iServHandlerRef;
       
   665         
       
   666         CIdle*              iConstructDelayed;
       
   667         HBufC*              iNumberInPbkProcessing;
       
   668         HBufC*              iUriInPbkProcessing;    
       
   669         TBool               iConstructDelayedOk;   
       
   670         HBufC*              iSendUiText;
       
   671         HBufC*              iAddress;
       
   672         CLogsTimer*         iLogsTimer;
       
   673 
       
   674     protected:  // data
       
   675 
       
   676         enum TLogsFocusChangeControl  
       
   677             {
       
   678             ELogsOkToChange,             //Ok to change focus.
       
   679             ELogsNoChange,               //Do not change focus
       
   680             ELogsNoChange_PbkUpdPending, //Special case as resetting back to normal cannot be indicated reliably (no 
       
   681                                          //way of finding out when reading(re-reading of db is really finished. Works 
       
   682                                          //differently in emulator and hardware as order of needed notifications cannot 
       
   683                                          //be preempted, e.g. HandleGainingForeground may or may not be received before 
       
   684                                          //CLogsBaseView::HandleNotifyL is received. Also the reading of db because of the
       
   685                                          //above may be finished or interrupted depending on the timing of the above)
       
   686             };
       
   687         TLogsFocusChangeControl iFocusChangeControl;                  
       
   688         
       
   689         TLogsModel  iModel;
       
   690         TInt        iEventListCurrent; //Points to current event in normal Logs processing when Logs has not
       
   691                                        //lost foreground and hence has not lost currency in listboxes.
       
   692         TInt        iEventListTop;
       
   693         TBool       iRefreshMenuOnUpdate; 
       
   694         CPhCltEmergencyCall* iEmergencyCallAPI; 
       
   695         CEikMenuBar::TMenuType iMenuType;
       
   696         TInt iPreviousCommand;        
       
   697         TInt iEventUidWhenMenuOpened;
       
   698         CAknInputBlock* iInputBlocker;
       
   699         
       
   700         // AiW call params are needed for possible cancel of the save to pbk command
       
   701         TInt iAiwCommandId;
       
   702         TBool  iAiwCalledFromMenu;
       
   703         TBool  iIsCheckedCntLinkInvaild;
       
   704         CAiwGenericParamList*  iAiwInParamList;
       
   705         // ---------------------------------------------------------------------
       
   706         
       
   707         TLogsShowToolbar iToolBarState;
       
   708         
       
   709         MLogsModel::TDoActivate iResetAndRefreshOnHandleNotify;
       
   710         
       
   711         // EJZO-7RJB3V,When send AIW menu call command with contact link,
       
   712         //ignore the view deactivate and lost foreground operations
       
   713         TBool iIgnoreViewDeactivatedHandling;
       
   714         TBool iSemiFinishViewDeactivatedOperation;
       
   715         
       
   716     };
       
   717 
       
   718 #endif  // __Logs_App_CLogsBaseView_H__
       
   719 
       
   720 // End of File
       
   721