ViewPager.OnAdapterChangeListener


public interface ViewPager.OnAdapterChangeListener


Callback interface for responding to adapter changes.

Summary

Public methods

abstract void
onAdapterChanged(
    @NonNull ViewPager viewPager,
    @Nullable PagerAdapter oldAdapter,
    @Nullable PagerAdapter newAdapter
)

Called when the adapter for the given view pager has changed.

Public methods

onAdapterChanged

Added in 1.1.0-beta01
abstract void onAdapterChanged(
    @NonNull ViewPager viewPager,
    @Nullable PagerAdapter oldAdapter,
    @Nullable PagerAdapter newAdapter
)

Called when the adapter for the given view pager has changed.

Parameters
@NonNull ViewPager viewPager

ViewPager where the adapter change has happened

@Nullable PagerAdapter oldAdapter

the previously set adapter

@Nullable PagerAdapter newAdapter

the newly set adapter