fix issue #7 - invoke view_dispatcher_remove_view

This commit is contained in:
Derek Jamison
2023-04-18 22:06:36 -04:00
parent bfd76eac24
commit f7f6e2a17e
2 changed files with 14 additions and 5 deletions

View File

@@ -153,10 +153,14 @@ void hid_free(Hid* app) {
notification_internal_message(app->notifications, &sequence_reset_blue);
// Free views
view_dispatcher_remove_view(app->view_dispatcher, HidViewSubmenu);
submenu_free(app->submenu);
view_dispatcher_remove_view(app->view_dispatcher, BtHidViewClicker);
hid_cc_free(app->hid_cc);
view_dispatcher_remove_view(app->view_dispatcher, BtHidViewCredits);
widget_free(app->widget_credits);
view_dispatcher_remove_view(app->view_dispatcher, BtHidViewInstructions);
widget_free(app->widget_instructions);
view_dispatcher_remove_view(app->view_dispatcher, HidViewSubmenu);
submenu_free(app->submenu);
view_dispatcher_free(app->view_dispatcher);
// Close records