mirror of
https://github.com/eried/portapack-mayhem.git
synced 2025-05-09 10:15:18 -04:00
View::add_children: Use std::list_initializer as argument.
Improvement in code size -- 944 bytes. Some day I will understand C++11 well enough to do the right thing the first time.
This commit is contained in:
parent
298324d6e4
commit
8a69b0523e
16 changed files with 57 additions and 55 deletions
|
@ -44,10 +44,10 @@ AMOptionsView::AMOptionsView(
|
|||
{
|
||||
set_style(style);
|
||||
|
||||
add_children({ {
|
||||
add_children({
|
||||
&label_config,
|
||||
&options_config,
|
||||
} });
|
||||
});
|
||||
|
||||
options_config.set_selected_index(receiver_model.am_configuration());
|
||||
options_config.on_change = [this](size_t n, OptionsField::value_t) {
|
||||
|
@ -63,10 +63,10 @@ NBFMOptionsView::NBFMOptionsView(
|
|||
{
|
||||
set_style(style);
|
||||
|
||||
add_children({ {
|
||||
add_children({
|
||||
&label_config,
|
||||
&options_config,
|
||||
} });
|
||||
});
|
||||
|
||||
options_config.set_selected_index(receiver_model.nbfm_configuration());
|
||||
options_config.on_change = [this](size_t n, OptionsField::value_t) {
|
||||
|
@ -79,7 +79,7 @@ NBFMOptionsView::NBFMOptionsView(
|
|||
AnalogAudioView::AnalogAudioView(
|
||||
NavigationView& nav
|
||||
) {
|
||||
add_children({ {
|
||||
add_children({
|
||||
&rssi,
|
||||
&channel,
|
||||
&audio,
|
||||
|
@ -90,7 +90,7 @@ AnalogAudioView::AnalogAudioView(
|
|||
&field_volume,
|
||||
&record_view,
|
||||
&waterfall,
|
||||
} });
|
||||
});
|
||||
|
||||
field_frequency.set_value(receiver_model.tuning_frequency());
|
||||
field_frequency.set_step(receiver_model.frequency_step());
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue