Class DynamicPageIndicator2

java.lang.Object
android.view.View
com.pranavpandey.android.dynamic.support.widget.DynamicPageIndicator2
All Implemented Interfaces:
Drawable.Callback, AccessibilityEventSource, KeyEvent.Callback, View.OnAttachStateChangeListener

public class DynamicPageIndicator2 extends View implements View.OnAttachStateChangeListener
An ink inspired widget for indicating pages in a ViewPager2.
  • Constructor Details

    • DynamicPageIndicator2

      public DynamicPageIndicator2(Context context)
    • DynamicPageIndicator2

      public DynamicPageIndicator2(Context context, AttributeSet attrs)
    • DynamicPageIndicator2

      public DynamicPageIndicator2(Context context, AttributeSet attrs, int defStyle)
  • Method Details

    • setViewPager

      public void setViewPager(ViewPager2 viewPager)
    • getUnselectedColour

      public int getUnselectedColour()
    • setUnselectedColour

      public void setUnselectedColour(int unselectedColour)
    • getSelectedColour

      public int getSelectedColour()
    • setSelectedColour

      public void setSelectedColour(int selectedColour)
    • onMeasure

      protected void onMeasure(int widthMeasureSpec, int heightMeasureSpec)
      Overrides:
      onMeasure in class View
    • onViewAttachedToWindow

      public void onViewAttachedToWindow(View view)
      Specified by:
      onViewAttachedToWindow in interface View.OnAttachStateChangeListener
    • onViewDetachedFromWindow

      public void onViewDetachedFromWindow(View view)
      Specified by:
      onViewDetachedFromWindow in interface View.OnAttachStateChangeListener
    • onDraw

      protected void onDraw(Canvas canvas)
      Overrides:
      onDraw in class View