Toolkit.
| Access | Constructor and Description |
|---|---|
| public |
| Modifier and Type | Method and Description |
|---|---|
| public String | getContents()
Implements com. gets the current content of the clipboard if it contains text for WebGL app, getting the system clipboard is currently not supported. |
| public boolean | hasContents()
Implements com. Check if the clipboard has contents. |
| public void | lostOwnership(Clipboard arg0, Transferable arg1)
Implements java. Notifies this object that it is no longer the clipboard owner. |
| public void | setContents(String content)
Implements com. Sets the content of the system clipboard. |
| LwjglClipboard | back to summary |
|---|---|
| public LwjglClipboard() | |
| getContents | back to summary |
|---|---|
| public String getContents() Implements com. Doc from com. gets the current content of the clipboard if it contains text for WebGL app, getting the system clipboard is currently not supported. It works only inside the app
| |
| hasContents | back to summary |
|---|---|
| public boolean hasContents() Implements com. Doc from com. Check if the clipboard has contents. Recommended to use over getContents() for privacy reasons, if you only want to check if there's something on the clipboard. For instance, calling getContents() on iOS shows a privacy notification since iOS 14, while hasContents() does not.
| |
| lostOwnership | back to summary |
|---|---|
| public void lostOwnership(Clipboard arg0, Transferable arg1) Implements java. Doc from java. Notifies this object that it is no longer the clipboard owner. This method will be called when another application or another object within this application asserts ownership of the clipboard.
| |
| setContents | back to summary |
|---|---|
| public void setContents(String content) Implements com. Doc from com. Sets the content of the system clipboard. for WebGL app, clipboard content might not be set if user denied permission, setting clipboard is not synchronous so you can't rely on getting same content just after setting it
| |