Commit a1370693 authored by Thomas's avatar Thomas
Browse files

Merge branch 'develop'

parents 6314e6c2 fcc323af
Loading
Loading
Loading
Loading
+2 −2
Original line number Diff line number Diff line
@@ -13,8 +13,8 @@ android {
    defaultConfig {
        minSdk 21
        targetSdk 34
        versionCode 501
        versionName "3.25.0"
        versionCode 505
        versionName "3.26.0"
        testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
    }
    flavorDimensions "default"
+5 −1
Original line number Diff line number Diff line
@@ -193,7 +193,11 @@ public abstract class PeertubeBaseMainActivity extends BaseActivity implements C
        super.onDestroy();
        ChromeCasts.unregisterListener(this);
        if (manage_chromecast != null) {
            try {
                unregisterReceiver(manage_chromecast);
            } catch (IllegalArgumentException e) {
                e.printStackTrace();
            }
            new Thread(() -> {
                if (chromeCasts != null && chromeCasts.size() > 0) {
                    for (ChromeCast cast : chromeCasts) {
+20 −0
Original line number Diff line number Diff line
[
  {
    "version": "3.26.0",
    "code": "505",
    "note": "Added:\n- Android 14 support\n- Automatically split long messages in threads (default: ASK)\n- Links and media are clickable when composing\n- Allow to underline clickable elements (Settings > Timelines - default: disabled)\n- Allow to disable relative date in messages\n- Add a scroll bar for timelines (default: disabled)\n- Add a search bar for custom emojis\n- Links clickable in media descriptions\n\nChanged:\n- Counters close to action buttons\n- Hide emoji picker if the instance has no emoji\n- Followed tags are ordered\n- Account picker when opening with another account\n\nFixed:\n- Avoid error 429 with NTFY\n- Fix custom colors (Android 14)\n- Fix a crash when composing\n- Display issue with followed tags\n- Crashes with profiles\n- Fix an issue with poll and Pleroma\n- Emoji not displayed in the picker\n- Several crashes are fixed"
  },
  {
    "version": "3.25.3",
    "code": "504",
    "note": "Added:\n- Add a scroll bar for timelines (default: disabled)\n- Add a search bar for custom emojis\n\nFixed:\n- Fix prompt to split asked several times when refusing\n- Crashes with profiles\n- Fix an issue with poll and Pleroma\n- Emoji not displayed in the picker"
  },
  {
    "version": "3.25.2",
    "code": "503",
    "note": "Added:\n- Allow to underline clickable elements (Settings > Timelines - default: disabled)\n- Allow to disable relative date in messages\n\nChanged:\n- Counters close to action buttons\n- Hide emoji picker if the instance has no emoji\n- Followed tags are ordered\n- Account picker when opening with another account\n\nFixed:\n- Fix a crash when composing\n- Fix an issue with the back button\n- Display issue with followed tags"
  },
  {
    "version": "3.25.1",
    "code": "502",
    "note": "Fix a crash from release 3.25.0"
  },
  {
    "version": "3.25.0",
    "code": "501",
+8 −3
Original line number Diff line number Diff line
@@ -36,6 +36,7 @@ import android.content.Context;
import android.content.Intent;
import android.content.IntentFilter;
import android.content.SharedPreferences;
import android.content.res.Configuration;
import android.database.MatrixCursor;
import android.graphics.PorterDuff;
import android.graphics.drawable.BitmapDrawable;
@@ -214,6 +215,7 @@ public abstract class BaseMainActivity extends BaseActivity implements NetworkSt
    public static BaseAccount currentAccount;
    public static iconLauncher mLauncher = iconLauncher.BUBBLES;
    public static boolean headerMenuOpen;
    public static int currentNightMode;
    Fragment currentFragment;
    private AppBarConfiguration mAppBarConfiguration;
    private ActivityMainBinding binding;
@@ -1859,9 +1861,12 @@ public abstract class BaseMainActivity extends BaseActivity implements NetworkSt
    @Override
    protected void onDestroy() {

        try {
            unregisterReceiver(broadcast_data);
            unregisterReceiver(broadcast_error_message);

        } catch (IllegalArgumentException e) {
            e.printStackTrace();
        }
        if (networkStateReceiver != null) {
            try {
                unregisterReceiver(networkStateReceiver);
+21 −2
Original line number Diff line number Diff line
@@ -15,12 +15,16 @@ package app.fedilab.android.activities;
 * see <http://www.gnu.org/licenses>. */


import android.content.ClipData;
import android.content.ClipboardManager;
import android.content.Context;
import android.content.Intent;
import android.content.pm.PackageInfo;
import android.content.pm.PackageManager;
import android.os.Bundle;
import android.view.MenuItem;
import android.view.View;
import android.widget.Toast;

import androidx.core.app.ActivityOptionsCompat;
import androidx.lifecycle.ViewModelProvider;
@@ -40,6 +44,7 @@ import app.fedilab.android.mastodon.helper.CrossActionHelper;
import app.fedilab.android.mastodon.helper.Helper;
import app.fedilab.android.mastodon.helper.MastodonHelper;
import app.fedilab.android.mastodon.viewmodel.mastodon.AccountsVM;
import es.dmoral.toasty.Toasty;


public class AboutActivity extends BaseBarActivity {
@@ -58,10 +63,10 @@ public class AboutActivity extends BaseBarActivity {
        if (getSupportActionBar() != null) {
            getSupportActionBar().setDisplayHomeAsUpEnabled(true);
        }

        String version = "";
        try {
            PackageInfo pInfo = getPackageManager().getPackageInfo(getPackageName(), 0);
            String version = pInfo.versionName;
            version = pInfo.versionName;
            binding.aboutVersion.setText(getResources().getString(R.string.about_vesrion, version));
        } catch (PackageManager.NameNotFoundException ignored) {
        }
@@ -77,6 +82,20 @@ public class AboutActivity extends BaseBarActivity {
        }
        binding.aboutSupportPaypal.setOnClickListener(v -> Helper.openBrowser(AboutActivity.this, "https://www.paypal.me/Mastalab"));


        String finalVersion = version;
        binding.aboutVersionCopy.setOnClickListener(v->{

            ClipboardManager clipboard = (ClipboardManager) getSystemService(Context.CLIPBOARD_SERVICE);
            String content = "Fedilab v" + finalVersion + " for " + (BuildConfig.DONATIONS?"FDroid":"Google");

            ClipData clip = ClipData.newPlainText(Helper.CLIP_BOARD, content);
            if (clipboard != null) {
                clipboard.setPrimaryClip(clip);
                Toasty.info(AboutActivity.this, getString(R.string.clipboard_version), Toast.LENGTH_LONG).show();
            }

        });
        if (BuildConfig.DONATIONS) {
            binding.aboutSupportPaypal.setVisibility(View.VISIBLE);
        } else {
Loading