shapedrawerlistviewcontainer.h

来自「s60源码」· C头文件 代码 · 共 75 行

H
75
字号
#ifndef __SHAPEDRAWER_LIST_VIEW_CONTAINER_H__
#define __SHAPEDRAWER_LIST_VIEW_CONTAINER_H__

//INCLUDES

//System Includes
#include <coecntrl.h>
#include <aknlists.h>
#include <aknview.h>


//User Includes
#include "ShapeListManager.h"


//FORWARD DECLARATIONS
class	CShapeDrawerDocument;

/**
 *
 * @class	CShapesDrawerListViewContainer ShapeDrawerListViewContainer.h 
 * @brief	This control draws a list representation of the model data for
 * the SHAPEDRAWER example
 *
 * Copyright (c) EMCC Software Ltd 2003
 * @version	1.0 
 */
class CShapeDrawerListViewContainer : public CCoeControl,public MEikListBoxObserver
    {

	class CMyDynamicArray : public MDesCArray
	{
	public:
		virtual ~CMyDynamicArray();
		virtual TInt MdcaCount() const;
		virtual TPtrC MdcaPoint(TInt aIndex) const;
		void SetArray(CDesCArray* aArray);
		CDesCArray* Array();
	private:
		CDesCArray* iArray;
	};

public:
	void RemoveCurrentItemL();
	virtual TInt CountComponentControls() const;
    static CShapeDrawerListViewContainer* NewL(const TRect& aRect, CAknView& aOwningView);
	void HandleListBoxEventL(CEikListBox* , TListBoxEvent) {}
    static CShapeDrawerListViewContainer* NewLC(const TRect& aRect, CAknView& aOwningView);
    ~CShapeDrawerListViewContainer();

  
public:	// from CCoeControl
  TKeyResponse OfferKeyEventL(const TKeyEvent& aKeyEvent,TEventCode aType);

protected:
	virtual CCoeControl* ComponentControl(TInt aIndex) const;

private: 
	void PopulateListBoxFromModelL();
	CShapeListManager* GetModel() const;
    CShapeDrawerListViewContainer(CAknView& aOwningView);

public:
    void ConstructL(const TRect& aRect);

private:
	CAknSingleStyleListBox* iListBox;
	CAknView& iOwningView;
};


#endif // __SHAPEDRAWER_LIST_VIEW_CONTAINER_H__

//End of File

⌨️ 快捷键说明

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