Remove BaseGitActivity's onOptionsItemSelected override (#1075)

Each activity that inherits from it should handle its own navigation

Signed-off-by: Harsh Shandilya <me@msfjarvis.dev>
This commit is contained in:
Harsh Shandilya 2020-09-04 11:47:50 +05:30 committed by GitHub
parent 3840f43fa0
commit b7f58cfb6e
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -4,7 +4,6 @@
*/
package com.zeapo.pwdstore.git
import android.view.MenuItem
import androidx.appcompat.app.AppCompatActivity
import androidx.core.content.edit
import com.github.ajalt.timberkt.Timber.tag
@ -35,16 +34,6 @@ import net.schmizz.sshj.userauth.UserAuthException
*/
abstract class BaseGitActivity : AppCompatActivity() {
override fun onOptionsItemSelected(item: MenuItem): Boolean {
return when (item.itemId) {
android.R.id.home -> {
finish()
true
}
else -> super.onOptionsItemSelected(item)
}
}
/**
* Attempt to launch the requested Git operation.
* @param operation The type of git operation to launch