Skip to content

Commit

Permalink
fixes issue named-data-mobile#143 added to register option if failed …
Browse files Browse the repository at this point in the history
…to register
  • Loading branch information
Amit Yadav committed Jan 14, 2020
1 parent cbb0de3 commit c322255
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 0 deletions.
2 changes: 2 additions & 0 deletions app/src/main/java/memphis/myapplication/UI/MainFragment.java
Original file line number Diff line number Diff line change
Expand Up @@ -184,6 +184,8 @@ public boolean onOptionsItemSelected(MenuItem item) {
case R.id.action_about:
Navigation.findNavController(mainView).navigate(R.id.action_mainFragment_to_aboutFragment);
return true;
case R.id.action_register:
Navigation.findNavController(mainView).navigate(R.id.action_mainFragment_to_registerFragment);
default:
return super.onOptionsItemSelected(item);
}
Expand Down
5 changes: 5 additions & 0 deletions app/src/main/res/menu/menu_main.xml
Original file line number Diff line number Diff line change
Expand Up @@ -15,4 +15,9 @@
android:orderInCategory="101"
android:title="@string/action_about"
app:showAsAction="collapseActionView" />
<item
android:id="@+id/action_register"
android:orderInCategory="101"
android:title="Register"
app:showAsAction="collapseActionView" />
</menu>
4 changes: 4 additions & 0 deletions app/src/main/res/navigation/nav_graph.xml
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,10 @@
<action
android:id="@+id/action_mainFragment_to_selectRecipientsFragment"
app:destination="@id/selectRecipientsFragment" />
<action
android:id="@+id/action_mainFragment_to_registerFragment"
app:destination="@id/loginFragment" />

</fragment>
<fragment
android:id="@+id/blankFragment"
Expand Down

0 comments on commit c322255

Please sign in to comment.