menu

Xamarin.Android

  • Code Examples
  • Upgrade Guide
  • User Guide
  • Demos
  • Support
  • Forums
  • Download
Class SfCarousel - Xamarin.Android API Reference | Syncfusion

    Show / Hide Table of Contents

    Class SfCarousel

    Initializes a new instance of the SfCarousel class.

    Inheritance
    System.Object
    SfCarousel
    Implements
    Android.Views.View.IOnClickListener
    Android.Runtime.IJavaObject
    System.IDisposable
    Java.Interop.IJavaPeerable
    Namespace: Com.Syncfusion.Carousel
    Assembly: Syncfusion.SfCarousel.Android.dll
    Syntax
    public class SfCarousel : FrameLayout, View.IOnClickListener, IJavaObject, IDisposable, IJavaPeerable

    Constructors

    SfCarousel(Context)

    Initializes a new instance of the SfCarousel class.

    Declaration
    public SfCarousel(Context context)
    Parameters
    Type Name Description
    Android.Content.Context context

    Context of the carousel.

    SfCarousel(Context, IAttributeSet)

    Initializes a new instance of the SfCarousel class.

    Declaration
    public SfCarousel(Context context, IAttributeSet attribute)
    Parameters
    Type Name Description
    Android.Content.Context context

    Context of the carousel.

    Android.Util.IAttributeSet attribute

    Attribute set value.

    SfCarousel(Context, IAttributeSet, Int32)

    Initializes a new instance of the SfCarousel class.

    Declaration
    public SfCarousel(Context context, IAttributeSet attribute, int style)
    Parameters
    Type Name Description
    Android.Content.Context context

    The Context.

    Android.Util.IAttributeSet attribute

    Attribute set.

    System.Int32 style

    Default style.

    SfCarousel(Context, IAttributeSet, Int32, Int32)

    Initializes a new instance of the SfCarousel class.

    Declaration
    public SfCarousel(Context context, IAttributeSet attribute, int style, int resource)
    Parameters
    Type Name Description
    Android.Content.Context context

    Context set.

    Android.Util.IAttributeSet attribute

    Attribute set.

    System.Int32 style

    Default style.

    System.Int32 resource

    Default resource.

    SfCarousel(IntPtr, JniHandleOwnership)

    Initializes a new instance of the class.

    Declaration
    public SfCarousel(IntPtr a, JniHandleOwnership b)
    Parameters
    Type Name Description
    System.IntPtr a

    The a

    Android.Runtime.JniHandleOwnership b

    The b

    Properties

    Adapter

    Gets or sets the adapter.

    Declaration
    public ICarouselAdapter Adapter { get; set; }
    Property Value
    Type Description
    ICarouselAdapter

    The adapter.

    AllowLoadMore

    Gets or sets a value indicating whether this SfCarousel allow load more.

    Declaration
    public bool AllowLoadMore { get; set; }
    Property Value
    Type Description
    System.Boolean

    true if allow load more; otherwise, false.

    DataSource

    Gets or sets the data source.

    Declaration
    public IList<SfCarouselItem> DataSource { get; set; }
    Property Value
    Type Description
    System.Collections.Generic.IList<SfCarouselItem>

    The data source.

    Duration

    Gets or sets the duration.

    Declaration
    public int Duration { get; set; }
    Property Value
    Type Description
    System.Int32

    The duration.

    EnableInteraction

    Gets or sets a value indicating whether this SfCarousel EnableInteraction or not

    Declaration
    public bool EnableInteraction { get; set; }
    Property Value
    Type
    System.Boolean

    EnableVirtualization

    Gets or sets a value indicating whether this SfCarousel is virtualization.

    Declaration
    public bool EnableVirtualization { get; set; }
    Property Value
    Type Description
    System.Boolean

    true if is virtualization; otherwise, false.

    ItemHeight

    Gets or sets the height of the item.

    Declaration
    public int ItemHeight { get; set; }
    Property Value
    Type Description
    System.Int32

    The height of the item.

    ItemSpacing

    Gets or sets the item spacing.

    Declaration
    public int ItemSpacing { get; set; }
    Property Value
    Type Description
    System.Int32

    The item spacing.

    ItemsSource

    Gets or sets items collection

    Declaration
    public IEnumerable ItemsSource { get; set; }
    Property Value
    Type Description
    System.Collections.IEnumerable

    The item collection.

    ItemWidth

    Gets or sets the width of the item.

    Declaration
    public int ItemWidth { get; set; }
    Property Value
    Type Description
    System.Int32

    The width of the item.

    LoadMoreItemsCount

    Gets or sets the maximum items count.

    Declaration
    public int LoadMoreItemsCount { get; set; }
    Property Value
    Type Description
    System.Int32

    The maximum items count.

    LoadMoreView

    Gets or sets a value indicating whether this SfCarousel allow load more.

    Declaration
    public View LoadMoreView { get; set; }
    Property Value
    Type Description
    Android.Views.View

    true if allow load more; otherwise, false.

    Offset

    Gets or sets the offset.

    Declaration
    public int Offset { get; set; }
    Property Value
    Type Description
    System.Int32

    The offset.

    RotationAngle

    Gets or sets the rotation angle.

    Declaration
    public int RotationAngle { get; set; }
    Property Value
    Type Description
    System.Int32

    The rotation angle.

    ScaleOffset

    Gets or sets the scale offset.

    Declaration
    public float ScaleOffset { get; set; }
    Property Value
    Type Description
    System.Single

    The scale offset.

    SelectedIndex

    Gets or sets the index of the selected.

    Declaration
    public int SelectedIndex { get; set; }
    Property Value
    Type Description
    System.Int32

    The index of the selected.

    SelectedItemOffset

    Gets or sets the selected item offset.

    Declaration
    public int SelectedItemOffset { get; set; }
    Property Value
    Type Description
    System.Int32

    The selected item offset.

    ViewMode

    Gets or sets the view mode.

    Declaration
    public ViewMode ViewMode { get; set; }
    Property Value
    Type Description
    ViewMode

    The view mode.

    Methods

    Dispose(Boolean)

    Dispose the specified disposing.

    Declaration
    protected override void Dispose(bool disposing)
    Parameters
    Type Name Description
    System.Boolean disposing

    If set to true disposing.

    LoadMore()

    Load More method.

    Declaration
    public void LoadMore()

    MoveNext()

    Moves the next.

    Declaration
    public void MoveNext()

    MovePrevious()

    Moves the previous.

    Declaration
    public void MovePrevious()

    OnClick(View)

    On the click.

    Declaration
    public void OnClick(View v)
    Parameters
    Type Name Description
    Android.Views.View v

    Clicked view.

    OnInterceptTouchEvent(MotionEvent)

    On the intercept touch event.

    Declaration
    public override bool OnInterceptTouchEvent(MotionEvent ev)
    Parameters
    Type Name Description
    Android.Views.MotionEvent ev

    Event values.

    Returns
    Type Description
    System.Boolean

    true, if intercept touch event was enabled, false otherwise.

    OnLayout(Boolean, Int32, Int32, Int32, Int32)

    On the layout.

    Declaration
    protected override void OnLayout(bool changed, int left, int top, int right, int bottom)
    Parameters
    Type Name Description
    System.Boolean changed

    If set to true changed.

    System.Int32 left

    Left value.

    System.Int32 top

    Top value.

    System.Int32 right

    Right value.

    System.Int32 bottom

    Bottom value.

    OnSizeChanged(Int32, Int32, Int32, Int32)

    On the size changed.

    Declaration
    protected override void OnSizeChanged(int w, int h, int oldw, int oldh)
    Parameters
    Type Name Description
    System.Int32 w

    The width.

    System.Int32 h

    The height.

    System.Int32 oldw

    Old width value.

    System.Int32 oldh

    Old height value.

    OnTouchEvent(MotionEvent)

    On the touch event.

    Declaration
    public override bool OnTouchEvent(MotionEvent e)
    Parameters
    Type Name Description
    Android.Views.MotionEvent e

    motion events.

    Returns
    Type Description
    System.Boolean

    true, if touch event was enabled, false otherwise.

    RefreshCarousel()

    Refresh the carousel.

    Declaration
    public void RefreshCarousel()

    Events

    CollectionChanged

    Occurs when collection changed.

    Declaration
    public event EventHandler<ItemsCollectionChangedEventArgs> CollectionChanged
    Event Type
    Type
    System.EventHandler<ItemsCollectionChangedEventArgs>

    SelectionChanged

    Occurs when selection changed.

    Declaration
    public event EventHandler<SelectionChangedEventArgs> SelectionChanged
    Event Type
    Type
    System.EventHandler<SelectionChangedEventArgs>

    SwipeEnded

    Occurs when Swipe Ended.

    Declaration
    public event EventHandler<EventArgs> SwipeEnded
    Event Type
    Type
    System.EventHandler<System.EventArgs>

    SwipeStarted

    Occurs when Swipe Started.

    Declaration
    public event EventHandler<SwipeStartedEventArgs> SwipeStarted
    Event Type
    Type
    System.EventHandler<SwipeStartedEventArgs>

    Implements

    Android.Views.View.IOnClickListener
    Android.Runtime.IJavaObject
    System.IDisposable
    Java.Interop.IJavaPeerable
    Back to top Generated by DocFX
    Copyright © 2001 - 2025 Syncfusion Inc. All Rights Reserved