This commit is contained in:
stom79 2019-02-13 09:30:45 +01:00
parent edc317f97b
commit be873f203e
3 changed files with 5 additions and 4 deletions

View File

@ -748,10 +748,10 @@ public class NotificationsListAdapter extends RecyclerView.Adapter implements On
case R.id.action_copy_link:
clipboard = (ClipboardManager) context.getSystemService(Context.CLIPBOARD_SERVICE);
clip = ClipData.newPlainText(Helper.CLIP_BOARD, status.getUrl());
clip = ClipData.newPlainText(Helper.CLIP_BOARD, status.getReblog()!=null?status.getReblog().getUrl():status.getUrl());
if (clipboard != null) {
clipboard.setPrimaryClip(clip);
Toasty.info(context, context.getString(R.string.clipboard), Toast.LENGTH_LONG).show();
Toasty.info(context, context.getString(R.string.clipboard_url), Toast.LENGTH_LONG).show();
}
return true;
case R.id.action_share:

View File

@ -2048,10 +2048,10 @@ public class StatusListAdapter extends RecyclerView.Adapter implements OnPostAct
case R.id.action_copy_link:
clipboard = (ClipboardManager) context.getSystemService(Context.CLIPBOARD_SERVICE);
clip = ClipData.newPlainText(Helper.CLIP_BOARD, status.getUrl());
clip = ClipData.newPlainText(Helper.CLIP_BOARD, status.getReblog()!=null?status.getReblog().getUrl():status.getUrl());
if (clipboard != null) {
clipboard.setPrimaryClip(clip);
Toasty.info(context, context.getString(R.string.clipboard), Toast.LENGTH_LONG).show();
Toasty.info(context, context.getString(R.string.clipboard_url), Toast.LENGTH_LONG).show();
}
return true;
case R.id.action_share:

View File

@ -37,6 +37,7 @@
<string name="toast_account_changed" formatted="false">Now works with the account %1$s</string>
<string name="add_account">Add an account</string>
<string name="clipboard">The content of the toot has been copied to the clipboard</string>
<string name="clipboard_url">The URL of the toot has been copied to the clipboard</string>
<string name="change">Change</string>
<string name="choose_picture">Select a picture…</string>
<string name="clear">Clean</string>