Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
New in Android Studio
Search
pluulove (노현석)
December 21, 2019
Programming
0
1.2k
New in Android Studio
Android Dev Summit 2019 extended Seoul에서 발표한 자료입니다.
pluulove (노현석)
December 21, 2019
Tweet
Share
More Decks by pluulove (노현석)
See All by pluulove (노현석)
N.E.X.T LEVEL
pluu
3
410
안드로이드 기술 이력서의 최소 조건
pluu
1
2.2k
I/O Extended Android in Korea 2024 ~ Whats new in Android development tools
pluu
0
590
Android Studio와 좀 더 친해지기
pluu
0
150
우리모두 삽질한다
pluu
0
1.3k
Re:Android Studio 설정 살펴보기 및 생산성 올리기
pluu
0
1.5k
What's new in Android development tools
pluu
1
860
What's new in Android development tools
pluu
1
430
개발자 Side Next Step ~ 커뮤니티 x Android
pluu
2
270
Other Decks in Programming
See All in Programming
最近のVS Codeで気になるニュース 2025/01
74th
1
250
Amazon ECS とマイクロサービスから考えるシステム構成
hiyanger
2
490
ASP. NET CoreにおけるWebAPIの最新情報
tomokusaba
0
360
[JAWS-UG横浜 #80] うわっ…今年のServerless アップデート、少なすぎ…?
maroon1st
1
170
2,500万ユーザーを支えるSREチームの6年間のスクラムのカイゼン
honmarkhunt
6
5.1k
SwiftUIで単方向アーキテクチャを導入して得られた成果
takuyaosawa
0
260
2024年のWebフロントエンドのふりかえりと2025年
sakito
1
230
Flutter × Firebase Genkit で加速する生成 AI アプリ開発
coborinai
0
150
Multi Step Form, Decentralized Autonomous Organization
pumpkiinbell
1
660
2024年のkintone API振り返りと2025年 / kintone API look back in 2024
tasshi
0
210
テストをしないQAエンジニアは何をしているか?
nealle
0
130
Amazon Q Developer Proで効率化するAPI開発入門
seike460
PRO
0
110
Featured
See All Featured
VelocityConf: Rendering Performance Case Studies
addyosmani
328
24k
ピンチをチャンスに:未来をつくるプロダクトロードマップ #pmconf2020
aki_iinuma
114
50k
The Psychology of Web Performance [Beyond Tellerrand 2023]
tammyeverts
45
2.3k
Product Roadmaps are Hard
iamctodd
PRO
50
11k
Speed Design
sergeychernyshev
25
780
Why You Should Never Use an ORM
jnunemaker
PRO
55
9.2k
GraphQLの誤解/rethinking-graphql
sonatard
68
10k
[RailsConf 2023] Rails as a piece of cake
palkan
53
5.2k
Fontdeck: Realign not Redesign
paulrobertlloyd
82
5.4k
The Straight Up "How To Draw Better" Workshop
denniskardys
232
140k
JavaScript: Past, Present, and Future - NDC Porto 2020
reverentgeek
47
5.2k
It's Worth the Effort
3n
184
28k
Transcript
Android Dev Summit 2019 extended Seoul New in Android Studio
GDE for Android GDG Korea Android Organizer HyeonSeok.Noh
উ֞ೞࣁਃ pluuੑפ Android App Developer Google Developers Expert GDG Korea
Android Organizer
Android Auto Emulator Emulator Multi-Display support Google Maps Emulator Integration
Design Tools : Split View & Zoom Control View Binding Support Profilers: Leak detection Filtering JNI support for Kotlin APK Reloader Intellij 2019.2 v3.6 Jetpack Compose Support Motion Editor Build Attribution Desugaring in D8 & R8 Design Tools : Multi-Preview Updated Layout Inspector Kotlin DSL script (KTS) Proguard Editing Kotlin Live Templates Intellij 2019.3 v4.0+
Android Dev Summit 2019 extended Seoul Project Structure v3.6 /
v4.0
build.gradle (~v3.6) New Versions
build.gradle (~v3.6) New Versions (Not Visible)
build.gradle (v4.0) Solved problem new version
build.gradle Variable / Dependency
Android Dev Summit 2019 extended Seoul Build Speed v4.0 Canary
3+
None
Build Speed • Build ࠙ࢳद Build Task Critical Pathܳ ӝળਵ۽
ഛੋ • Critical Path : Gradle োࣘਵ۽ प೯ • ਃ ҃۽о Build दрਸ Ѿ • 4.0.0-alpha03 ࢚ ਃ
Build Speed Click
Build Speed 40.7%
Build Speed
Build Speed
Build Speed
Build Speed
Build Speed
Build Speed
Build Speed
Build Speed
Incremental Build Speed First Build (Total 127.233 s) Second Build
(Total 7.129 s) 48.394 s 5.598 s
Android Dev Summit 2019 extended Seoul Multi Preview v3.6 /
v4.0
Multi Preview • নೠ ٣߄झ ߂ Configuration җ ҙ۲ػ ۨইਓਸ
زदী ܻ ࠅ ࣻ ח ٣ੋ بҳ • Pixel Devices • Locale • Color Blind Mode • IDE ହ য়ܲଃ ࢚ױীח Multi Preview చਸ ܼೞৈ ഝࢿച
Split View Code / Split / Design
Multi Preview Click
Pixel Devices Click
Project Locales Click
Color Blind Mode Click
Android Dev Summit 2019 extended Seoul Desugaring v4.0
Android ѐߊद Ҋ • Java? Kotlin? • ӝמ ࢎਊೡ
ࣻ חо? • ݽٚ ۽Ӓې߁ীࢲ minSdkVersionী ח ޙઁٜ • Shadow / ShadowColor / Java 8 Retrolambda, jack, desugar, Kotlin
~ Android Studio 3.x • Android Studio 3.0 ࢚ DEX
Compiler D8ীࢲ desugaring ۽ࣁझܳ ా೧ Java 8 য ӝמ ਗ • lambda expressions • default interface methods • try with resources • Java 8ਸ ॶ ࣻ ݅, ৈ ୭ ߡ ઁড ઓ Desugaring https://developer.android.com/studio/write/java8-support
~ Android Studio 3.x Desugaring
Desugaring Need High API Level
Android Studio 4.0+ • ୭ࣗ API Levelਸ ਃҳೞ ঋҊ Java
8 API ࢎਊ оמ • D8 ־ۅػ API ҳഅਸ ߹ب Library DEX ੌ۽ ஹੌ • Library ղࠗী ־ۅػ API ҳഅ ನೣ • Desugaring ۽ࣁझח Runtimeद Libraryܳ ࢎਊೞب۾ ٘ ࢿ Desugaring https://developer.android.com/studio/preview/features#j8-desugar
Desugaring // build.gradle android { compileOptions { // ࢜۽ Language
APIܳ ਗೞӝ ਤೠ Flag coreLibraryDesugaringEnabled true // Java compatibility ࢸী Java 8 ਊ sourceCompatibility JavaVersion.VERSION_1_8 targetCompatibility JavaVersion.VERSION_1_8 } }
Desugaring coreLibraryDesugaringEnabled
Default
Default
Desugaring ਊૐо
Desugaring
Supported API • java.util.stream • java.time • java.util.function • java.util.{Map,Collection,Comparator}
• java.util.Optional, java.util.OptionalInt, java.util.OptionalDouble • java.util.concurrent.atomic (new methods on AtomicInteger, AtomicLong, AtomicReference) • ConcurrentHashMap (with bug fixes for Android 5.0) Desugaring https://developer.android.com/studio/preview/features#j8-desugar
Android Dev Summit 2019 extended Seoul View Binding v3.6 /
v4.0
View Binding • View৬ ࢚ഐਊೞח ٘ܳ औѱ ࢿ • ViewBinding
ഝࢿചद XML Layout Binding ېझ ࢤࢿ • ࠗ࠙ ҃, findViewByIdܳ • Android Studio 3.6 Canary 11+ ࠗఠ ഝࢿച <!-- ignore --> <LinearLayout ... tools:viewBindingIgnore="true" > ... </LinearLayout>
View Binding // build.gradle android { viewBinding { isEnabled =
true } }
Example // result_profile.xml <LinearLayout ... > <TextView android:id="@+id/name" /> <ImageView
android:cropToPadding="true" /> <Button android:id="@+id/button" android:background="@drawable/rounded_button" /> </LinearLayout>
Example // result_profile.xml <LinearLayout ... > <TextView android:id="@+id/name" /> <ImageView
android:cropToPadding="true" /> <Button android:id="@+id/button" android:background="@drawable/rounded_button" /> </LinearLayout> public final class ResultProfileBinding implements ViewBinding { @NonNull private final LinearLayout rootView; @NonNull public final Button button; @NonNull public final TextView name; private ResultProfileBinding( @NonNull LinearLayout rootView, @NonNull Button button, @NonNull TextView name) { this.rootView = rootView; this.button = button; this.name = name; } @Override @NonNull public LinearLayout getRoot() { return rootView; } @NonNull public static ResultProfileBinding inflate(...) { ... }
View Binding • Binding ېझ ੋझఢझী Viewী ೠ ଵઑо ನೣ
• Root • IDо ח View public final class ResultProfileBinding implements ViewBinding { @NonNull private final LinearLayout rootView; @NonNull public final Button button; @NonNull public final TextView name; private ResultProfileBinding( @NonNull LinearLayout rootView, @NonNull Button button, @NonNull TextView name) { this.rootView = rootView; this.button = button; this.name = name; } @Override @NonNull public LinearLayout getRoot() { return rootView; } @NonNull public static ResultProfileBinding inflate(...) { ... }
View Binding private lateinit var binding: ResultProfileBinding @Override fun onCreate(savedInstanceState:
Bundle) { super.onCreate(savedInstanceState) binding = ResultProfileBinding.inflate(layoutInflater) setContentView(binding.root) } DataBindingҗ زੌೠ ࢎਊߨ
findViewById৬ ର • Null safety : Viewী ೠ ଵઑܳ
ࢤࢿ • ੜޅػ View ID۽ ੋೠ NPE ߊࢤ ۰ח হ • ੌࠗ࠙ী݅ ח ҃ @Nullable • Type safety : XMLীࢲ View Typeҗ ੌ • Layoutҗ ٘ ࠺ഐജࢿਵ۽ ੋ೧ Compileदী ࠽٘о पಁ
• Data Binding <layout> కӒܳ ࢎਊೠ ۨইਓ݅ ܻ • View
Binding ۨইਓ ߸ࣻ/അध ਗ • XML ؘఠ৬ ۨইਓ ߄ੋ٬ ࠛоמ • ࢎਊ ؊ औҊ ࠽٘ ࣘبী ؏ ೱਸ ષ Data Bindingҗ ର
Android Dev Summit 2019 extended Seoul Jetpack Compose v4.0
Before & after Simple app that filters contacts and display
name + photo
None
@Composable fun FilteredList(contacts: List<Contact>, filterText: String = "") { val
state = +state { filterText } VerticalScroller { Column { TextField(filterText, onValueChange = { state.value = it }) contacts.filter { it.contains(state.value) }.forEach { Row { Image(it.photo) Text(it.name) } } } } } Compose Version
None
None
None
Jetpack Compose • pre alpha version • API Not Fixed
Android Dev Summit 2019 extended Seoul Embed Emulator on Android
Studio NOT RELEASE
Embed Emulator
Android Dev Summit 2019 extended Seoul Editor v4.0
NOT RELEASE
Android Dev Summit 2019 extended Seoul Editor ~ Debugging v3.6
/ v4.0
Debugging ~ Problem • ٣ߡӦ Break Point ۄੋਸ աஜ
• ٣ߡӦ ୶о٘ܳ ؊ ֍Ҋ रয ೧Ѿߨ 1. ನӝೠ 2. द दೠ 3. Apply Changesܳ दبೠ
Apply Changes & Frame Drop Apply Changes & Frame Drop
Android Dev Summit 2019 extended Seoul Layout Inspector v4.0
• I/O 19ীࢲ ࣗѐػ ә • ࢜۽ Layout Inspector
• AS 4.0 Canary 4ীࢲ ز • AS 4.0 Canary 5ীࢲ ز • AS 4.0 Canary 6ীࢲ ز Layout Inspector
• Preference - Experimental - Layout Inspector - Enable Live
Layout Inspector • Install Plugin • Skia Layout Inspector Enable
• Skia Parser Server Requirement
None
None
None
None
None
None
None
None
None
• 3D View ഋక۽ ۨইਓ Өܳ द пਵ۽ ഛੋ оמ
• അ Live updates Slooooow Reviews
Motion Editor v4.0
None
None
None
None
None
None
None
Custom
Kotlin Live Template v4.0
Live Template
Emulator
Displays Apply Changes Add Display
Multiple Display
New Old Emulator 29.2.2 Canary
Location
Location
Location
Location
Location
Location
Android Dev Summit 2019 extended Seoul Android Gradle plugin 4.0.0
v4.0
Feature // build.gradle android { buildFeatures { // Jetpack Compose
compose = false buildConfig = true // View Binding / viewBinding.enabled is deprecated viewBinding = false // Data Binding / dataBinding.enabled property is deprecated dataBinding = false aidl = true renderScript = true resValues = true shaders = true } }
Android Dev Summit 2019 extended Seoul