mirror of
https://github.com/M66B/FairEmail.git
synced 2026-03-28 20:06:29 +01:00
Added check for updates button in about
This commit is contained in:
@@ -31,6 +31,7 @@ import android.view.MenuInflater;
|
||||
import android.view.MenuItem;
|
||||
import android.view.View;
|
||||
import android.view.ViewGroup;
|
||||
import android.widget.ImageButton;
|
||||
import android.widget.LinearLayout;
|
||||
import android.widget.TextView;
|
||||
|
||||
@@ -51,12 +52,26 @@ public class FragmentAbout extends FragmentBase {
|
||||
|
||||
TextView tvVersion = view.findViewById(R.id.tvVersion);
|
||||
TextView tvRelease = view.findViewById(R.id.tvRelease);
|
||||
ImageButton ibUpdate = view.findViewById(R.id.ibUpdate);
|
||||
TextView tvGplV3 = view.findViewById(R.id.tvGplV3);
|
||||
LinearLayout llContributors = view.findViewById(R.id.llContributors);
|
||||
|
||||
tvVersion.setText(getString(R.string.title_version, BuildConfig.VERSION_NAME));
|
||||
tvRelease.setText(BuildConfig.RELEASE_NAME);
|
||||
|
||||
ibUpdate.setVisibility(
|
||||
Helper.hasValidFingerprint(getContext()) || BuildConfig.DEBUG
|
||||
? View.VISIBLE : View.GONE);
|
||||
ibUpdate.setOnClickListener(new View.OnClickListener() {
|
||||
@Override
|
||||
public void onClick(View v) {
|
||||
if (BuildConfig.PLAY_STORE_RELEASE)
|
||||
Helper.view(v.getContext(), Helper.getIntentRate(v.getContext()));
|
||||
else
|
||||
onMenuChangelog();
|
||||
}
|
||||
});
|
||||
|
||||
tvGplV3.setPaintFlags(tvGplV3.getPaintFlags() | Paint.UNDERLINE_TEXT_FLAG);
|
||||
tvGplV3.setOnClickListener(new View.OnClickListener() {
|
||||
@Override
|
||||
|
||||
Reference in New Issue
Block a user