|
| 1 | +#pragma once |
| 2 | + |
| 3 | +#include <furi.h> |
| 4 | +#include <furi_hal.h> |
| 5 | +#include <gui/gui.h> |
| 6 | +#include <input/input.h> |
| 7 | +#include <stdlib.h> |
| 8 | +#include <assets_icons.h> |
| 9 | +#include <dialogs/dialogs.h> |
| 10 | +#include <notification/notification_messages.h> |
| 11 | +#include <gui/view_dispatcher.h> |
| 12 | +#include <gui/modules/submenu.h> |
| 13 | +#include <gui/scene_manager.h> |
| 14 | +#include <gui/modules/variable_item_list.h> |
| 15 | +#include <gui/modules/button_menu.h> |
| 16 | +#include <gui/modules/dialog_ex.h> |
| 17 | +#include "scenes/meal_pager_scene.h" |
| 18 | +#include "views/meal_pager_startscreen.h" |
| 19 | +#include "views/meal_pager_transmit.h" |
| 20 | +#include "helpers/meal_pager_storage.h" |
| 21 | + |
| 22 | +#define TAG "Meal_Pager" |
| 23 | + |
| 24 | +#define SUBGHZ_APP_EXTENSION ".sub" |
| 25 | +#define SUBGHZ_APP_FOLDER ANY_PATH("subghz") |
| 26 | + |
| 27 | +typedef struct Meal_PagerTransmit Meal_PagerTransmit; |
| 28 | + |
| 29 | +typedef struct { |
| 30 | + Gui* gui; |
| 31 | + NotificationApp* notification; |
| 32 | + ViewDispatcher* view_dispatcher; |
| 33 | + Submenu* submenu; |
| 34 | + SceneManager* scene_manager; |
| 35 | + VariableItemList* variable_item_list; |
| 36 | + Meal_PagerStartscreen* meal_pager_startscreen; |
| 37 | + Meal_PagerTransmit* meal_pager_transmit; |
| 38 | + DialogsApp* dialogs; // File Browser |
| 39 | + FuriString* file_path; // File Browser |
| 40 | + uint32_t haptic; |
| 41 | + uint32_t speaker; |
| 42 | + uint32_t led; |
| 43 | + uint32_t save_settings; |
| 44 | + uint32_t pager_type; |
| 45 | + uint32_t first_station; |
| 46 | + char* first_station_char; |
| 47 | + uint32_t last_station; |
| 48 | + char* last_station_char; |
| 49 | + uint32_t first_pager; |
| 50 | + char* first_pager_char; |
| 51 | + uint32_t last_pager; |
| 52 | + char* last_pager_char; |
| 53 | + uint32_t current_station; |
| 54 | + uint32_t current_pager; |
| 55 | +} Meal_Pager; |
| 56 | + |
| 57 | +typedef enum { |
| 58 | + Meal_PagerViewIdStartscreen, |
| 59 | + Meal_PagerViewIdMenu, |
| 60 | + Meal_PagerViewIdTransmit, |
| 61 | + Meal_PagerViewIdSettings, |
| 62 | +} Meal_PagerViewId; |
| 63 | + |
| 64 | +typedef enum { |
| 65 | + Meal_PagerPagerTypeT119, |
| 66 | + Meal_PagerPagerTypeTD157, |
| 67 | + Meal_PagerPagerTypeTD165, |
| 68 | + Meal_PagerPagerTypeTD174, |
| 69 | +} Meal_PagerPagerType; |
| 70 | + |
| 71 | + |
| 72 | + |
| 73 | +typedef enum { |
| 74 | + Meal_PagerHapticOff, |
| 75 | + Meal_PagerHapticOn, |
| 76 | +} Meal_PagerHapticState; |
| 77 | + |
| 78 | +typedef enum { |
| 79 | + Meal_PagerSpeakerOff, |
| 80 | + Meal_PagerSpeakerOn, |
| 81 | +} Meal_PagerSpeakerState; |
| 82 | + |
| 83 | +typedef enum { |
| 84 | + Meal_PagerLedOff, |
| 85 | + Meal_PagerLedOn, |
| 86 | +} Meal_PagerLedState; |
| 87 | + |
| 88 | +typedef enum { |
| 89 | + Meal_PagerSettingsOff, |
| 90 | + Meal_PagerSettingsOn, |
| 91 | +} Meal_PagerSettingsStoreState; |
0 commit comments