From: Damyan Ivanov Date: Tue, 27 Nov 2018 21:09:17 +0000 (+0000) Subject: exit when the Exit drawer item is clicked X-Git-Tag: v0.3~394 X-Git-Url: https://git.ktnx.net/?a=commitdiff_plain;h=ffec15332fc5eb907dde8b35d9c9c17c1e546cf2;p=mobile-ledger.git exit when the Exit drawer item is clicked --- diff --git a/app/src/main/java/net/ktnx/mobileledger/LatestTransactions.java b/app/src/main/java/net/ktnx/mobileledger/LatestTransactions.java index f8c70604..111b71e9 100644 --- a/app/src/main/java/net/ktnx/mobileledger/LatestTransactions.java +++ b/app/src/main/java/net/ktnx/mobileledger/LatestTransactions.java @@ -10,6 +10,7 @@ import android.support.v4.widget.DrawerLayout; import android.support.v7.app.ActionBarDrawerToggle; import android.support.v7.app.AppCompatActivity; import android.support.v7.widget.Toolbar; +import android.util.Log; import android.view.Menu; import android.view.MenuItem; import android.view.View; @@ -52,6 +53,11 @@ public class LatestTransactions extends AppCompatActivity } } + public void nav_exit_clicked(View view) { + Log.w("mobileledger", "exiting"); + finish(); + } + @Override public void onBackPressed() { DrawerLayout drawer = findViewById(R.id.drawer_layout); diff --git a/app/src/main/res/layout/drawer.xml b/app/src/main/res/layout/drawer.xml index b8f069ff..1f03cfc3 100644 --- a/app/src/main/res/layout/drawer.xml +++ b/app/src/main/res/layout/drawer.xml @@ -83,10 +83,11 @@ android:text="@string/action_settings" />