📄 exerciselistbox.h
字号:
/*
========================================================================
Name : ExerciseListBox.h
Author :
Copyright : Your copyright notice
Description :
========================================================================
*/
#ifndef EXERCISELISTBOX_H
#define EXERCISELISTBOX_H
// [[[ begin generated region: do not modify [Generated Includes]
#include <coecntrl.h>
// ]]] end generated region [Generated Includes]
// [[[ begin [Event Handler Includes]
// ]]] end [Event Handler Includes]
// [[[ begin generated region: do not modify [Generated Forward Declarations]
class MEikCommandObserver;
class CAknSingleStyleListBox;
class CEikTextListBox;
// ]]] end generated region [Generated Forward Declarations]
/**
* Container class for ExerciseListBox
*
* @class CExerciseListBox ExerciseListBox.h
*/
class CExerciseListBox : public CCoeControl
{
public:
// constructors and destructor
CExerciseListBox();
static CExerciseListBox* NewL(
const TRect& aRect,
const CCoeControl* aParent,
MEikCommandObserver* aCommandObserver );
static CExerciseListBox* NewLC(
const TRect& aRect,
const CCoeControl* aParent,
MEikCommandObserver* aCommandObserver );
void ConstructL(
const TRect& aRect,
const CCoeControl* aParent,
MEikCommandObserver* aCommandObserver );
virtual ~CExerciseListBox();
public:
// from base class CCoeControl
TInt CountComponentControls() const;
CCoeControl* ComponentControl( TInt aIndex ) const;
TKeyResponse OfferKeyEventL(
const TKeyEvent& aKeyEvent,
TEventCode aType );
void HandleResourceChange( TInt aType );
protected:
// from base class CCoeControl
void SizeChanged();
private:
// from base class CCoeControl
void Draw( const TRect& aRect ) const;
private:
void InitializeControlsL();
void LayoutControls();
CCoeControl* iFocusControl;
MEikCommandObserver* iCommandObserver;
// [[[ begin generated region: do not modify [Generated Methods]
public:
static void AddListBoxItemL(
CEikTextListBox* aListBox,
const TDesC& aString );
static RArray< TInt >* GetSelectedListBoxItemsLC( CEikTextListBox* aListBox );
static void DeleteSelectedListBoxItemsL( CEikTextListBox* aListBox );
CAknSingleStyleListBox* ListBox();
static void CreateListBoxItemL( TDes& aBuffer,
const TDesC& aMainText );
void AddListBoxResourceArrayItemL( TInt aResourceId );
void SetupListBoxIconsL();
TBool HandleMarkableListCommandL( TInt aCommand );
// ]]] end generated region [Generated Methods]
// [[[ begin generated region: do not modify [Generated Type Declarations]
public:
// ]]] end generated region [Generated Type Declarations]
void RunAddListItemL(TBuf<100>& aName);
void RunDeleteItemL();
// [[[ begin generated region: do not modify [Generated Instance Variables]
private:
CAknSingleStyleListBox* iListBox;
// ]]] end generated region [Generated Instance Variables]
// [[[ begin [Overridden Methods]
protected:
// ]]] end [Overridden Methods]
// [[[ begin [User Handlers]
protected:
// ]]] end [User Handlers]
public:
enum TControls
{
// [[[ begin generated region: do not modify [Generated Contents]
EListBox,
// ]]] end generated region [Generated Contents]
// add any user-defined entries here...
ELastControl
};
enum TListBoxImages
{
// [[[ begin generated region: do not modify [Generated Enums]
EListBoxFirstUserImageIndex
// ]]] end generated region [Generated Enums]
};
};
#endif // EXERCISELISTBOX_H
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -