1
0

DragExt.h 1.6 KB

12345678910111213141516171819202122232425262728293031323334353637383940
  1. //---------------------------------------------------------------------------
  2. #ifndef DragExtH
  3. #define DragExtH
  4. //---------------------------------------------------------------------------
  5. #define DRAG_EXT_MAPPING L"WinSCPDragExtMapping"
  6. #define DRAG_EXT_MUTEX L"WinSCPDragExtMutex"
  7. #define DRAG_EXT_RUNNING_MUTEX L"WinSCPDragExtLogMutex"
  8. #define DRAG_EXT_DUMMY_DIR_PREFIX L"scp"
  9. #define DRAG_EXT_DUMMY_DIR_PREFIX_LEN 3
  10. //---------------------------------------------------------------------------
  11. EXTERN_C const CLSID CLSID_ShellExtension;
  12. DEFINE_GUID(CLSID_ShellExtension, 0xe15e1d68, 0x0d1c, 0x49f7,
  13. 0xbe, 0xb8, 0x81, 0x2b, 0x1e, 0x00, 0xfa, 0x60 );
  14. //---------------------------------------------------------------------------
  15. #pragma pack(push, 4)
  16. //---------------------------------------------------------------------------
  17. // Note that the change between 0 and 1 was incompatible in both directions.
  18. // So unfortunately version 0 extension (4.x and older) will accept incompatible request
  19. // from version 1 application (5.x and newer).
  20. // Luckily the extension will gracefully fail, when using the Unicode path in
  21. // GetShortPathName(CommStruct->DropDest, ...) and will ignore the request.
  22. struct TDragExtCommStruct
  23. {
  24. enum TVersion
  25. {
  26. Version0 = 0,
  27. Version1 = 1,
  28. CurrentVersion = Version1,
  29. MinVersion = Version1,
  30. MaxVersion = CurrentVersion
  31. };
  32. int Version;
  33. bool Dragging;
  34. wchar_t DropDest[MAX_PATH];
  35. };
  36. //---------------------------------------------------------------------------
  37. #pragma pack(pop)
  38. //---------------------------------------------------------------------------
  39. #endif // DragExtH