mirror of
https://github.com/DarkFlippers/unleashed-firmware
synced 2024-12-22 10:43:11 +00:00
53435579b3
* fbt, faploader: minimal app module implementation * faploader, libs: moved API hashtable core to flipper_application * example: compound api * lib: flipper_application: naming fixes, doxygen comments * fbt: changed `requires` manifest field behavior for app extensions * examples: refactored plugin apps; faploader: changed new API naming; fbt: changed PLUGIN app type meaning * loader: dropped support for debug apps & plugin menus * moved applications/plugins -> applications/external * Restored x bit on chiplist_convert.py * git: fixed free-dap submodule path * pvs: updated submodule paths * examples: example_advanced_plugins.c: removed potential memory leak on errors * examples: example_plugins: refined requires * fbt: not deploying app modules for debug/sample apps; extra validation for .PLUGIN-type apps * apps: removed cdefines for external apps * fbt: moved ext app path definition * fbt: reworked fap_dist handling; f18: synced api_symbols.csv * fbt: removed resources_paths for extapps * scripts: reworked storage * scripts: reworked runfap.py & selfupdate.py to use new api * wip: fal runner * fbt: moved file packaging into separate module * scripts: storage: fixes * scripts: storage: minor fixes for new api * fbt: changed internal artifact storage details for external apps * scripts: storage: additional fixes and better error reporting; examples: using APP_DATA_PATH() * fbt, scripts: reworked launch_app to deploy plugins; moved old runfap.py to distfap.py * fbt: extra check for plugins descriptors * fbt: additional checks in emitter * fbt: better info message on SDK rebuild * scripts: removed requirements.txt * loader: removed remnants of plugins & debug menus * post-review fixes
65 lines
No EOL
1.8 KiB
C
65 lines
No EOL
1.8 KiB
C
#pragma once
|
|
|
|
#include <furi.h>
|
|
#include <furi_hal_bt.h>
|
|
#include <furi_hal_bt_hid.h>
|
|
#include <furi_hal_usb.h>
|
|
#include <furi_hal_usb_hid.h>
|
|
|
|
#include <bt/bt_service/bt.h>
|
|
#include <gui/gui.h>
|
|
#include <gui/view.h>
|
|
#include <gui/view_dispatcher.h>
|
|
#include <notification/notification.h>
|
|
#include <storage/storage.h>
|
|
|
|
#include <gui/modules/submenu.h>
|
|
#include <gui/modules/dialog_ex.h>
|
|
#include <gui/modules/popup.h>
|
|
#include "views/hid_keynote.h"
|
|
#include "views/hid_keyboard.h"
|
|
#include "views/hid_media.h"
|
|
#include "views/hid_mouse.h"
|
|
#include "views/hid_mouse_jiggler.h"
|
|
#include "views/hid_tiktok.h"
|
|
|
|
#define HID_BT_KEYS_STORAGE_NAME ".bt_hid.keys"
|
|
|
|
typedef enum {
|
|
HidTransportUsb,
|
|
HidTransportBle,
|
|
} HidTransport;
|
|
|
|
typedef struct Hid Hid;
|
|
|
|
struct Hid {
|
|
Bt* bt;
|
|
Gui* gui;
|
|
NotificationApp* notifications;
|
|
ViewDispatcher* view_dispatcher;
|
|
Submenu* device_type_submenu;
|
|
DialogEx* dialog;
|
|
HidKeynote* hid_keynote;
|
|
HidKeyboard* hid_keyboard;
|
|
HidMedia* hid_media;
|
|
HidMouse* hid_mouse;
|
|
HidMouseJiggler* hid_mouse_jiggler;
|
|
HidTikTok* hid_tiktok;
|
|
|
|
HidTransport transport;
|
|
uint32_t view_id;
|
|
};
|
|
|
|
void hid_hal_keyboard_press(Hid* instance, uint16_t event);
|
|
void hid_hal_keyboard_release(Hid* instance, uint16_t event);
|
|
void hid_hal_keyboard_release_all(Hid* instance);
|
|
|
|
void hid_hal_consumer_key_press(Hid* instance, uint16_t event);
|
|
void hid_hal_consumer_key_release(Hid* instance, uint16_t event);
|
|
void hid_hal_consumer_key_release_all(Hid* instance);
|
|
|
|
void hid_hal_mouse_move(Hid* instance, int8_t dx, int8_t dy);
|
|
void hid_hal_mouse_scroll(Hid* instance, int8_t delta);
|
|
void hid_hal_mouse_press(Hid* instance, uint16_t event);
|
|
void hid_hal_mouse_release(Hid* instance, uint16_t event);
|
|
void hid_hal_mouse_release_all(Hid* instance); |