vdr  1.7.27
interface.h
Go to the documentation of this file.
00001 /*
00002  * interface.h: Abstract user interface layer
00003  *
00004  * See the main source file 'vdr.c' for copyright information and
00005  * how to reach the author.
00006  *
00007  * $Id: interface.h 2.0 2004/05/01 11:11:13 kls Exp $
00008  */
00009 
00010 #ifndef __INTERFACE_H
00011 #define __INTERFACE_H
00012 
00013 #include "config.h"
00014 #include "remote.h"
00015 #include "skins.h"
00016 #include "svdrp.h"
00017 
00018 class cInterface {
00019 private:
00020   bool interrupted;
00021   cSVDRP *SVDRP;
00022   bool QueryKeys(cRemote *Remote, cSkinDisplayMenu *DisplayMenu);
00023 public:
00024   cInterface(int SVDRPport = 0);
00025   ~cInterface();
00026   bool HasSVDRPConnection(void) { return SVDRP && SVDRP->HasConnection(); }
00027   void Interrupt(void) { interrupted = true; }
00028   eKeys GetKey(bool Wait = true);
00029   eKeys Wait(int Seconds = 0, bool KeepChar = false);
00030   bool Confirm(const char *s, int Seconds = 10, bool WaitForTimeout = false);
00031   void LearnKeys(void);
00032   };
00033 
00034 extern cInterface *Interface;
00035 
00036 #endif //__INTERFACE_H