Fix A/D switches not making click sounds
This commit is contained in:
parent
63de2cf5ae
commit
b95c770acb
@ -27,6 +27,7 @@ pub enum ActionSwitch {
|
||||
#[derive(Clone, Copy, Debug)]
|
||||
pub enum FrontpanelInteraction {
|
||||
ActionSw(ActionSwitch, SwitchState),
|
||||
AddrData(u16),
|
||||
Power(bool),
|
||||
}
|
||||
|
||||
@ -163,6 +164,7 @@ impl Widget for &mut Frontpanel<'_> {
|
||||
{
|
||||
self.state.ad_sws =
|
||||
(self.state.ad_sws & !(bit_mask)) | (u16::from(sw_state) << (16 - i));
|
||||
self.interaction = Some(FrontpanelInteraction::AddrData(self.state.ad_sws()));
|
||||
resp.mark_changed();
|
||||
};
|
||||
});
|
||||
|
@ -95,6 +95,7 @@ impl EmuState {
|
||||
self.audio_tx.send(AudioMessage::FanOff).unwrap();
|
||||
}
|
||||
}
|
||||
FrontpanelInteraction::AddrData(_) => (),
|
||||
}
|
||||
self.update_fp();
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user