flip_wifi.c 831 B

12345678910111213141516171819202122232425262728293031323334353637
  1. #include "flip_wifi.h"
  2. #include <callback/free.h>
  3. WiFiPlaylist *wifi_playlist = NULL;
  4. // Function to free the resources used by FlipWiFiApp
  5. void flip_wifi_app_free(FlipWiFiApp *app)
  6. {
  7. if (!app)
  8. {
  9. FURI_LOG_E(TAG, "FlipWiFiApp is NULL");
  10. return;
  11. }
  12. // Free Submenu(s)
  13. if (app->submenu_main)
  14. {
  15. view_dispatcher_remove_view(app->view_dispatcher, FlipWiFiViewSubmenuMain);
  16. submenu_free(app->submenu_main);
  17. }
  18. free_all(app);
  19. // free the view dispatcher
  20. if (app->view_dispatcher)
  21. view_dispatcher_free(app->view_dispatcher);
  22. // close the gui
  23. furi_record_close(RECORD_GUI);
  24. // free the app
  25. if (app)
  26. free(app);
  27. }
  28. char *ssid_list[64];
  29. uint32_t ssid_index = 0;
  30. char current_ssid[64];
  31. char current_password[64];
  32. bool back_from_ap = false;