IdwThread.h
changeset 0 523a7dc3469f
child 1 d9a866996670
     1.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     1.2 +++ b/IdwThread.h	Sun Mar 16 09:11:39 2014 +0100
     1.3 @@ -0,0 +1,63 @@
     1.4 +//------------------------------------------------------------------------------
     1.5 +#ifndef IDWTHREAD_H_INCLUDED
     1.6 +#define IDWTHREAD_H_INCLUDED
     1.7 +//------------------------------------------------------------------------------
     1.8 +#include <windows.h>
     1.9 +#include "Thread.h"
    1.10 +#include "Event.h"
    1.11 +#include "Mutex.h"
    1.12 +#include "iMONDisplayDefines.h"
    1.13 +#include "iMONDisplayWrapper.h"
    1.14 +//------------------------------------------------------------------------------
    1.15 +class IdwThread : public Thread
    1.16 +{
    1.17 +public:
    1.18 +  IdwThread(HINSTANCE hInstance);
    1.19 +  virtual ~IdwThread();
    1.20 +
    1.21 +private:
    1.22 +  IdwThread(const IdwThread& other) {}
    1.23 +  IdwThread& operator=(const IdwThread& other) { return *this; }
    1.24 +
    1.25 +public:
    1.26 +  virtual void Interrupt();
    1.27 +  DSPResult Init(IDW_INITRESULT* pInitResult);
    1.28 +  DSPResult Uninit();
    1.29 +  DSPResult IsInited();
    1.30 +  DSPResult IsPluginModeEnabled();
    1.31 +  DSPResult SetVfdText(LPCWSTR lpszLine1, LPCWSTR lpszLine2);
    1.32 +  DSPResult SetVfdEqData(PDSPEQDATA pEqData);
    1.33 +  DSPResult SetLcdText(LPCWSTR lpszText);
    1.34 +  DSPResult SetLcdEqData(PDSPEQDATA pEqDataL, PDSPEQDATA pEqDataR);
    1.35 +  DSPResult SetLcdAllIcons(BOOL bOn);
    1.36 +  DSPResult SetLcdOrangeIcon(BYTE btIconData1, BYTE btIconData2);
    1.37 +  DSPResult SetLcdMediaTypeIcon(BYTE btIconData);
    1.38 +  DSPResult SetLcdSpeakerIcon(BYTE btIconData1, BYTE btIconData2);
    1.39 +  DSPResult SetLcdVideoCodecIcon(BYTE btIconData);
    1.40 +  DSPResult SetLcdAudioCodecIcon(BYTE btIconData);
    1.41 +  DSPResult SetLcdAspectRatioIcon(BYTE btIconData);
    1.42 +  DSPResult SetLcdEtcIcon(BYTE btIconData);
    1.43 +  DSPResult SetLcdProgress(int nCurPos, int nTotal);
    1.44 +
    1.45 +protected:
    1.46 +  virtual void Run();
    1.47 +
    1.48 +private:
    1.49 +  bool RegisterClass();
    1.50 +  bool CreateMessageWindow();
    1.51 +  void AllowImonMessages();
    1.52 +  bool WaitForWindow();
    1.53 +  static LRESULT CALLBACK WndProc(
    1.54 +    HWND hwnd, UINT uMsg, WPARAM wParam, LPARAM lParam);
    1.55 +  static void MapChars(
    1.56 +    LPWSTR lpszTarget, LPCWSTR lpszSource, int nMaxLength);
    1.57 +  static wchar_t MapChar(wchar_t ch);
    1.58 +
    1.59 +private:
    1.60 +  HINSTANCE m_hInstance;
    1.61 +  HWND m_hWnd;
    1.62 +  Event m_eventWindowCreationDone;
    1.63 +};
    1.64 +//------------------------------------------------------------------------------
    1.65 +#endif
    1.66 +//------------------------------------------------------------------------------