Upgrade to Pro — share decks privately, control downloads, hide ads and more …

Oh, the places you'll go! Cracking Navigation o...

Oh, the places you'll go! Cracking Navigation on Android

" You’re building your app, you’re out on your way,
Activity to fragment, you’ll add deep links one day.
Notifications, transitions, you pass arguments, too,
Just a messy piece of cake, for a developer like you!
But then the user hits back, or up or away -
What should happen? You’re lost! The road starts to sway!

They talk about launch modes, affinity, activity stack...
We will deep-dive to those,
then learn the new stuff from Jetpack! "

*** Presented at Android Summit, and Andorid NYC meetup, on August 2018.

Britt Barak

August 16, 2018
Tweet

More Decks by Britt Barak

Other Decks in Programming

Transcript

  1. @BrittBarak You’re on your own You know what you know

    And you are the DEV that decides where your USER will go! @BrittBarak
  2. @BrittBarak 5.1 Navigate from Menu override fun onOptionsItemSelected(item: MenuItem): Boolean

    { return NavigationUI. onNavDestinationSelected(item,navController) }
  3. @BrittBarak 5.1 Navigate from Menu override fun onOptionsItemSelected(item: MenuItem): Boolean

    { return NavigationUI. onNavDestinationSelected(item,navController) || super.onOptionsItemSelected(item) }
  4. @BrittBarak AndroidManifest.xml <activity android:name=".MainActivity"> <!— . . . . —>

    <nav-graph android:value=“@navigation/nav_graph”/> </activity>
  5. @BrittBarak “And will you succeed? Yes! You will, indeed! (98

    an 3/4 percent guaranteed)” DEV, you’ll move fragments! @BrittBarak