📄 videocontainer.h
字号:
/*
* ============================================================================
* Name : VideoContainer.h
* Part of : Video
* Created : 10/14/2003 by Forum Nokia
* Description:
* Declares container control for application.
* Version :
* Copyright: Forum Corporation, 2003
* ============================================================================
*/
#ifndef VIDEOCONTAINER_H
#define VIDEOCONTAINER_H
#include <coecntrl.h>
#include <coemain.h>
class CAknDoubleNumberStyleListBox;
class CDesC16ArrayFlat;
class CDesC16Array;
class CFileListEngine;
class CEikButtonGroupContainer;
/**
* CVideoContainer
* Container control class.
*/
class CVideoContainer : public CCoeControl, MCoeControlObserver
{
public: // Constructors and destructor
/**
* Symbian default constructor.
* @param aRect Frame rectangle for container.
*/
void ConstructL(const TRect& aRect);
/**
* Destructor.
*/
~CVideoContainer();
public: // New functions
/**
* Return Containers RWindow
*/
inline RWindow& ClientWindow();
/**
* Return TRect of the video area
*/
inline TRect VideoRect() const;
/**
* Return Containers RWsSession
*/
inline RWsSession& ClientWsSession();
/**
* Return Containers CWsScreenDevice
*/
inline CWsScreenDevice& ScreenDevice();
/**
* Get the total number of items in the list box
*/
TInt GetNumOfItemsInListBox();
/**
* Get the current video file name in the list box
* @param aFileName output to hold the selected video file name
*/
void GetCurrentVideoFileNameL(TDes &aFileName);
public: // Functions from base classes
/**
* See CCoeControl::OfferKeyEventL()
*/
TKeyResponse OfferKeyEventL(const TKeyEvent& aKeyEvent,TEventCode aType);
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);
private:
/**
* Set the File list
*/
void SetFileList(TInt aDirectory, TInt aSizeDate);
private: //data
TRect iVideoRect;
CAknDoubleNumberStyleListBox* iListBox;
CFileListEngine* iFileListEngine;
CEikButtonGroupContainer* iCba;
};
/*
-----------------------------------------------------------------------------
inline RWindow& CVideoContainer::ClientWindow()
Description: Returns client window handle
Comments :
Return values: Returns client window handle
-----------------------------------------------------------------------------
*/
inline RWindow& CVideoContainer::ClientWindow()
{
return Window();
}
/*
-----------------------------------------------------------------------------
inline TRect CVideoContainer::VideoRect() const
Description: Returns video area
Comments :
Return values: Returns video area
-----------------------------------------------------------------------------
*/
inline TRect CVideoContainer::VideoRect() const
{
return iVideoRect;
}
/*
-----------------------------------------------------------------------------
inline RWsSession& CVideoContainer::ClientWsSession()
Description: Returns client WsSession
Comments :
Return values: Returns client WsSession
-----------------------------------------------------------------------------
*/
inline RWsSession& CVideoContainer::ClientWsSession()
{
return ControlEnv()->WsSession();
}
/*
-----------------------------------------------------------------------------
inline CWsScreenDevice& CVideoContainer::ScreenDevice()
Description: Returns client ScreenDevice
Comments :
Return values: Returns client ScreenDevice
-----------------------------------------------------------------------------
*/
inline CWsScreenDevice& CVideoContainer::ScreenDevice()
{
return *(ControlEnv()->ScreenDevice());
}
#endif
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -