00001 /* 00002 * CTerminal.h 00003 * 00004 * Created on: 16.04.2010 00005 * Author: vdv 00006 */ 00007 00008 #ifndef LIBGUI_CTERMINAL_H_ 00009 #define LIBGUI_CTERMINAL_H_ 00010 00011 #include "integer.h" 00012 #include "UIStructs.h" 00013 00014 class CDisplay; 00015 class CKeyboard; 00016 class CForm; 00017 class CComponent; 00018 class CFont; 00019 00020 class CTerminal 00021 { 00022 public: 00023 CTerminal(); 00024 ~CTerminal(); 00025 // static functions 00030 static BOOL Init(); 00031 // 00035 static void BlankDisplay(); 00039 static void UnBlankDisplay(); 00040 // 00045 static INT16 GetScreenWidth(); 00050 static INT16 GetScreenHeight(); 00055 static INT16 GetPreferredScreenWidth(); 00060 static INT16 GetPreferredScreenHeight(); 00065 static INT16 GetPreferredScreenPositionX(); 00070 static INT16 GetPreferredScreenPositionY(); 00071 // form actions 00076 static void AddForm(CForm* form); 00081 static void RemoveForm(CForm* form); 00086 static void ToFront(CForm* form); 00087 // input actions 00092 static BOOL NextAction(); 00096 static void ProcessUserActions(); 00100 static void OnTimer(); 00101 // 00105 static void Paint(); 00110 static void Repaint(CComponent* form); 00119 static void AddRepaintRegion(CComponent* form, INT16 x, INT16 y, INT16 width, INT16 height); 00120 // 00121 public: 00125 static SColorScheme m_scheme; 00126 private: 00127 static CDisplay m_display; 00128 static CKeyboard m_keyboard; 00129 // form manager 00130 static CForm** m_forms; 00131 static INT8 m_formLength; 00132 static INT8 m_nforms; 00133 static INT8 m_paintorder;// start index for repaint z-order 00134 // input manager 00135 static SKeyEvent m_key_event; 00136 }; 00137 00138 #endif /* LIBGUI_CTERMINAL_H_ */