flip_wifi_callback.h 1.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051
  1. #ifndef FLIP_WIFI_CALLBACK_H
  2. #define FLIP_WIFI_CALLBACK_H
  3. #include <flip_wifi.h>
  4. #include <flip_storage/flip_wifi_storage.h>
  5. #include <flip_wifi_icons.h>
  6. // array to store each SSID
  7. extern char *ssid_list[64];
  8. extern uint32_t ssid_index;
  9. void flip_wifi_redraw_submenu_saved(FlipWiFiApp *app);
  10. uint32_t callback_to_submenu_main(void *context);
  11. uint32_t callback_to_submenu_scan(void *context);
  12. uint32_t callback_to_submenu_saved(void *context);
  13. void popup_callback_saved(void *context);
  14. void popup_callback_main(void *context);
  15. // Callback for drawing the main screen
  16. void flip_wifi_view_draw_callback_scan(Canvas *canvas, void *model);
  17. void flip_wifi_view_draw_callback_saved(Canvas *canvas, void *model);
  18. // Input callback for the view (async input handling)
  19. bool flip_wifi_view_input_callback_scan(InputEvent *event, void *context);
  20. // Input callback for the view (async input handling)
  21. bool flip_wifi_view_input_callback_saved(InputEvent *event, void *context);
  22. // Function to trim leading and trailing whitespace
  23. // Returns the trimmed start pointer and updates the length
  24. char *trim_whitespace(char *start, size_t *length);
  25. bool flip_wifi_handle_scan(FlipWiFiApp *app);
  26. void callback_submenu_choices(void *context, uint32_t index);
  27. void flip_wifi_text_updated_password_scan(void *context);
  28. void flip_wifi_text_updated_password_saved(void *context);
  29. void flip_wifi_text_updated_add_ssid(void *context);
  30. void flip_wifi_text_updated_add_password(void *context);
  31. #endif // FLIP_WIFI_CALLBACK_H