chore: Source tracker url in the menu.
This commit is contained in:
parent
a03f08fca1
commit
e58914ef58
@ -1,6 +1,7 @@
|
||||
package bou.amine.apps.readerforselfossv2.android
|
||||
|
||||
import android.content.Intent
|
||||
import android.net.Uri
|
||||
import android.os.Bundle
|
||||
import android.view.Menu
|
||||
import android.view.MenuItem
|
||||
@ -565,6 +566,11 @@ class HomeActivity : AppCompatActivity(), SearchView.OnQueryTextListener, DIAwar
|
||||
|
||||
override fun onOptionsItemSelected(item: MenuItem): Boolean {
|
||||
when (item.itemId) {
|
||||
R.id.issue_tracker -> {
|
||||
val browserIntent = Intent(Intent.ACTION_VIEW, Uri.parse(AppSettingsService.trackerUrl))
|
||||
startActivity(browserIntent)
|
||||
return true
|
||||
}
|
||||
R.id.action_filter -> {
|
||||
val filterSheetFragment = FilterSheetFragment()
|
||||
filterSheetFragment.show(supportFragmentManager, FilterSheetFragment.TAG)
|
||||
|
@ -4,6 +4,7 @@ import android.animation.Animator
|
||||
import android.animation.AnimatorListenerAdapter
|
||||
import android.annotation.SuppressLint
|
||||
import android.content.Intent
|
||||
import android.net.Uri
|
||||
import android.os.Bundle
|
||||
import android.text.TextUtils
|
||||
import android.view.Menu
|
||||
@ -254,10 +255,17 @@ class LoginActivity : AppCompatActivity(), DIAware {
|
||||
|
||||
override fun onOptionsItemSelected(item: MenuItem): Boolean {
|
||||
return when (item.itemId) {
|
||||
R.id.issue_tracker -> {
|
||||
val browserIntent = Intent(Intent.ACTION_VIEW, Uri.parse(AppSettingsService.trackerUrl))
|
||||
startActivity(browserIntent)
|
||||
return true
|
||||
}
|
||||
R.id.about -> {
|
||||
LibsBuilder()
|
||||
.withAboutIconShown(true)
|
||||
.withAboutVersionShown(true)
|
||||
.withAboutSpecial2("Bug reports").withAboutSpecial2Description(AppSettingsService.trackerUrl)
|
||||
.withAboutSpecial1("Project Page").withAboutSpecial1Description(AppSettingsService.sourceUrl)
|
||||
.start(this)
|
||||
true
|
||||
}
|
||||
|
@ -36,6 +36,12 @@
|
||||
android:orderInCategory="101"
|
||||
android:title="@string/menu_home_refresh" />
|
||||
|
||||
<item
|
||||
android:id="@+id/issue_tracker"
|
||||
app:showAsAction="never"
|
||||
android:orderInCategory="103"
|
||||
android:title="@string/issue_tracker_link" />
|
||||
|
||||
<item android:id="@+id/action_disconnect"
|
||||
android:title="@string/action_disconnect"
|
||||
android:orderInCategory="104"
|
||||
|
@ -3,6 +3,13 @@
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto">
|
||||
|
||||
|
||||
|
||||
<item
|
||||
android:id="@+id/issue_tracker"
|
||||
app:showAsAction="never"
|
||||
android:orderInCategory="101"
|
||||
android:title="@string/issue_tracker_link" />
|
||||
|
||||
<item android:id="@+id/about"
|
||||
android:title="@string/action_about"
|
||||
android:orderInCategory="102"
|
||||
|
Loading…
Reference in New Issue
Block a user