From 02aab9b4e28cf11c30ea8775d3b4030a337c3f0a Mon Sep 17 00:00:00 2001 From: Jared Boone Date: Fri, 14 Aug 2015 15:52:11 -0700 Subject: [PATCH] Application main() refactoring to group relevant bits. --- firmware/application/main.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/firmware/application/main.cpp b/firmware/application/main.cpp index 13189be4..d707f95d 100755 --- a/firmware/application/main.cpp +++ b/firmware/application/main.cpp @@ -456,7 +456,6 @@ int main(void) { init_message_queues(); portapack::io.init(); - ui::Context context; portapack::display.init(); sdcStart(&SDCD1, nullptr); @@ -470,9 +469,10 @@ int main(void) { events_initialize(chThdSelf()); + ui::Context context; ui::SystemView system_view { context, - { 0, 0, 240, 320 } + portapack::display.screen_rect() }; ui::Painter painter; EventDispatcher event_dispatcher { &system_view, painter, context };