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

What's New in Android

What's New in Android

Android N, now known as Nougat, was announced this past spring at Google IO 2016. Drop in to hear a rundown of all the new and exciting features that you as a developer can take advantage of in the new Nougat release. From the new split window feature to Java 8 feature support, there are some exciting topics to cover. We will also cover the latest in build tools: Android Studio, Jack and Jill, and Gradle plugins.

Avatar for Douglas Knudsen

Douglas Knudsen

October 21, 2016
Tweet

More Decks by Douglas Knudsen

Other Decks in Technology

Transcript

  1. WHATS NEW IN ANDROID? AGENDA ▸ What this is and

    not ▸ Nougat! ▸ Developer Tools
  2. WHATS NEW IN ANDROID? MULTI LOCALE ▸ Users can choose

    multiple locales on device ▸ Prioritized ▸ Gives multi-lingual users better chance at using your app
  3. WHATS NEW IN ANDROID? MULTI LOCALE ▸ Developers have new

    API LocaleList such as getDefault() ▸ Developers can use this to customize UIs, such as providing data results in two languages or not offering to translate a known language
  4. WHATS NEW IN ANDROID? MULTI LOCALE ▸ Developers should prefer

    formatters even for static content. ▸ format(locale, "Choose a %d-digit PIN", 4) ▸ Android 7.0 and higher includes support for 27 Arabic locales!!!!
  5. WHATS NEW IN ANDROID? MULTI WINDOW ▸ Apps can opt

    in/out and set minimum sizes ▸ Apps should ‘just work’ since we are all pros :) ▸ Apps can open new activities in multi-window ▸ Drag and drop API is updated to allow functionality across windows ▸ Developers need make use of onStart() and onStop() since app can still be visible after onPause() fires
  6. WHATS NEW IN ANDROID? MULTI WINDOW ▸ For API <

    24, if no fixed orientation, your app is multi- window ▸ Can set at Application or Activity level android:resizeableActivity ▸ Use android:supportsPictureInPicture for LeanBack APIs
  7. WHATS NEW IN ANDROID? MULTI WINDOW <activity android:name=".KoolActivity"> <layout android:defaultHeight="500dp"

    android:defaultWidth="600dp" android:gravity="top|end" android:minHeight="450dp" android:minWidth="300dp" /> </activity>
  8. WHATS NEW IN ANDROID? DOZE ALL THE TIME ▸ Introduced

    in Android M aka 6.0 aka Marshmallow aka API 23 ▸ Now full time, screen off for a time ▸ If stationary for a time, goes full on
  9. WHATS NEW IN ANDROID? DOZE ALL THE TIME ▸ When

    full doze is on, network is restricted, wake locks ignored, no JobScheduler, and no AlarmManager alarms. ( setAlarmClock() fires normally ) ▸ During partial doze, these are all queued ▸ Consumers can be involved in whitelisting
  10. WHATS NEW IN ANDROID? PROJECT SVELTE…RICO ▸ Implicit CONNECTIVITY_ACTION broadcasts

    are not received ▸ Developers can use CONNECTIVITY_CHANGE still ▸ ACTION_NEW_PICTURE and ACTION_NEW_VIDEO are no longer delivered ▸ Developers need to use JobScheduler API. ▸ Future Android SDK may even remove startService()
  11. WHATS NEW IN ANDROID? WORK ▸ Work mode toggle ▸

    VPN stays on ▸ Customized provisioning, get those corporate logos and colors!
  12. WHATS NEW IN ANDROID? JAVA 8 ▸ Default interface methods

    public interface Fruity { default void pickMe(){ System.out.println("Calling Fruity.pickMe())"); } } public class Zurple implements Fruity {} Zurple zurple = new Zurple(); zurple.pickMe(); //Calling Fruity.pickMe()
  13. WHATS NEW IN ANDROID? JAVA 8 ▸ Lamba and Method

    expressions! ( < 24 ) TextView textView = (TextView) findViewById(R.id.text_view); textView.setOnLongClickListener(v -> System.out.println("Long Click")); ▸ Repeatable Annotations @Custom(foo = 45) @Custom(foo = 99, goo = 42) public Goo foo;
  14. WHATS NEW IN ANDROID? JAVA 8 ▸ java.util.function and java.util.stream

    myList.stream() .filter(s -s.startsWith(“c”)) .map(String::toUpperCase) .sorted() .forEach(System.out::println); ▸ ICU4J (partially) ▸ All this requires Jack
  15. WHATS NEW IN ANDROID? JACK AND JILL ▸ Jack is

    the new compiler toolchain - Java Android Compiler Kit ▸ Replaces javac, jarjar, dx, and ProGuard ▸ Faster and OSS and Java 8 ▸ Jill moves existing jar files into the new format for Jack - Java Intermediate Library Linker
  16. WHATS NEW IN ANDROID? JIT, JIT, THE JIT IS BACK

    ▸ JIT is back and mixed in with AOT inside ART ▸ Remember AOT? note seamless upgrades!
  17. WHATS NEW IN ANDROID? APP SHORTCUTS ▸ API 25! yes,

    7.1…Nougat.1? ▸ Long press = deep links ▸ Static or dynamic
  18. WHATS NEW IN ANDROID? EMOJI!!!!!!! ▸ eemohjeeeeee! ▸ Unicode 9

    support ▸ Image keyboard support updates ▸ Skin tone choice support
  19. WHATS NEW IN ANDROID? NOTIFICATIONS ▸ Updated…again ▸ Actionable…direct reply

    RemoteInput API ▸ Bundled…gather by topic ▸ Custom views…bit more control ▸ Peeking…into groups
  20. WHATS NEW IN ANDROID? QUICK SETTINGS ▸ Google follows device

    manufactures ▸ Exposed to developers! ▸ Use for frequently used actions in your app ▸ TileService
  21. WHATS NEW IN ANDROID? QUICK SETTINGS <SERVICE ANDROID:NAME=".MYTILESERVICE" ANDROID:ICON="@DRAWABLE/MY_TILE_ICON" ANDROID:LABEL=“@STRING/MY_TILE_LABEL"

    ANDROID:PERMISSION="ANDROID.PERMISSION.BIND_QUICK_SE TTINGS_TILE"> <INTENT-FILTER> <ACTION ANDROID:NAME="ANDROID.SERVICE.QUICKSETTINGS.ACTION. QS_TILE" /> </INTENT-FILTER> </SERVICE>
  22. WHATS NEW IN ANDROID? INSTANT APPS ▸ Just Google it!

    ▸ And they will run it! ▸ No extra code ▸ Provided your code is modular ▸ Sign up for the early fun
  23. WHATS NEW IN ANDROID? GRAPHICS ▸ New Vulcan Graphics API

    ▸ Implementation of the Khronos Group API ▸ low-overhead, high performance, 3-D
  24. WHATS NEW IN ANDROID? ANDROID STUDIO ▸ 2.2 is here,

    its a big dot! ▸ Layout Editor and Inspector ▸ Constraint Layout ▸ Better C++/NDK support ▸ Last IntelliJ base from June ▸ PSD import to Vector Drawables
  25. WHATS NEW IN ANDROID? CIRCLES! ▸ Circular launcher icons ▸

    New tool for these too ▸ Having a tool is so official
  26. WHATS NEW IN ANDROID? ANDROID STUDIO ▸ Java 8 support,

    actually ships with Java 8 runtime ▸ Updated emulators…finally fast ▸ More instant run improvements ▸ Espresso Test Recorder
  27. WHATS NEW IN ANDROID? CONSTRAINT LAYOUTS ▸ Responsive UI layouts

    in a ‘flat’ setup ▸ New layout engine and tooling in Android Studio 2.2 ▸ Similar to RelativeLayout, but more goodies ▸ compile ‘com.android.support.constraint:constraint- layout:1.0.0’ ▸ Backward compatible to 2.3! Gingerbread!
  28. WHATS NEW IN ANDROID? CONSTRAINT LAYOUTS ▸ go to demo

    ▸ demo layout editor, constraints, and espresso test recorder ▸ espresso video back up plan https://youtu.be/ 1GOnfXdWvTM?t=27
  29. WHATS NEW IN ANDROID? APP COMPAT APIS ▸ Password visibility

    toggle ▸ Custom Tabs support for Instant Apps ( inception! ) ▸ New getDrawable() version to load Vector Drawables ▸ A new DiffUtil to determine differences in Collections and notify UIs
  30. WHATS NEW IN ANDROID? APP COMPAT V4 ▸ NotificationCompat.MessagingStyle For

    those fancy threaded looking notifications ▸ NotificationManagerCompat.areNotificationsEnabl ed() and getImportance() Now we can tell if the user turned off notifications for our app. Also, is this important to the user? ▸ Library split! Much like v7 and others, can use a subset now ▸ Drop support of API 9 and lower. No more Froyo, Ginger, Eclair, etc
  31. WHATS NEW IN ANDROID? APP COMPAT V7 ▸ Vector support

    in DrawableContainers…so StateListDrawables ▸ Night Mode! Day and Night themes, can use GPS to auto- update these ▸ VectorDrawableCompat and AnimatedVectorDrawableCompat added, yes, animated vectors Victor!
  32. WHATS NEW IN ANDROID? APP COMPATIBLE MATERIAL ▸ Bottom Sheets!

    ▸ Persistent ▸ Min height, yet draggable
  33. WHATS NEW IN ANDROID? RESOURCES ▸ Android Dialogs https://www.youtube.com/channel/ UCMEmNnHT69aZuaOrE-dF6ug

    ▸ Fragmented Podcast http://fragmentedpodcast.com/ ▸ Android Backstage http://androidbackstage.blogspot.com/ ▸ https://developers.googleblog.com/ ▸ https://medium.com/exploring-android/exploring-the-new- android-constraintlayout-eed37fe8d8f1#.x6rtenlov