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.

83 lines
2.3 KiB

  1. Attribute VB_Name = "Globals"
  2. Option Explicit
  3. Public Declare Function SendMessage Lib "user32" Alias "SendMessageA" (ByVal hwnd As Long, ByVal wMsg As Long, ByVal wParam As Long, ByVal lParam As String) As Long
  4. Public Declare Function GetUserDefaultLCID Lib "kernel32" () As Long
  5. Public Const LB_SELECTSTRING = &H18C
  6. Public g_AuthDatabase As AuthDatabase.Main
  7. Public g_ErrorInfo As CErrorInfo
  8. Public g_Font As StdFont
  9. Public g_FontColor As Long
  10. Public Const FILE_EXT_HHC_C As String = ".HHC"
  11. Public Const FILE_EXT_HHK_C As String = ".HHK"
  12. Public Const FILE_EXT_XLS_C As String = ".XLS"
  13. Public Const FILE_EXT_CHM_C As String = ".CHM"
  14. Public Const FILE_EXT_HTM_C As String = ".HTM"
  15. Public Const FILE_EXT_HHT_C As String = ".HHT"
  16. Public Enum SEARCH_TARGET_E
  17. ST_TITLE_E = &H1
  18. ST_URI_E = &H2
  19. ST_DESCRIPTION_E = &H4
  20. ST_COMMENTS_E = &H8
  21. ST_BASE_FILE_E = &H10
  22. ST_TOPICS_WITHOUT_KEYWORDS_E = &H20
  23. ST_NODES_WITHOUT_KEYWORDS_E = &H40
  24. ST_SELF_AUTHORING_GROUP_E = &H80
  25. ST_MARK1_E = &H100
  26. ST_BROKEN_LINK_WINME_E = &H200
  27. ST_BROKEN_LINK_STD_E = &H400
  28. ST_BROKEN_LINK_PRO_E = &H800
  29. ST_BROKEN_LINK_PRO64_E = &H1000
  30. ST_BROKEN_LINK_SRV_E = &H2000
  31. ST_BROKEN_LINK_ADV_E = &H4000
  32. ST_BROKEN_LINK_ADV64_E = &H8000
  33. ST_BROKEN_LINK_DAT_E = &H10000
  34. ST_BROKEN_LINK_DAT64_E = &H20000
  35. End Enum
  36. Public LocIncludes() As String
  37. Public Sub InitializeLocIncludes()
  38. Static blnInitialized As Boolean
  39. If (blnInitialized) Then
  40. Exit Sub
  41. End If
  42. blnInitialized = True
  43. ReDim LocIncludes(2)
  44. LocIncludes(0) = LOC_INCLUDE_ALL_C
  45. LocIncludes(1) = LOC_INCLUDE_ENU_C
  46. LocIncludes(2) = LOC_INCLUDE_LOC_C
  47. End Sub
  48. Public Sub PopulateCboWithSKUs(ByVal i_cbo As ComboBox)
  49. Dim intIndex As Long
  50. Dim SKUs(8) As SKU_E
  51. SKUs(0) = SKU_STANDARD_E
  52. SKUs(1) = SKU_PROFESSIONAL_E
  53. SKUs(2) = SKU_PROFESSIONAL_64_E
  54. SKUs(3) = SKU_SERVER_E
  55. SKUs(4) = SKU_ADVANCED_SERVER_E
  56. SKUs(5) = SKU_DATA_CENTER_SERVER_E
  57. SKUs(6) = SKU_ADVANCED_SERVER_64_E
  58. SKUs(7) = SKU_DATA_CENTER_SERVER_64_E
  59. SKUs(8) = SKU_WINDOWS_MILLENNIUM_E
  60. For intIndex = LBound(SKUs) To UBound(SKUs)
  61. i_cbo.AddItem DisplayNameForSKU(SKUs(intIndex)), intIndex
  62. i_cbo.ItemData(intIndex) = SKUs(intIndex)
  63. Next
  64. i_cbo.ListIndex = 0
  65. End Sub