Changeset 19150 in vbox
- Timestamp:
- Apr 23, 2009 7:01:05 PM (16 years ago)
- svn:sync-xref-src-repo-rev:
- 46393
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Additions/x11/VBoxClient/clipboard.cpp
r18360 r19150 20 20 */ 21 21 22 /**************************************************************************** ***23 * Header Files 24 **************************************************************************** ***/22 /**************************************************************************** 23 * Header Files * 24 ****************************************************************************/ 25 25 #include <VBox/HostServices/VBoxClipboardSvc.h> 26 26 #include <VBox/log.h> … … 50 50 #define USE_CTEXT 51 51 52 /**************************************************************************** ***53 * Global Variables 54 **************************************************************************** ***/52 /**************************************************************************** 53 * Global Variables * 54 ****************************************************************************/ 55 55 /** The different clipboard formats which we support. */ 56 56 enum g_eClipboardFormat … … 512 512 int *piFormat) 513 513 { 514 /* The X Toolkit may have failed to get the clipboard selection for us. */515 514 LogFlowFunc(("*pcLen=%lu, *piFormat=%d, requested target format: %d, g_ctx.requestBufferSize=%d\n", 516 515 *pcLen, *piFormat, g_ctx.requestGuestFormat, g_ctx.requestBufferSize)); 516 /* The X Toolkit may have failed to get the clipboard selection for us. */ 517 517 if (*atomType == XT_CONVERT_FAIL) 518 518 { … … 1215 1215 g_ctx.guestTextFormat = INVALID; 1216 1216 g_ctx.guestBitmapFormat = INVALID; 1217 if (XtOwnSelection(g_ctx.widget, g_ctx.atomClipboard, CurrentTime, vboxClipboardConvertProc, 1218 vboxClipboardLoseProc, 0) != True) 1217 if (XtOwnSelection(g_ctx.widget, g_ctx.atomClipboard, CurrentTime, 1218 vboxClipboardConvertProc, vboxClipboardLoseProc, 0) 1219 == True) 1220 XtOwnSelection(g_ctx.widget, g_ctx.atomPrimary, CurrentTime, 1221 vboxClipboardConvertProc, NULL, 0); 1222 else 1219 1223 { 1220 1224 LogFlow(("vboxClipboardFormatAnnounce: returning clipboard ownership to the guest\n")); … … 1222 1226 g_ctx.eOwner = GUEST; 1223 1227 } 1224 XtOwnSelection(g_ctx.widget, g_ctx.atomPrimary, CurrentTime, vboxClipboardConvertProc,1225 NULL, 0);1226 1228 LogFlowFunc(("returning\n")); 1227 1229 } … … 1397 1399 return VERR_NOT_SUPPORTED; 1398 1400 } 1399 g_ctx.eOwner = HOST; 1401 /* Assume that if the guest clipboard already contains data then the 1402 * user put it there for a reason. */ 1403 g_ctx.eOwner = GUEST; 1400 1404 LogFlowFunc(("g_ctx.client=%u rc=%Rrc\n", g_ctx.client, rc)); 1401 1405 return rc;
Note:
See TracChangeset
for help on using the changeset viewer.