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.

156 lines
2.1 KiB

  1. /*++
  2. Copyright (c) 1996 Microsoft Corporation
  3. Module Name:
  4. tapiutil.h
  5. Abstract:
  6. Utility functions for working with TAPI
  7. Environment:
  8. Windows NT fax driver user interface
  9. Revision History:
  10. 09/18/96 -davidx-
  11. Created it.
  12. dd-mm-yy -author-
  13. description
  14. --*/
  15. #ifndef _TAPIUTIL_H_
  16. #define _TAPIUTIL_H_
  17. #include <tapi.h>
  18. #include <shellapi.h>
  19. //
  20. // Initialize TAPI services if necessary
  21. //
  22. BOOL
  23. InitTapiService(
  24. VOID
  25. );
  26. //
  27. // Deinitialize TAPI services if necessary
  28. //
  29. VOID
  30. DeinitTapiService(
  31. VOID
  32. );
  33. //
  34. // Get a list of locations from TAPI
  35. //
  36. LPLINETRANSLATECAPS
  37. GetTapiLocationInfo(
  38. HWND hWnd
  39. );
  40. //
  41. // Change the default TAPI location
  42. //
  43. BOOL
  44. SetCurrentLocation(
  45. DWORD locationID
  46. );
  47. //
  48. // Initialize the country list box
  49. //
  50. VOID
  51. InitCountryListBox(
  52. HWND hwndList,
  53. HWND hwndAreaCode,
  54. DWORD countryCode
  55. );
  56. //
  57. // Handle selection changes in the country list box
  58. //
  59. VOID
  60. SelChangeCountryListBox(
  61. HWND hwndList,
  62. HWND hwndAreaCode
  63. );
  64. //
  65. // Return the current selection of country list box
  66. //
  67. DWORD
  68. GetCountryListBoxSel(
  69. HWND hwndList
  70. );
  71. //
  72. // Return the default country ID for the current location
  73. //
  74. DWORD
  75. GetDefaultCountryID(
  76. VOID
  77. );
  78. //
  79. // Given a LINECOUNTRYENTRY structure, determine if area code is needed in that country
  80. //
  81. INT
  82. AreaCodeRules(
  83. LPLINECOUNTRYENTRY pLineCountryEntry
  84. );
  85. #define AREACODE_DONTNEED 0
  86. #define AREACODE_REQUIRED 1
  87. #define AREACODE_OPTIONAL 2
  88. //
  89. // Find the specified country from a list of all countries and
  90. // return a pointer to the corresponding LINECOUNTRYENTRY structure
  91. //
  92. LPLINECOUNTRYENTRY
  93. FindCountry(
  94. DWORD countryId
  95. );
  96. //
  97. // Assemble a canonical phone number given the following:
  98. // country code, area code, and phone number
  99. //
  100. VOID
  101. AssemblePhoneNumber(
  102. LPTSTR pAddress,
  103. DWORD countryCode,
  104. LPTSTR pAreaCode,
  105. LPTSTR pPhoneNumber
  106. );
  107. //
  108. // bring up the telephony control panel
  109. //
  110. BOOL
  111. DoTapiProps(
  112. HWND hDlg
  113. );
  114. #endif // !_TAPIUTIL_H_