#ifndef __DVB_SUBTITLES_VIEWER_H
#define __DVB_SUBTITLES_VIEWER_H

#include <vdr/osdcontroller.h>

class cOsd;
class cSubtitlesPage;
class cMutex;
class cSubtitlesPage;


using namespace NonInteractiveOsdPatch;

class SubtitlesViewer : public cOsdListener
{

public:
  
  SubtitlesViewer( );
  virtual ~SubtitlesViewer();
  void Show();
  void Hide();
  void SetPage( cSubtitlesPage* page );
  void Clear();
  void Flush();

private:

  void DrawPage();
  cOsd*  iOsd;
  cMutex*    iMutex;
  int iWinHandle;
  bool iShowing;
  cSubtitlesPage* iCurrentPage;

};

#endif
