Manages the positioning, path-based animation and virtualization of the items displayed by a RadCarouselElement.
Definition
Namespace:Telerik.WinControls.UI
Assembly:Telerik.WinControls.UI.dll
Syntax:
public class CarouselItemsContainer : RadItem, INotifyPropertyChanged, ICustomTypeDescriptor, ISupportSystemSkin, IBindableComponent, IComponent, IDisposable, ISupportDrag, ISupportDrop, IShortcutProvider, IStylableElement, IStylableNode, IVirtualViewport
Inheritance: objectDisposableObjectRadObjectRadElementVisualElementRadComponentElementRadItemCarouselItemsContainer...
Implements:
Inherited Members
Constructors
Creates the item container owned by the specified carousel element.
public CarouselItemsContainer(RadCarouselElement owner)
The carousel element whose items and animation settings this container manages.
Fields
Identifies the dependency property that stores the per-item animation path data used while an item transitions between carousel positions.
public static readonly RadProperty CarouselAnimationData
Identifies the dependency property that stores an item's current normalized position along the carousel path.
public static readonly RadProperty CarouselLocationProperty
Properties
Set ot get the Carousel animation frames
[Browsable(false)]
public int AnimationDelay { get; set; }
Set ot get the Carousel animation frames
[Browsable(false)]
public int AnimationFrames { get; set; }
Gets or sets the set of animations to be applied on carousel items
[Browsable(false)]
public Animations AnimationsApplied { get; set; }
Gets or sets a value indicating whether carousel will increnment or decrement item indexes when in auto-loop mode.
public AutoLoopDirections AutoLoopDirection { get; set; }
Gets or sets a value indicating when carousel will pause looping if in auto-loop mode.
public AutoLoopPauseConditions AutoLoopPauseCondition { get; set; }
Gets or sets CarouselPath object that defines the curve which carousel items will animate through
[Browsable(false)]
public ICarouselPath CarouselPath { get; set; }
Gets or sets carousel items' animation easing.
[Browsable(false)]
public RadEasingType EasingType { get; set; }
Enable or disable the re-animation of RadCarousel on form maximize, minimeze or resize
public virtual bool EnableAnimationOnFormResize { get; set; }
Gets or sets a value indicating that the Carousel will loop items automatically
public bool EnableAutoLoop { get; set; }
Gets or sets whether navigating past the last item wraps around to the first item (and vice versa).
public bool EnableLooping { get; set; }
Gets or sets whether the carousel path is interpreted relative to the container's current size rather than in absolute coordinates.
public bool EnableRelativePath { get; set; }
Gets whether an item repositioning animation is currently in progress.
public bool IsAnimationRunning { get; }
Gets or sets the minimum opacity applied to items furthest from the selected position, in the 0.0-1.0 range.
public double MinFadeOpacity { get; set; }
Sets the way opacity is applied to carousel items
public OpacityChangeConditions OpacityChangeCondition { get; set; }
Gets the owner RadCarouselElement.
public RadCarouselElement Owner { get; }
The owner.
Gets or sets the index of the item centered/selected on the carousel path; assigning it triggers the selection-change animation.
[Browsable(false)]
public int SelectedIndex { get; set; }
Gets whether the container is operating in virtualized mode, where only visible items are realized as elements.
public bool Virtualized { get; set; }
Implements:
Gets or sets how many items are simultaneously visible along the carousel path.
public int VisibleItemCount { get; set; }
Methods
Begins a batch of item updates and defers synchronization until the matching EndUpdate() call.
public void BeginUpdate()
Implements:
Immediately stops any running item transition animation, leaving items at their current position.
public void CancelAniamtion()
Unsubscribes from item-collection changes before disposing base resources.
protected override void DisposeManagedResources()
Overrides:
Ends an item-update batch and synchronizes the carousel when the outermost batch is complete.
public void EndUpdate()
Implements:
Returns the child index for an item, creating and initializing a CarouselContentItem when needed.
Immediately recalculates and applies item layout, bypassing animation.
public virtual void ForceUpdate()
Finds the child index of the element supplied for an item without realizing a wrapper for it.
Initializes the default carousel path, virtualization state, item collection, and location behavior.
protected override void InitializeFields()
Overrides:
Switches the range mapper when looping changes and raises state notifications; the auto-loop notification is also forwarded to the owner.
Resets item positions when resize animation is enabled and forces the carousel layout to update.
protected override void OnBoundsChanged(RadPropertyChangedEventArgs e)
The bounds property-change details.
Overrides:
Replaces the hosted element when the changed item is realized, then synchronizes the carousel.
public void OnItemDataSet(int index, object oldItemData, object newItemData)
The index of the changed item.
oldItemDataobjectThe previous item data.
newItemDataobjectThe replacement item data, which must be a RadElement.
Implements:
Resets the container when the backing item collection is cleared.
public void OnItemsDataClear()
Implements:
Synchronizes the visible item arrangement after the backing collection has been sorted.
public void OnItemsDataSortComplete()
Implements:
Synchronizes the realized children with the item collection after the container is loaded.
protected override void OnLoaded()
Overrides:
Synchronizes carousel items after path, virtualization, visible-count, or looping changes and notifies the owner of auto-loop changes.
protected override void OnNotifyPropertyChanged(PropertyChangedEventArgs e)
The property-change details.
Overrides:
This method currently does not assign the supplied collection; the container continues using its existing item collection.
public void SetVirtualItemsCollection(IVirtualizationCollection virtualItemsCollection)
The collection argument, which is not used by the current implementation.
Implements:
Plays the entrance animation used the first time the carousel lays out its items.
public void StartInitialAnimation()
Recomputes item positions along the carousel path and starts the transition animation if needed. Returns true if an update was performed.