DefaultBannerIndicator

class DefaultBannerIndicator(context: Context? = null, val params: IndicatorParams? = null) : BannerXIndicator, BannerTitleDisplayable

The default BannerXIndicator for BannerX.

This indicator supports displaying Banner titles and number of Banner objects. However, this indicator shows either the indicator panels or number of Banner objects but never both.

NOTE: The list of Banner titles are not parceled during re-instantiation of this class, the updateTitleList must be manually invoked.

Author

IODevBlue

Since

1.0.0

Constructors

Link copied to clipboard
fun DefaultBannerIndicator(context: Context? = null, params: IndicatorParams? = null)

Functions

Link copied to clipboard
open override fun applyFadeOnIdle()

Apply a fade animation when the BannerXIndicator is idle to hide it.

Link copied to clipboard
open override fun displayTitleTextView(display: Boolean)

Toggles the visibility of the TextView displaying Banner titles.

Link copied to clipboard
open override fun getIndicatorView(): RelativeLayout?

Get the View representation of the BannerXIndicator.

Link copied to clipboard
open override fun onBannerScrolled(position: Int, positionOffset: Float, positionOffsetPixels: Int)

This is invoked by BannerX when the current Banner is being scrolled.

Link copied to clipboard
open override fun onBannerSelected(position: Int)

This is invoked when a new Banner is selected by BannerX.

Link copied to clipboard
open override fun removeFadeOnIdle()

Apply an animation to gradually display the BannerXIndicator when hidden.

Link copied to clipboard
open infix override fun resetUsingParams(params: IndicatorParams)

Reset an existing BannerXIndicator instance to use the properties from the provided params object.

Link copied to clipboard
open override fun setContext(context: Context): BannerXIndicator

The Context object to be used internally by the BannerXIndicator implementation.

Link copied to clipboard
open override fun supportsBannerTitles(): Boolean

Validates if this BannerXIndicator supports displaying Banner titles.

Link copied to clipboard
open override fun updateTitleList(list: List<String>)

Updates the list of titles to be displayed by the indicator.

Properties

Link copied to clipboard
var allowNumberIndicator: Boolean = false

Enable or disable displaying number of banners on the DefaultBannerIndicator. It is disabled by default.

Link copied to clipboard
var indicatorBackgroundDrawable: Drawable? = null

The background Drawable for the DefaultBannerIndicator.

Link copied to clipboard
var indicatorFadeOnIdle: Boolean = false

Enable or disable a fade animation when the DefaultBannerIndicator is idle. Default: false.

Link copied to clipboard

The time it takes for DefaultBannerIndicator to be visible when idle before it fades away.

Link copied to clipboard
@ColorInt
var indicatorTextColor: Int = 0

Color applied to texts displayed by the DefaultBannerIndicator.

Link copied to clipboard
@Dimension
var indicatorTextSize: Float = 0.0f

Text size applied to texts displayed by the DefaultBannerIndicator.

Link copied to clipboard
var indicatorTextTypeface: Typeface?

The Typeface applied to texts displayed by the DefaultBannerIndicator.

Link copied to clipboard
var numberIndicatorBackgroundDrawable: Drawable? = null

The background Drawable for the DefaultBannerIndicator's number indicator widget.

Link copied to clipboard
open override val params: IndicatorParams? = null

Use the properties stored in this IndicatorParams object to setup the BannerXIndicator instance.

Link copied to clipboard
var showIndicatorText: Boolean = false

Enable or disable the DefaultBannerIndicator from showing Banner titles. It is disabled by default