Leaked source code of windows server 2003
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.

98 lines
3.5 KiB

  1. /////////////////////////////////////////////////////////////////////////////
  2. // FILE : dlgutils.h //
  3. // //
  4. // DESCRIPTION : dialog utility functions //
  5. // //
  6. // AUTHOR : yossg //
  7. // //
  8. // HISTORY : //
  9. // Apr 29 1998 zvib Add AdjustColumns. //
  10. // May 13 1999 roytal Add GetIpAddrDword //
  11. // Jun 10 1999 AvihaiL Add proxy rule wizard. //
  12. // //
  13. // Dec 30 1999 yossg Welcome to Fax Server. (reduced version) //
  14. // Aug 10 2000 yossg Add TimeFormat functions //
  15. // Sept 12 2001 alexmay Add InvokePropSheet functions //
  16. // //
  17. // Copyright (C) 1998 - 2000 Microsoft Corporation All Rights Reserved //
  18. /////////////////////////////////////////////////////////////////////////////
  19. #ifndef _DLGUTLIS_H_
  20. #define _DLGUTLIS_H_
  21. #include <atlsnap.h>
  22. // CONVINIENCE MACRO FOR atl
  23. #define ATTACH_ATL_CONTROL(member, ControlId) member.Attach(GetDlgItem(ControlId));
  24. #define RADIO_CHECKED(idc) ((IsDlgButtonChecked(idc) == BST_CHECKED))
  25. #define ENABLE_CONTROL(idc, State) ::EnableWindow(GetDlgItem(idc), State);
  26. //int GetDlgItemTextLength(HWND hDlg, int idc);
  27. HRESULT
  28. ConsoleMsgBox(
  29. IConsole * pConsole,
  30. int ids,
  31. LPTSTR lptstrTitle = NULL,
  32. UINT fuStyle = MB_OK,
  33. int *piRetval = NULL,
  34. BOOL StringFromCommonDll = FALSE);
  35. void PageError(int ids, HWND hWnd, HINSTANCE hInst = NULL);
  36. void PageErrorEx(int idsHeader, int ids, HWND hWnd, HINSTANCE hInst = NULL);
  37. HRESULT
  38. SetComboBoxItem (CComboBox combo,
  39. DWORD comboBoxIndex,
  40. LPCTSTR lpctstrFieldText,
  41. DWORD dwItemData,
  42. HINSTANCE hInst = NULL);
  43. HRESULT
  44. AddComboBoxItem (CComboBox combo,
  45. LPCTSTR lpctstrFieldText,
  46. DWORD dwItemData,
  47. HINSTANCE hInst = NULL);
  48. HRESULT
  49. SelectComboBoxItemData (CComboBox combo, DWORD_PTR dwItemData);
  50. DWORD
  51. WinContextHelp(
  52. ULONG_PTR dwHelpId,
  53. HWND hWnd
  54. );
  55. HRESULT
  56. DisplayContextHelp(
  57. IDisplayHelp* pDisplayHelp,
  58. LPOLESTR helpFile,
  59. WCHAR* szTopic);
  60. //
  61. // Help topics
  62. //
  63. #define HLP_INBOUND_ROUTING L"::/FaxS_C_RcvdFaxRout.htm"
  64. #define HLP_COVER_PAGES L"::/FaxS_C_CovPages.htm"
  65. #define HLP_DEVICES L"::/FaxS_C_ManDvices.htm"
  66. #define HLP_INTRO L"::/FaxS_C_FaxIntro.htm"
  67. #define HLP_MAN_INCOM L"::/FaxS_C_ManIncom.htm"
  68. #define HLP_GROUPS L"::/FaxS_C_Groups.htm"
  69. #define HLP_MAN_OUTGOING L"::/FaxS_C_ManOutgo.htm"
  70. //
  71. // Time Format Utils
  72. //
  73. #define FXS_MAX_TIMEFORMAT_LEN 80 //MSDN "LOCALE_STIMEFORMAT" MAX VAL
  74. HRESULT
  75. InvokePropSheet(
  76. CSnapInItem* pNode,
  77. DATA_OBJECT_TYPES type,
  78. LPUNKNOWN lpUnknown,
  79. LPCWSTR szTitle,
  80. DWORD dwPage);
  81. #endif //_DLGUTLIS_H_