Merge pull request #1221 from caleb-allen/email-subject

add title to story sharing
This commit is contained in:
Samuel Clay 2019-08-06 09:31:16 -07:00 committed by GitHub
commit d3a429e4d3
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -307,6 +307,7 @@ public class FeedUtils {
Intent intent = new Intent(android.content.Intent.ACTION_SEND);
intent.setType("text/plain");
intent.addFlags(Intent.FLAG_ACTIVITY_NEW_TASK);
intent.putExtra(Intent.EXTRA_SUBJECT, UIUtils.fromHtml(story.title).toString());
intent.putExtra(Intent.EXTRA_TEXT, String.format(context.getResources().getString(R.string.send_brief), new Object[]{UIUtils.fromHtml(story.title), story.permalink}));
context.startActivity(Intent.createChooser(intent, "Send using"));
}