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
Adnan A M
October 26, 2018
Programming
0
110
A slice of Android Slices - droidcon London 2018
Slides for my talk at droidcon London 2018.
Adnan A M
October 26, 2018
Tweet
Share
More Decks by Adnan A M
See All by Adnan A M
Abridge Coding Guidelines
adnan321
0
47
A developer's guide to wealth
adnan321
0
250
What the Hook ?
adnan321
0
83
Scoping Your Storage
adnan321
2
150
What The Context ?
adnan321
2
210
Putting Work Manager To Work
adnan321
0
98
OOP To FP
adnan321
1
200
Putting Work Manager To Work
adnan321
1
160
Having fun with Kotlin fun()
adnan321
0
91
Other Decks in Programming
See All in Programming
たった 1 枚の PHP ファイルで実装する MCP サーバ / MCP Server with Vanilla PHP
okashoi
1
220
Systèmes distribués, pour le meilleur et pour le pire - BreizhCamp 2025 - Conférence
slecache
0
120
「Cursor/Devin全社導入の理想と現実」のその後
saitoryc
0
690
RailsGirls IZUMO スポンサーLT
16bitidol
0
140
5つのアンチパターンから学ぶLT設計
narihara
1
140
deno-redisの紹介とJSRパッケージの運用について (toranoana.deno #21)
uki00a
0
170
童醫院敏捷轉型的實踐經驗
cclai999
0
210
ソフトウェア品質を数字で捉える技術。事業成長を支えるシステム品質の マネジメント
takuya542
0
730
GitHub Copilot and GitHub Codespaces Hands-on
ymd65536
1
140
LT 2025-06-30: プロダクトエンジニアの役割
yamamotok
0
670
Result型で“失敗”を型にするPHPコードの書き方
kajitack
4
570
PHPでWebSocketサーバーを実装しよう2025
kubotak
0
250
Featured
See All Featured
Intergalactic Javascript Robots from Outer Space
tanoku
271
27k
Mobile First: as difficult as doing things right
swwweet
223
9.7k
The Art of Programming - Codeland 2020
erikaheidi
54
13k
The Success of Rails: Ensuring Growth for the Next 100 Years
eileencodes
45
7.5k
XXLCSS - How to scale CSS and keep your sanity
sugarenia
248
1.3M
Connecting the Dots Between Site Speed, User Experience & Your Business [WebExpo 2025]
tammyeverts
5
230
Bash Introduction
62gerente
614
210k
Testing 201, or: Great Expectations
jmmastey
42
7.6k
Design and Strategy: How to Deal with People Who Don’t "Get" Design
morganepeng
130
19k
Put a Button on it: Removing Barriers to Going Fast.
kastner
60
3.9k
Six Lessons from altMBA
skipperchong
28
3.9k
Agile that works and the tools we love
rasmusluckow
329
21k
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 !