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.

98 lines
2.6 KiB

  1. #include <windows.h>
  2. #include <stdio.h>
  3. #include <stdlib.h>
  4. #include <string.h>
  5. #include <shellapi.h>
  6. #include <shlobj.h>
  7. #include <shlwapi.h>
  8. #define NO_SHLWAPI_STRFCNS
  9. #define NO_SHLWAPI_PATH
  10. #define NO_SHLWAPI_REG
  11. #define NO_SHLWAPI_UALSTR
  12. #define NO_SHLWAPI_HTTP
  13. #define NO_SHLWAPI_INTERNAL
  14. #include <shlwapip.h>
  15. #define FE_SB 1
  16. #include <shlobjp.h>
  17. #ifndef PLINKINFO
  18. #define PLINKINFO LPVOID
  19. #endif
  20. #define EXP_SZ_LINK_SIG 0xA0000001
  21. //#define NT_CONSOLE_PROPS_SIG 0xA0000002 // moved to shlobj.w
  22. #define EXP_TRACKER_SIG 0xA0000003
  23. //#define NT_FE_CONSOLE_PROPS_SIG 0xA0000004 // moved to shlobj.w
  24. #define EXP_DARWIN_ID_SIG 0xA0000006
  25. #define EXP_HEADER DATABLOCK_HEADER
  26. #define LPEXP_HEADER LPDATABLOCK_HEADER
  27. // most expansion data structures go here
  28. // those shared with other components (NT40 Console stuff)
  29. // are in shlobj.w (private)
  30. //
  31. typedef struct {
  32. IShellLink sl;
  33. IPersistStream ps;
  34. IPersistFile pf;
  35. IShellExtInit si;
  36. IContextMenu2 cm;
  37. IDropTarget dt;
  38. #ifdef USE_DATA_OBJ
  39. IDataObj dobj;
  40. #endif
  41. ////IExtractIcon xi;
  42. #ifdef UNICODE
  43. IShellLinkA slA; // To support ANSI callers
  44. #endif
  45. #ifdef ENABLE_TRACK
  46. IShellLinkTracker slt; // Interface to CTracker object.
  47. #endif
  48. #ifdef WINNT
  49. IShellLinkDataList sldl;
  50. #endif
  51. UINT cRef;
  52. BOOL bDirty; // something has changed
  53. LPTSTR pszCurFile; // current file from IPersistFile
  54. LPTSTR pszRelSource; // overrides pszCurFile in relative tracking
  55. IContextMenu *pcmTarget; // stuff for IContextMenu
  56. UINT indexMenuSave;
  57. UINT idCmdFirstSave;
  58. UINT idCmdLastSave;
  59. UINT uFlagsSave;
  60. BOOL fDataAlreadyResolved; // for data object
  61. // IDropTarget specific
  62. IDropTarget* pdtSrc; // IDropTarget of link source (unresolved)
  63. DWORD grfKeyStateLast;
  64. // persistant data
  65. LPITEMIDLIST pidl; // may be NULL
  66. PLINKINFO pli; // may be NULL
  67. LPTSTR pszName; // title on short volumes
  68. LPTSTR pszRelPath;
  69. LPTSTR pszWorkingDir;
  70. LPTSTR pszArgs;
  71. LPTSTR pszIconLocation;
  72. LPDBLIST pExtraData; // extra data to preserve for future compatibility
  73. #ifdef ENABLE_TRACK
  74. struct CTracker * ptracker;
  75. #endif
  76. SHELL_LINK_DATA sld;
  77. } CShellLink;