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.

101 lines
3.0 KiB

  1. //---------------------------------------------------------------------------
  2. //
  3. //---------------------------------------------------------------------------
  4. #define STRICT
  5. #define _INC_OLE
  6. #include <windows.h>
  7. #include <shlapip.h>
  8. #include <shlobj.h>
  9. #include <shlobjp.h>
  10. #include <shlwapi.h>
  11. #include <shlwapip.h>
  12. #include <shsemip.h>
  13. #include <shellp.h>
  14. #include <commdlg.h>
  15. #include <commctrl.h>
  16. #include <comctrlp.h>
  17. //---------------------------------------------------------------------------
  18. // Global to the app.
  19. #define CCHSZSHORT 32
  20. #define CCHSZNORMAL 256
  21. #define MAXGROUPNAMELEN 30 // from progman
  22. extern HINSTANCE g_hinst;
  23. extern TCHAR g_szStartGroup[MAXGROUPNAMELEN + 1];
  24. extern HKEY g_hkeyGrpConv;
  25. extern const TCHAR c_szGroups[];
  26. extern const TCHAR c_szNULL[];
  27. extern const TCHAR c_szSettings[];
  28. extern BOOL g_fDoingCommonGroups;
  29. extern BOOL g_fDoProgmanDde;
  30. extern BOOL g_fShowUI;
  31. #define REGSTR_PATH_EXPLORER_SHELLFOLDERS REGSTR_PATH_EXPLORER TEXT("\\Shell Folders")
  32. // This version of grpconv has to work on win95 and NT4, as well as memphis and NT5.
  33. // Therefore, we have to undef a few things that get #defined to the xxxA and xxxW
  34. // functions so the binary will link to the old shell32.nt4 and shell32.w95 libs.
  35. #undef IsLFNDrive
  36. WINSHELLAPI BOOL WINAPI IsLFNDrive(LPCTSTR pszPath);
  37. #undef SHGetSpecialFolderPath
  38. WINSHELLAPI BOOL WINAPI SHGetSpecialFolderPath(HWND hwndOwner, LPTSTR lpszPath, int nFolder, BOOL fCreate);
  39. #undef PathFindFileName
  40. LPTSTR WINAPI PathFindFileName(LPCTSTR pPath);
  41. #undef PathAppend
  42. BOOL WINAPI PathAppend(LPTSTR pPath, LPNCTSTR pMore);
  43. #undef PathFileExists
  44. BOOL WINAPI PathFileExists(LPCTSTR lpszPath);
  45. #undef PathGetArgs
  46. LPTSTR WINAPI PathGetArgs(LPCTSTR pszPath);
  47. #undef PathUnquoteSpaces
  48. void WINAPI PathUnquoteSpaces(LPTSTR lpsz);
  49. #undef ILCreateFromPath
  50. LPITEMIDLIST WINAPI ILCreateFromPath(LPCTSTR pszPath);
  51. #undef PathRemoveFileSpec
  52. BOOL WINAPI PathRemoveFileSpec(LPTSTR pFile);
  53. #undef PathFindExtension
  54. WINSHELLAPI LPTSTR WINAPI PathFindExtension(LPCTSTR pszPath);
  55. #undef PathAddBackslash
  56. LPTSTR WINAPI PathAddBackslash(LPTSTR lpszPath);
  57. #undef PathIsRoot
  58. BOOL WINAPI PathIsRoot(LPCTSTR pPath);
  59. #undef PathCombine
  60. LPTSTR WINAPI PathCombine(LPTSTR lpszDest, LPCTSTR lpszDir, LPNCTSTR lpszFile);
  61. #undef PathGetDriveNumber
  62. int WINAPI PathGetDriveNumber(LPNCTSTR lpsz);
  63. #undef PathRemoveBlanks
  64. void WINAPI PathRemoveBlanks(LPTSTR lpszString);
  65. #undef PathIsUNC
  66. BOOL WINAPI PathIsUNC(LPTSTR pszPath);
  67. // from shlguidp.h
  68. DEFINE_GUID(IID_IShellLinkDataList, 0x45e2b4ae, 0xb1c3, 0x11d0, 0xb9, 0x2f, 0x0, 0xa0, 0xc9, 0x3, 0x12, 0xe1);
  69. #ifndef UNICODE
  70. // The current headers will #define this to IID_IShellLinkA if
  71. // unicode is not defined. This will prevent us from linking to
  72. // the win95 shell32.lib (iedev\lib\chicago\*\shell32.w95) and
  73. // so we just define it here for the ANSI case.
  74. #undef IID_IShellLink
  75. DEFINE_SHLGUID(IID_IShellLink, 0x000214EEL, 0, 0);
  76. #endif