diff options
Diffstat (limited to 'androidApp/src/main/java/mx/trackermap')
-rw-r--r-- | androidApp/src/main/java/mx/trackermap/TrackerMap/android/units/UnitsActivity.kt | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/androidApp/src/main/java/mx/trackermap/TrackerMap/android/units/UnitsActivity.kt b/androidApp/src/main/java/mx/trackermap/TrackerMap/android/units/UnitsActivity.kt index 9598077..409919a 100644 --- a/androidApp/src/main/java/mx/trackermap/TrackerMap/android/units/UnitsActivity.kt +++ b/androidApp/src/main/java/mx/trackermap/TrackerMap/android/units/UnitsActivity.kt @@ -39,21 +39,24 @@ class UnitsActivity : AppCompatActivity() { private fun setupEvents() { binding.drawerButton.setOnClickListener { - binding.drawerLayout.openDrawer(Gravity.LEFT) + binding.drawerLayout.openDrawer(binding.navigationView) } binding.navigationView.setNavigationItemSelectedListener { when (it.itemId) { R.id.nav_account -> { Toast.makeText(this, "Account button tapped!", Toast.LENGTH_SHORT).show() - true + binding.drawerLayout.closeDrawers() + false } R.id.nav_about -> { Toast.makeText(this, "About button tapped!", Toast.LENGTH_SHORT).show() - true + binding.drawerLayout.closeDrawers() + false } R.id.nav_logout -> { Toast.makeText(this, "Logout button tapped!", Toast.LENGTH_SHORT).show() - true + binding.drawerLayout.closeDrawers() + false } else -> false } |