chxavnetconnectui.h
上传用户:zhongxx05
上传日期:2007-06-06
资源大小:33641k
文件大小:2k
源码类别:

Symbian

开发平台:

C/C++

  1. /************************************************************************
  2.  * chxavnetconnectui.h
  3.  * --------------------
  4.  *
  5.  * Synopsis:
  6.  * Access point selector implementation.
  7.  *
  8.  *
  9.  * Target:
  10.  * Symbian OS
  11.  *
  12.  *
  13.  * (c) 1995-2003 RealNetworks, Inc. Patents pending. All rights reserved.
  14.  *
  15.  ************************************************************************/
  16. #ifndef CHXAVNETCONNECTUI_H__
  17. #define CHXAVNETCONNECTUI_H__
  18. // includes
  19. #include "hxcom.h"
  20. #include "hxccf.h"
  21. #include "hxprefs.h"
  22. #include "chxbody.h"
  23. #include "chxsmartptr.h"
  24. #include "ihxsymplayerstateobserver.h"
  25. #include "chxavaccesspointdb.h"
  26. #include "comptr.h"
  27. #include "chxavwaitnote.h"
  28. // forward declarations
  29. _INTERFACE IHXAccessPointManager;
  30. _INTERFACE IHXAccessPointSelectorResponse;
  31. // class CHXAvNetConnectUI
  32. class CHXAvNetConnectUI 
  33. : public CHXBody
  34. , public IHXSymPlayerStateObserver
  35. {
  36. public:
  37.     CHXAvNetConnectUI();
  38.     virtual ~CHXAvNetConnectUI(); 
  39.     void ConstructL(IUnknown* pUnk, const CHXAvCommand& cmdCancelConnect);
  40.     
  41.     HX_RESULT DoSelectAccessPointL(IHXAccessPointManager* pManager,
  42.        IHXAccessPointSelectorResponse* pResponse);
  43. private:
  44. // IHXSymPlayerStateObserver
  45.     void OnStop();
  46.     void OnBeginBuffering(bool bIsBegin);
  47.     void OnError(HX_RESULT code);
  48.     void OnNetConnect();
  49. // implementation helpers
  50.     TUint32 GetAndValidateDefaultAccessPointL(CHXAvAccessPointDB* pDb);
  51.     TUint32 PromptForDefaultAccessPointL(CHXAvAccessPointDB* pDb);
  52.     bool PromptForDisconnectL(CHXAvAccessPointDB* pDb, TUint32 activeAccessPointId);
  53.     TUint32 GetAccessPointFromPrefsL(CHXAvAccessPointDB* pDb);
  54.     void ShowConnectNote();
  55.     void HideConnectNote();
  56. private:
  57.     comptr<IHXCommonClassFactory> m_factory;
  58.     comptr<IHXPreferences> m_prefs;
  59.     CHXAvWaitNotePtr m_spConnectNote;
  60.     bool m_bDoingSelect;
  61. };
  62. typedef CHXSmartPtr<CHXAvNetConnectUI> CHXAvNetConnectUIPtr;
  63. #endif // CHXAVNETCONNECTUI_H__