File worker helper. Slightly optimized iButton app code size. (#545)

* File worker: file operations helper
* Notification app: removed yield
* File worker: write operations, calls to system file widgets
* App ibutton: use file worker
* App ibutton: small save fix, forgotten byte
This commit is contained in:
SG
2021-06-29 23:08:45 +10:00
committed by GitHub
parent 22e1ecb642
commit dce3665f63
5 changed files with 357 additions and 137 deletions

View File

@@ -22,7 +22,6 @@ void notification_message_block(NotificationApp* app, const NotificationSequence
.sequence = sequence,
.back_event = osEventFlagsNew(NULL)};
furi_check(osMessageQueuePut(app->queue, &m, 0, osWaitForever) == osOK);
osThreadYield();
osEventFlagsWait(m.back_event, NOTIFICATION_EVENT_COMPLETE, osFlagsWaitAny, osWaitForever);
osEventFlagsDelete(m.back_event);
};
@@ -33,7 +32,6 @@ void notification_internal_message_block(
NotificationAppMessage m = {
.type = InternalLayerMessage, .sequence = sequence, .back_event = osEventFlagsNew(NULL)};
furi_check(osMessageQueuePut(app->queue, &m, 0, osWaitForever) == osOK);
osThreadYield();
osEventFlagsWait(m.back_event, NOTIFICATION_EVENT_COMPLETE, osFlagsWaitAny, osWaitForever);
osEventFlagsDelete(m.back_event);
};