From d6d708660007d02d381a0e651e1588d517fdbbee Mon Sep 17 00:00:00 2001 From: tom79 Date: Thu, 16 Apr 2020 16:23:48 +0200 Subject: [PATCH] Prepare release 2.35.0 --- app/build.gradle | 4 +- app/src/main/assets/changelogs/363.txt | 4 ++ .../app/fedilab/android/helper/Helper.java | 56 ++++++++++--------- 3 files changed, 35 insertions(+), 29 deletions(-) create mode 100644 app/src/main/assets/changelogs/363.txt diff --git a/app/build.gradle b/app/build.gradle index 780fc4b99..6e554190e 100644 --- a/app/build.gradle +++ b/app/build.gradle @@ -6,8 +6,8 @@ android { defaultConfig { minSdkVersion 19 targetSdkVersion 29 - versionCode 362 - versionName "2.34.5" + versionCode 363 + versionName "2.35.0" multiDexEnabled true renderscriptTargetApi 28 as int renderscriptSupportModeEnabled true diff --git a/app/src/main/assets/changelogs/363.txt b/app/src/main/assets/changelogs/363.txt new file mode 100644 index 000000000..bd7b31b80 --- /dev/null +++ b/app/src/main/assets/changelogs/363.txt @@ -0,0 +1,4 @@ +Fixed: +- Lot of crashes 🥺🥺🥺🥺🥺😱 +- Push notifications not working +- Some issues with filters \ No newline at end of file diff --git a/app/src/main/java/app/fedilab/android/helper/Helper.java b/app/src/main/java/app/fedilab/android/helper/Helper.java index 4d91a1027..1816699de 100644 --- a/app/src/main/java/app/fedilab/android/helper/Helper.java +++ b/app/src/main/java/app/fedilab/android/helper/Helper.java @@ -1788,37 +1788,39 @@ public class Helper { if (!accountChoice.getAvatar().startsWith("http")) accountChoice.setAvatar("https://" + accountChoice.getInstance() + accountChoice.getAvatar()); ImageView itemIconAcc = new ImageView(activity); - Glide.with(activity) - .asDrawable() - .apply(new RequestOptions().transform(new CenterCrop(), new RoundedCorners(270))) - .load(!disableGif ? accountChoice.getAvatar() : accountChoice.getAvatar_static()) - .listener(new RequestListener() { + if( !activity.isFinishing()) { + Glide.with(activity) + .asDrawable() + .apply(new RequestOptions().transform(new CenterCrop(), new RoundedCorners(270))) + .load(!disableGif ? accountChoice.getAvatar() : accountChoice.getAvatar_static()) + .listener(new RequestListener() { - @Override - public boolean onResourceReady(Drawable resource, Object model, Target target, DataSource dataSource, boolean isFirstResource) { - return false; - } + @Override + public boolean onResourceReady(Drawable resource, Object model, Target target, DataSource dataSource, boolean isFirstResource) { + return false; + } - @Override - public boolean onLoadFailed(@Nullable GlideException e, Object model, Target target, boolean isFirstResource) { - if (MainActivity.social == UpdateAccountInfoAsyncTask.SOCIAL.MASTODON || MainActivity.social == UpdateAccountInfoAsyncTask.SOCIAL.PLEROMA) - itemIconAcc.setImageResource(R.drawable.missing); - else if (MainActivity.social == UpdateAccountInfoAsyncTask.SOCIAL.PEERTUBE) - itemIconAcc.setImageResource(R.drawable.missing_peertube); - return false; - } - }) - .into(new CustomTarget() { - @Override - public void onResourceReady(@NonNull Drawable resource, Transition transition) { - itemIconAcc.setImageDrawable(resource); - } + @Override + public boolean onLoadFailed(@Nullable GlideException e, Object model, Target target, boolean isFirstResource) { + if (MainActivity.social == UpdateAccountInfoAsyncTask.SOCIAL.MASTODON || MainActivity.social == UpdateAccountInfoAsyncTask.SOCIAL.PLEROMA) + itemIconAcc.setImageResource(R.drawable.missing); + else if (MainActivity.social == UpdateAccountInfoAsyncTask.SOCIAL.PEERTUBE) + itemIconAcc.setImageResource(R.drawable.missing_peertube); + return false; + } + }) + .into(new CustomTarget() { + @Override + public void onResourceReady(@NonNull Drawable resource, Transition transition) { + itemIconAcc.setImageDrawable(resource); + } - @Override - public void onLoadCleared(@Nullable Drawable placeholder) { + @Override + public void onLoadCleared(@Nullable Drawable placeholder) { - } - }); + } + }); + } if (accounts.size() > 2) { if (accountChoice.getSocial() != null && accountChoice.getSocial().equals("PEERTUBE"))