ControlEx.h 579 B

12345678910111213141516171819202122232425262728
  1. #pragma once
  2. class ComputerExamineUI : public CContainerUI
  3. {
  4. public:
  5. ComputerExamineUI()
  6. {
  7. CDialogBuilder builder;
  8. CContainerUI* pComputerExamine = static_cast<CContainerUI*>(builder.Create(_T("ComputerExamine.xml"), (UINT)0));
  9. if( pComputerExamine ) {
  10. this->Add(pComputerExamine);
  11. }
  12. else {
  13. this->RemoveAll();
  14. return;
  15. }
  16. }
  17. };
  18. class CDialogBuilderCallbackEx : public IDialogBuilderCallback
  19. {
  20. public:
  21. CControlUI* CreateControl(LPCTSTR pstrClass)
  22. {
  23. if( _tcscmp(pstrClass, _T("ComputerExamine")) == 0 ) return new ComputerExamineUI;
  24. return NULL;
  25. }
  26. };