Remove screenshot in mentions

This commit is contained in:
tom79 2019-05-11 19:29:39 +02:00
parent 5a7f431f25
commit f8d823360e
2 changed files with 7 additions and 7 deletions

View File

@ -456,9 +456,9 @@ public class TootActivity extends BaseActivity implements OnPostActionInterface,
toot_content.setSelection(toot_content.getText().length());
toot_space_left.setText(String.valueOf(toot_content.length()));
}
if( tootMention != null && urlMention != null && fileMention != null) {
Bitmap pictureMention = BitmapFactory.decodeFile(getCacheDir() + "/" + fileMention);
if (pictureMention != null) {
if( tootMention != null && urlMention != null) {
if (fileMention != null) {
Bitmap pictureMention = BitmapFactory.decodeFile(getCacheDir() + "/" + fileMention);
AsyncTask.execute(new Runnable() {
@Override
public void run() {

View File

@ -2508,13 +2508,13 @@ public class StatusListAdapter extends RecyclerView.Adapter implements OnPostAct
handler.postDelayed(new Runnable() {
@Override
public void run() {
String name = "@" + (status.getReblog() != null ? status.getReblog().getAccount().getAcct() : status.getAccount().getAcct());
/*String name = "@" + (status.getReblog() != null ? status.getReblog().getAccount().getAcct() : status.getAccount().getAcct());
if (name.split("@", -1).length - 1 == 1)
name = name + "@" + getLiveInstance(context);
Bitmap bitmap = Helper.convertTootIntoBitmap(context, name, holder.status_content);
Bitmap bitmap = Helper.convertTootIntoBitmap(context, name, holder.status_content);*/
Intent intent = new Intent(context, TootActivity.class);
Bundle b = new Bundle();
String fname = "tootmention_" + status.getId() + ".jpg";
/*String fname = "tootmention_" + status.getId() + ".jpg";
File file = new File(context.getCacheDir() + "/", fname);
if (file.exists()) //noinspection ResultOfMethodCallIgnored
file.delete();
@ -2526,7 +2526,7 @@ public class StatusListAdapter extends RecyclerView.Adapter implements OnPostAct
out.close();
} catch (Exception ignored) {
}
b.putString("fileMention", fname);
b.putString("fileMention", fname);*/
b.putString("tootMention", (status.getReblog() != null) ? status.getReblog().getAccount().getAcct() : status.getAccount().getAcct());
b.putString("urlMention", (status.getReblog() != null) ? status.getReblog().getUrl() : status.getUrl());
intent.putExtras(b);