mirror of
https://github.com/juce-framework/JUCE.git
synced 2026-01-10 23:44:24 +00:00
Android: fix crash when accessing system clipboard.
This commit is contained in:
parent
f737fc0882
commit
5862d832e6
1 changed files with 3 additions and 1 deletions
|
|
@ -478,7 +478,9 @@ public class JuceAppActivity extends $$JuceAppActivityBaseClass$$
|
|||
public final String getClipboardContent()
|
||||
{
|
||||
ClipboardManager clipboard = (ClipboardManager) getSystemService (CLIPBOARD_SERVICE);
|
||||
return clipboard.getText().toString();
|
||||
|
||||
CharSequence content = clipboard.getText();
|
||||
return content != null ? content.toString() : new String();
|
||||
}
|
||||
|
||||
public final void setClipboardContent (String newText)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue