| 22 | choices: BTreeMap<usize, HashMap<String, Label>>, |
| 23 | } |
| 24 | |
| 25 | impl Timeline { |
| 26 | fn insert_bgm(&mut self, index: usize, bgm: String) { |
| 27 | self.bgm.insert(index, bgm); |
| 28 | } |
| 29 | |
| 30 | fn insert_background(&mut self, index: usize, command: Command) { |
| 31 | self.backgrounds.insert(index, command); |
| 32 | } |
| 33 | |
| 34 | fn insert_choices(&mut self, index: usize, choices: HashMap<String, Label>) { |
| 35 | self.choices.insert(index, choices); |
| 36 | } |
| 37 | |
| 38 | fn get_choice_label(&self, index: usize, choice: &str) -> Option<&Label> { |
| 39 | if let Some(choices) = self.choices.get(&index) { |
| 40 | choices.get(choice) |
| 41 | } else { |
| 42 | None |
| 43 | } |
| 44 | } |
nothing calls this directly
no outgoing calls
no test coverage detected