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
A slice of Android Slices - droidcon London 2018
Search
Sponsored
·
SiteGround - Reliable hosting with speed, security, and support you can count on.
→
Adnan A M
October 26, 2018
Programming
130
0
Share
A slice of Android Slices - droidcon London 2018
Slides for my talk at droidcon London 2018.
Adnan A M
October 26, 2018
More Decks by Adnan A M
See All by Adnan A M
Abridge Coding Guidelines
adnan321
0
71
A developer's guide to wealth
adnan321
0
290
What the Hook ?
adnan321
0
97
Scoping Your Storage
adnan321
2
180
What The Context ?
adnan321
2
240
Putting Work Manager To Work
adnan321
0
110
OOP To FP
adnan321
1
220
Putting Work Manager To Work
adnan321
1
190
Having fun with Kotlin fun()
adnan321
0
110
Other Decks in Programming
See All in Programming
AI Agent と正しく分析するための環境作り
yoshyum
3
610
Augmenting AI with the Power of Jakarta EE
ivargrimstad
0
230
TypeScriptだけでAIエージェントを作る フロント・エージェント・インフラのフルスタック実践
har1101
6
1k
JavaDoc 再入門
nagise
0
120
AI時代だからこそ「Bloc」を採用する価値があるのかもしれない
takuroabe
0
240
Moments When Things Go Wrong
aurimas
3
120
AlarmKitで明後日起きれるアラームアプリを作る
trickart
0
150
These Five Tricks Can Make Your Apps Greener, Cheaper, & Nicer
hollycummins
0
210
RTSPクライアントを自作してみた話
simotin13
0
210
OSもどきOS
arkw
0
170
気づいたらRubyで100作品 ー クリエイティブコーディングが生活の一部になるまで / 100 Ruby Sketches Later: How Creative Coding Became Part of My Life
chobishiba
2
380
運用エージェントは "作る" から "育てる" へ - 記憶と自己進化の3層設計パターン / self-evolving-agents-three-layer-agent-design
gawa
12
3k
Featured
See All Featured
Data-driven link building: lessons from a $708K investment (BrightonSEO talk)
szymonslowik
1
1.1k
Writing Fast Ruby
sferik
630
63k
Designing Experiences People Love
moore
143
24k
Designing Powerful Visuals for Engaging Learning
tmiket
1
380
Product Roadmaps are Hard
iamctodd
PRO
55
12k
Taking LLMs out of the black box: A practical guide to human-in-the-loop distillation
inesmontani
PRO
3
2.2k
How to Create Impact in a Changing Tech Landscape [PerfNow 2023]
tammyeverts
55
3.3k
Fireside Chat
paigeccino
42
3.9k
How to Grow Your eCommerce with AI & Automation
katarinadahlin
PRO
1
190
Why Your Marketing Sucks and What You Can Do About It - Sophie Logan
marketingsoph
0
150
jQuery: Nuts, Bolts and Bling
dougneiner
66
8.5k
YesSQL, Process and Tooling at Scale
rocio
174
15k
Transcript
A Slice of Android Slices Adnan A M
What are Android Slices ? ◎ Small Interactable UI elements
◎ Fancy Content Providers ◎ Remote Content Views -Widgets
Why should you have a Slice ? ◎ Interactable ◎
Dynamic/Updatable ◎ Supports API 19(Kitkat) - Yaaay
The Life Of A Slice
Building Your First Slice ◎ Add Dependencies dependencies { //
... implementation "androidx.slice:slice-builders-ktx:(ver)" // ... }
Building Your First Slice ◎ Extend Slice Provider class class
CoffeeSliceProvider: SliceProvider() { .. .. }
Building Your First Slice ◎ Register the Fancy Content Provider
Building Your First Slice ◎ onCreateSliceProvider() - Cp.onCreate(), Ahem Ahem
override fun onCreateSliceProvider(): Boolean { coffeeContext = context return true }
Building Your First Slice ◎ onBindSlice() override fun onBindSlice(sliceUri: Uri):
Slice? { when(sliceUri.path) { "/coffee" -> return createCoffeeSlice(sliceUri) } return null }
Congrats You have built your first Android Slice ! But,
there’s more….. A lot more
Quick Recap
Styling a Slice Templated UI - It all starts with
a List
Place your screenshot here 13
Slice Templates ◎ Range Row/Input Range Row ◎ Header Row
◎ Regular Row ◎ Grid Row
Header Row
Header Row
Regular Row
Regular Row
Grid Row
Grid Row
Range Row
Range Row
Slice Templates
Place your screenshot here 24
Adding Actions To Your Slice
Updating Slices/Dynamic Content
Updating Slices/Dynamic Content
Updating Slices/Dynamic Content
Use-cases/Roadmap
Limitations ◎ UI Templates ◎ Search Results/Ranking ◎ Permission Slice
◎ Actions ◎ Slice Host Ability - For 3rd party Apps
References/Credits & Source ◎ Novoda ◎ Google IO 2018 ◎
Source Code - https://github.com/adnan-SM/slices-starbucks ◎ Slide Theme - SlidesCarnival
Thank You !