Changeset 50830 in vbox
- Timestamp:
- Mar 20, 2014 4:13:19 PM (11 years ago)
- svn:sync-xref-src-repo-rev:
- 92902
- Location:
- trunk
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/include/VBox/GuestHost/DragAndDrop.h
r50561 r50830 36 36 int DnDPathSanitizeFilename(char *pszPath, size_t cbPath); 37 37 int DnDPathSanitize(char *pszPath, size_t cbPath); 38 39 /** Keep the original paths, don't convert paths to relative ones. */ 40 #define DNDURILIST_FLAGS_ABSOLUTE_PATHS RT_BIT(0) 38 41 39 42 class DnDURIObject … … 120 123 protected: 121 124 122 /** List of all top-level file/directory entries. */ 125 /** List of all top-level file/directory entries. 126 * Note: All paths are kept internally as UNIX paths for 127 * easier conversion/handling! */ 123 128 RTCList<RTCString> m_lstRoot; 124 129 /** List of all URI objects added. */ -
trunk/src/VBox/Additions/WINNT/VBoxTray/VBoxDnDDropTarget.cpp
r50734 r50830 453 453 if (RT_SUCCESS(rc)) 454 454 { 455 cchFiles += 1; /* Add string termination. */ 455 456 uint32_t cbFiles = cchFiles * sizeof(char); 456 Assert(cbFiles); 457 458 LogFlowFunc(("cFiles=%u, cchFiles=%RU32, cbFiles=%RU32, pszFiles=0x%p\n", 459 cFiles, cchFiles, cbFiles, pszFiles)); 457 460 458 461 /* Translate the list into URI elements. */ 459 462 DnDURIList lstURI; 460 rc = lstURI.AppendNativePathsFromList(pszFiles, cbFiles, 461 0 /* Flags */);463 rc = lstURI.AppendNativePathsFromList(pszFiles, cbFiles, 464 DNDURILIST_FLAGS_ABSOLUTE_PATHS); 462 465 if (RT_SUCCESS(rc)) 463 466 { … … 494 497 495 498 /* 496 * Third stage: Release access to the storage medium again.499 * Third stage: Unlock + release access to the storage medium again. 497 500 */ 498 501 switch (mFormatEtc.tymed) … … 508 511 } 509 512 513 /* Release storage medium again. */ 514 ReleaseStgMedium(&stgMed); 515 510 516 /* Signal waiters. */ 511 517 mDroppedRc = rc; 512 518 RTSemEventSignal(hEventDrop); 513 514 /* Release storage medium again. */515 ReleaseStgMedium(&stgMed);516 519 } 517 520 } -
trunk/src/VBox/Additions/common/VBoxGuestLib/VBoxGuestR3LibDragAndDrop.cpp
r50724 r50830 1082 1082 1083 1083 static int vbglR3DnDGHProcessURIMessages(uint32_t u32ClientId, 1084 void *pvData, uint32_t cbData)1084 const void *pvData, uint32_t cbData) 1085 1085 { 1086 1086 AssertPtrReturn(pvData, VERR_INVALID_POINTER); -
trunk/src/VBox/GuestHost/DragAndDrop/DnDURIList.cpp
r50734 r50830 430 430 { 431 431 Assert(pszFileName >= pszFilePath); 432 char *pszRoot = &pszFilePath[pszFileName - pszFilePath]; 432 size_t cbBase = (fFlags & DNDURILIST_FLAGS_ABSOLUTE_PATHS) 433 ? 0 /* Use start of path as root. */ 434 : pszFileName - pszFilePath; 435 char *pszRoot = &pszFilePath[cbBase]; 433 436 m_lstRoot.append(pszRoot); 434 437 #ifdef DEBUG_andy … … 436 439 pszFilePath, pszFileName, pszRoot)); 437 440 #endif 438 rc = appendPathRecursive(pszFilePath, 439 pszFileName - pszFilePath, 441 rc = appendPathRecursive(pszFilePath, cbBase, 440 442 fFlags); 441 443 } … … 551 553 { 552 554 const char *pszCurRoot = m_lstRoot.at(i).c_str(); 555 #ifdef DEBUG_andy 556 LogFlowFunc(("pszCurRoot=%s\n", pszCurRoot)); 557 #endif 553 558 if (strBasePath.isNotEmpty()) 554 559 {
Note:
See TracChangeset
for help on using the changeset viewer.