when using flavor image overflow menu prefer stream URI is available for sharing etc
This commit is contained in:
parent
4582e6afef
commit
b7b4d29395
@ -1147,15 +1147,18 @@ public class HeadlinesFragment extends Fragment implements OnItemClickListener,
|
||||
popup.setOnMenuItemClickListener(new PopupMenu.OnMenuItemClickListener() {
|
||||
@Override
|
||||
public boolean onMenuItemClick(MenuItem item) {
|
||||
|
||||
Uri mediaUri = Uri.parse(article.flavorStreamUri != null ? article.flavorStreamUri : article.flavorImageUri);
|
||||
|
||||
switch (item.getItemId()) {
|
||||
case R.id.article_img_open:
|
||||
m_activity.openUri(Uri.parse(article.flavorImageUri));
|
||||
m_activity.openUri(mediaUri);
|
||||
return true;
|
||||
case R.id.article_img_copy:
|
||||
m_activity.copyToClipboard(article.flavorImageUri);
|
||||
m_activity.copyToClipboard(mediaUri.toString());
|
||||
return true;
|
||||
case R.id.article_img_share:
|
||||
m_activity.shareText(article.flavorImageUri);
|
||||
m_activity.shareText(mediaUri.toString());
|
||||
return true;
|
||||
case R.id.article_img_view_caption:
|
||||
m_activity.displayImageCaption(article.flavorImageUri, article.content);
|
||||
|
@ -12,8 +12,8 @@
|
||||
<item
|
||||
android:id="@+id/article_img_share"
|
||||
android:icon="@drawable/ic_share"
|
||||
app:showAsAction="ifRoom"
|
||||
android:title="@string/article_img_share"/>
|
||||
app:showAsAction=""
|
||||
android:title="@string/article_media_share"/>
|
||||
<item
|
||||
android:id="@+id/article_img_view_caption"
|
||||
app:showAsAction=""
|
||||
|
@ -164,8 +164,7 @@
|
||||
<string name="headlines_starred">Starred</string>
|
||||
<string name="headlines_published">Published</string>
|
||||
<string name="headlines_unread">Unread</string>
|
||||
<string name="article_img_open">Open image</string>
|
||||
<string name="article_img_share">Share image</string>
|
||||
<string name="article_media_share">Share</string>
|
||||
<string name="article_img_view_caption">View Caption</string>
|
||||
<string name="pref_headlines_mark_read_scroll">Mark read on scroll</string>
|
||||
<string name="pref_headlines_mark_read_scroll_long">Headlines will be marked read when scrolling past them</string>
|
||||
|
Loading…
Reference in New Issue
Block a user