Animations in Android
  • Introduction
  • About us
  • Basic animations
  • ConstraintLayout: Core concepts
  • I like to move it, move it!
  • Step 1
  • Step 2
  • Step 2: Solution
  • Step 3
  • Step 3: Solution
  • Step 4
  • Step 4: Solution
  • Step 5
  • Step 5: Solution
  • Step 6
  • Step 7
  • Step 7: Solution
  • Step 8
  • Step 8: Solution
  • MotionLayout
  • Party time!
  • Shared element transition
  • Adding a RecyclerView
  • Activity transitions
  • Adding a second Activity
  • Adding the shared element transition
  • You made it!
  • VectorDrawable
  • VectorDrawable: Solution
  • Using the VectorDrawable
  • RecyclerView item animation & self-contained MotionScene
  • Creating a self-contained MotionScene
  • Creating a self-contained MotionScene : Solution
  • Adding animations in the RecyclerView items: Step 1
  • Adding animations in the RecyclerView items: Step 2
  • RecyclerView animations step 2: Solution
  • Physic based animations
  • Implement a spring animation
  • Spring animation: Solution
  • The finish line!
Powered by GitBook
On this page
  • A painful truth...
  • An animated history...
  • About this workshop
  • Prerequisites

Introduction

Why animations are an important component of an app, who is this tutorial for and what you'll learn

NextAbout us

Last updated 6 years ago

A painful truth...

Tying up the users to your app is the most important and yet one of the most puzzling parts of the app development. Studies have shown that users acquire a very strong impression about your app within the first 30''; Including of course splash screens or empty lists and loading indicators, that we’re all going to agree that are pretty much impossible to avoid in most of the apps. Given this fact it's easy to understand that catching the user's interest instantly is one of the most important things in modern development. The other one would be meaningful, non-distracting feedback on their actions. What they both have in common? They're both achievable with the use of motion.

Motion is the key word you need to add to your android dictionary, if you haven't’ already and focus on.

There are multiple ways you can add motion to your app and make it come alive using the different Android's animation APIs. This tutorial is focusing on the newest ones.

An animated history...

Animations have been around since the very first Android versions. The first animation APIs though made their appearance in HoneyComb 3.0 (API level 11). That's 7(!) years ago! They still got quite popular only after the Material design guidelines were released by Google in 2014. Fast forward 2 years, they announced ConstraintLayout, a new container class as an alternative to the 'RelativeLayout' and the LinearLayout. The advantages of that new layout would be that all the developers could use the new Android Studio's drag-n-drop GUI builder. With just a drag-n-drop gesture, you would only have to provide the x,y coordinates of the view and it would work like magic Meanwhile, other awesome APIs, tools and classes like the AnimatedVectorDrawable and the by Alex Lockwood shaped (and shook) the Android animation world.

This year, ConstraintLayout got a makeover and a lot of new features were added (while in the meantime the GUI builder is getting much better and faster as well). One of the biggest ones was the introduction to the MotionLayout. According to the release notes, MotionLayout is a layout designed to provide a rich framework for declarative animation and input-driven motion. But enough with the Android animation history! Time to start building!

About this workshop

This workshop mainly focuses to people that have little to no experience with the ContraintLayout (and its subclass, the MotionLayout), the path morphing and the transitions. It will guide you through step by step on how to create clean and animated layouts without the pain, just the gain!

Briefly some basic animation classes like the PropertyView animations are also mentioned. If you'e already aware with it though feel free to jump to the "I like to move it, move it" step.

Prerequisites

  • Android Studio 3.1.3 or higher

  • a device or emulator running Android API level 21 or higher

  • A basic understanding of Kotlin

✨
ShapeShifter