mirror of
https://github.com/DarkFlippers/unleashed-firmware.git
synced 2024-12-26 23:05:05 +03:00
Now Mifare word is changed only on the app level without changes to lib level
This commit is contained in:
parent
22aba527b7
commit
321a56d934
@ -23,6 +23,8 @@ static void nfc_scene_info_on_enter_mf_classic(NfcApp* instance) {
|
|||||||
FuriString* temp_str = furi_string_alloc();
|
FuriString* temp_str = furi_string_alloc();
|
||||||
furi_string_cat_printf(
|
furi_string_cat_printf(
|
||||||
temp_str, "\e#%s\n", nfc_device_get_name(device, NfcDeviceNameTypeFull));
|
temp_str, "\e#%s\n", nfc_device_get_name(device, NfcDeviceNameTypeFull));
|
||||||
|
furi_string_replace(temp_str, "Mifare", "MIFARE");
|
||||||
|
|
||||||
nfc_render_mf_classic_info(data, NfcProtocolFormatTypeFull, temp_str);
|
nfc_render_mf_classic_info(data, NfcProtocolFormatTypeFull, temp_str);
|
||||||
|
|
||||||
widget_add_text_scroll_element(
|
widget_add_text_scroll_element(
|
||||||
@ -126,6 +128,8 @@ static void nfc_scene_read_success_on_enter_mf_classic(NfcApp* instance) {
|
|||||||
FuriString* temp_str = furi_string_alloc();
|
FuriString* temp_str = furi_string_alloc();
|
||||||
furi_string_cat_printf(
|
furi_string_cat_printf(
|
||||||
temp_str, "\e#%s\n", nfc_device_get_name(device, NfcDeviceNameTypeFull));
|
temp_str, "\e#%s\n", nfc_device_get_name(device, NfcDeviceNameTypeFull));
|
||||||
|
furi_string_replace(temp_str, "Mifare", "MIFARE");
|
||||||
|
|
||||||
nfc_render_mf_classic_info(data, NfcProtocolFormatTypeShort, temp_str);
|
nfc_render_mf_classic_info(data, NfcProtocolFormatTypeShort, temp_str);
|
||||||
|
|
||||||
widget_add_text_scroll_element(
|
widget_add_text_scroll_element(
|
||||||
|
@ -24,7 +24,7 @@ void nfc_scene_extra_actions_on_enter(void* context) {
|
|||||||
instance);
|
instance);
|
||||||
submenu_add_item(
|
submenu_add_item(
|
||||||
submenu,
|
submenu,
|
||||||
"Mifare Classic Keys",
|
"MIFARE Classic Keys",
|
||||||
SubmenuIndexMfClassicKeys,
|
SubmenuIndexMfClassicKeys,
|
||||||
nfc_scene_extra_actions_submenu_callback,
|
nfc_scene_extra_actions_submenu_callback,
|
||||||
instance);
|
instance);
|
||||||
|
@ -32,10 +32,20 @@ void nfc_scene_set_type_on_enter(void* context) {
|
|||||||
nfc_protocol_support_common_submenu_callback,
|
nfc_protocol_support_common_submenu_callback,
|
||||||
instance);
|
instance);
|
||||||
|
|
||||||
|
FuriString* str = furi_string_alloc();
|
||||||
for(size_t i = 0; i < NfcDataGeneratorTypeNum; i++) {
|
for(size_t i = 0; i < NfcDataGeneratorTypeNum; i++) {
|
||||||
const char* name = nfc_data_generator_get_name(i);
|
furi_string_cat_str(str, nfc_data_generator_get_name(i));
|
||||||
submenu_add_item(submenu, name, i, nfc_protocol_support_common_submenu_callback, instance);
|
furi_string_replace_str(str, "Mifare", "MIFARE");
|
||||||
|
|
||||||
|
submenu_add_item(
|
||||||
|
submenu,
|
||||||
|
furi_string_get_cstr(str),
|
||||||
|
i,
|
||||||
|
nfc_protocol_support_common_submenu_callback,
|
||||||
|
instance);
|
||||||
|
furi_string_reset(str);
|
||||||
}
|
}
|
||||||
|
furi_string_free(str);
|
||||||
|
|
||||||
view_dispatcher_switch_to_view(instance->view_dispatcher, NfcViewMenu);
|
view_dispatcher_switch_to_view(instance->view_dispatcher, NfcViewMenu);
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user