Skip to main content



      Home
Home » Eclipse Projects » Remote Application Platform (RAP) » Copy-Paste
Copy-Paste [message #1864127] Mon, 18 March 2024 06:47 Go to next message
Eclipse UserFriend

Hi everyone

it doesn't work Clipboard function inside Safari browser
for Chrome that's all right
Is this restrict for Safari or RAP problem?
Dmitry

static void copyToClipboard(String text) {
        Clipboard clipboard = new Clipboard(Display.getCurrent());
        clipboard.setContents(new Object[]{text}, new Transfer[]{TextTransfer.getInstance()});
        clipboard.dispose();
        infoCopyToClipboard();
    }


2024-03-18 12:33:01 SEVERE: RAP exception: Cannot set data in clipboard thread UIThread [6dd402f6]
org.eclipse.swt.SWTError: Cannot set data in clipboard
at org.eclipse.swt.dnd.DND.error(DND.java:263)
at org.eclipse.swt.dnd.DND.error(DND.java:219)
at org.eclipse.swt.dnd.Clipboard.setContents(Clipboard.java:272)
at shop.rwt.widgets.RwtWidget.copyToClipboard(RwtWidget.java:580)
at shop.rwt.table.RwtMenuTable$CopyRowsView.lambda$createDialogArea$6b06c921$1(RwtMenuTable.java:324)
at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java:109)
at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:687)
at org.eclipse.swt.widgets.Widget.notifyListeners(Widget.java:594)
at org.eclipse.swt.widgets.Display.executeNextEvent(Display.java:1216)
at org.eclipse.swt.widgets.Display.runPendingMessages(Display.java:1197)
at org.eclipse.swt.widgets.Display.safeReadAndDispatch(Display.java:1180)
at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:1172)
at org.eclipse.jface.window.Window.runEventLoop(Window.java:869)
at org.eclipse.jface.window.Window.open(Window.java:845)
Re: Copy-Paste [message #1864483 is a reply to message #1864127] Tue, 19 March 2024 09:07 Go to previous messageGo to next message
Eclipse UserFriend
The question is closed
This is safari's behaviour
with chrome, firefox, edge is all right

[Updated on: Mon, 15 April 2024 17:28] by Moderator

Re: Copy-Paste [message #1870509 is a reply to message #1864483] Sat, 31 August 2024 07:36 Go to previous message
Eclipse UserFriend
Question is opened again. I saw that ChatGpt UI has copy-function from web for Safari and it'w works.
Previous Topic:Rap and Style
Next Topic:Part view in a subproject with fragment.e4xmi: method with annotation @PostConstruct is not called
Goto Forum:
  


Current Time: Wed Jul 02 11:47:01 EDT 2025

Powered by FUDForum. Page generated in 0.04427 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top