46 #ifndef LEGATO_SCROLLBAR_H 47 #define LEGATO_SCROLLBAR_H 51 #if LE_SCROLLBAR_WIDGET_ENABLED == 1 83 typedef enum leScrollBarState
85 LE_SCROLLBAR_STATE_NONE,
86 LE_SCROLLBAR_STATE_TOP_PRESSED,
87 LE_SCROLLBAR_STATE_TOP_INSIDE,
88 LE_SCROLLBAR_STATE_BOTTOM_PRESSED,
89 LE_SCROLLBAR_STATE_BOTTOM_INSIDE,
90 LE_SCROLLBAR_STATE_HANDLE_DOWN
93 typedef struct leScrollBarWidget leScrollBarWidget;
102 typedef void (* leScrollBarWidget_ValueChangedEvent)(leScrollBarWidget*);
104 typedef struct leScrollBarWidget leScrollBarWidget;
110 #define LE_SCROLLBARWIDGET_VTABLE(THIS_TYPE) \ 111 LE_WIDGET_VTABLE(THIS_TYPE) \ 113 leOrientation (*getOrientation)(const THIS_TYPE* _this); \ 114 leResult (*setOrientation)(THIS_TYPE* _this, leOrientation align, leBool swapDimensions); \ 115 uint32_t (*getMaximumValue)(const THIS_TYPE* _this); \ 116 leResult (*setMaximumValue)(THIS_TYPE* _this, uint32_t val); \ 117 uint32_t (*getExtentValue)(const THIS_TYPE* _this); \ 118 leResult (*setExtentValue)(THIS_TYPE* _this, uint32_t val); \ 119 uint32_t (*getScrollPercentage)(const THIS_TYPE* _this); \ 120 leResult (*setScrollPercentage)(THIS_TYPE* _this, uint32_t val); \ 121 uint32_t (*getScrollValue)(const THIS_TYPE* _this); \ 122 leResult (*setScrollValue)(THIS_TYPE* _this, uint32_t val); \ 123 uint32_t (*getStepSize)(const THIS_TYPE* _this); \ 124 leResult (*setStepSize)(THIS_TYPE* _this, uint32_t val); \ 125 leResult (*stepBackward)(THIS_TYPE* _this); \ 126 leResult (*stepForward)(THIS_TYPE* _this); \ 127 leScrollBarWidget_ValueChangedEvent (*getValueChangedEventCallback)(const THIS_TYPE* _this); \ 128 leResult (*setValueChangedEventCallback)(THIS_TYPE* _this, leScrollBarWidget_ValueChangedEvent cb); \ 130 typedef struct leScrollBarWidgetVTable
132 LE_SCROLLBARWIDGET_VTABLE(leScrollBarWidget)
133 } leScrollBarWidgetVTable;
148 typedef struct leScrollBarWidget
152 const leScrollBarWidgetVTable* fn;
154 leScrollBarState state;
162 leScrollBarWidget_ValueChangedEvent valueChangedEvent;
204 leScrollBarWidget* leScrollBarWidget_New(
void);
216 void leScrollBarWidget_Constructor(leScrollBarWidget* wgt);
219 #define THIS_TYPE struct leWidget 251 leOrientation getOrientation(
const leScrollBarWidget* _this);
292 virtual leResult setOrientation(leScrollBarWidget* _this,
325 virtual uint32_t getMaximumValue(
const leScrollBarWidget* _this);
361 virtual leResult setMaximumValue(leScrollBarWidget* _this,
393 virtual uint32_t getExtentValue(
const leScrollBarWidget* _this);
429 virtual leResult setExtentValue(leScrollBarWidget* _this,
462 virtual uint32_t getScrollPercentage(
const leScrollBarWidget* _this);
499 virtual leResult setScrollPercentage(leScrollBarWidget* _this,
531 virtual uint32_t getScrollValue(
const leScrollBarWidget* _this);
567 virtual leResult setScrollValue(leScrollBarWidget* _this,
599 virtual uint32_t getStepSize(
const leScrollBarWidget* _this);
636 virtual leResult setStepSize(leScrollBarWidget* _this,
668 virtual leResult stepBackward(leScrollBarWidget* _this);
699 virtual leResult stepForward(leScrollBarWidget* _this);
711 virtual leScrollBarWidget_ValueChangedEvent getValueChangedEventCallback
712 (
const leScrollBarWidget* _this);
727 virtual leResult setValueChangedEventCallback(leScrollBarWidget* _this,
728 leScrollBarWidget_ValueChangedEvent cb);
737 #endif // LE_SCROLLBAR_WIDGET_ENABLED Common macros and definitions used by Legato.
leResult
This enum represents function call results.
Definition: legato_common.h:123
leOrientation
This enum represents the orientation modes for objects.
Definition: legato_common.h:329
This structure represents a integer Cartesian point.
Definition: legato_common.h:346
leBool
This enum represents booleans.
Definition: legato_common.h:146
Fixed string functions and definitions.