Kanzi 4.1.0
kanzi::DefaultListBoxTrajectoryPresenter< TFinalClass, TLayout, TItemClass, TScrollView > Class Template Reference

#include <kanzi/ui/node/concept/list_box/list_box_trajectory_presenter.hpp>

Inheritance diagram for kanzi::DefaultListBoxTrajectoryPresenter< TFinalClass, TLayout, TItemClass, TScrollView >:
[legend]

Public Member Functions

 DefaultListBoxTrajectoryPresenter ()
 
- Public Member Functions inherited from kanzi::ListBoxTrajectoryPresenter< DefaultListBoxTrajectoryPresenter< TFinalClass, TLayout, TItemClass, TScrollView >, TFinalClass, TLayout, TItemClass, TScrollView >
void addToLayout (ItemSharedPtr listBoxItem)
 
void bringItemCenter (size_t selection, bool smooth)
 Brings given item to the selector position.
 
void enableKeyNavigation (bool enabled)
 Enables directional key navigation on the Trajectory Presenter.
 
size_t getItemCount () const
 Gets number of items in presenters list box.
 
LayoutSharedPtr getLayout () const
 
void initialize (TFinalClass *listBox, LayoutSharedPtr layout)
 Initializes the trajectory presenter for the list box.
 
bool isEffectivelyLooping () const
 Returns whether presentation is in looping mode.
 
 ListBoxTrajectoryPresenter ()
 
void notifyItemAdded (size_t index)
 Implements notifyItemAdded for a trajectory list box.
 
void notifyItemContainerChanged ()
 Invalidates layout if the item container is changed.
 
void notifyItemRemoved (size_t index)
 Implements notifyItemRemoved for a trajectory list box.
 
void notifyItemReplaced (size_t)
 Invalidates layout if the item is replaced.
 
void removeFromLayout (ItemSharedPtr listBoxItem)
 
void setScroll (Vector2 scroll)
 ListBoxScrollPresenterConceptImpl::setScroll implementation.
 
void snap (Vector2 position, Vector2 direction, bool changeTarget, Vector2 *out_position, int *out_itemIndex)
 Snaps from a given position towards a given direction.
 
void startNavigation (NavigationDirection direction)
 Defines the behavior on navigational key press.
 
void tryMoveFocusInDirection (ListBoxConcept::FocusMoveTarget target, bool fallback=false)
 Tries to move the focus to the next or previous item in a Trajectory List Box node.
 
void tryMoveFocusToEdge (ListBoxConcept::FocusMoveTarget target, bool fallback=false)
 Tries to move the focus to the first or last item in a Trajectory List Box node.
 
void tryMoveFocusToPage (ListBoxConcept::FocusMoveTarget target, bool fallback=false)
 
void update ()
 Updates presenter's state and visible items.
 
- Public Member Functions inherited from kanzi::ListBoxScrollPresenterConceptImpl< TDerivedClass, TListBoxClass, TScrollView >
ScrollViewSharedPtr getScrollView () const
 Returns the Scroll View that the presenter uses.
 
void initialize (TListBoxClass *listBox)
 ListBoxScrollPresenterConceptImpl specific initialization.
 
 ListBoxScrollPresenterConceptImpl ()=default
 Constructor.
 

Additional Inherited Members

- Public Types inherited from kanzi::ListBoxTrajectoryPresenter< DefaultListBoxTrajectoryPresenter< TFinalClass, TLayout, TItemClass, TScrollView >, TFinalClass, TLayout, TItemClass, TScrollView >
using BaseClass
 
using ItemSharedPtr
 
using LayoutSharedPtr
 
using ListBoxTrajectoryPresenterType
 
using ScrollViewSharedPtr
 
- Protected Member Functions inherited from kanzi::ListBoxTrajectoryPresenter< DefaultListBoxTrajectoryPresenter< TFinalClass, TLayout, TItemClass, TScrollView >, TFinalClass, TLayout, TItemClass, TScrollView >
bool calculateAliveItemsRange ()
 Sets indices and offsets of first and last alive items and the number of alive elements.
 
void extendAliveItemsRangeToItem (size_t index)
 Extends the alive items range of the presenter to include the item at a given index.
 
VirtualListBoxItem findMiddleIterator ()
 
ItemSharedPtr getItem (size_t presenterIndex) const
 Returns the item at the given index.
 
Vector3 getItemSize (size_t itemIndex)
 Returns the size of an item at a given index.
 
float getItemSpacing () const
 Returns list box item spacing.
 
bool isHorizontalScroll () const
 Returns whether the Trajectory List Box is scrolling horizontally.
 
void iterateToIndex (VirtualListBoxItem &iterator, size_t index)
 Iterates the virtual list box item to the given index.
 
void snapImprove (TrajectoryLayoutSnapInfo *snap, unsigned int objectIndex, float offset, float selectorOffset, bool snapLeft, bool snapRight)
 Updates the snap info structure to point to the given object index if this object is closer to the selector offset and the snap in the corresponding direction is enabled.
 
void updateAliveItemsRange ()
 Asks the List Box to update the items in the layout according to the currently set firstIndex and rangeSize, also taking into account the keep alive items.
 
- Protected Member Functions inherited from kanzi::ListBoxScrollPresenterConceptImpl< TDerivedClass, TListBoxClass, TScrollView >
TDerivedClassgetThisObject ()
 
const TDerivedClassgetThisObject () const
 
void onClickBegin (ClickManipulator::ClickBeginMessageArguments &messageArguments)
 Handles ClickManipulator::onClickBeginMessage.
 
void onItemSelected (ListBoxConcept::ItemSelectedMessageArguments &messageArguments)
 Handles ListBoxConcept::ItemSelectedMessage.
 
void onScrolled (ScrollViewConcept::ScrolledMessageArguments &messageArguments)
 Handles ScrollViewClass::ScrolledMessage.
 
void onScrollFinished (ScrollViewConcept::ScrollFinishedMessageArguments &messageArguments)
 Handles ScrollViewClass::ScrollFinishedMessage.
 
void onScrollStarted (ScrollViewConcept::ScrollStartedMessageArguments &messageArguments)
 Handles ScrollViewClass::ScrollStartedMessage.
 
void onSnapRequested (ScrollViewConcept::SnapRequestMessageArguments &messageArguments)
 Handles ScrollViewClass::SnapRequestMessage.
 
void onUserScrollFinished (ScrollViewConcept::UserScrollFinishedMessageArguments &messageArguments)
 Handles ScrollViewClass::UserScrollFinishedMessage.
 
void onUserScrollStarted (ScrollViewConcept::UserScrollStartedMessageArguments &messageArguments)
 Handles ScrollViewClass::UserScrollStartedMessage.
 
void scrollToTargetItem (size_t itemIndex, Vector2 scrollPosition, bool smooth) const
 Requests Scroll View to scroll to target item position.
 
void sendListBoxTargetChangedMessage (size_t targetItem) const
 Sends ListBoxScrollPresenterConcept::TargetChangedMessage message to List Box.
 
void sendScrollViewSetScrollMessage (const Vector2 &scrollPosition) const
 Sends ScrollViewConcept::SetScrollMessage message to Scroll View.
 
void sendScrollViewSetScrollTargetMessage (const Vector2 &scrollTarget) const
 Sends ScrollViewConcept::SetScrollTargetMessage message to Scroll View.
 
- Protected Attributes inherited from kanzi::ListBoxTrajectoryPresenter< DefaultListBoxTrajectoryPresenter< TFinalClass, TLayout, TItemClass, TScrollView >, TFinalClass, TLayout, TItemClass, TScrollView >
int m_fixedPointIndex
 Index of an item that is currently acting as a fixed point in the list.
 
float m_fixedPointOffset
 The offset of the fixed point.
 
size_t m_lastItemCount
 Item count from the previous update(), used to detect bulk item count decreases.
 
size_t m_rangeSize
 Number of items in the visible area.
 
float m_scrollOffset
 Offset of scrolling. In proportional space.
 
VirtualListBoxItem m_viewIntervalLeft
 Virtual leftmost item in the visible area.
 
VirtualListBoxItem m_viewIntervalRight
 Virtual rightmost item in the visible area.
 
- Protected Attributes inherited from kanzi::ListBoxScrollPresenterConceptImpl< TDerivedClass, TListBoxClass, TScrollView >
TListBoxClassm_listBox
 List Box that owns this presenter.
 

Constructor & Destructor Documentation

◆ DefaultListBoxTrajectoryPresenter()

template<typename TFinalClass , typename TLayout , typename TItemClass , typename TScrollView >
kanzi::DefaultListBoxTrajectoryPresenter< TFinalClass, TLayout, TItemClass, TScrollView >::DefaultListBoxTrajectoryPresenter ( )
inlineexplicit

The documentation for this class was generated from the following file: