S60 3rd Edition SDK for Symbian OS
Example Applications Guide

ChatAppui.h

00001 /*
00002 * ==============================================================================
00003 *  Name        : ChatAppui.h
00004 *  Part of     : Chat
00005 *  Interface   : 
00006 *  Description : 
00007 *  Version     : 
00008 *
00009 *  Copyright (c) 2005-2006 Nokia Corporation.
00010 *  This material, including documentation and any related 
00011 *  computer programs, is protected by copyright controlled by 
00012 *  Nokia Corporation.
00013 * ==============================================================================
00014 */
00015 
00016 #ifndef CHATAPPUI_H
00017 #define CHATAPPUI_H
00018 
00019 // INCLUDES
00020 #include <aknappui.h>
00021 
00022 // FORWARD DECLARATIONS
00023 class CChatContainer;
00024 class CChatBt;
00025 class CChatInet;
00026 
00027 // CLASS DECLARATION
00028 
00029 /**
00030 * Application UI class.
00031 * Provides support for the following features:
00032 * - EIKON control architecture
00033 * 
00034 */
00035 class CChatAppUi : public CAknAppUi
00036     {
00037     public: // Constructors and destructor
00038 
00039         /**
00040         * default constructor.
00041         */      
00042         void ConstructL();
00043 
00044         /**
00045         * Destructor.
00046         */      
00047         ~CChatAppUi();
00048         
00049     public: // New functions
00050 
00051     public: // Functions from base classes
00052 
00053     private:  // From MEikMenuObserver
00054         
00055         void DynInitMenuPaneL( TInt aResourceId,CEikMenuPane* aMenuPane );
00056 
00057     private:
00058 
00059         /**
00060         * From CEikAppUi, takes care of command handling.
00061         * @param aCommand command to be handled
00062         */
00063         void HandleCommandL( TInt aCommand );
00064 
00065         /**
00066         * From CEikAppUi, handles key events.
00067         * @param aKeyEvent Event to handled.
00068         * @param aType Type of the key event. 
00069         * @return Response code (EKeyWasConsumed, EKeyWasNotConsumed). 
00070         */
00071         virtual TKeyResponse HandleKeyEventL(
00072             const TKeyEvent& aKeyEvent,TEventCode aType );
00073             
00074         /**
00075         * From CEikAppUi, handles key events.
00076         * @param aType The type of resources that have changed
00077         */    
00078         virtual void HandleResourceChangeL( TInt aType );  
00079       
00080         /**
00081         *  ShowBTNotAvailableNoteL.
00082         *  Show note if BT is not available
00083         */
00084       void ShowBTNotAvailableNoteL();
00085 
00086     
00087     private: // Data
00088     
00089         CChatContainer* iAppContainer; 
00090 
00091         /** 
00092         * iClient
00093         * the BT chat engine 
00094         * Owned by CChatAppUi
00095         */
00096         CChatBt* iChatBt;
00097         
00098         /** 
00099         * iClientInet
00100         * the TCPIP chat engine 
00101         * Owned by CChatAppUi
00102         */        
00103         CChatInet* iChatInet;
00104 
00105         /**
00106         * iBtAvailable, ETrue if an SDP session can be opened, EFalse otherwise.
00107         */
00108         TBool iBtAvailable;        
00109     };
00110 
00111 #endif // CHATAPPUI_H
00112 
00113 // End of File

© Nokia 2006

Back to top