remotestoragefw/gsplugin/inc/rsfwgsplugin.h
branchRCL_3
changeset 20 1aa8c82cb4cb
parent 0 3ad9d5175a89
equal deleted inserted replaced
19:88ee4cf65e19 20:1aa8c82cb4cb
       
     1 /*
       
     2 * Copyright (c) 2005 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:  Rsfw GS plugin, UI(CAknView) interface header
       
    15 *
       
    16 */
       
    17 
       
    18 
       
    19 
       
    20 #ifndef CRSFWGSPLUGIN_H
       
    21 #define CRSFWGSPLUGIN_H
       
    22 
       
    23 // INCLUDES
       
    24 #include <ConeResLoader.h>
       
    25 #include <gsplugininterface.h>
       
    26 #include <aknnotewrappers.h>
       
    27 #include "rsfwgsplugin.hrh"
       
    28 #include "rsfwgsremotedrivesend.h"
       
    29 
       
    30 // CONSTANTS
       
    31 
       
    32 // the drive letter is required in these
       
    33 // resource file
       
    34 _LIT( KRsfwGsPluginResourceFileName, "Z:\\resource\\rsfwgspluginrsc.rsc" );
       
    35 // icons
       
    36 _LIT(KGSPluginBitmapFile,       "Z:\\resource\\apps\\rsfwgsplugin.mif");
       
    37 
       
    38 // FORWARD DECLARATIONS
       
    39 class CRsfwGsPluginDriveListContainer;
       
    40 class CRsfwGsPluginDriveSettingsContainer;
       
    41 class CRsfwMountMan;
       
    42 
       
    43 /**
       
    44 *  CRsfwGsPlugin view class (CAknView).
       
    45 *
       
    46 * This is RSFW GS plugin.
       
    47 */
       
    48 class CRsfwGsPlugin : public CGSPluginInterface
       
    49     {
       
    50     
       
    51     public: // Constructors and destructor
       
    52         
       
    53         /**
       
    54         * Symbian OS two-phased constructor
       
    55         * @return 
       
    56         */
       
    57         static CRsfwGsPlugin* NewL( TAny* aInitParams );
       
    58     
       
    59         /**
       
    60         * Destructor.
       
    61         */
       
    62         ~CRsfwGsPlugin();
       
    63         
       
    64         /**
       
    65         * Load the SettingsView with specified mount entry and type of loading
       
    66         * The types are EEditExisting, ENewDefault, ENewFromExisting
       
    67         */
       
    68         void LoadSettingsViewL(TRsfwSettingsViewType aType, TDesC& aMountName, TBool aAddToViewStack);
       
    69 
       
    70         /**
       
    71         * Loads the Main View where list of remote drives is visible
       
    72         */
       
    73         void LoadMainViewL();
       
    74         
       
    75 		/**
       
    76         * Help launcher method.
       
    77         * @param aContext The help context
       
    78         */
       
    79         void LaunchHelpL( const TDesC& aContext );
       
    80         
       
    81     public: // From CAknView
       
    82         
       
    83         /**
       
    84         * This function is used for identifying the plugin
       
    85         */
       
    86         TUid Id() const;
       
    87         
       
    88         /**
       
    89         * See CAknView
       
    90         */
       
    91         void HandleViewRectChange();
       
    92 
       
    93         /**
       
    94         * See CAknView
       
    95         */
       
    96         void DoActivateL( const TVwsViewId& aPrevViewId,
       
    97                           TUid aCustomMessageId,
       
    98                           const TDesC8& aCustomMessage );
       
    99         /**
       
   100         * See CAknView
       
   101         */
       
   102         void DoDeactivate();
       
   103 
       
   104         /**
       
   105         * See CAknView
       
   106         */
       
   107         void HandleCommandL( TInt aCommand );
       
   108         
       
   109   public:
       
   110         
       
   111         /**
       
   112         * Is the current remote drive connected?
       
   113         * Fetches the information from RFE
       
   114         */
       
   115         TBool IsDriveConnectedL();
       
   116         
       
   117         /**
       
   118         * Update softkeys
       
   119         */
       
   120         void UpdateCbaL();
       
   121         
       
   122         /**
       
   123         * This function deletes the current remote drive.
       
   124         */
       
   125         void DeleteRemoteDriveL();
       
   126         
       
   127         /**
       
   128         * Return the currently active container
       
   129         */   
       
   130         CCoeControl* CurrentContainer();
       
   131         
       
   132         /**
       
   133         * Process the existed deleting dialog
       
   134         */   
       
   135         void ProcessDeletingDialog();
       
   136 
       
   137     protected:
       
   138 
       
   139         /**
       
   140         * C++ default constructor.
       
   141         */
       
   142         CRsfwGsPlugin( );
       
   143 
       
   144         /**
       
   145         * Symbian OS default constructor.
       
   146         */
       
   147         void ConstructL();
       
   148         
       
   149     private:
       
   150     
       
   151         /**
       
   152         * See base classes
       
   153         */
       
   154         void DynInitMenuPaneL(TInt aResourceId,CEikMenuPane* aMenuPane);
       
   155         
       
   156        
       
   157         /**
       
   158         * Connect he current remote drive
       
   159         */
       
   160         void ConnectRemoteDriveL();
       
   161 
       
   162         /**
       
   163         * Disconnect he current remote drive
       
   164         */
       
   165         void DisconnectRemoteDriveL();
       
   166         
       
   167         
       
   168         /**
       
   169         * Sends a link to the current remote drive as a smart message
       
   170         */
       
   171         void SendLinkL();
       
   172         
       
   173         
       
   174         /**
       
   175         * Process "Send As"
       
   176         */
       
   177         void DoSendAsL();
       
   178         
       
   179  
       
   180     public: // From CGSPluginInterface
       
   181     
       
   182         /**
       
   183         * See CGSPluginInterface
       
   184         */
       
   185         void GetCaptionL( TDes& aCaption ) const;
       
   186         
       
   187         /**
       
   188         * See CGSPluginInterface
       
   189         */
       
   190         CGulIcon* CreateIconL( const TUid aIconType );
       
   191     
       
   192     public:    
       
   193         
       
   194         void HandleResourceChangeManual(TInt aType);
       
   195         
       
   196     protected: //Data        
       
   197         
       
   198         // Reference to application UI - not owned.
       
   199         CAknViewAppUi* iAppUi;
       
   200         
       
   201         // RConeResourceLoader
       
   202         RConeResourceLoader iResources;
       
   203         
       
   204         // Previous View ID
       
   205         TVwsViewId iPrevViewId; // Previous view.
       
   206         
       
   207     private:
       
   208     
       
   209         // Pointer to the main list container - owned
       
   210         CRsfwGsPluginDriveListContainer* iMainListContainer;
       
   211         
       
   212         // Pointer to the setting list container - owned.
       
   213         CRsfwGsPluginDriveSettingsContainer* iSettingListContainer;
       
   214         
       
   215         // Pointer to the model - owned
       
   216         CRsfwMountMan*  iMountMan;
       
   217         
       
   218         // Pointer to the current container - not owned.
       
   219         CCoeControl* iCurrentContainer;   
       
   220         
       
   221         // for sending remote drive links - owned
       
   222         CRsfwGsRemoteDriveSend*	iSender;
       
   223         
       
   224         // Pointer to the possible deleting dialog
       
   225         CAknQueryDialog* iDialog;
       
   226         
       
   227         // The deleting id of remote drive
       
   228         TChar iDeletingId;
       
   229     };
       
   230   
       
   231 
       
   232 
       
   233 #endif // CRSFWGSPLUGIN_H
       
   234 
       
   235 // End of File