[FL-1720] BLE GUI refactoring (#678)
* dialog_ex: add clean method, fix documentation * application: add bt debug and settings application * bt: add debug application * bt: add settings application * bt: rework bt service * bt debug: fix carrier debug app * assets: add debug animation to main menu * bt debug: fix bt packet test * bt service: rework bt service * bt: cleanup * Assets: fix spelling * Ble: wait for core 2 startup complete before initializing radio stack. * Accessor: remove dead code, switch port PA6 to PA4, because interrupt line 6 is used by down button. * FuriHal: assert interrupt line on add_int_callback. * Bt: update icon on core2 startup complete. Co-authored-by: あく <alleteam@gmail.com>
This commit is contained in:
19
applications/gui/modules/dialog_ex.c
Normal file → Executable file
19
applications/gui/modules/dialog_ex.c
Normal file → Executable file
@@ -243,3 +243,22 @@ void dialog_ex_set_right_button_text(DialogEx* dialog_ex, const char* text) {
|
||||
return true;
|
||||
});
|
||||
}
|
||||
|
||||
void dialog_ex_clean(DialogEx* dialog_ex) {
|
||||
furi_assert(dialog_ex);
|
||||
TextElement clean_text_el = {
|
||||
.text = NULL, .x = 0, .y = 0, .horizontal = AlignLeft, .vertical = AlignLeft};
|
||||
IconElement clean_icon_el = {.icon = NULL, .x = 0, .y = 0};
|
||||
with_view_model(
|
||||
dialog_ex->view, (DialogExModel * model) {
|
||||
model->header = clean_text_el;
|
||||
model->text = clean_text_el;
|
||||
model->icon = clean_icon_el;
|
||||
model->left_text = NULL;
|
||||
model->center_text = NULL;
|
||||
model->right_text = NULL;
|
||||
return true;
|
||||
});
|
||||
dialog_ex->context = NULL;
|
||||
dialog_ex->callback = NULL;
|
||||
}
|
||||
|
Reference in New Issue
Block a user