This commit is contained in:
tom79 2020-04-08 19:15:44 +02:00
parent 56e74e3120
commit 050a492338
1 changed files with 23 additions and 21 deletions

View File

@ -1669,9 +1669,7 @@ public class StatusListAdapter extends RecyclerView.Adapter implements OnPostAct
Toasty.error(context, context.getString(R.string.toast_error), Toast.LENGTH_LONG).show();
}
});
holder.fetch_more.setOnLongClickListener(new View.OnLongClickListener() {
@Override
public boolean onLongClick(View v) {
holder.fetch_more.setOnLongClickListener(v -> {
status.setFetchMore(false);
holder.fetch_more.setEnabled(false);
holder.fetch_more.setVisibility(View.GONE);
@ -1692,7 +1690,6 @@ public class StatusListAdapter extends RecyclerView.Adapter implements OnPostAct
Toasty.error(context, context.getString(R.string.toast_error), Toast.LENGTH_LONG).show();
}
return false;
}
});
} else {
holder.fetch_more.setVisibility(View.GONE);
@ -3402,7 +3399,12 @@ public class StatusListAdapter extends RecyclerView.Adapter implements OnPostAct
});
boolean long_press_media = sharedpreferences.getBoolean(Helper.SET_LONG_PRESS_MEDIA, true);
if (long_press_media) {
String finalUrl = url;
String finalUrl;
if( attachment.getUrl() == null ){
finalUrl = attachment.getRemote_url();
}else{
finalUrl = attachment.getUrl();
}
imageView.setOnLongClickListener(v -> {
Helper.manageMove(context, finalUrl, false);
return true;