mirror of
https://github.com/ByteWelder/Tactility.git
synced 2026-02-18 19:03:16 +00:00
Software Rotation for ST7789 i8080 Driver (#422)
This commit is contained in:
parent
c6cc4034df
commit
8de88dd3fd
@ -311,7 +311,7 @@ bool St7789i8080Display::startLvgl() {
|
|||||||
.flags = {
|
.flags = {
|
||||||
.buff_dma = true,
|
.buff_dma = true,
|
||||||
.buff_spiram = false,
|
.buff_spiram = false,
|
||||||
.sw_rotate = false,
|
.sw_rotate = true,
|
||||||
.swap_bytes = true,
|
.swap_bytes = true,
|
||||||
.full_refresh = false,
|
.full_refresh = false,
|
||||||
.direct_mode = false
|
.direct_mode = false
|
||||||
|
|||||||
@ -148,8 +148,8 @@ public:
|
|||||||
lv_obj_set_style_border_color(orientation_dropdown, lv_color_hex(0xFAFAFA), LV_PART_MAIN);
|
lv_obj_set_style_border_color(orientation_dropdown, lv_color_hex(0xFAFAFA), LV_PART_MAIN);
|
||||||
lv_obj_set_style_border_width(orientation_dropdown, 1, LV_PART_MAIN);
|
lv_obj_set_style_border_width(orientation_dropdown, 1, LV_PART_MAIN);
|
||||||
lv_obj_add_event_cb(orientation_dropdown, onOrientationSet, LV_EVENT_VALUE_CHANGED, this);
|
lv_obj_add_event_cb(orientation_dropdown, onOrientationSet, LV_EVENT_VALUE_CHANGED, this);
|
||||||
auto orientation = settings::display::toLvglDisplayRotation(displaySettings.orientation);
|
// Set the dropdown to match current orientation enum
|
||||||
lv_dropdown_set_selected(orientation_dropdown, orientation);
|
lv_dropdown_set_selected(orientation_dropdown, static_cast<uint16_t>(displaySettings.orientation));
|
||||||
}
|
}
|
||||||
|
|
||||||
void onHide(TT_UNUSED AppContext& app) override {
|
void onHide(TT_UNUSED AppContext& app) override {
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user