SlideShare a Scribd company logo
James Montemagno
Developer Evangelist, Xamarin
@JamesMontemagno
Sweeten Up Your Android
Apps with Lollipop and
Material Design
Who’s this guy?
James
Montemagno
Developer
Evangelist
james@xamarin.com
http://motz.codes
@JamesMontemagno
Android Lollipop
Android Lollipop Major Features
§  ART Runtime!
§  Material Design!
§  Widgets, Views, and Shadows!
§  Animations!
§  Notifications!
§  Compatibility!
Material

Design
Android L Major Features
google.com/design/spec/material-‐design/introduction.html
Bold, graphic, intentional
Material metaphor
 Motion provides meaning
§  Brand new style for
applications. 
•  Theme.Material
•  Theme.Material.Light
•  Theme.Material.Light.
DarkActionBar
Material Design
§  colorPrimary – App
Branding Color
§  colorPrimaryDark – Status
bar & contextual bars
§  colorAccent – Theme UI
Controls (﴾ie. checkbox)﴿
Material Design – Color Palette
Material Design – Color Palette
Let’s
Look
§  AppCompat v21 to the Rescue!!
§  New Themes
§  New Controls
§  New Support Libraries
Lollipop Only?
§  Brand new style for
applications. 
•  Theme.AppCompat
•  Theme.AppCompat.Light
•  Theme.AppCompat.Light.
DarkActionBar
AppCompat Material Design
App Compat Material Design – Color Palette
§  Google Design Guidelines
–  http://www.google.com/design/spec/style/color.html#color-‐color-‐palette
Find Your Theme
§  Material Palette
materialpalette.com
Find Your Theme
§  Also use:
– SupportActionBar
Update Activity
§  Extendable & Customizable
ActionBar
–  Inherits from ActionBar
§  You can have multiple in your
Layout now!
§  Uses the same menu items!
§  Works with AppCompat
Goodbye ActionBar, Hello Toolbar
Step 1: toolbar.axml
Step 2: Insert into Activity axml
Step 3: Update ActionBarActivity
Step 4: Update Theme
Optional: Additional Toolbars
Add	
  into	
  axml	
  &	
  FindViewById:	
  
Complete!
h6p://developer.xamarin.com/samples/monodroid/Supportv7/AppCompat/Toolbar/	
  
Let’s
Look
Xamarin.Forms?
Kind of J 
h6ps://github.com/jamesmontemagno/Hanselman.Forms	
  
Add Style-‐v21
values/styles.xml	
  
values-­‐v21/styles.xml	
  
Remove Icon
Update Hamburger Button
MasterDetailPage	
  
-­‐Set	
  Icon	
  to	
  “slideout.png”	
  or	
  whatever	
  you	
  have	
  
named	
  it	
  
-­‐Add	
  default	
  and	
  v21	
  drawables	
  
Let’s
Look
Views and
Shadows
§ Palettes
§ CardView
§ RecyclerView
§ Elevation
Android Lollipop Major Features
§  Extract Prominent
Colors from Image
§  6 Palettes Generated
Generate a color pallet from an image
Material Design –Palettes
https://www.nuget.org/packages/Xamarin.Android.Support.v7.Palette/
§  Bitmaps as alpha maps
§  android:tint=“@color/blue”
Material Design – Drawable Tint
CardView
Wrap any view in a CardView
https://www.nuget.org/packages Xamarin.Android.Support.v7.CardView/
RecyclerView
https://www.nuget.org/packages/Xamarin.Android.Support.v7.RecyclerView/
§  High speed efficient ListView
§  Includes layout manager for positioning items
§  Default animations for common item operations
Elevation
§  android:elevation=“2dp”
§  View.SetTranslationZ method
§  Z = elevation + translationZ
Demo
Animations
§ Touch Feedback
§ Reveal
§ Activity Transitions
Android Lollipop Major Features
Surface reaction
Animation
Surface reaction
Animation
Material response
Surface reaction
Animation
Material response
 Radial action
§  Default Touch Feedback Animation:
RippleDrawable
§  Set Background to:
•  ?android:attr/
selectableItemBackground
•  ?android:attr/
selectableItemBackgroundBorderless
§  Create custom RippleDrawable using
the ripple element
Animation – Touch Feedback
Animation – Reveal
§  Easily create
clipping circles
§  Custom animations for enter and exit transitions
of activities
•  Enter: How views in the activity enter
•  Exit: How view in activity exit
•  Shared Elements: How views that are shared
between 2 activities animate
Animation – Activity Transitions
Let’s
Look
Notifications
§  Lock Screen Notifications
§  Notifications Metadata 
§  Unified Notifications
Android Lollipop Major Features
§  Android.App.Notification.Builder.SetVisibility(﴾)﴿ 

•  Private: Shows basic information such as icon, but
hides full content
•  Public: Show the notification's full content
•  Secret: Show nothing, excluding even the
notification’s icon
New APIs – Lock Screen Notifications (﴾Android Lollipop)﴿
§  SetCategory(﴾)﴿: Tells the system how to handle
notifications when the device is in Do not Disturb
§  SetPriority(﴾)﴿: Set to Max or High to appear in a
small floating window if the sound also has a vibration
or sound.
§  AddPerson(﴾)﴿: Add a list of people to notification. 
New APIs – Notifications Metadata (﴾Android Lollipop)﴿
Unified Notifications – Standard and Extended
Compatibility

& More
§  New APIs
§  Android Lollipop Small Features
§  Google Play Services via NuGet
Android Lollipop Major Features
§  Material Theme
•  Only available in Android L
Developer Preview
o  Define theme that inherits from
older theme (﴾like Holo)﴿ in res/
values/styles.xml
o  Define them with same name that
inherits from Material in res/values-‐
v21/styles.xml
o  Set theme as your app’s theme in
manifest file
New APIs – Compatibility
§  Layouts
•  Do not use any of the new XML attributes from
Android L Developer Preview, they will not work
with previous versions of Android.
•  You must provide alternative layouts if you wish
to use them
o  L Preview Layouts: res/layout-‐v21/
o  Alternative Layouts: res/layout/
o  Do avoid duplication of code, define styles in
res/values/
o  Modify the style in res/values-‐v21/ for new APIs
§  UI Widgets
•  Support v7: RecyclerView & CardView
o  Limitations (﴾pre-‐L Preview)﴿:
o  CardView falls back to
programmatic shadows
implementation using additional
padding
o  CardView does not clip its children
that intersect with rounded corners
New APIs – Compatibility
§  Animations
•  Following are Android L Developer Preview ONLY:
o  Activity Transitions
o  Touch feedback
o  Reveal animations
o  Path-‐based animations
§  Camera
•  Enhanced image and
video capturing. Capture
Raw sensor data.
§  Multi-‐networking
•  Dynamically scan for
available network with
specific capability and
automatically connect.
§  BLE Peripheral Mode
•  Apps that connect to devices
such as pedometer or health
monitor and transfer data to
another BLE device.
§  Document-‐Centric Recents
§  Job Scheduler
Android L Small Features
Google Play Services via NuGet
§  Play Game Services: event –based challenges, saved
games, and game profiles 
§  App Indexing API
§  Google Cast: Media tracks for closed captioning
§  Wallet: Save to Wallet, geo-‐fenced in-‐store notifications,
split tender between wallet & card
§  Analytics: Measure product impressions/product clicks
§  Mobile Ads: in-‐app purchase ads
§  Dynamic Security Provider
Views
§ Floating Action Button (﴾FAB)﴿
§ Page Slider
Android Lollipop – Not Built In
§  https://components.xamarin.com/view/fab
Floating Action Button
§  https://components.xamarin.com/view/PagerSlidingTabStrip
Pager Slider
Demo
Android Recap
•  Android Lollipop
•  Material Design
•  Views & Animations
•  Notifications
• New Templates
– https://visualstudiogallery.msdn.microsoft.com/
bee6442f-‐8f5a-‐4bba-‐8849-‐e380b61e76b0
• AppCompat is your new friend
§  Intro to AppCompat & Toolbar!
§  http://blog.xamarin.com/android-tips-hello-material-design-v7-appcompat/!
§  http://blog.xamarin.com/android-tips-hello-toolbar-goodbye-action-bar/!
§  Android L Documentation!
§  http://developer.xamarin.com/guides/android/platform_features/android_l/
introduction_to_android_l/!
!
§  Samples!
§  http://developer.xamarin.com/samples/android/!
Resources
James Montemagno
Developer Evangelist, Xamarin
@JamesMontemagno
Thank you!
Q & A

More Related Content

PPTX
Material Design Android
PDF
Material design basics
PPTX
What’s new for Android Developers in 2015 - Material Design, Android Studio, ...
PPTX
Material design in android L developer Preview
PDF
Android Material Design APIs/Tips
PDF
EIA 2015 Creating Apps with Android Material Design
PPTX
Android material design lecture #2
PPTX
Material Design in Android
Material Design Android
Material design basics
What’s new for Android Developers in 2015 - Material Design, Android Studio, ...
Material design in android L developer Preview
Android Material Design APIs/Tips
EIA 2015 Creating Apps with Android Material Design
Android material design lecture #2
Material Design in Android

What's hot (17)

PDF
Android Materials Design
PDF
Best Practices for Android UI by RapidValue Solutions
PPT
Android Ui
PDF
Android UX-UI Design for fun and profit | Fernando Cejas | Tuenti
PPTX
Android Layout
PDF
Android UI System
PDF
Android Layout 3分クッキング
PPTX
Android ui with xml
PDF
09 material design
PPTX
Android session 2-behestee
ODP
Application Craft Tutorial for Google Map
PDF
Getting started with Google Android - OSCON 2008
PPTX
Android app development lesson 1
PPTX
Chapter 2 lesson-1 adding the action bar
PPTX
Chapter 2 lesson-2 styling the action bar
PDF
Create Location Sharing apps using the Ionic framework
PDF
Training Session 2
Android Materials Design
Best Practices for Android UI by RapidValue Solutions
Android Ui
Android UX-UI Design for fun and profit | Fernando Cejas | Tuenti
Android Layout
Android UI System
Android Layout 3分クッキング
Android ui with xml
09 material design
Android session 2-behestee
Application Craft Tutorial for Google Map
Getting started with Google Android - OSCON 2008
Android app development lesson 1
Chapter 2 lesson-1 adding the action bar
Chapter 2 lesson-2 styling the action bar
Create Location Sharing apps using the Ionic framework
Training Session 2
Ad

Viewers also liked (20)

PPTX
Google Material Design - Conceito, aplicações, código e web components
PPTX
Material design
PDF
Material Design and Backwards Compatibility
PPTX
Material Design - do smartphone ao desktop
PDF
Web components
PDF
Workshop de Web Components
PDF
Introduction To Dart (GDG NY Jan 2014 Meetup)
PDF
Apresentação Google I/O Extended Vitória
PDF
Angular js gtg-27feb2013
PDF
WebApps com Web Components
PDF
The Beautiful Simplicity of ES2015
PDF
Chrome Dev Summit Highlights (NYC GDG Dec 2013)
PDF
Polymer and Firebase: Componentizing the Web in Realtime
PDF
Polymer Starter Kit
PDF
Battle of Frameworks: Polymer - Meetup Paris Web Components - 2016-09
PDF
Tech talk polymer
PDF
O futuro do Android
PDF
Polymer Elements: Tudo que você precisa saber para criar a web
PDF
Um salve para evolução! construindo uma nova web com polymer
PPTX
Material design
Google Material Design - Conceito, aplicações, código e web components
Material design
Material Design and Backwards Compatibility
Material Design - do smartphone ao desktop
Web components
Workshop de Web Components
Introduction To Dart (GDG NY Jan 2014 Meetup)
Apresentação Google I/O Extended Vitória
Angular js gtg-27feb2013
WebApps com Web Components
The Beautiful Simplicity of ES2015
Chrome Dev Summit Highlights (NYC GDG Dec 2013)
Polymer and Firebase: Componentizing the Web in Realtime
Polymer Starter Kit
Battle of Frameworks: Polymer - Meetup Paris Web Components - 2016-09
Tech talk polymer
O futuro do Android
Polymer Elements: Tudo que você precisa saber para criar a web
Um salve para evolução! construindo uma nova web com polymer
Material design
Ad

Similar to Android Lollipop and Material Design (20)

PPTX
Android L and So Much More Webinar Slides
PPTX
Android L and Wear overview
PPTX
Material Design - Høgskolen Ringerike 2017
PPTX
Material design
PPTX
Android Lollipop: The developer's perspective
PPTX
TDC 2014 - Trilha Mobile - Material design
PPTX
Material design for android
PPTX
Material design
PPTX
Material design in android lollipop
PPTX
Material Design on Android
PPTX
Material design full topics_animation
PDF
Excellence in the Android User Experience
PPTX
Material design
PPTX
Consistent UI Across Android Devices
PDF
Getting Started With Material Design
PDF
Google I/O 2014 Recap
PDF
Android development first steps
PDF
Android development 1july
PPTX
Google Material Design
PDF
What's new in Android Lollipop
Android L and So Much More Webinar Slides
Android L and Wear overview
Material Design - Høgskolen Ringerike 2017
Material design
Android Lollipop: The developer's perspective
TDC 2014 - Trilha Mobile - Material design
Material design for android
Material design
Material design in android lollipop
Material Design on Android
Material design full topics_animation
Excellence in the Android User Experience
Material design
Consistent UI Across Android Devices
Getting Started With Material Design
Google I/O 2014 Recap
Android development first steps
Android development 1july
Google Material Design
What's new in Android Lollipop

More from James Montemagno (20)

PDF
What's new and next for mobile development with .NET
PPTX
Taking Mobile Development Serverless with C#
PDF
.NET North UG - What’s new & next for Xamarin developers
PPTX
Building Stream Deck Plugins in C#
PDF
.Net Dev Summit 2020 - What's new and next for Xamarin developers
PDF
Creating Island Tracker - Xamarin, Azure Functions, Table Storage, & More
PDF
Xamarin.forms Shell + Navigation
PPTX
Seattle Mobile .NET User Group - Nov. 13th 2019
PDF
Expert Day - What's New, Hot, & Awesome for Xamarin Devs
PDF
Oxford .NET - Go Mobile with Xamarin
PDF
Xamarin - New & Awesome + Building Xamarin.Essentials
PDF
Zebra App Forum 2019 - Building iOS & Android Apps with Xamarin
PPTX
Stunning Mobile Apps with the Xamarin Visual Design System​
PDF
What's New, Hot, & Awesome for Xamarin Developers!
PDF
Introduction to Mobile Development with Xamarin -DotNet Westide
PDF
What's New in Xamarin? - Santo Domingo
PDF
Xamarin: The Future of App Development
PDF
Optimizing and Extending Xamarin.Forms iOS, Android, and UWP Apps
PDF
.NET Everywhere and for Everyone
PDF
MS Experiences 17 - Xamarin: Future of Mobile Development
What's new and next for mobile development with .NET
Taking Mobile Development Serverless with C#
.NET North UG - What’s new & next for Xamarin developers
Building Stream Deck Plugins in C#
.Net Dev Summit 2020 - What's new and next for Xamarin developers
Creating Island Tracker - Xamarin, Azure Functions, Table Storage, & More
Xamarin.forms Shell + Navigation
Seattle Mobile .NET User Group - Nov. 13th 2019
Expert Day - What's New, Hot, & Awesome for Xamarin Devs
Oxford .NET - Go Mobile with Xamarin
Xamarin - New & Awesome + Building Xamarin.Essentials
Zebra App Forum 2019 - Building iOS & Android Apps with Xamarin
Stunning Mobile Apps with the Xamarin Visual Design System​
What's New, Hot, & Awesome for Xamarin Developers!
Introduction to Mobile Development with Xamarin -DotNet Westide
What's New in Xamarin? - Santo Domingo
Xamarin: The Future of App Development
Optimizing and Extending Xamarin.Forms iOS, Android, and UWP Apps
.NET Everywhere and for Everyone
MS Experiences 17 - Xamarin: Future of Mobile Development

Recently uploaded (20)

PPT
Project quality management in manufacturing
PPTX
Engineering Ethics, Safety and Environment [Autosaved] (1).pptx
PDF
PPT on Performance Review to get promotions
PPTX
Lecture Notes Electrical Wiring System Components
PDF
Embodied AI: Ushering in the Next Era of Intelligent Systems
PDF
The CXO Playbook 2025 – Future-Ready Strategies for C-Suite Leaders Cerebrai...
PDF
TFEC-4-2020-Design-Guide-for-Timber-Roof-Trusses.pdf
PDF
Operating System & Kernel Study Guide-1 - converted.pdf
PPTX
Welding lecture in detail for understanding
PDF
Automation-in-Manufacturing-Chapter-Introduction.pdf
PPT
CRASH COURSE IN ALTERNATIVE PLUMBING CLASS
PPTX
OOP with Java - Java Introduction (Basics)
PDF
Evaluating the Democratization of the Turkish Armed Forces from a Normative P...
PPTX
CYBER-CRIMES AND SECURITY A guide to understanding
DOCX
ASol_English-Language-Literature-Set-1-27-02-2023-converted.docx
PPTX
Recipes for Real Time Voice AI WebRTC, SLMs and Open Source Software.pptx
PDF
keyrequirementskkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkk
PDF
Well-logging-methods_new................
PPTX
UNIT 4 Total Quality Management .pptx
PDF
Model Code of Practice - Construction Work - 21102022 .pdf
Project quality management in manufacturing
Engineering Ethics, Safety and Environment [Autosaved] (1).pptx
PPT on Performance Review to get promotions
Lecture Notes Electrical Wiring System Components
Embodied AI: Ushering in the Next Era of Intelligent Systems
The CXO Playbook 2025 – Future-Ready Strategies for C-Suite Leaders Cerebrai...
TFEC-4-2020-Design-Guide-for-Timber-Roof-Trusses.pdf
Operating System & Kernel Study Guide-1 - converted.pdf
Welding lecture in detail for understanding
Automation-in-Manufacturing-Chapter-Introduction.pdf
CRASH COURSE IN ALTERNATIVE PLUMBING CLASS
OOP with Java - Java Introduction (Basics)
Evaluating the Democratization of the Turkish Armed Forces from a Normative P...
CYBER-CRIMES AND SECURITY A guide to understanding
ASol_English-Language-Literature-Set-1-27-02-2023-converted.docx
Recipes for Real Time Voice AI WebRTC, SLMs and Open Source Software.pptx
keyrequirementskkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkk
Well-logging-methods_new................
UNIT 4 Total Quality Management .pptx
Model Code of Practice - Construction Work - 21102022 .pdf

Android Lollipop and Material Design