FrmMonitoringEditF.h 6.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236
  1. //---------------------------------------------------------------------------
  2. #ifndef FrmMonitoringEditFH
  3. #define FrmMonitoringEditFH
  4. //---------------------------------------------------------------------------
  5. #include <Classes.hpp>
  6. #include <Controls.hpp>
  7. #include <StdCtrls.hpp>
  8. #include <Forms.hpp>
  9. #include <DB.hpp>
  10. #include <DBClient.hpp>
  11. #include <FMTBcd.hpp>
  12. #include <Provider.hpp>
  13. #include <SqlExpr.hpp>
  14. #include <Menus.hpp>
  15. #include <ExtCtrls.hpp>
  16. #include <Graphics.hpp>
  17. #include <ComCtrls.hpp>
  18. #include <ADODB.hpp>
  19. #include <Dialogs.hpp>
  20. #include <ExtDlgs.hpp>
  21. //---------------------------------------------------------------------------
  22. //---------------------------------------------------------------------------
  23. #include "cxButtons.hpp"
  24. #include "cxCalendar.hpp"
  25. #include "cxContainer.hpp"
  26. #include "cxControls.hpp"
  27. #include "cxDropDownEdit.hpp"
  28. #include "cxEdit.hpp"
  29. #include "cxGraphics.hpp"
  30. #include "cxGroupBox.hpp"
  31. #include "cxLabel.hpp"
  32. #include "cxLookAndFeelPainters.hpp"
  33. #include "cxLookAndFeels.hpp"
  34. #include "cxMaskEdit.hpp"
  35. #include "cxPC.hpp"
  36. #include "cxPCdxBarPopupMenu.hpp"
  37. #include "cxSpinEdit.hpp"
  38. #include "cxSplitter.hpp"
  39. #include "cxTextEdit.hpp"
  40. #include "cxTimeEdit.hpp"
  41. #include "dxSkinBlack.hpp"
  42. #include "dxSkinBlue.hpp"
  43. #include "dxSkinCaramel.hpp"
  44. #include "dxSkinCoffee.hpp"
  45. #include "dxSkinDarkRoom.hpp"
  46. #include "dxSkinDarkSide.hpp"
  47. #include "dxSkinFoggy.hpp"
  48. #include "dxSkinGlassOceans.hpp"
  49. #include "dxSkiniMaginary.hpp"
  50. #include "dxSkinLilian.hpp"
  51. #include "dxSkinLiquidSky.hpp"
  52. #include "dxSkinLondonLiquidSky.hpp"
  53. #include "dxSkinMcSkin.hpp"
  54. #include "dxSkinMoneyTwins.hpp"
  55. #include "dxSkinOffice2007Black.hpp"
  56. #include "dxSkinOffice2007Blue.hpp"
  57. #include "dxSkinOffice2007Green.hpp"
  58. #include "dxSkinOffice2007Pink.hpp"
  59. #include "dxSkinOffice2007Silver.hpp"
  60. #include "dxSkinOffice2010Black.hpp"
  61. #include "dxSkinOffice2010Blue.hpp"
  62. #include "dxSkinOffice2010Silver.hpp"
  63. #include "dxSkinsCore.hpp"
  64. #include "dxSkinscxPCPainter.hpp"
  65. #include "dxSkinSeven.hpp"
  66. #include "dxSkinSharp.hpp"
  67. #include "dxSkinSilver.hpp"
  68. #include "dxSkinStardust.hpp"
  69. #include "cxRadioGroup.hpp"
  70. #include "cxClasses.hpp"
  71. #include "cxCustomData.hpp"
  72. #include "cxData.hpp"
  73. #include "cxDataStorage.hpp"
  74. #include "cxDBData.hpp"
  75. #include "cxFilter.hpp"
  76. #include "cxGrid.hpp"
  77. #include "cxGridCustomTableView.hpp"
  78. #include "cxGridCustomView.hpp"
  79. #include "cxGridDBTableView.hpp"
  80. #include "cxGridLevel.hpp"
  81. #include "cxGridTableView.hpp"
  82. #include "cxStyles.hpp"
  83. #include "cxCheckBox.hpp"
  84. #include "cxImage.hpp"
  85. #include "cxButtonEdit.hpp"
  86. #include "cxBlobEdit.hpp"
  87. #include "cxCalc.hpp"
  88. #include "cxColorComboBox.hpp"
  89. //---------------------------------------------------------------------------
  90. typedef enum enMonitoringScreen
  91. {
  92. enMonitoringPhase = 1,
  93. enMonitoringScenario = 2,
  94. enMonitoringCamera = 3,
  95. enMonitoringModule = 4,
  96. } EN_MONITORING_SCREEN;
  97. //---------------------------------------------------------------------------
  98. class TFrmMonitoringEdit : public TForm
  99. {
  100. __published: // IDE-managed Components
  101. TTimer *TmrShow;
  102. TShape *ShpTitle;
  103. TcxButton *BtnClose;
  104. TLabel *LblCaption;
  105. TShape *ShpList;
  106. TEdit *EdFocus;
  107. TPanel *PanelBack;
  108. TPanel *PnlLeft;
  109. TcxGroupBox *GrpList;
  110. TPanel *Panel1;
  111. TPanel *Panel3;
  112. TcxGroupBox *cxGroupBox1;
  113. TcxGrid *CxScrnList;
  114. TcxGridTableView *TvScrnList;
  115. TcxGridColumn *Col01;
  116. TcxGridColumn *Col02;
  117. TcxGridColumn *Col03;
  118. TcxGridLevel *GlScrnList;
  119. TPanel *PnlMenu;
  120. TcxButton *BtnEdit;
  121. TcxButton *BtnInsert;
  122. TcxButton *BtnDelete;
  123. TcxButton *BtnSave;
  124. TPanel *PnlCmd;
  125. TcxButton *BtnSearch;
  126. TPanel *Panel2;
  127. TPanel *Panel4;
  128. TcxButton *BtnUp;
  129. TcxButton *BtnDown;
  130. TcxButton *BtnListAdd;
  131. TcxButton *BtnListDelete;
  132. TcxGrid *CxScrnCtlr;
  133. TcxGridTableView *TvScrnCtlr;
  134. TcxGridColumn *ColCtlr1;
  135. TcxGridColumn *ColCtlr2;
  136. TcxGridColumn *ColCtlr3;
  137. TcxGridLevel *GScrnCtlr;
  138. TcxTextEdit *EdOrgName;
  139. TPanel *Panel5;
  140. TImage *ImgDesc19;
  141. TcxLabel *cxLabel2;
  142. TcxTextEdit *EdName;
  143. TcxLabel *lblText1;
  144. TcxLabel *lblText2;
  145. TcxLabel *lblText3;
  146. TcxLabel *lblText4;
  147. TcxLabel *lblText5;
  148. TcxLabel *lblText6;
  149. TcxLabel *lblText7;
  150. TcxLabel *lblText8;
  151. TcxLabel *lblText9;
  152. TcxGrid *CxCtlrList;
  153. TcxGridTableView *TvCtlrList;
  154. TcxGridColumn *ColumnSel;
  155. TcxGridColumn *Column00;
  156. TcxGridColumn *Column01;
  157. TcxGridColumn *Column02;
  158. TcxGridColumn *Column03;
  159. TcxGridColumn *Column04;
  160. TcxGridColumn *Column05;
  161. TcxGridColumn *Column06;
  162. TcxGridColumn *Column07;
  163. TcxGridColumn *Column10;
  164. TcxGridColumn *Column99;
  165. TcxGridColumn *Column08;
  166. TcxGridColumn *Column09;
  167. TcxGridColumn *Column11;
  168. TcxGridColumn *Column13;
  169. TcxGridColumn *Column12;
  170. TcxGridLevel *GlCtlrList;
  171. void __fastcall FormShow(TObject *Sender);
  172. void __fastcall TmrShowTimer(TObject *Sender);
  173. void __fastcall BtnCloseClick(TObject *Sender);
  174. void __fastcall FormClose(TObject *Sender, TCloseAction &Action);
  175. void __fastcall BtnEditClick(TObject *Sender);
  176. void __fastcall BtnSaveClick(TObject *Sender);
  177. void __fastcall BtnInsertClick(TObject *Sender);
  178. void __fastcall BtnDeleteClick(TObject *Sender);
  179. void __fastcall TvScrnListCellDblClick(TcxCustomGridTableView *Sender, TcxGridTableDataCellViewInfo *ACellViewInfo,
  180. TMouseButton AButton, TShiftState AShift,
  181. bool &AHandled);
  182. void __fastcall TvScrnListFocusedRecordChanged(TcxCustomGridTableView *Sender, TcxCustomGridRecord *APrevFocusedRecord,
  183. TcxCustomGridRecord *AFocusedRecord, bool ANewItemRecordFocusingChanged);
  184. void __fastcall BtnSearchClick(TObject *Sender);
  185. void __fastcall BtnListAddClick(TObject *Sender);
  186. void __fastcall BtnListDeleteClick(TObject *Sender);
  187. void __fastcall BtnUpClick(TObject *Sender);
  188. void __fastcall BtnDownClick(TObject *Sender);
  189. private: // User declarations
  190. void __fastcall CommClose();
  191. String FTitle;
  192. bool FNewDb;
  193. bool EditMode;
  194. public:
  195. bool FUpdate;
  196. int FMonitoringType;
  197. TADOConnection *FDbConnection;
  198. public: // User declarations
  199. __fastcall TFrmMonitoringEdit(TComponent* Owner);
  200. TcxDataController *m_pGDC;
  201. void __fastcall FormInit();
  202. void __fastcall RefreshData();
  203. void __fastcall UpdateCtlrList();
  204. void __fastcall LoadCmraMonitoring();
  205. void __fastcall DisplayInfo();
  206. void __fastcall ChangeEditMode(int AEdit);
  207. void __fastcall FormClear();
  208. void __fastcall DisplayFormInfo(int AIdx);
  209. bool __fastcall DelCmraMonitoring(String AFormName);
  210. int __fastcall CheckDupFormName(String ANewName, String AOldName);
  211. bool __fastcall FindCtlrInfo(String ACtlrNmbr);
  212. void __fastcall UpdateScrnCtlrSeq();
  213. };
  214. //---------------------------------------------------------------------------
  215. //extern PACKAGE TFrmMonitoringEdit *FrmMonitoringEdit;
  216. //---------------------------------------------------------------------------
  217. #endif