Feat: demo songs
This commit is contained in:
@@ -27,6 +27,7 @@ pub enum OptionsFocus {
|
||||
MidiInput2,
|
||||
MidiInput3,
|
||||
ResetOnboarding,
|
||||
LoadDemoOnStartup,
|
||||
}
|
||||
|
||||
impl CyclicEnum for OptionsFocus {
|
||||
@@ -55,6 +56,7 @@ impl CyclicEnum for OptionsFocus {
|
||||
Self::MidiInput2,
|
||||
Self::MidiInput3,
|
||||
Self::ResetOnboarding,
|
||||
Self::LoadDemoOnStartup,
|
||||
];
|
||||
}
|
||||
|
||||
@@ -77,6 +79,7 @@ const STANDALONE_ONLY: &[OptionsFocus] = &[
|
||||
OptionsFocus::MidiInput2,
|
||||
OptionsFocus::MidiInput3,
|
||||
OptionsFocus::ResetOnboarding,
|
||||
OptionsFocus::LoadDemoOnStartup,
|
||||
];
|
||||
|
||||
/// Section layout: header line, divider line, then option lines.
|
||||
@@ -113,6 +116,7 @@ const FULL_LAYOUT: &[(OptionsFocus, usize)] = &[
|
||||
(OptionsFocus::MidiInput3, 39),
|
||||
// blank=40, ONBOARDING header=41, divider=42
|
||||
(OptionsFocus::ResetOnboarding, 43),
|
||||
(OptionsFocus::LoadDemoOnStartup, 44),
|
||||
];
|
||||
|
||||
impl OptionsFocus {
|
||||
|
||||
@@ -79,6 +79,8 @@ pub struct UiState {
|
||||
pub zoom_factor: f32,
|
||||
pub window_width: u32,
|
||||
pub window_height: u32,
|
||||
pub load_demo_on_startup: bool,
|
||||
pub demo_index: usize,
|
||||
}
|
||||
|
||||
impl Default for UiState {
|
||||
@@ -127,6 +129,8 @@ impl Default for UiState {
|
||||
zoom_factor: 1.5,
|
||||
window_width: 1200,
|
||||
window_height: 800,
|
||||
load_demo_on_startup: true,
|
||||
demo_index: 0,
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user