Source code of Windows XP (NT5)
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

133 lines
6.2 KiB

  1. #pragma once
  2. #include "Globals.h"
  3. const int THREE_YEARS = 1095;
  4. BOOL CanSkipVerification();
  5. void SetItemText(CListCtrl& yo, int nItem, int subItem,CString& text);
  6. void SetItemText(CListCtrl& yo, int nItem, int subItem,TCHAR const * text);
  7. void SetItemText(CListCtrl& yo, int nItem, int subItem,TCHAR * text);
  8. void SetItemText(CListCtrl& yo, int nItem, int subItem,_bstr_t text);
  9. bool GetCheck(CListCtrl & yo,int nItem);
  10. void SetCheck(CListCtrl & yo,int nItem,bool checkit);
  11. void setupColumns(bool sourceIsNT4);
  12. void ShowWarning(HWND hwndDlg);
  13. void ErrorWrapper2(HWND hwndDlg,HRESULT returncode);
  14. void OnFileBrowse(HWND hwndDlg,int id);
  15. void ErrorWrapper(HWND hwndDlg,HRESULT returncode);
  16. void ErrorWrapper4(HWND hwndDlg,HRESULT returncode,CString domainName);
  17. _bstr_t GET_BSTR1(int id);
  18. void doNothingToVarset();
  19. bool enableNextIfNecessary(HWND hwndDlg,int id);
  20. void enableNextIfObjectsSelected(HWND hwndDlg);
  21. HRESULT InitObjectPicker2(IDsObjectPicker *pDsObjectPicker,bool multiselect,CString targetComputer,bool sourceIsNT4);
  22. bool validString(HWND hwndDlg,int id);
  23. void JobFileGetActionText(WCHAR const * filename,CString & text);
  24. DWORD VerifyPassword(WCHAR * sUserName, WCHAR * sPassword, WCHAR * sDomain);
  25. void obtainTrustCredentials(HWND hwdDlg);
  26. void activateServiceButtons(HWND hwndDlg);
  27. void activateTrustButton(HWND hwndDlg);
  28. void activateServiceButtons2(HWND hwndDlg);
  29. void activateCancelIfNecessary(HWND hwndDlg);
  30. bool CheckSameForest(CString& domain1,CString& domain2,HRESULT& hr);
  31. bool findInVarSet(HWND hwndDlg,int id, BSTR bstr);
  32. void initnoncollisionrename(HWND hwndDlg);
  33. bool noncollisionrename(HWND hwndDlg);
  34. void handleDB();
  35. CString GET_CSTRING(int id);
  36. bool number(CString num);
  37. HRESULT doSidHistory(HWND hwndDlg);
  38. bool administrator(CString m_Computer,HRESULT& hr);
  39. bool targetNativeMode(_bstr_t b,HRESULT &hr);
  40. HRESULT validDomain(CString m_Computer,bool &isNt4);
  41. bool validDir(CString dir);
  42. bool checkFile(HWND hwndDlg);
  43. bool verifyprivs(HWND hwndDlg,CString &sourceDomainController,CString &targetDomainController,LPSHAREDWIZDATA& pdata);
  44. bool someServiceAccounts(int accounts,HWND hwndDlg);
  45. void swap(CString yo1,CString yo2);
  46. void refreshDB(HWND hwndDlg);
  47. void populateList(CComboBox&);
  48. void getReporting();
  49. bool tooManyChars(HWND hwndDlg,int id);
  50. void putReporting();
  51. void populateReportingTime();
  52. CString timeToCString(int varsetKey);
  53. void MessageBoxWrapper(HWND hwndDlg,int m,int t);
  54. void getFailed(HWND hwndDlg);
  55. void handleCancel(HWND hwndDlg);
  56. void getService();
  57. void OnADD(HWND hwndDlg,bool sourceIsNT4);
  58. void enable(HWND hwndDlg,int id);
  59. void disable(HWND hwndDlg,int id);
  60. void OnREMOVE(HWND);
  61. void OnMIGRATE(HWND,int & accounts,int& servers);
  62. void initpasswordbox(HWND hwndDlg,int id1,int id2,int id3, BSTR bstr1, BSTR bstr2);
  63. void initdisablesrcbox(HWND hwndDlg);
  64. void inittgtstatebox(HWND hwndDlg);
  65. bool DC(WCHAR*,CString);
  66. bool IsDlgItemEmpty(HWND hwndDlg,int id);
  67. HRESULT InitObjectPicker(IDsObjectPicker *pDsObjectPicker,bool multiselect,CString targetComputer,bool sourceIsNT4);
  68. void ProcessSelectedObjects(IDataObject *pdo,HWND hwndDlg,bool sourceIsNT4);
  69. void ProcessSelectedObjects2(IDataObject *pdo,HWND hwndDlg);
  70. _variant_t get(int i);
  71. void put(int i,_variant_t v);
  72. void initcheckbox(HWND hwndDlg,int id,int varsetKey);
  73. void initeditbox(HWND hwndDlg,int id,int varsetKey);
  74. void inittranslationbox(HWND hwndDlg,int id1,int id2,int id3,int varsetKey,bool sameForest);
  75. void checkbox(HWND hwndDlg,int id,int varsetKey);
  76. void editbox(HWND hwndDlg,int id,int varsetKey);
  77. void translationbox(HWND hwndDlg,int id1,int id2,int id3,int varsetKey);
  78. long rebootbox(HWND hwndDlg,int id);
  79. void handleInitRename(HWND hwndDlg,bool sameForest,bool bCopyGroups);
  80. void addrebootValues(HWND hwndDlg);
  81. BOOL GetDirectory(WCHAR* filename);
  82. void populateTime(long rebootDelay,int servers);
  83. void OnTOGGLE();
  84. void OnRetryToggle();
  85. void OnRETRY();
  86. void setDBStatusSkip();
  87. bool setDBStatusInclude(HWND hwndDlg);
  88. HRESULT MigrateTrusts(HWND hwndDlg,bool& atleast1succeeded);
  89. void OnBROWSE(HWND hwndDlg,int id);
  90. void OnUPDATE(HWND hwndDlg);
  91. void enableRemoveIfNecessary(HWND hwndDlg);
  92. bool validDirectoryString(HWND hwndDlg,int id);
  93. bool validReboot(HWND hwndDlg,int id);
  94. bool SomethingToRetry();
  95. void helpWrapper(HWND hwndDlg, int t);
  96. HRESULT GetHelpFileFullPath( BSTR *bstrHelp );
  97. bool timeInABox(HWND hwndDlg,time_t& t);
  98. void ErrorWrapper3(HWND hwndDlg,HRESULT returncode,CString domainName);
  99. void MessageBoxWrapper3(HWND hwndDlg,int m,int t,CString domainName);
  100. void MessageBoxWrapperFormat1(HWND hwndDlg,int f,int m, int t);
  101. void getTrust();
  102. HRESULT BrowseForContainer(HWND hWnd,//Handle to window that should own the browse dialog.
  103. LPOLESTR szRootPath, //Root of the browse tree. NULL for entire forest.
  104. LPOLESTR *ppContainerADsPath, //Return the ADsPath of the selected container.
  105. LPOLESTR *ppContainerClass //Return the ldapDisplayName of the container's class.
  106. );
  107. void sort(CListCtrl & listbox,int col,bool order);
  108. HRESULT ReInitializeObjectPicker(IDsObjectPicker *pDsObjectPicker,bool multiselect,CString additionalDomainController,bool sourceIsNT4) ;
  109. bool verifyprivs2(HWND hwndDlg,CString& additionalDomainController,CString domainName);
  110. void calculateDate(HWND hwndDlg,CString s);
  111. bool verifyprivsSTW(HWND hwndDlg,CString &sourceDomainController,CString &targetDomainController,LPSHAREDWIZDATA& pdata);
  112. void switchboxes(HWND hwndDlg,int oldid, int newid);
  113. bool populatePasswordDCs(HWND hwndDlg, int id, bool bNT4);
  114. HRESULT QueryW2KDomainControllers(CString domainDNS, IEnumVARIANT*& pEnum);
  115. HRESULT QueryNT4DomainControllers(CString domainDNS, IEnumVARIANT*& pEnum);
  116. void addStringToComboBox(HWND hwndDlg, int id, CString s);
  117. void initDCcombobox(HWND hwndDlg, int id, int varsetKey);
  118. void initsecinputbox(HWND hwndDlg,int id1,int id2,int varsetKey);
  119. void OnMapFileBrowse(HWND hwndDlg,int id);
  120. bool checkMapFile(HWND hwndDlg);
  121. void initpropdlg(HWND hwndDlg);
  122. HRESULT BuildPropertyMap(CString Type, long lSrcVer, CMapStringToString * pPropMap);
  123. void moveproperties(HWND hwndDlg,bool bExclude);
  124. void listproperties(HWND hwndDlg);
  125. void saveproperties(HWND hwndDlg);
  126. bool IsPasswordDCReady(CString server, CString &msg, CString &title, UINT *msgtype);
  127. CString CreatePath(CString sDirPath);
  128. void GetValidPathPart(CString sFullPath, CString &sDirectory, CString &sFileName);