- Timestamp:
- Sep 17, 2019 3:40:00 PM (5 years ago)
- Location:
- trunk/src/VBox
- Files:
-
- 5 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Additions/WINNT/VBoxTray/VBoxClipboard.cpp
r80862 r80866 94 94 *********************************************************************************************************************************/ 95 95 #ifdef VBOX_WITH_SHARED_CLIPBOARD_TRANSFERS 96 static DECLCALLBACK(void) vboxClipboardTransfer TransferCompleteCallback(PSHCLTRANSFERCALLBACKDATA pData, int rc);97 static DECLCALLBACK(void) vboxClipboardTransfer TransferErrorCallback(PSHCLTRANSFERCALLBACKDATA pData, int rc);96 static DECLCALLBACK(void) vboxClipboardTransferCompleteCallback(PSHCLTRANSFERCALLBACKDATA pData, int rc); 97 static DECLCALLBACK(void) vboxClipboardTransferErrorCallback(PSHCLTRANSFERCALLBACKDATA pData, int rc); 98 98 #endif 99 99 … … 160 160 #endif 161 161 162 static void vboxClipboardTransfer TransferCallbackCleanup(PSHCLTRANSFERCALLBACKDATA pData)162 static void vboxClipboardTransferCallbackCleanup(PSHCLTRANSFERCALLBACKDATA pData) 163 163 { 164 164 PSHCLTRANSFERCTX pCtx = (PSHCLTRANSFERCTX)pData->pvUser; … … 183 183 } 184 184 185 static DECLCALLBACK(void) vboxClipboardTransfer TransferCompleteCallback(PSHCLTRANSFERCALLBACKDATA pData, int rc)185 static DECLCALLBACK(void) vboxClipboardTransferCompleteCallback(PSHCLTRANSFERCALLBACKDATA pData, int rc) 186 186 { 187 187 RT_NOREF(rc); … … 191 191 LogRel2(("Shared Clipboard: Transfer to destination complete\n")); 192 192 193 vboxClipboardTransfer TransferCallbackCleanup(pData);194 } 195 196 static DECLCALLBACK(void) vboxClipboardTransfer TransferErrorCallback(PSHCLTRANSFERCALLBACKDATA pData, int rc)193 vboxClipboardTransferCallbackCleanup(pData); 194 } 195 196 static DECLCALLBACK(void) vboxClipboardTransferErrorCallback(PSHCLTRANSFERCALLBACKDATA pData, int rc) 197 197 { 198 198 RT_NOREF(rc); … … 202 202 LogRel(("Shared Clipboard: Transfer to destination failed with %Rrc\n", rc)); 203 203 204 vboxClipboardTransfer TransferCallbackCleanup(pData);205 } 206 207 static int vboxClipboardTransfer TransferOpen(PSHCLPROVIDERCTX pCtx)204 vboxClipboardTransferCallbackCleanup(pData); 205 } 206 207 static int vboxClipboardTransferOpen(PSHCLPROVIDERCTX pCtx) 208 208 { 209 209 RT_NOREF(pCtx); … … 213 213 } 214 214 215 static int vboxClipboardTransfer TransferClose(PSHCLPROVIDERCTX pCtx)215 static int vboxClipboardTransferClose(PSHCLPROVIDERCTX pCtx) 216 216 { 217 217 RT_NOREF(pCtx); … … 969 969 970 970 TransferCallbacks.pvUser = &pCtx->URI; 971 TransferCallbacks.pfnTransferComplete = vboxClipboardTransfer TransferCompleteCallback;972 TransferCallbacks.pfnTransferError = vboxClipboardTransfer TransferErrorCallback;971 TransferCallbacks.pfnTransferComplete = vboxClipboardTransferCompleteCallback; 972 TransferCallbacks.pfnTransferError = vboxClipboardTransferErrorCallback; 973 973 974 974 SharedClipboardTransferSetCallbacks(pTransfer, &TransferCallbacks); -
trunk/src/VBox/HostServices/SharedClipboard/VBoxSharedClipboardSvc-internal.h
r80862 r80866 197 197 198 198 # ifdef VBOX_WITH_SHARED_CLIPBOARD_TRANSFERS 199 int sharedClipboardSvcTransferTransferStart(PSHCLCLIENT pClient, 200 SHCLTRANSFERDIR enmDir, SHCLSOURCE enmSource, 201 PSHCLTRANSFER *ppTransfer); 199 int sharedClipboardSvcTransferStart(PSHCLCLIENT pClient, 200 SHCLTRANSFERDIR enmDir, SHCLSOURCE enmSource, 201 PSHCLTRANSFER *ppTransfer); 202 int sharedClipboardSvcTransferStop(PSHCLCLIENT pClient, PSHCLTRANSFER pTransfer); 202 203 bool sharedClipboardSvcTransferMsgIsAllowed(uint32_t uMode, uint32_t uMsg); 203 204 # endif /* VBOX_WITH_SHARED_CLIPBOARD_TRANSFERS */ … … 222 223 223 224 #ifdef VBOX_WITH_SHARED_CLIPBOARD_TRANSFERS 224 int sharedClipboardSvcTransfer TransferOpen(PSHCLPROVIDERCTX pCtx);225 DECLCALLBACK(int) sharedClipboardSvcTransfer TransferClose(PSHCLPROVIDERCTX pCtx);225 int sharedClipboardSvcTransferOpen(PSHCLPROVIDERCTX pCtx); 226 DECLCALLBACK(int) sharedClipboardSvcTransferClose(PSHCLPROVIDERCTX pCtx); 226 227 227 228 int sharedClipboardSvcTransferGetRoots(PSHCLPROVIDERCTX pCtx, PSHCLROOTLIST *ppRootList); -
trunk/src/VBox/HostServices/SharedClipboard/VBoxSharedClipboardSvc-transfers.cpp
r80862 r80866 58 58 *********************************************************************************************************************************/ 59 59 60 DECLCALLBACK(int) sharedClipboardSvcTransfer TransferOpen(PSHCLPROVIDERCTX pCtx)60 DECLCALLBACK(int) sharedClipboardSvcTransferOpen(PSHCLPROVIDERCTX pCtx) 61 61 { 62 62 RT_NOREF(pCtx); … … 66 66 } 67 67 68 DECLCALLBACK(int) sharedClipboardSvcTransfer TransferClose(PSHCLPROVIDERCTX pCtx)68 DECLCALLBACK(int) sharedClipboardSvcTransferClose(PSHCLPROVIDERCTX pCtx) 69 69 { 70 70 RT_NOREF(pCtx); … … 1162 1162 * @param paParms Array function parameters supplied. 1163 1163 */ 1164 static int sharedClipboardSvcTransfer TransferHandleReply(PSHCLCLIENT pClient, PSHCLTRANSFER pTransfer,1165 1164 static int sharedClipboardSvcTransferHandleReply(PSHCLCLIENT pClient, PSHCLTRANSFER pTransfer, 1165 uint32_t cParms, VBOXHGCMSVCPARM paParms[]) 1166 1166 { 1167 1167 RT_NOREF(pClient); … … 1366 1366 creationCtx.enmSource = pClient->State.enmSource; 1367 1367 1368 creationCtx.Interface.pfnTransferOpen = sharedClipboardSvcTransfer TransferOpen;1369 creationCtx.Interface.pfnTransferClose = sharedClipboardSvcTransfer TransferClose;1368 creationCtx.Interface.pfnTransferOpen = sharedClipboardSvcTransferOpen; 1369 creationCtx.Interface.pfnTransferClose = sharedClipboardSvcTransferClose; 1370 1370 creationCtx.Interface.pfnListOpen = sharedClipboardSvcTransferListOpen; 1371 1371 creationCtx.Interface.pfnListClose = sharedClipboardSvcTransferListClose; … … 1431 1431 case VBOX_SHCL_GUEST_FN_REPLY: 1432 1432 { 1433 rc = sharedClipboardSvcTransfer TransferHandleReply(pClient, pTransfer, cParms, paParms);1433 rc = sharedClipboardSvcTransferHandleReply(pClient, pTransfer, cParms, paParms); 1434 1434 1435 1435 /* This message does not need any completion, as it can happen at any time from the guest side. */ … … 2099 2099 * @param puEvent Where to store the created wait event. Optional. 2100 2100 */ 2101 int sharedClipboardSvcTransfer TransferSendStatus(PSHCLCLIENT pClient, PSHCLTRANSFER pTransfer, SHCLTRANSFERSTATUS uStatus,2102 2101 int sharedClipboardSvcTransferSendStatus(PSHCLCLIENT pClient, PSHCLTRANSFER pTransfer, SHCLTRANSFERSTATUS uStatus, 2102 int rcTransfer, PSHCLEVENTID puEvent) 2103 2103 { 2104 2104 AssertPtrReturn(pClient, VERR_INVALID_POINTER); … … 2153 2153 * @param ppTransfer Where to return the created transfer on success. Optional. 2154 2154 */ 2155 int sharedClipboardSvcTransfer TransferStart(PSHCLCLIENT pClient,2156 2157 2155 int sharedClipboardSvcTransferStart(PSHCLCLIENT pClient, 2156 SHCLTRANSFERDIR enmDir, SHCLSOURCE enmSource, 2157 PSHCLTRANSFER *ppTransfer) 2158 2158 { 2159 2159 AssertPtrReturn(pClient, VERR_INVALID_POINTER); … … 2182 2182 if (RT_SUCCESS(rc)) 2183 2183 { 2184 creationCtx.Interface.pfnTransferOpen = sharedClipboardSvcTransfer TransferOpen;2185 creationCtx.Interface.pfnTransferClose = sharedClipboardSvcTransfer TransferClose;2184 creationCtx.Interface.pfnTransferOpen = sharedClipboardSvcTransferOpen; 2185 creationCtx.Interface.pfnTransferClose = sharedClipboardSvcTransferClose; 2186 2186 creationCtx.Interface.pfnListOpen = sharedClipboardSvcTransferListOpen; 2187 2187 creationCtx.Interface.pfnListClose = sharedClipboardSvcTransferListClose; … … 2235 2235 { 2236 2236 SHCLEVENTID uEvent; 2237 rc = sharedClipboardSvcTransfer TransferSendStatus(pClient, pTransfer,2238 2239 2237 rc = sharedClipboardSvcTransferSendStatus(pClient, pTransfer, 2238 SHCLTRANSFERSTATUS_READY, VINF_SUCCESS, 2239 &uEvent); 2240 2240 if (RT_SUCCESS(rc)) 2241 2241 { … … 2304 2304 * @param pTransfer Transfer to stop. 2305 2305 */ 2306 int sharedClipboardSvcTransfer TransferStop(PSHCLCLIENT pClient, PSHCLTRANSFER pTransfer)2306 int sharedClipboardSvcTransferStop(PSHCLCLIENT pClient, PSHCLTRANSFER pTransfer) 2307 2307 { 2308 2308 int rc = SharedClipboardTransferClose(pTransfer); … … 2310 2310 { 2311 2311 SHCLEVENTID uEvent; 2312 rc = sharedClipboardSvcTransfer TransferSendStatus(pClient, pTransfer,2313 2314 2312 rc = sharedClipboardSvcTransferSendStatus(pClient, pTransfer, 2313 SHCLTRANSFERSTATUS_STOPPED, VINF_SUCCESS, 2314 &uEvent); 2315 2315 if (RT_SUCCESS(rc)) 2316 2316 { -
trunk/src/VBox/HostServices/SharedClipboard/VBoxSharedClipboardSvc-win.cpp
r80862 r80866 340 340 { 341 341 PSHCLTRANSFER pTransfer; 342 int rc = sharedClipboardSvcTransfer TransferStart(pCtx->pClient,343 344 342 int rc = sharedClipboardSvcTransferStart(pCtx->pClient, 343 SHCLTRANSFERDIR_READ, SHCLSOURCE_REMOTE, 344 &pTransfer); 345 345 if (RT_SUCCESS(rc)) 346 346 { -
trunk/src/VBox/HostServices/SharedClipboard/VBoxSharedClipboardSvc.cpp
r80862 r80866 1378 1378 if (uFormat == VBOX_SHCL_FMT_URI_LIST) 1379 1379 { 1380 rc = sharedClipboardSvcTransfer TransferStart(pClient, SHCLTRANSFERDIR_WRITE, SHCLSOURCE_LOCAL,1381 1380 rc = sharedClipboardSvcTransferStart(pClient, SHCLTRANSFERDIR_WRITE, SHCLSOURCE_LOCAL, 1381 NULL /* pTransfer */); 1382 1382 if (RT_FAILURE(rc)) 1383 1383 LogRel(("Shared Clipboard: Initializing host write transfer failed with %Rrc\n", rc));
Note:
See TracChangeset
for help on using the changeset viewer.