Embedded SDK
Embedded SDK
Loading...
Searching...
No Matches
nbgl_screen.h
Go to the documentation of this file.
1
7#ifndef NBGL_SCREEN_H
8#define NBGL_SCREEN_H
9
10#ifdef __cplusplus
11extern "C" {
12#endif
13
14/*********************
15 * INCLUDES
16 *********************/
17
18#include "nbgl_types.h"
19#include "nbgl_obj.h"
20
21/*********************
22 * DEFINES
23 *********************/
24
25/**********************
26 * TYPEDEFS
27 **********************/
28
32typedef void (*nbgl_tickerCallback_t)(void);
33
46
53typedef struct PACKED__ nbgl_screen_s {
56#ifdef HAVE_SE_TOUCH
59#else // HAVE_SE_TOUCH
60 nbgl_buttonCallback_t buttonCallback;
61#endif // HAVE_SE_TOUCH
62 struct nbgl_screen_s
66 uint8_t index;
69
70/**********************
71 * GLOBAL PROTOTYPES
72 **********************/
75
76#ifdef HAVE_STAX_DISPLAY_FAST_MODE
78#endif // HAVE_STAX_DISPLAY_FAST_MODE
79
80#ifdef HAVE_STAX_CONFIG_DISPLAY_FAST_MODE
82#endif // HAVE_STAX_CONFIG_DISPLAY_FAST_MODE
83
91
92#ifdef HAVE_SE_TOUCH
97#else // HAVE_SE_TOUCH
102#endif // HAVE_SE_TOUCH
108#ifdef HAVE_SE_TOUCH
113#else // HAVE_SE_TOUCH
118#endif // HAVE_SE_TOUCH
122
123/**********************
124 * MACROS
125 **********************/
126
127#ifdef __cplusplus
128} /* extern "C" */
129#endif
130
131#endif /* NBGL_SCREEN_H */
API to draw all basic graphic objects.
void(* nbgl_touchCallback_t)(void *obj, nbgl_touchType_t eventType)
prototype of function to be called when a touch event is received by an object
Definition nbgl_obj.h:346
void(* nbgl_buttonCallback_t)(void *obj, nbgl_buttonEvent_t buttonEvent)
prototype of function to be called when a button event is received by an object (TODO: change to scre...
Definition nbgl_obj.h:325
struct PACKED__ nbgl_container_s nbgl_container_t
struct to represent a container (CONTAINER type)
struct PACKED__ nbgl_obj_s nbgl_obj_t
Common structure for all graphical objects.
int nbgl_screenSet(nbgl_obj_t ***elements, uint8_t nbElements, const nbgl_screenTickerConfiguration_t *ticker, nbgl_touchCallback_t touchCallback)
int nbgl_screenPush(nbgl_obj_t ***elements, uint8_t nbElements, const nbgl_screenTickerConfiguration_t *ticker, nbgl_touchCallback_t touchCallback)
void nbgl_wait_pipeline(void)
int nbgl_screenUpdateNbElements(uint8_t screenIndex, uint8_t nbElements)
int nbgl_screenUpdateTicker(uint8_t screenIndex, const nbgl_screenTickerConfiguration_t *ticker)
bool nbgl_screenContainsObj(nbgl_obj_t *obj)
struct PACKED__ nbgl_screen_s nbgl_screen_t
struct to represent a screen (SCREEN type)
nbgl_obj_t * nbgl_screenGetAt(uint8_t screenIndex)
int nbgl_screenReset(void)
nbgl_obj_t ** nbgl_screenGetElements(uint8_t screenIndex)
void(* nbgl_tickerCallback_t)(void)
prototype of function to be called when a timer on screen is fired
Definition nbgl_screen.h:32
uint8_t nbgl_screenGetUxStackSize(void)
nbgl_obj_t * nbgl_screenGetTop(void)
int nbgl_screenPop(uint8_t screenIndex)
uint8_t nbgl_screenGetCurrentStackSize(void)
struct PACKED__ nbgl_screenTickerConfiguration_s nbgl_screenTickerConfiguration_t
struct to configure a screen layer
int nbgl_screenUpdateBackgroundColor(uint8_t screenIndex, color_t color)
int nbgl_screenRelease(void)
nbgl_obj_t * nbgl_screenContainsObjType(nbgl_screen_t *screen, nbgl_obj_type_t type)
void nbgl_screenRedraw(void)
void nbgl_screenHandler(uint32_t intervaleMs)
void nbgl_screen_reinit(void)
common types for Graphical Library
color_t
Definition nbgl_types.h:140
nbgl_obj_type_t
All types of graphical objects.
Definition nbgl_types.h:154
#define PACKED__
Definition nbgl_types.h:127
struct to configure a screen layer
Definition nbgl_screen.h:38
nbgl_tickerCallback_t tickerCallback
callback called when ticker timer is fired. Set to NULL for no ticker
Definition nbgl_screen.h:40
struct to represent a screen (SCREEN type)
Definition nbgl_screen.h:53
uint8_t index
index in screenStack array
Definition nbgl_screen.h:66
nbgl_screenTickerConfiguration_t ticker
ticker configuration
Definition nbgl_screen.h:55
bool isUxScreen
set to TRUE if allocated by Bolos-UX
Definition nbgl_screen.h:67
nbgl_container_t container
common part
Definition nbgl_screen.h:54
struct nbgl_screen_s * previous
Definition nbgl_screen.h:64
struct nbgl_screen_s * next
pointer to screen on top of this one (or NULL is this screen is top of stack)
Definition nbgl_screen.h:62
nbgl_touchCallback_t touchCallback
function to be called on events defined in touchMask of each objects
Definition nbgl_screen.h:58