chxavplayviewwindow.h
来自「symbian 下的helix player源代码」· C头文件 代码 · 共 141 行
H
141 行
/************************************************************************
* chxavplayviewwindow.h
* ---------------------
*
* Synopsis:
* Contains the declaration of the CHXAvPlayViewWindow class. This class
* handles the play/pause/stop buttons.
*
* Target:
* Symbian OS
*
*
* (c) 1995-2003 RealNetworks, Inc. Patents pending. All rights reserved.
*
************************************************************************/
#ifndef _chxavplayviewwindow_h
#define _chxavplayviewwindow_h
// Symbian includes...
#include <coecntrl.h>
// Helix includes...
// Includes from this project...
#include "chxbody.h"
#include "chxavplayer.h"
#include "chxsmartptr.h"
#include "ihxsymplayerstateobserver.h"
// Forward declarations...
class CHXAvViewBase;
class CHXAvPlayerUI;
class CHXAvPlayView;
// CHXAvPresentationWindow declaration...
class CHXAvPresentationWindow :
public CCoeControl,
public IHXSymPlayerStateObserver,
public CHXBody
{
public:
friend class CHXAvPlayViewWindow;
public:
CHXAvPresentationWindow();
virtual ~CHXAvPresentationWindow();
void ConstructL(CCoeControl *parent, CHXAvPlayerUI *playerUI, const TRect& rc);
// CCoeControl overrides
CCoeControl* ComponentControl( TInt aIndex ) const { return NULL; }
TInt CountComponentControls() const { return 0; }
void Draw(const TRect& aRect) const;
TKeyResponse OfferKeyEventL(const TKeyEvent& aKeyEvent,TEventCode aType);
private:
// IHXSymPlayerStateObserver
void OnPlayInitiate(const char* url);
void OnLoadSession(IHXRequest* request);
void OnStop();
// Helpers
void LoadLogoItems();
void SetBackgroundItems(const TDesC& fileName, TInt idxLogo, TInt idxAudioIcon);
CCoeControl *m_parent;
CHXAvPlayerUI *m_playerUI;
CFbsBitmap m_logo;
CFbsBitmap m_audioIcon;
bool m_bLastClipPlayedHadVideo;
bool m_bShowLogo;
bool m_bShowAudioIcon;
};
typedef CHXSmartPtr<CHXAvPresentationWindow> CHXAvPresentationWindowPtr;
// CHXAvFileViewWindow declaration...
class CHXAvPlayViewWindow :
public CCoeControl,
public IHXSymPlayerStateObserver,
public CHXBody
{
public:
CHXAvPlayViewWindow();
virtual ~CHXAvPlayViewWindow();
void ConstructL(CHXAvPlayerUI *playerUI, CHXAvPlayView *parentView, const TRect& rc);
// CCoeControl overrides...
CCoeControl* ComponentControl( TInt aIndex ) const;
TInt CountComponentControls() const;
//void FocusChanged(TDrawNow aDrawNow);
//void GetHelpContext(TCoeHelpContext& aContext) const {}
void Draw(const TRect& aRect) const;
TKeyResponse OfferKeyEventL(const TKeyEvent& aKeyEvent,TEventCode aType);
TKeyResponse HandleEventKeyEventL(const TKeyEvent& event);
TKeyResponse HandleKeyUpEventL(const TKeyEvent& event);
TKeyResponse HandleKeyDownEventL(const TKeyEvent& event);
void HandleSeekKeyEvent(const TKeyEvent& event);
CHXAvPresentationWindow *GetPresentationWindow() { return m_spPresentationWindow.raw_ptr(); }
private:
CHXAvPlayView *m_playView;
CHXAvPlayerUI *m_playerUI;
comptr<CHXAvPlayer> m_spPlayer;
BOOL m_bInSeekMode;
// This is the main presentation (rendering) window...
CHXAvPresentationWindowPtr m_spPresentationWindow;
};
typedef CHXSmartPtr<CHXAvPlayViewWindow> CHXAvPlayViewWindowPtr;
#endif // _chxavplayviewwindow_h
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?