Register now for Android Dev Summit 2019!

CompositePageTransformer

class CompositePageTransformer : ViewPager2.PageTransformer
kotlin.Any
   ↳ androidx.viewpager2.widget.CompositePageTransformer

Allows for combining multiple PageTransformer objects.

Summary

Public constructors

Allows for combining multiple PageTransformer objects.

Public methods

Unit

Adds a page transformer to the list.

Unit

Removes a page transformer from the list.

Unit
transformPage(@NonNull page: View, position: Float)

Public constructors

<init>

CompositePageTransformer()

Allows for combining multiple PageTransformer objects.

Public methods

addTransformer

fun addTransformer(@NonNull transformer: ViewPager2.PageTransformer): Unit

Adds a page transformer to the list.

Transformers will be executed in the order that they were added.

removeTransformer

fun removeTransformer(@NonNull transformer: ViewPager2.PageTransformer): Unit

Removes a page transformer from the list.

transformPage

fun transformPage(@NonNull page: View, position: Float): Unit