From 63b40992efedfbd344e03402b5eb2e7e6d569f65 Mon Sep 17 00:00:00 2001 From: MX <10697207+xMasterX@users.noreply.github.com> Date: Sun, 11 Dec 2022 00:09:38 +0300 Subject: [PATCH] Fix naming was different from OFW --- applications/main/infrared/infrared_brute_force.c | 10 +++++----- applications/main/infrared/infrared_brute_force.h | 2 +- applications/main/infrared/infrared_cli.c | 2 +- .../scenes/common/infrared_scene_universal_common.c | 2 +- 4 files changed, 8 insertions(+), 8 deletions(-) diff --git a/applications/main/infrared/infrared_brute_force.c b/applications/main/infrared/infrared_brute_force.c index ebc34bd15..3f426f1dc 100644 --- a/applications/main/infrared/infrared_brute_force.c +++ b/applications/main/infrared/infrared_brute_force.c @@ -38,11 +38,6 @@ InfraredBruteForce* infrared_brute_force_alloc() { return brute_force; } -void infrared_brute_force_clear_records(InfraredBruteForce* brute_force) { - furi_assert(!brute_force->is_started); - InfraredBruteForceRecordDict_reset(brute_force->records); -} - void infrared_brute_force_free(InfraredBruteForce* brute_force) { furi_assert(!brute_force->is_started); InfraredBruteForceRecordDict_clear(brute_force->records); @@ -151,3 +146,8 @@ void infrared_brute_force_add_record( InfraredBruteForceRecordDict_set_at(brute_force->records, key, value); furi_string_free(key); } + +void infrared_brute_force_reset(InfraredBruteForce* brute_force) { + furi_assert(!brute_force->is_started); + InfraredBruteForceRecordDict_reset(brute_force->records); +} diff --git a/applications/main/infrared/infrared_brute_force.h b/applications/main/infrared/infrared_brute_force.h index fff472e79..b6c48e3f6 100644 --- a/applications/main/infrared/infrared_brute_force.h +++ b/applications/main/infrared/infrared_brute_force.h @@ -16,7 +16,7 @@ bool infrared_brute_force_start( bool infrared_brute_force_is_started(InfraredBruteForce* brute_force); void infrared_brute_force_stop(InfraredBruteForce* brute_force); bool infrared_brute_force_send_next(InfraredBruteForce* brute_force); -void infrared_brute_force_clear_records(InfraredBruteForce* brute_force); +void infrared_brute_force_reset(InfraredBruteForce* brute_force); void infrared_brute_force_add_record( InfraredBruteForce* brute_force, uint32_t index, diff --git a/applications/main/infrared/infrared_cli.c b/applications/main/infrared/infrared_cli.c index 7d4c150ef..8f35a8fd1 100644 --- a/applications/main/infrared/infrared_cli.c +++ b/applications/main/infrared/infrared_cli.c @@ -453,7 +453,7 @@ static void } while(false); furi_string_free(remote_path); - infrared_brute_force_clear_records(brute_force); + infrared_brute_force_reset(brute_force); infrared_brute_force_free(brute_force); } diff --git a/applications/main/infrared/scenes/common/infrared_scene_universal_common.c b/applications/main/infrared/scenes/common/infrared_scene_universal_common.c index 7feb36412..d55d8d0a6 100644 --- a/applications/main/infrared/scenes/common/infrared_scene_universal_common.c +++ b/applications/main/infrared/scenes/common/infrared_scene_universal_common.c @@ -87,6 +87,6 @@ void infrared_scene_universal_common_on_exit(void* context) { Infrared* infrared = context; ButtonPanel* button_panel = infrared->button_panel; view_stack_remove_view(infrared->view_stack, button_panel_get_view(button_panel)); - infrared_brute_force_clear_records(infrared->brute_force); + infrared_brute_force_reset(infrared->brute_force); button_panel_reset(button_panel); }