[FL-1286] Add vertical screen orientation (#472)

This commit is contained in:
Albert Kharisov
2021-05-19 12:43:15 +03:00
committed by GitHub
parent f5f9a04fda
commit 4fa49882e0
16 changed files with 248 additions and 4 deletions

View File

@@ -9,6 +9,11 @@ extern "C" {
typedef struct ViewPort ViewPort;
typedef enum {
ViewPortOrientationHorizontal,
ViewPortOrientationVertical,
} ViewPortOrientation;
/*
* ViewPort Draw callback
* @warning called from GUI thread
@@ -75,6 +80,13 @@ void view_port_input_callback_set(
*/
void view_port_update(ViewPort* view_port);
/*
* Set ViewPort orientation.
* @param orientation, display orientation, horizontal or vertical.
*/
void view_port_set_orientation(ViewPort* view_port, ViewPortOrientation orientation);
ViewPortOrientation view_port_get_orientation(const ViewPort* view_port);
#ifdef __cplusplus
}
#endif