From 00d9c605157aabf2bc0d7105777e0036483eae5d Mon Sep 17 00:00:00 2001 From: MX <10697207+xMasterX@users.noreply.github.com> Date: Fri, 5 Jan 2024 18:24:09 +0300 Subject: [PATCH] subghz use long press to exit transmitter [ci skip] to avoid unwanted 2 buttons hold condition holding arrow button and exit causes default button change, which is stays as hidden feature but this change makes it harder to call it accidentally --- applications/main/subghz/views/transmitter.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/applications/main/subghz/views/transmitter.c b/applications/main/subghz/views/transmitter.c index 16a2ea110..f75bbc661 100644 --- a/applications/main/subghz/views/transmitter.c +++ b/applications/main/subghz/views/transmitter.c @@ -127,7 +127,8 @@ bool subghz_view_transmitter_input(InputEvent* event, void* context) { SubGhzViewTransmitter* subghz_transmitter = context; bool can_be_sent = false; - if(event->key == InputKeyBack && event->type == InputTypeShort) { + if(event->key == InputKeyBack && event->type == InputTypeLong) { + // Reset view model with_view_model( subghz_transmitter->view, SubGhzViewTransmitterModel * model,