mirror of
https://codeberg.org/Freeyourgadget/Gadgetbridge
synced 2024-11-27 20:36:51 +01:00
Add version to About screen
This commit is contained in:
parent
4d42e169b9
commit
95c35deb90
@ -20,6 +20,7 @@ package nodomain.freeyourgadget.gadgetbridge.activities;
|
||||
import android.os.Bundle;
|
||||
import android.text.method.LinkMovementMethod;
|
||||
import android.widget.TextView;
|
||||
import nodomain.freeyourgadget.gadgetbridge.BuildConfig;
|
||||
|
||||
import nodomain.freeyourgadget.gadgetbridge.R;
|
||||
|
||||
@ -29,6 +30,10 @@ public class AboutActivity extends AbstractGBActivity {
|
||||
protected void onCreate(Bundle savedInstanceState) {
|
||||
super.onCreate(savedInstanceState);
|
||||
setContentView(R.layout.activity_about);
|
||||
TextView about_version = findViewById(R.id.about_version);
|
||||
String versionName = BuildConfig.VERSION_NAME;
|
||||
about_version.setText(String.format(getString(R.string.about_version), versionName));
|
||||
|
||||
TextView link1 = findViewById(R.id.links1);
|
||||
link1.setMovementMethod(LinkMovementMethod.getInstance());
|
||||
TextView link2 = findViewById(R.id.links2);
|
||||
|
@ -12,7 +12,7 @@
|
||||
android:layout_centerInParent="true"
|
||||
android:alpha="0.1"
|
||||
android:contentDescription="@string/icon_placeholder"
|
||||
android:tint="?attr/textColorPrimary"
|
||||
app:tint="?attr/textColorPrimary"
|
||||
app:srcCompat="@drawable/gadgetbridge_img" />
|
||||
|
||||
<ScrollView
|
||||
@ -48,6 +48,11 @@
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@string/about_description" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/about_version"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content" />
|
||||
</LinearLayout>
|
||||
|
||||
<TextView
|
||||
|
@ -930,6 +930,7 @@
|
||||
<string name="codeberg_url" translatable="false">Code: <a href="https://codeberg.org/Freeyourgadget/Gadgetbridge">https://codeberg.org/Freeyourgadget/Gadgetbridge</a></string>
|
||||
<string name="fdroid_url" translatable="false">F-Droid: <a href="https://f-droid.org/packages/nodomain.freeyourgadget.gadgetbridge/">https://f-droid.org/packages/nodomain.freeyourgadget.gadgetbridge/</a></string>
|
||||
<string name="about_title">About</string>
|
||||
<string name="about_version">Version %s</string>
|
||||
<string name="about_activity_title">About Gadgetbridge</string>
|
||||
<string name="about_description">Cloudless copylefted libre replacement for closed source Android gadget apps from vendors.</string>
|
||||
<string name="about_core_team_title">Core Team (in order of first code contribution)</string>
|
||||
|
Loading…
Reference in New Issue
Block a user