aknexsettinglistview.h

来自「symbian ui的 例子 初学者可以 好好看看,这个是培训的资料,应该比较宝」· C头文件 代码 · 共 176 行

H
176
字号
/* Copyright (c) 2005, Nokia. All rights reserved */


#ifndef __AKNEXSETTINGLISTVIEW_H__
#define __AKNEXSETTINGLISTVIEW_H__



// INCLUDES
#include <aknview.h>

// CONSTANTS
 // UID of View.
const TUid KViewId = { 1 };
const TInt KAknExSettingListTitleBufLength = 256;
const TInt KAknExSettingListInitial = 0;



// FORWARD DECLARATIONS
class CAknExSettingListContainer;
class CAknExSettingListListbox;
class CAknExSettingListItemData;


// CLASS DECLARATION
/**
* CAknExSettingListView view class.
*/
class CAknExSettingListView : public CAknView
    {
    public: // Constructors and destructor
        
        
        static CAknExSettingListView* NewL();
        static CAknExSettingListView* NewLC();

        /**
        * ~CAknExSettingListView
        * Virtual Destructor.
        */
        virtual ~CAknExSettingListView();



    public: // New function

        /**
        * DisplayNextOutlineL
        * Requires to display next outline screen.
        */
        void DisplayNextOutlineL();


        /**
        * DisplayNextOutlineL
        * Requires to display Previous outline screen.
        */
        void DisplayPreviousOutlineL();


        /**
        * SetCurrentOutlineId
        * Set iCurrentOutline
        * @param  aOutlineId ID of current outline
        */
        void SetCurrentOutlineId( const TInt aOutlineId );

    public: // From CAknView

        /**
        * Id
        * Returns the ID of view.
        * @return The ID of view.
        */
        TUid Id() const;


        /**
        * HandleCommandL.
        * handles the commands. if the command is command which is require to
        * display outline-screen, the command is reported to container class.
        * @param aCommand Command to be handled.
        */
        void HandleCommandL( TInt aCommand );

        /**
        * CurrentOutlineId
        * Returns current outline id
        * @return current outline id
        */
        TInt CurrentOutlineId();


    private: // New functions

        /**
        * IndicateTitlePaneTextL
        * Sets text on title pane by ID of resource.
        * @param aCommand Command selected in menu.
        */
        void IndicateTitlePaneTextL( const TInt aCommand );

        /**
        * SwapContainerL
        * Swaps container window
        * @param bActiveContainer Becames container
        */
        void SwapContainerL( TBool aActiveContainer );


        /**
        * CreateListBoxL
        * Creates ListBox
        * @param aResourceId for ListBox initialization
        */
        void CreateListBoxL( TInt aResourceId );


    private: // From CAknView

        /**
        * CAknExSettingListView
        * C++ default constructor.
        */
        CAknExSettingListView();
        void ConstructL();

        /**
        * DoActivateL.
        * Creates the Container class object.
        * @param aPrevViewId aPrevViewId is not used.
        * @param aCustomMessageId aCustomMessageId is not used.
        * @param aCustomMessage aCustomMessage is not used.
        */
        void DoActivateL( const TVwsViewId& aPrevViewId,
                          TUid aCustomMessageId,
                          const TDesC8& aCustomMessage );


        /**
        * DoDeactivate.
        * Deletes the Container class object.
        */
        void DoDeactivate();

    private: // Data

        /**
        * iContainer
        * owned by CAknExSettingListView object.
        */  
        CAknExSettingListContainer*     iContainer;

        /**
        * iListBox
        * owned by CAknExSettingListView object.
        */ 
        CAknExSettingListListbox*       iListBox;

        /**
        * iData
        * owned by CAknExSettingListView object.
        */ 
        CAknExSettingListItemData*      iData;


        TBool iActiveContainer;
        TInt iCurrentOutlineId;

    };

#endif //__AKNEXSETTINGLISTVIEW_H__

// End of File

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?