explaingit

nhaarman/listviewanimations

5,528JavaAudience · developerComplexity · 2/5LicenseSetup · easy

TLDR

ListViewAnimations is a deprecated Android library that added scroll animations, swipe-to-dismiss, and drag-and-drop reordering to Android list views, no longer maintained since RecyclerView now handles this natively.

Mindmap

mindmap
  root((repo))
    What it does
      Scroll animations
      Swipe to dismiss
      Drag and drop
    Animation Styles
      Fade in
      Swing from side
      Scale up
    Modules
      Core animations
      Swipe and drag
      StickyListHeaders compat
    Status
      Deprecated
      Use RecyclerView instead
Click or tap to explore — scroll the page freely

Code map

Detail Auto

An interactive map of this repo's files and how they connect — its source is parsed live in your browser. Click Visualize to build it.

filefunction / class

Things people build with this

USE CASE 1

Add fade-in or slide-in animations to items in an Android ListView as users scroll, in a legacy app.

USE CASE 2

Implement swipe-to-dismiss with an undo option on a list item in an older Android ListView-based UI.

USE CASE 3

Enable drag-and-drop list item reordering in an Android app that still uses ListView instead of RecyclerView.

Tech stack

JavaAndroid

Getting it running

Difficulty · easy Time to first run · 30min

Deprecated, for new Android projects use RecyclerView with ItemAnimator and ItemTouchHelper instead of this library.

Apache License 2.0, use, modify, and distribute freely for any purpose, including commercial apps, with attribution.

In plain English

ListViewAnimations is a deprecated Android library that added animations to scrollable lists in Android apps. The README is upfront about this: the project is no longer being developed because newer Android tools, specifically the RecyclerView component, now handle this type of animation more effectively. The existing code still works, but no new updates will be made. When it was active, the library let Android developers make their list items animate into view as a user scrolled through them. Several animation styles were built in, including items that fade in, swing in from the left or right, scale up from small, or slide in from the bottom. Developers could also add their own custom animation styles beyond those included. Beyond the appearance effects, the library also included interaction features. It supported swipe-to-dismiss, where a user swipes an item sideways to remove it, including a version with an undo option. It also supported drag-and-drop reordering, where a user can hold and drag an item to a new position in the list. A separate feature allowed list items to expand in place to reveal additional content when tapped. The library was split into three modules so developers could include only the parts they needed. The core module handled appearance animations. A second module handled the swipe and drag interactions. A third added compatibility with a third-party library called StickyListHeaders, which makes section headers stick to the top of the screen while scrolling. The project is licensed under the Apache License 2.0. For new Android projects, the README implicitly points toward RecyclerView-based solutions instead.

Copy-paste prompts

Prompt 1
Show me how to add a swing-in-from-left animation to items in an Android ListView using ListViewAnimations.
Prompt 2
How do I implement swipe-to-dismiss with an undo option in an Android ListView using this library?
Prompt 3
Walk me through migrating from ListViewAnimations to RecyclerView ItemAnimator and ItemTouchHelper for the same scroll and swipe effects.
Open on GitHub → Explain another repo

← nhaarman on gitmyhub — every repo by this author, as a profile.

Verify against the repo before relying on details.