Merge pull request #5091 from k9mail/about_screen

Rework appearance of About screen
This commit is contained in:
cketti 2021-01-19 01:47:05 +01:00 committed by GitHub
commit 1def1cb065
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
18 changed files with 546 additions and 289 deletions

View file

@ -1,5 +1,7 @@
package com.fsck.k9.ui.settings
import android.content.ActivityNotFoundException
import android.content.Context
import android.content.Intent
import android.content.pm.PackageManager
import android.net.Uri
@ -7,18 +9,15 @@ import android.os.Bundle
import android.view.LayoutInflater
import android.view.View
import android.view.ViewGroup
import android.widget.TextView
import android.widget.Toast
import androidx.fragment.app.Fragment
import androidx.recyclerview.widget.LinearLayoutManager
import androidx.recyclerview.widget.RecyclerView
import com.fsck.k9.ui.R
import de.cketti.library.changelog.ChangeLog
import java.util.Calendar
import kotlinx.android.synthetic.main.about_library.view.*
import kotlinx.android.synthetic.main.fragment_about.*
import timber.log.Timber
private data class Library(val name: String, val URL: String, val license: String)
class AboutFragment : Fragment() {
override fun onCreateView(inflater: LayoutInflater, container: ViewGroup?, savedInstanceState: Bundle?): View? {
return inflater.inflate(R.layout.fragment_about, container, false)
@ -27,32 +26,50 @@ class AboutFragment : Fragment() {
override fun onViewCreated(view: View, savedInstanceState: Bundle?) {
super.onViewCreated(view, savedInstanceState)
version.text = getVersionNumber()
val versionTextView = view.findViewById<TextView>(R.id.version)
versionTextView.text = getVersionNumber()
val versionLayout = view.findViewById<View>(R.id.versionLayout)
versionLayout.setOnClickListener { displayChangeLog() }
val year = Calendar.getInstance().get(Calendar.YEAR).toString()
copyright.text = getString(R.string.app_copyright_fmt, year, year)
val authorsLayout = view.findViewById<View>(R.id.authorsLayout)
authorsLayout.setOnClickListener {
startActivity(Intent(Intent.ACTION_VIEW, Uri.parse(getString(R.string.app_authors_url))))
openUrl(getString(R.string.app_authors_url))
}
val licenseLayout = view.findViewById<View>(R.id.licenseLayout)
licenseLayout.setOnClickListener {
startActivity(Intent(Intent.ACTION_VIEW, Uri.parse(getString(R.string.app_license_url))))
openUrl(getString(R.string.app_license_url))
}
source.setOnClickListener {
startActivity(Intent(Intent.ACTION_VIEW, Uri.parse(getString(R.string.app_source_url))))
val sourceCodeLayout = view.findViewById<View>(R.id.sourceCodeLayout)
sourceCodeLayout.setOnClickListener {
openUrl(getString(R.string.app_source_url))
}
changelog.setOnClickListener { displayChangeLog() }
val websiteLayout = view.findViewById<View>(R.id.websiteLayout)
websiteLayout.setOnClickListener {
openUrl(getString(R.string.app_webpage_url))
}
revisions.setOnClickListener {
startActivity(Intent(Intent.ACTION_VIEW, Uri.parse(getString(R.string.app_revision_url))))
val userForumLayout = view.findViewById<View>(R.id.userForumLayout)
userForumLayout.setOnClickListener {
openUrl(getString(R.string.user_forum_url))
}
val fediverseLayout = view.findViewById<View>(R.id.fediverseLayout)
fediverseLayout.setOnClickListener {
openUrl(getString(R.string.fediverse_url))
}
val twitterLayout = view.findViewById<View>(R.id.twitterLayout)
twitterLayout.setOnClickListener {
openUrl(getString(R.string.twitter_url))
}
val manager = LinearLayoutManager(view.context)
libraries.apply {
val librariesRecyclerView = view.findViewById<RecyclerView>(R.id.libraries)
librariesRecyclerView.apply {
layoutManager = manager
adapter = LibrariesAdapter(USED_LIBRARIES)
isNestedScrollingEnabled = false
@ -104,10 +121,26 @@ class AboutFragment : Fragment() {
}
}
private fun Fragment.openUrl(url: String) = requireContext().openUrl(url)
private fun Context.openUrl(url: String) {
try {
val viewIntent = Intent(Intent.ACTION_VIEW, Uri.parse(url))
startActivity(viewIntent)
} catch (e: ActivityNotFoundException) {
Toast.makeText(this, R.string.error_activity_not_found, Toast.LENGTH_SHORT).show()
}
}
private data class Library(val name: String, val url: String, val license: String)
private class LibrariesAdapter(private val dataset: Array<Library>) :
RecyclerView.Adapter<LibrariesAdapter.ViewHolder>() {
class ViewHolder(val view: View) : RecyclerView.ViewHolder(view)
class ViewHolder(view: View) : RecyclerView.ViewHolder(view) {
val name: TextView = view.findViewById(R.id.name)
val license: TextView = view.findViewById(R.id.license)
}
override fun onCreateViewHolder(parent: ViewGroup, viewType: Int): ViewHolder {
val view = LayoutInflater.from(parent.context).inflate(R.layout.about_library, parent, false)
@ -116,11 +149,10 @@ private class LibrariesAdapter(private val dataset: Array<Library>) :
override fun onBindViewHolder(holder: ViewHolder, index: Int) {
val library = dataset[index]
holder.view.name.text = library.name
holder.view.license.text = library.license
holder.view.setOnClickListener {
holder.view.context
.startActivity(Intent(Intent.ACTION_VIEW, Uri.parse(library.URL)))
holder.name.text = library.name
holder.license.text = library.license
holder.itemView.setOnClickListener {
holder.itemView.context.openUrl(library.url)
}
}

View file

@ -1,9 +0,0 @@
<vector xmlns:android="http://schemas.android.com/apk/res/android"
android:width="24dp"
android:height="24dp"
android:viewportHeight="24.0"
android:viewportWidth="24.0">
<path
android:fillColor="#FFFFFFFF"
android:pathData="M9.4 16.6L4.8 12l4.6-4.6L8 6l-6 6 6 6 1.4-1.4zm5.2 0l4.6-4.6-4.6-4.6L16 6l6 6-6 6-1.4-1.4z" />
</vector>

View file

@ -1,9 +0,0 @@
<vector xmlns:android="http://schemas.android.com/apk/res/android"
android:width="24dp"
android:height="24dp"
android:viewportHeight="24.0"
android:viewportWidth="24.0">
<path
android:fillColor="#FFFFFFFF"
android:pathData="M14 2H6c-1.1 0-1.99.9-1.99 2L4 20c0 1.1.89 2 1.99 2H18c1.1 0 2-.9 2-2V8l-6-6zm2 16H8v-2h8v2zm0-4H8v-2h8v2zm-3-5V3.5L18.5 9H13z" />
</vector>

View file

@ -1,10 +0,0 @@
<vector xmlns:android="http://schemas.android.com/apk/res/android"
android:width="24dp"
android:height="24dp"
android:alpha="0.54"
android:viewportHeight="24.0"
android:viewportWidth="24.0">
<path
android:fillColor="#FF000000"
android:pathData="M14 2H6c-1.1 0-1.99.9-1.99 2L4 20c0 1.1.89 2 1.99 2H18c1.1 0 2-.9 2-2V8l-6-6zm2 16H8v-2h8v2zm0-4H8v-2h8v2zm-3-5V3.5L18.5 9H13z" />
</vector>

View file

@ -1,10 +1,10 @@
<vector xmlns:android="http://schemas.android.com/apk/res/android"
android:width="24dp"
android:height="24dp"
android:alpha="0.54"
android:viewportHeight="24.0"
android:viewportWidth="24.0">
android:tint="?attr/colorControlNormal"
android:viewportWidth="24"
android:viewportHeight="24">
<path
android:fillColor="#FF000000"
android:fillColor="@android:color/white"
android:pathData="M9.4 16.6L4.8 12l4.6-4.6L8 6l-6 6 6 6 1.4-1.4zm5.2 0l4.6-4.6-4.6-4.6L16 6l6 6-6 6-1.4-1.4z" />
</vector>

View file

@ -0,0 +1,10 @@
<vector xmlns:android="http://schemas.android.com/apk/res/android"
android:width="24dp"
android:height="24dp"
android:tint="?attr/colorControlNormal"
android:viewportWidth="24"
android:viewportHeight="24">
<path
android:fillColor="@android:color/white"
android:pathData="M14 2H6c-1.1 0-1.99.9-1.99 2L4 20c0 1.1.89 2 1.99 2H18c1.1 0 2-.9 2-2V8l-6-6zm2 16H8v-2h8v2zm0-4H8v-2h8v2zm-3-5V3.5L18.5 9H13z" />
</vector>

View file

@ -0,0 +1,10 @@
<vector xmlns:android="http://schemas.android.com/apk/res/android"
android:width="24dp"
android:height="24dp"
android:tint="?attr/colorControlNormal"
android:viewportWidth="24"
android:viewportHeight="24">
<path
android:fillColor="@android:color/white"
android:pathData="M21,6h-2v9L6,15v2c0,0.55 0.45,1 1,1h11l4,4L22,7c0,-0.55 -0.45,-1 -1,-1zM17,12L17,3c0,-0.55 -0.45,-1 -1,-1L3,2c-0.55,0 -1,0.45 -1,1v14l4,-4h10c0.55,0 1,-0.45 1,-1z" />
</vector>

View file

@ -0,0 +1,10 @@
<vector xmlns:android="http://schemas.android.com/apk/res/android"
android:width="24dp"
android:height="24dp"
android:tint="?attr/colorControlNormal"
android:viewportWidth="24"
android:viewportHeight="24">
<path
android:fillColor="@android:color/white"
android:pathData="M11,17h2v-6h-2v6zM12,2C6.48,2 2,6.48 2,12s4.48,10 10,10 10,-4.48 10,-10S17.52,2 12,2zM12,20c-4.41,0 -8,-3.59 -8,-8s3.59,-8 8,-8 8,3.59 8,8 -3.59,8 -8,8zM11,9h2L13,7h-2v2z" />
</vector>

View file

@ -0,0 +1,10 @@
<vector xmlns:android="http://schemas.android.com/apk/res/android"
android:width="24dp"
android:height="24dp"
android:tint="?attr/colorControlNormal"
android:viewportWidth="24"
android:viewportHeight="24">
<path
android:fillColor="@android:color/white"
android:pathData="M3.9,12c0,-1.71 1.39,-3.1 3.1,-3.1h4L11,7L7,7c-2.76,0 -5,2.24 -5,5s2.24,5 5,5h4v-1.9L7,15.1c-1.71,0 -3.1,-1.39 -3.1,-3.1zM8,13h8v-2L8,11v2zM17,7h-4v1.9h4c1.71,0 3.1,1.39 3.1,3.1s-1.39,3.1 -3.1,3.1h-4L13,17h4c2.76,0 5,-2.24 5,-5s-2.24,-5 -5,-5z" />
</vector>

View file

@ -0,0 +1,10 @@
<vector xmlns:android="http://schemas.android.com/apk/res/android"
android:width="24dp"
android:height="24dp"
android:tint="?attr/colorControlNormal"
android:viewportWidth="24"
android:viewportHeight="24">
<path
android:fillColor="@android:color/white"
android:pathData="M20.94,14c-0.28,1.41 -2.44,2.96 -4.97,3.26c-1.31,0.15 -2.6,0.3 -3.97,0.24c-2.25,-0.11 -4,-0.54 -4,-0.54v0.62c0.32,2.22 2.22,2.35 4.03,2.42c1.82,0.05 3.44,-0.46 3.44,-0.46l0.08,1.65s-1.28,0.68 -3.55,0.81c-1.25,0.07 -2.81,-0.03 -4.62,-0.5c-3.92,-1.05 -4.6,-5.24 -4.7,-9.5l-0.01,-3.43c0,-4.34 2.83,-5.61 2.83,-5.61C6.95,2.3 9.41,2 11.97,2h0.06c2.56,0 5.02,0.3 6.47,0.96c0,0 2.83,1.27 2.83,5.61c0,0 0.04,3.21 -0.39,5.43M18,8.91c0,-1.08 -0.3,-1.91 -0.85,-2.56c-0.56,-0.63 -1.3,-0.96 -2.23,-0.96c-1.06,0 -1.87,0.41 -2.42,1.23l-0.5,0.88l-0.5,-0.88c-0.56,-0.82 -1.36,-1.23 -2.43,-1.23c-0.92,0 -1.66,0.33 -2.23,0.96C6.29,7 6,7.83 6,8.91v5.26h2.1V9.06c0,-1.06 0.45,-1.62 1.36,-1.62c1,0 1.5,0.65 1.5,1.93v2.79h2.07V9.37c0,-1.28 0.5,-1.93 1.51,-1.93c0.9,0 1.35,0.56 1.35,1.62v5.11H18V8.91z" />
</vector>

View file

@ -0,0 +1,10 @@
<vector xmlns:android="http://schemas.android.com/apk/res/android"
android:width="24dp"
android:height="24dp"
android:tint="?attr/colorControlNormal"
android:viewportWidth="24"
android:viewportHeight="24">
<path
android:fillColor="@android:color/white"
android:pathData="M16,11c1.66,0 2.99,-1.34 2.99,-3S17.66,5 16,5c-1.66,0 -3,1.34 -3,3s1.34,3 3,3zM8,11c1.66,0 2.99,-1.34 2.99,-3S9.66,5 8,5C6.34,5 5,6.34 5,8s1.34,3 3,3zM8,13c-2.33,0 -7,1.17 -7,3.5L1,19h14v-2.5c0,-2.33 -4.67,-3.5 -7,-3.5zM16,13c-0.29,0 -0.62,0.02 -0.97,0.05 1.16,0.84 1.97,1.97 1.97,3.45L17,19h6v-2.5c0,-2.33 -4.67,-3.5 -7,-3.5z" />
</vector>

View file

@ -0,0 +1,10 @@
<vector xmlns:android="http://schemas.android.com/apk/res/android"
android:width="24dp"
android:height="24dp"
android:tint="?attr/colorControlNormal"
android:viewportWidth="24"
android:viewportHeight="24">
<path
android:fillColor="@android:color/white"
android:pathData="M22.46,6c-0.77,0.35 -1.6,0.58 -2.46,0.69c0.88,-0.53 1.56,-1.37 1.88,-2.38c-0.83,0.5 -1.75,0.85 -2.72,1.05C18.37,4.5 17.26,4 16,4c-2.35,0 -4.27,1.92 -4.27,4.29c0,0.34 0.04,0.67 0.11,0.98C8.28,9.09 5.11,7.38 3,4.79c-0.37,0.63 -0.58,1.37 -0.58,2.15c0,1.49 0.75,2.81 1.91,3.56c-0.71,0 -1.37,-0.2 -1.95,-0.5v0.03c0,2.08 1.48,3.82 3.44,4.21a4.22,4.22 0,0 1,-1.93 0.07a4.28,4.28 0,0 0,4 2.98a8.521,8.521 0,0 1,-5.33 1.84c-0.34,0 -0.68,-0.02 -1.02,-0.06C3.44,20.29 5.7,21 8.12,21C16,21 20.33,14.46 20.33,8.79c0,-0.19 0,-0.37 -0.01,-0.56c0.84,-0.6 1.56,-1.36 2.14,-2.23z" />
</vector>

View file

@ -1,31 +1,31 @@
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:paddingTop="16dp"
android:paddingBottom="16dp"
android:paddingLeft="16dp"
android:paddingRight="16dp"
android:clickable="true"
android:focusable="true"
android:background="?attr/selectableItemBackground">
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:background="?attr/selectableItemBackground"
android:clickable="true"
android:focusable="true"
android:orientation="vertical"
android:paddingLeft="16dp"
android:paddingTop="12dp"
android:paddingRight="16dp"
android:paddingBottom="12dp">
<TextView
android:id="@+id/name"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:gravity="center_vertical"
android:text="Test"
android:textColor="?android:attr/textColorPrimary" />
android:id="@+id/name"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:textAppearance="@style/TextAppearance.AppCompat.Medium"
android:textColor="?android:attr/textColorPrimary"
tools:text="Android Jetpack libraries" />
<TextView
android:id="@+id/license"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginLeft="16dp"
android:gravity="center_vertical"
android:ellipsize="end"
android:maxLines="1"
android:text="Test"
android:textColor="?android:attr/textColorSecondary" />
android:id="@+id/license"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="4dp"
android:textAppearance="@style/TextAppearance.AppCompat.Small"
tools:text="Apache License, Version 2.0" />
</LinearLayout>

View file

@ -1,216 +1,371 @@
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
android:orientation="vertical"
android:layout_height="fill_parent"
android:layout_width="fill_parent">
<androidx.core.widget.NestedScrollView xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent">
<androidx.core.widget.NestedScrollView
android:layout_height="fill_parent"
android:layout_width="fill_parent">
<LinearLayout
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="vertical">
<ImageView
android:layout_width="100dp"
android:layout_height="100dp"
android:layout_gravity="center"
android:layout_margin="16dp"
android:contentDescription="@null"
app:srcCompat="@mipmap/icon" />
<TextView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:paddingLeft="16dp"
android:paddingTop="16dp"
android:paddingBottom="16dp"
android:text="@string/about_title"
android:textAppearance="?android:attr/textAppearanceLarge"
android:textColor="?android:attr/textColorPrimary" />
<LinearLayout
android:orientation="vertical"
android:layout_height="fill_parent"
android:layout_width="fill_parent">
android:id="@+id/versionLayout"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:background="?attr/selectableItemBackground"
android:clickable="true"
android:focusable="true"
android:gravity="center_vertical"
android:paddingLeft="16dp"
android:paddingTop="8dp"
android:paddingRight="16dp"
android:paddingBottom="8dp">
<ImageView
app:srcCompat="@mipmap/icon"
android:layout_width="100dp"
android:layout_height="100dp"
android:layout_gravity="center"
android:layout_margin="16dp" />
<TextView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:paddingTop="16dp"
android:paddingBottom="16dp"
android:paddingLeft="16dp"
android:gravity="center_vertical"
android:text="@string/about_title"
android:textColor="?android:attr/textColorPrimary"
android:textAppearance="?android:attr/textAppearanceLarge" />
android:layout_width="24dp"
android:layout_height="24dp"
android:layout_gravity="center"
android:contentDescription="@null"
app:srcCompat="?attr/iconAboutVersion" />
<LinearLayout
android:id="@+id/versionLayout"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="vertical"
android:paddingLeft="30dp">
<TextView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:paddingTop="8dp"
android:paddingBottom="8dp"
android:paddingLeft="16dp"
android:paddingRight="16dp"
android:gravity="center_vertical"
android:clickable="true"
android:focusable="true"
android:background="?attr/selectableItemBackground">
<ImageView
app:srcCompat="?attr/iconSettingsAbout"
android:layout_width="24dp"
android:layout_height="24dp"
android:layout_gravity="center" />
android:text="@string/version"
android:textColor="?android:attr/textColorPrimary" />
<LinearLayout
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:paddingLeft="30dp"
android:orientation="vertical">
<TextView
android:text="@string/version"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:textColor="?android:attr/textColorPrimary" />
<TextView
android:id="@+id/version"
android:text="Version"
android:layout_width="match_parent"
android:layout_height="wrap_content" />
</LinearLayout>
<TextView
android:id="@+id/version"
android:layout_width="match_parent"
android:layout_height="wrap_content"
tools:text="1.2.3" />
</LinearLayout>
<LinearLayout
android:id="@+id/authorsLayout"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:paddingTop="8dp"
android:paddingBottom="8dp"
android:paddingLeft="16dp"
android:paddingRight="16dp"
android:gravity="center_vertical"
android:clickable="true"
android:focusable="true"
android:background="?attr/selectableItemBackground">
<ImageView
app:srcCompat="?attr/iconAboutAuthors"
android:layout_width="24dp"
android:layout_height="24dp"
android:layout_gravity="center" />
<LinearLayout
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:paddingLeft="30dp"
android:orientation="vertical">
<TextView
android:text="@string/authors"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:textColor="?android:attr/textColorPrimary" />
<TextView
android:text="@string/app_authors"
android:layout_width="match_parent"
android:layout_height="wrap_content" />
</LinearLayout>
</LinearLayout>
<LinearLayout
android:id="@+id/licenseLayout"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:paddingTop="8dp"
android:paddingBottom="8dp"
android:paddingLeft="16dp"
android:paddingRight="16dp"
android:gravity="center_vertical"
android:clickable="true"
android:focusable="true"
android:background="?attr/selectableItemBackground">
<ImageView
app:srcCompat="?attr/iconAboutLicense"
android:layout_width="24dp"
android:layout_height="24dp"
android:layout_gravity="center" />
<LinearLayout
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:paddingLeft="30dp"
android:orientation="vertical">
<TextView
android:text="@string/license"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:textColor="?android:attr/textColorPrimary" />
<TextView
android:text="@string/app_license"
android:layout_width="match_parent"
android:layout_height="wrap_content" />
</LinearLayout>
</LinearLayout>
<LinearLayout
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="16dp"
android:layout_gravity="center">
<Button
android:id="@+id/source"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginLeft="8dp"
android:layout_gravity="center_vertical"
android:padding="8dp"
android:background="?android:attr/selectableItemBackground"
android:text="@string/source_code"
android:textAllCaps="true" />
<Button
android:id="@+id/changelog"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginLeft="8dp"
android:layout_gravity="center_vertical"
android:padding="8dp"
android:background="?android:attr/selectableItemBackground"
android:text="@string/changelog_full_title"
android:textAllCaps="true" />
<Button
android:id="@+id/revisions"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginLeft="8dp"
android:layout_marginRight="8dp"
android:layout_gravity="center_vertical"
android:padding="8dp"
android:background="?android:attr/selectableItemBackground"
android:text="@string/app_revision"
android:textAllCaps="true" />
</LinearLayout>
<TextView
android:id="@+id/copyright"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:padding="16dp"
android:gravity="center_vertical"
android:textAppearance="?android:attr/textAppearanceSmall" />
<View
android:layout_height="2dp"
android:layout_width="match_parent"
android:background="?android:attr/listDivider" />
<TextView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:paddingTop="16dp"
android:paddingBottom="16dp"
android:paddingLeft="16dp"
android:gravity="center_vertical"
android:text="@string/about_libraries"
android:textColor="?android:attr/textColorPrimary"
android:textAppearance="?android:attr/textAppearanceLarge" />
<androidx.recyclerview.widget.RecyclerView
android:id="@+id/libraries"
android:layout_width="match_parent"
android:layout_height="wrap_content" />
</LinearLayout>
</androidx.core.widget.NestedScrollView>
</LinearLayout>
<LinearLayout
android:id="@+id/authorsLayout"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:background="?attr/selectableItemBackground"
android:clickable="true"
android:focusable="true"
android:gravity="center_vertical"
android:paddingLeft="16dp"
android:paddingTop="8dp"
android:paddingRight="16dp"
android:paddingBottom="8dp">
<ImageView
android:layout_width="24dp"
android:layout_height="24dp"
android:layout_gravity="center"
android:contentDescription="@null"
app:srcCompat="?attr/iconAboutAuthors" />
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="vertical"
android:paddingLeft="30dp">
<TextView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:text="@string/authors"
android:textColor="?android:attr/textColorPrimary" />
<TextView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:text="@string/app_authors" />
</LinearLayout>
</LinearLayout>
<LinearLayout
android:id="@+id/sourceCodeLayout"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:background="?attr/selectableItemBackground"
android:clickable="true"
android:focusable="true"
android:gravity="center_vertical"
android:paddingLeft="16dp"
android:paddingTop="8dp"
android:paddingRight="16dp"
android:paddingBottom="8dp">
<ImageView
android:layout_width="24dp"
android:layout_height="24dp"
android:layout_gravity="center"
android:contentDescription="@null"
app:srcCompat="?attr/iconAboutSourceCode" />
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="vertical"
android:paddingLeft="30dp">
<TextView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:text="@string/source_code"
android:textColor="?android:attr/textColorPrimary" />
<TextView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:text="@string/app_source_url" />
</LinearLayout>
</LinearLayout>
<LinearLayout
android:id="@+id/licenseLayout"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:background="?attr/selectableItemBackground"
android:clickable="true"
android:focusable="true"
android:gravity="center_vertical"
android:paddingLeft="16dp"
android:paddingTop="8dp"
android:paddingRight="16dp"
android:paddingBottom="8dp">
<ImageView
android:layout_width="24dp"
android:layout_height="24dp"
android:layout_gravity="center"
android:contentDescription="@null"
app:srcCompat="?attr/iconAboutLicense" />
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="vertical"
android:paddingLeft="30dp">
<TextView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:text="@string/license"
android:textColor="?android:attr/textColorPrimary" />
<TextView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:text="@string/app_license" />
</LinearLayout>
</LinearLayout>
<TextView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:paddingLeft="16dp"
android:paddingTop="32dp"
android:paddingBottom="16dp"
android:text="@string/about_project_title"
android:textAppearance="?android:attr/textAppearanceLarge"
android:textColor="?android:attr/textColorPrimary" />
<LinearLayout
android:id="@+id/websiteLayout"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:background="?attr/selectableItemBackground"
android:clickable="true"
android:focusable="true"
android:gravity="center_vertical"
android:paddingLeft="16dp"
android:paddingTop="8dp"
android:paddingRight="16dp"
android:paddingBottom="8dp">
<ImageView
android:layout_width="24dp"
android:layout_height="24dp"
android:layout_gravity="center"
android:contentDescription="@null"
app:srcCompat="?attr/iconAboutWebsite" />
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="vertical"
android:paddingLeft="30dp">
<TextView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:text="@string/about_website_title"
android:textColor="?android:attr/textColorPrimary" />
<TextView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:text="@string/app_webpage_url" />
</LinearLayout>
</LinearLayout>
<LinearLayout
android:id="@+id/userForumLayout"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:background="?attr/selectableItemBackground"
android:clickable="true"
android:focusable="true"
android:gravity="center_vertical"
android:paddingLeft="16dp"
android:paddingTop="8dp"
android:paddingRight="16dp"
android:paddingBottom="8dp">
<ImageView
android:layout_width="24dp"
android:layout_height="24dp"
android:layout_gravity="center"
android:contentDescription="@null"
app:srcCompat="?attr/iconUserForum" />
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="vertical"
android:paddingLeft="30dp">
<TextView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:text="@string/user_forum_title"
android:textColor="?android:attr/textColorPrimary" />
<TextView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:text="@string/user_forum_url" />
</LinearLayout>
</LinearLayout>
<LinearLayout
android:id="@+id/fediverseLayout"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:background="?attr/selectableItemBackground"
android:clickable="true"
android:focusable="true"
android:gravity="center_vertical"
android:paddingLeft="16dp"
android:paddingTop="8dp"
android:paddingRight="16dp"
android:paddingBottom="8dp">
<ImageView
android:layout_width="24dp"
android:layout_height="24dp"
android:layout_gravity="center"
android:contentDescription="@null"
app:srcCompat="?attr/iconAboutFediverse" />
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="vertical"
android:paddingLeft="30dp">
<TextView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:text="@string/about_fediverse_title"
android:textColor="?android:attr/textColorPrimary" />
<TextView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:text="@string/fediverse_handle" />
</LinearLayout>
</LinearLayout>
<LinearLayout
android:id="@+id/twitterLayout"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:background="?attr/selectableItemBackground"
android:clickable="true"
android:focusable="true"
android:gravity="center_vertical"
android:paddingLeft="16dp"
android:paddingTop="8dp"
android:paddingRight="16dp"
android:paddingBottom="8dp">
<ImageView
android:layout_width="24dp"
android:layout_height="24dp"
android:layout_gravity="center"
android:contentDescription="@null"
app:srcCompat="?attr/iconAboutTwitter" />
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="vertical"
android:paddingLeft="30dp">
<TextView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:text="@string/about_twitter_title"
android:textColor="?android:attr/textColorPrimary" />
<TextView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:text="@string/twitter_handle" />
</LinearLayout>
</LinearLayout>
<TextView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:gravity="center_vertical"
android:paddingLeft="16dp"
android:paddingTop="32dp"
android:paddingBottom="16dp"
android:text="@string/about_libraries"
android:textAppearance="?android:attr/textAppearanceLarge"
android:textColor="?android:attr/textColorPrimary" />
<androidx.recyclerview.widget.RecyclerView
android:id="@+id/libraries"
android:layout_width="match_parent"
android:layout_height="wrap_content" />
</LinearLayout>
</androidx.core.widget.NestedScrollView>

View file

@ -88,8 +88,14 @@
<attr name="tintColorBulletPointNeutral" format="reference|color"/>
<attr name="tintColorBulletPointNegative" format="reference|color"/>
<attr name="iconAboutVersion" format="reference"/>
<attr name="iconAboutAuthors" format="reference"/>
<attr name="iconAboutSourceCode" format="reference"/>
<attr name="iconAboutLicense" format="reference"/>
<attr name="iconAboutWebsite" format="reference"/>
<attr name="iconAboutTwitter" format="reference"/>
<attr name="iconAboutFediverse" format="reference"/>
<attr name="iconUserForum" format="reference"/>
<attr name="unencryptedAttachmentUnlock" format="reference|color" />
<attr name="openpgp_black" format="reference|color" />

View file

@ -1,9 +1,14 @@
<?xml version="1.0" encoding="utf-8"?>
<resources xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
<resources>
<string name="app_revision_url" translatable="false">https://github.com/k9mail/k-9/wiki/ReleaseNotes</string>
<string name="app_webpage_url" translatable="false">https://k9mail.github.io/</string>
<string name="app_webpage_url" translatable="false">https://k9mail.app/</string>
<string name="user_forum_url" translatable="false">https://forum.k9mail.app/</string>
<string name="message_header_mua" translatable="false">K-9 Mail for Android</string>
<string name="app_authors_url" translatable="false">https://github.com/k9mail/k-9/graphs/contributors</string>
<string name="app_source_url" translatable="false">https://github.com/k9mail/k-9</string>
<string name="app_license_url" translatable="false">https://www.apache.org/licenses/LICENSE-2.0</string>
<string name="fediverse_handle" translatable="false">\@k9mail@fosstodon.org</string>
<string name="fediverse_url" translatable="false">https://fosstodon.org/@k9mail</string>
<string name="twitter_handle" translatable="false">\@k9mail_app</string>
<string name="twitter_url" translatable="false">https://twitter.com/k9mail_app</string>
</resources>

View file

@ -14,8 +14,13 @@
<!-- Used in the about dialog -->
<string name="app_authors">The K-9 Dog Walkers</string>
<string name="app_copyright_fmt">Copyright 2008-<xliff:g>%s</xliff:g> The K-9 Dog Walkers. Portions Copyright 2006-<xliff:g>%s</xliff:g> the Android Open Source Project.</string>
<string name="source_code">Source</string>
<string name="source_code">Source code</string>
<string name="app_license">Apache License, Version 2.0</string>
<string name="about_project_title">Open Source Project</string>
<string name="about_website_title">Website</string>
<string name="user_forum_title">User forum</string>
<string name="about_fediverse_title">Fediverse</string>
<string name="about_twitter_title">Twitter</string>
<string name="about_libraries">Libraries</string>
<string name="license">License</string>

View file

@ -113,8 +113,14 @@
<item name="tintColorBulletPointNegative">#dd2222</item>
<item name="tintColorBulletPointNeutral">#888</item>
<item name="iconAboutAuthors">@drawable/ic_code_light</item>
<item name="iconAboutLicense">@drawable/ic_description_light</item>
<item name="iconAboutVersion">@drawable/ic_info</item>
<item name="iconAboutAuthors">@drawable/ic_people</item>
<item name="iconAboutSourceCode">@drawable/ic_code</item>
<item name="iconAboutLicense">@drawable/ic_description</item>
<item name="iconAboutWebsite">@drawable/ic_link</item>
<item name="iconUserForum">@drawable/ic_forum</item>
<item name="iconAboutFediverse">@drawable/ic_mastodon</item>
<item name="iconAboutTwitter">@drawable/ic_twitter</item>
<item name="unencryptedAttachmentUnlock">@drawable/ic_visibility_light</item>
<item name="openpgp_black">#000</item>
@ -231,8 +237,14 @@
<item name="tintColorBulletPointNegative">#dd2222</item>
<item name="tintColorBulletPointNeutral">#bbb</item>
<item name="iconAboutAuthors">@drawable/ic_code_dark</item>
<item name="iconAboutLicense">@drawable/ic_description_dark</item>
<item name="iconAboutVersion">@drawable/ic_info</item>
<item name="iconAboutAuthors">@drawable/ic_people</item>
<item name="iconAboutSourceCode">@drawable/ic_code</item>
<item name="iconAboutLicense">@drawable/ic_description</item>
<item name="iconAboutWebsite">@drawable/ic_link</item>
<item name="iconUserForum">@drawable/ic_forum</item>
<item name="iconAboutFediverse">@drawable/ic_mastodon</item>
<item name="iconAboutTwitter">@drawable/ic_twitter</item>
<item name="unencryptedAttachmentUnlock">@drawable/ic_visibility_dark</item>
<item name="openpgp_black">#fff</item>