📄 heatmeter2container.h
字号:
/*
* ============================================================================
* Name : CHeatMeter2Container from HeatMeter2Container.h
* Part of : HeatMeter2
* Created : 2004.03.27. by
* Description:
* Declares container control for application.
* Version :
* Copyright:
* ============================================================================
*/
#ifndef HEATMETER2CONTAINER_H
#define HEATMETER2CONTAINER_H
// INCLUDES
#include <coecntrl.h>
#include <aknglobalnote.h>
#include "database.h"
// FORWARD DECLARATIONS
class CEikLabel; // for example labels
class CEikTextListBox;
class CDataBase;
// CLASS DECLARATION
/**
* CHeatMeter2Container container control class.
*
*/
class CHeatMeter2Container : public CCoeControl, public MCoeControlObserver, public MContainerObserver
{
public: // Constructors and destructor
/**
* EPOC default constructor.
* @param aRect Frame rectangle for container.
*/
void ConstructL(const TRect& aRect);
TKeyResponse OfferKeyEventL(const TKeyEvent& aKeyEvent,TEventCode aType);
/**
* Destructor.
*/
~CHeatMeter2Container();
public: // New functions
public: // Functions from base classes
//start the synchronising operation
void Synch();
//edit the value of the selected heatmeter state
void EditCurrentValue();
//called when synch is finished succesfully
void SynchReady();
//called when an error occured while synching
void SynchFailed(TInt aReason);
//called to update the listbox with data from database
void FillListBox();
private: // Functions from base classes
/**
* From CoeControl,SizeChanged.
*/
void SizeChanged();
/**
* From CoeControl,CountComponentControls.
*/
TInt CountComponentControls() const;
/**
* From CCoeControl,ComponentControl.
*/
CCoeControl* ComponentControl(TInt aIndex) const;
/**
* From CCoeControl,Draw.
*/
void Draw(const TRect& aRect) const;
/**
* From MCoeControlObserver
* Acts upon changes in the hosted control's state.
*
* @param aControl The control changing its state
* @param aEventType The type of control event
*/
void HandleControlEventL(CCoeControl* aControl,TCoeEvent aEventType);
public:
CDataBase *iHeatMeterDatabase;
TInetAddr iServerAddr;
private: //data
void DestroyGlobalNote();
void NewGlobalNote(TPtrC aNoteText);
CEikLabel* iLabel; // example label
//CEikLabel* iToDoLabel; // example label
CEikTextListBox* iListBox;
CAknGlobalNote *iGlobalNote;
TInt iPermanentNoteId;
CArrayFixFlat<TInt> *iValues;
CArrayFixFlat<TInt> *iIDs;
CDesCArray* iItemArray;
};
#endif
// End of File
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -