⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 symbian4container.h

📁 S60 3版 音乐播放器及进度条实现 功能:前后倒放歌曲及暂停等功能
💻 H
字号:
/*
============================================================================
Name        : CSymbian4Container from Symbian3Container.h
Author      : 
Version     :
Copyright   : Your copyright notice
Description : Declares container control for application.
============================================================================
*/

#ifndef SYMBIAN3CONTAINER_H
#define SYMBIAN3CONTAINER_H

// INCLUDES
#include <coecntrl.h>
#include "MyStone.h"
// FORWARD DECLARATIONS

class MAknsControlContext; // for skins support
class MEikCommandObserver;		
class CEikLabel;        // for example labels
class CEikProgressInfo; //进度条

// CLASS DECLARATION

/**
*  CSymbian4Container  container control class.
*  
*/
class CSymbian4Container : public CCoeControl, MCoeControlObserver
{
public: // Constructors and destructor

	/**
	* EPOC default constructor.
	* @param aRect Frame rectangle for container.
	*/

	CSymbian4Container();

	void ConstructL(const TRect& aRect);

	/**
	* Destructor.
	*/
	~CSymbian4Container();

public: // New functions

	void MakeProcessBar();

	void StartTimer();
	void ReStartProgressBar();   

	void	GetInfo();

	inline const CMyStone::TState& State() const;

public: // Functions from base classes

	static TInt Period(TAny* aPtr);

	void DoStep();

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:

	TKeyResponse OfferKeyEventL( 
		const TKeyEvent& aKeyEvent, 
		TEventCode aType );

private: //data

	TBool	   iReDraw;
	CEikProgressInfo*   iPBar;
	CPeriodic* iPeriodicTimer;

	CEikLabel* iLabel;          // example label
	CEikLabel* iToDoLabel;      // example label
	CEikLabel* iNumView;
	CEikLabel* iNameView;


	CMyStone*  iMyStone;
	// [[[ begin [Overridden Methods]
	CDesCArrayFlat* iArrayFlat; //接收UI中播放列表数组

	TInt iIndex;  //记录当前播放序号

	TTimeIntervalMicroSeconds iLastPosition;//存储时间

	TInt 	   iFlag;

	TBool     ibool;
	TInt64      ilength;
	TInt64      slow;

	TBuf<40> iNameofsong;
	TBuf<10> iNumofsong;
	TBuf<20> iNameofsinger;
	TBuf<40> iNextsong;
	TBuf<10> iTime;
	TBuf<10> iStartTime;

};

const CMyStone::TState& CSymbian4Container::State() const    { return iMyStone->State(); }				


#endif


⌨️ 快捷键说明

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