mirror of
https://github.com/DarkFlippers/unleashed-firmware.git
synced 2024-12-23 13:21:44 +03:00
[FL-3830] Emulation freeze (#3930)
Co-authored-by: あく <alleteam@gmail.com>
This commit is contained in:
parent
c3dc0ae6b9
commit
8c14361e6a
@ -559,6 +559,7 @@ static void nfc_protocol_support_scene_save_name_on_exit(NfcApp* instance) {
|
|||||||
*/
|
*/
|
||||||
enum {
|
enum {
|
||||||
NfcSceneEmulateStateWidget, /**< Widget view is displayed. */
|
NfcSceneEmulateStateWidget, /**< Widget view is displayed. */
|
||||||
|
NfcSceneEmulateStateWidgetLog, /**< Widget view with Log button is displayed */
|
||||||
NfcSceneEmulateStateTextBox, /**< TextBox view is displayed. */
|
NfcSceneEmulateStateTextBox, /**< TextBox view is displayed. */
|
||||||
};
|
};
|
||||||
|
|
||||||
@ -633,12 +634,14 @@ static bool
|
|||||||
"Log",
|
"Log",
|
||||||
nfc_protocol_support_common_widget_callback,
|
nfc_protocol_support_common_widget_callback,
|
||||||
instance);
|
instance);
|
||||||
|
scene_manager_set_scene_state(
|
||||||
|
instance->scene_manager, NfcSceneEmulate, NfcSceneEmulateStateWidgetLog);
|
||||||
}
|
}
|
||||||
// Update TextBox data
|
// Update TextBox data
|
||||||
text_box_set_text(instance->text_box, furi_string_get_cstr(instance->text_box_store));
|
text_box_set_text(instance->text_box, furi_string_get_cstr(instance->text_box_store));
|
||||||
consumed = true;
|
consumed = true;
|
||||||
} else if(event.event == GuiButtonTypeCenter) {
|
} else if(event.event == GuiButtonTypeCenter) {
|
||||||
if(state == NfcSceneEmulateStateWidget) {
|
if(state == NfcSceneEmulateStateWidgetLog) {
|
||||||
view_dispatcher_switch_to_view(instance->view_dispatcher, NfcViewTextBox);
|
view_dispatcher_switch_to_view(instance->view_dispatcher, NfcViewTextBox);
|
||||||
scene_manager_set_scene_state(
|
scene_manager_set_scene_state(
|
||||||
instance->scene_manager, NfcSceneEmulate, NfcSceneEmulateStateTextBox);
|
instance->scene_manager, NfcSceneEmulate, NfcSceneEmulateStateTextBox);
|
||||||
@ -649,7 +652,7 @@ static bool
|
|||||||
if(state == NfcSceneEmulateStateTextBox) {
|
if(state == NfcSceneEmulateStateTextBox) {
|
||||||
view_dispatcher_switch_to_view(instance->view_dispatcher, NfcViewWidget);
|
view_dispatcher_switch_to_view(instance->view_dispatcher, NfcViewWidget);
|
||||||
scene_manager_set_scene_state(
|
scene_manager_set_scene_state(
|
||||||
instance->scene_manager, NfcSceneEmulate, NfcSceneEmulateStateWidget);
|
instance->scene_manager, NfcSceneEmulate, NfcSceneEmulateStateWidgetLog);
|
||||||
consumed = true;
|
consumed = true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user