android n preview

24
Android N Preview GDG Korea Meetup March 30 - Hassan Abid

Upload: hassan-abid

Post on 15-Jan-2017

1.540 views

Category:

Software


0 download

TRANSCRIPT

Page 1: Android n preview

Android N PreviewGDG Korea Meetup March 30 - Hassan Abid

Page 2: Android n preview

Android N for DevelopersMultiWindow & Picture-in-PictureActive Notifications

Language and Locale

Direct Boot

Scoped Directory Access2

Page 3: Android n preview

References for Korean DevelopersGoogle Korea Official Blog post

Kunny’s Weekly blog post

Taehwan’s blog about Android N Preview Multiwindow

3

Page 4: Android n preview

SURVEY (ANDROID AUTHORITY)

4

Page 5: Android n preview

MultiWindowSplit Screen ( Mobile)Picture-in-picture (TV)Freeform mode (Large Devices)Drag & Drop

5

Page 6: Android n preview

MultiWindow - How ?android:resizeableActivity=["true" | "false"]

android:supportsPictureInPicture=["true" | "false"]

<activity android:name=".MyActivity">

<layout android:defaultHeight="500dp"

android:defaultWidth="600dp"

android:gravity="top|end"

android:minimalSize="450dp" />

</activity>

Activity.inMultiWindow()

Activity.inPictureInPicture()

Activity.onMultiWindowChanged()

Activity.onPictureInPictureChanged()

Frament.inMultiWindow

6

Page 7: Android n preview

7

Page 8: Android n preview

Tips for Multi-window support [ref]1. Use the right Context

2. Handle configuration changes correctly

3. Handle all orientations

4. Build a responsive UI for all screen sizes

5. Activities started by other apps must always support multi-window

8

Page 9: Android n preview

Active NotificationsInline ReplyBundled NotificationsCustom View

9

Page 10: Android n preview

Scoped Directory Access

10

Page 11: Android n preview

Direct BootCredential encrypted:

The default storage location for all apps, available only after the user has entered their pattern/password

Device encrypted:

A new storage location which is always available while the device is booted, both before and after any user credentials are entered

11

Page 12: Android n preview

Language and Locale

12

Page 13: Android n preview

Behavioral ChangesPerformance Improvement

Enhanced Doze mode

Project Svelte: Background Optimizations

13

Page 14: Android n preview

Doze (Android M)

Wakelock,AlarmWifi/Gps works

14

Page 15: Android n preview

Doze (Android N)

Wakelock,AlarmWifi/Gps works

15

Page 16: Android n preview

Doze ( Second-Level)

16

Page 17: Android n preview

Background OptimizationRestrictions on CONNECTIVITY_ACTION

Restrictions on NEW_PICTURE and NEW_VIDEO

17

Page 18: Android n preview

MoreData Saver TV RecordingFollow this link

18

Page 19: Android n preview

DEMO19

Page 20: Android n preview

Reference CodesAndroid MultiWindow [Github]

Active Notifications (Bundle Notificatiosn) [Github]

Inline Reply [Github]

Scoped Directory Access [Github]

Search Restaurant (My own project’s code upgraded to Android N - Checkout branch npreview) [Github]

ExoPlayer upgraded to NPreview [Github]20

Page 21: Android n preview

FeedbackLink : https://code.google.com/p/android/issues/entry?template=Developer%20preview%20report

21

Page 22: Android n preview

SURVEY22

Page 23: Android n preview

About me- Hassan Abid (www.hassanabid.com)

- GDE Since March 2016

- Works at NexStreaming

- Hobbies: Hiking, Cycling & Running

- Twitter : hassanabidpk

23

Page 24: Android n preview

감사합니다24