mirror of
https://github.com/eried/portapack-mayhem.git
synced 2024-12-25 23:39:37 -05:00
Merge pull request #750 from gullradriel/recon-delete-retune-fix
Retune after delete fix
This commit is contained in:
commit
7f64606fb2
@ -1002,9 +1002,18 @@ namespace ui {
|
|||||||
|
|
||||||
if( recon_thread )
|
if( recon_thread )
|
||||||
{
|
{
|
||||||
recon_thread->set_freq_index( current_index );
|
|
||||||
timer = 0 ;
|
timer = 0 ;
|
||||||
|
|
||||||
|
recon_thread->set_freq_index( current_index );
|
||||||
|
|
||||||
|
RetuneMessage message { };
|
||||||
|
receiver_model.set_tuning_frequency( frequency_list[ current_index ] . frequency_a ); // Retune
|
||||||
|
message.freq = frequency_list[ current_index ] . frequency_a ;
|
||||||
|
message.range = current_index ;
|
||||||
|
EventDispatcher::send_message(message);
|
||||||
|
|
||||||
|
chThdSleepMilliseconds( recon_lock_duration ); // give some time to Thread::Run to pause
|
||||||
|
|
||||||
if( previous_userpause )
|
if( previous_userpause )
|
||||||
{
|
{
|
||||||
user_pause();
|
user_pause();
|
||||||
@ -1013,9 +1022,9 @@ namespace ui {
|
|||||||
{
|
{
|
||||||
user_resume();
|
user_resume();
|
||||||
}
|
}
|
||||||
recon_thread->set_recon( previous_is_recon );
|
|
||||||
recon_thread->set_freq_delete(false);
|
recon_thread->set_freq_delete(false);
|
||||||
chThdSleepMilliseconds( recon_lock_duration ); // give some time to Thread::Run to pause
|
recon_thread->set_recon( previous_is_recon );
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user