Changeset 56657 in vbox for trunk/src/VBox
- Timestamp:
- Jun 26, 2015 8:54:42 AM (9 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Main/src-client/GuestDnDTargetImpl.cpp
r56656 r56657 727 727 mDataBase.mListOutgoing.clear(); 728 728 729 const char *pszFormat = pCtx->mFmtReq.c_str(); 730 uint32_t cbFormat = pCtx->mFmtReq.length() + 1; 731 732 /* Do we need to build up a file tree? */ 733 bool fHasURIList = DnDMIMEHasFileURLs(pszFormat, cbFormat); 729 /** 730 * Do we need to build up a file tree? 731 * Note: The decision whether we need to build up a file tree and sending 732 * actual file data only depends on the actual formats offered by this target. 733 * If the guest does not want an URI list ("text/uri-list") but text ("TEXT" and 734 * friends) instead, still send the data over to the guest -- the file as such still 735 * is needed on the guest in this case, as the guest then just wants a simple path 736 * instead of an URI list (pointing to a file on the guest itself). 737 * 738 ** @todo Support more than one format; add a format<->function handler concept. Later. */ 739 bool fHasURIList = std::find(m_vecFmtOff.begin(), 740 m_vecFmtOff.end(), "text/uri-list") != m_vecFmtOff.end(); 734 741 if (fHasURIList) 735 742 { … … 1302 1309 AssertPtr(pInst); 1303 1310 1304 /* At the moment we only allow up to 64K raw data. */ 1311 /** @todo At the moment we only allow sending up to 64K raw data. Fix this by 1312 * using HOST_DND_HG_SND_MORE_DATA. */ 1305 1313 size_t cbDataTotal = pCtx->mData.vecData.size(); 1306 1314 if ( !cbDataTotal … … 1319 1327 Msg.setNextUInt32(cbDataTotal); 1320 1328 1321 LogFlowFunc(("%zu total bytes of raw data to transfer\n", cbDataTotal)); 1322 1323 return pInst->hostCall(Msg.getType(), Msg.getCount(), Msg.getParms()); 1329 LogFlowFunc(("Transferring %zu total bytes of raw data ('%s')\n", cbDataTotal, pCtx->mFmtReq.c_str())); 1330 1331 int rc2; 1332 1333 int rc = pInst->hostCall(Msg.getType(), Msg.getCount(), Msg.getParms()); 1334 if (RT_FAILURE(rc)) 1335 rc2 = pCtx->mpResp->setProgress(100, DragAndDropSvc::DND_PROGRESS_ERROR, rc, 1336 GuestDnDTarget::i_hostErrorToString(rc)); 1337 else 1338 rc2 = pCtx->mpResp->setProgress(100, DragAndDropSvc::DND_PROGRESS_COMPLETE, rc); 1339 AssertRC(rc2); 1340 1341 LogFlowFuncLeaveRC(rc); 1342 return rc; 1324 1343 } 1325 1344
Note:
See TracChangeset
for help on using the changeset viewer.