coreapplicationuis/accfwuinotifier/inc/AccFwUiNoteNotifier.h
changeset 0 2e3d3ce01487
child 21 c4cbaa4fb734
child 62 924385140d98
equal deleted inserted replaced
-1:000000000000 0:2e3d3ce01487
       
     1 /*
       
     2 * Copyright (c) 2002-2009 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:  Implementation of accessory UI note notifier.
       
    15 *
       
    16 */
       
    17 
       
    18 
       
    19 #ifndef __CACCFWUINOTENOTIFIER_H
       
    20 #define __CACCFWUINOTENOTIFIER_H
       
    21 
       
    22 // INCLUDES
       
    23 #include <e32std.h>
       
    24 #include <e32base.h>
       
    25 #include <eiknotapi.h>
       
    26 
       
    27 // CONSTANTS
       
    28 const TUid KAccFwUiNoteNotifierUid = { 0x10205061 };
       
    29 
       
    30 // FUNCTION PROTOTYPES
       
    31 CArrayPtr<MEikSrvNotifierBase2>* NotifierArray();
       
    32 
       
    33 // FORWARD DECLARATIONS
       
    34 class CCoeEnv;
       
    35 class CAknNoteDialog;
       
    36 
       
    37 // CLASS DECLARATION
       
    38 /**
       
    39 *  Displays information note about connected accessory
       
    40 *  
       
    41 *  @lib accfwuinotifier.lib
       
    42 *  @since S60 3.1
       
    43 */
       
    44 class CAccFwUiNoteNotifier : public CActive, public MEikSrvNotifierBase2
       
    45     {
       
    46     public:  // Constructors and destructor
       
    47 
       
    48         static CAccFwUiNoteNotifier* NewL();	                    
       
    49         
       
    50         ~CAccFwUiNoteNotifier();
       
    51         
       
    52     public: 
       
    53             
       
    54         // From MEikSrvNotifierBase2
       
    55             
       
    56         void Release();
       
    57 
       
    58         TNotifierInfo RegisterL();
       
    59 
       
    60         TNotifierInfo Info() const;
       
    61 
       
    62         TPtrC8 StartL( const TDesC8& aBuffer );
       
    63 
       
    64         void StartL( const TDesC8& aBuffer, TInt aReplySlot, const RMessagePtr2& aMessage );
       
    65 
       
    66         void Cancel();
       
    67 
       
    68         TPtrC8 UpdateL( const TDesC8& aBuffer );
       
    69 
       
    70 		// From CActive
       
    71 	
       
    72 		void RunL();
       
    73         TInt RunError(TInt aError);
       
    74 		void DoCancel();
       
    75                 
       
    76     private: // Functions
       
    77 
       
    78         /**
       
    79         * C++ default constructor.
       
    80         */
       
    81         CAccFwUiNoteNotifier();
       
    82 
       
    83         /**
       
    84         * By default Symbian 2nd phase constructor is private.
       
    85         */
       
    86         void ConstructL();
       
    87 	
       
    88     private:    // Data
       
    89 	
       
    90 	    // Notifier info    
       
    91         TNotifierInfo iInfo;
       
    92         // not owned
       
    93         CCoeEnv* iCoeEnv;
       
    94         //resource file offset
       
    95         TInt iResourceFileOffset;
       
    96 		// Message to complete
       
    97 		RMessagePtr2 iMessage;
       
    98         // Indication whether notifier cancelled
       
    99         TBool iIsCancelled;
       
   100 	    // Note
       
   101         CAknNoteDialog* iNote;
       
   102 	    // Indication whether to show not supported note in cover display
       
   103         TBool iPublishNote;
       
   104 	    // Text to show in note
       
   105         HBufC* iNoteText;
       
   106 
       
   107     };
       
   108 
       
   109 #endif      // __CACCFWUINOTENOTIFIER_H
       
   110 
       
   111 // End of File