ArduinoDumbDisplay v0.9.9-r41
DumbDisplay Arduino Library -- https://github.com/trevorwslee/Arduino-DumbDisplay
 
Loading...
Searching...
No Matches
SelectionListLayerHelper Class Reference

helper for using of SelectionListLayerWrapper; suggested to use SelectionListLayerWrapper whenever it makes sense More...

#include <_dd_misc.h>

Public Member Functions

 SelectionListLayerHelper (SelectionListDDLayer *selectionListLayer)
 
SelectionListDDLayergetLayer ()
 
int getOffset ()
 
int getSelectionCount ()
 
void setListStateChangedCallback (void(*listStateChangedCallback)(), int viewSelectionCount=-1)
 set the "list state changed" callback; here "state" refers to "list add/remove text or change of offset"
 
int add (int selectionIdx=-1)
 
int remove (int selectionIdx=-1)
 
void setOffset (int offset)
 
void decrementOffset ()
 
void incrementOffset ()
 
void scrollToView (int selectionIdx)
 

Protected Member Functions

void onListStateChanged ()
 

Detailed Description

helper for using of SelectionListLayerWrapper; suggested to use SelectionListLayerWrapper whenever it makes sense

Member Function Documentation

◆ add()

int SelectionListLayerHelper::add ( int  selectionIdx = -1)
inline
Parameters
selectionIdx-1 means append as the last selection
Returns
-1 if selectionIdx is out of range

◆ remove()

int SelectionListLayerHelper::remove ( int  selectionIdx = -1)
inline
Parameters
selectionIdx-1 means the last selection
Returns
-1 if selectionIdx is out of range