mirror of
https://github.com/eried/portapack-mayhem.git
synced 2025-06-08 15:12:39 -04:00
Move UI dirty tracking out of application main.cpp.
This commit is contained in:
parent
fa465c14c4
commit
a9bb7c96e5
3 changed files with 20 additions and 10 deletions
|
@ -96,12 +96,6 @@ static spi_bus_t ssp0 = {
|
|||
};
|
||||
#endif
|
||||
|
||||
static bool ui_dirty = true;
|
||||
|
||||
void ui::dirty_event() {
|
||||
ui_dirty = true;
|
||||
}
|
||||
|
||||
class EventDispatcher {
|
||||
public:
|
||||
EventDispatcher(
|
||||
|
@ -316,9 +310,9 @@ private:
|
|||
}
|
||||
|
||||
void handle_lcd_frame_sync() {
|
||||
if( ui_dirty ) {
|
||||
if( ui::is_dirty() ) {
|
||||
paint_widget(top_widget);
|
||||
ui_dirty = false;
|
||||
ui::dirty_clear();
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue