Skip to content

Commit

Permalink
BFW-996 - temporary handling blindAlerts in RadioButtons for start/en…
Browse files Browse the repository at this point in the history
…d index until it gets refactored (#589)
  • Loading branch information
Chleba authored Jun 17, 2020
1 parent 08b258a commit 2f6d64d
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions src/gui/dialogs/DialogRadioButton.cpp
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
#include "DialogRadioButton.hpp"
#include <algorithm> //find
#include "button_draw.h"
#include "sound_C_wrapper.h"
/*****************************************************************************/
//static variables and methods
static const PhaseResponses no_responses = { Response::_none, Response::_none, Response::_none, Response::_none }; //used in constructor
Expand Down Expand Up @@ -38,6 +39,8 @@ RadioButton &RadioButton::operator++() {
if ((selected_index + 1) < btn_count) {
++selected_index; //btn_count can be 0
need_redraw = true;
} else {
Sound_Play(eSOUND_TYPE_BlindAlert);
}
return *this;
}
Expand All @@ -47,6 +50,8 @@ RadioButton &RadioButton::operator--() {
if (selected_index > 0) {
--selected_index;
need_redraw = true;
} else {
Sound_Play(eSOUND_TYPE_BlindAlert);
}
return *this;
}
Expand Down

0 comments on commit 2f6d64d

Please sign in to comment.