Add manual input elements to the app an ui #216

Merged
wojtek merged 17 commits from 188---add-option-for-manual-input-during-fetch into main 2024-09-15 15:20:11 +02:00
3 changed files with 4 additions and 4 deletions
Showing only changes of commit d5716b79e2 - Show all commits

View File

@ -163,7 +163,7 @@ impl IApp for App {
if let Some(input) = self.inner_mut().input.take() { if let Some(input) = self.inner_mut().input.take() {
AppMode::Input(AppInputMode::new(input, self.state())) AppMode::Input(AppInputMode::new(input, self.state()))
} else { } else {
AppMode::Browse(self.state()) AppMode::State(self.state())
} }
} }
} }

View File

@ -19,8 +19,8 @@ pub enum AppState<B, I, R, S, F, M, E, C> {
Critical(C), Critical(C),
} }
pub enum AppMode<BrowseMode, InputMode> { pub enum AppMode<StateMode, InputMode> {
Browse(BrowseMode), State(StateMode),
Input(InputMode), Input(InputMode),
} }

View File

@ -66,7 +66,7 @@ impl<APP: IApp> IEventHandlerPrivate<APP> for EventHandler {
match app.mode() { match app.mode() {
AppMode::Input(input_mode) => Self::handle_input_key_event(input_mode, key_event), AppMode::Input(input_mode) => Self::handle_input_key_event(input_mode, key_event),
AppMode::Browse(browse_mode) => match browse_mode { AppMode::State(state_mode) => match state_mode {
AppState::Browse(browse_state) => { AppState::Browse(browse_state) => {
Self::handle_browse_key_event(browse_state, key_event) Self::handle_browse_key_event(browse_state, key_event)
} }