move onOptionsItemSelected to BaseActivity (#2059)

* move onOptionsItemSelected to BaseActivity

* revert change in ComposeActivity
This commit is contained in:
Konrad Pozniak 2021-01-31 20:27:02 +01:00 committed by GitHub
commit 483beaa957
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
22 changed files with 13 additions and 195 deletions

View file

@ -8,7 +8,6 @@ import android.text.SpannableStringBuilder
import android.text.method.LinkMovementMethod
import android.text.style.URLSpan
import android.text.util.Linkify
import android.view.MenuItem
import android.widget.TextView
import com.keylesspalace.tusky.di.Injectable
import com.keylesspalace.tusky.util.CustomURLSpan
@ -50,16 +49,6 @@ class AboutActivity : BottomSheetActivity(), Injectable {
}
override fun onOptionsItemSelected(item: MenuItem): Boolean {
when (item.itemId) {
android.R.id.home -> {
onBackPressed()
return true
}
}
return super.onOptionsItemSelected(item)
}
}
private fun TextView.setClickableTextWithoutUnderlines(@StringRes textId: Int) {