Skip to content

Commit

Permalink
Just send Start and then RefreshNameplates to Input machine
Browse files Browse the repository at this point in the history
Currently this is fine as if I_Start is got for in wrong state nothing happens
we just ignore it in machine. There is no way for helper to know the current
state of Input machine for now.
  • Loading branch information
copyninja committed May 8, 2018
1 parent 349e37b commit 1c6ef49
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions core/src/inputhelper.rs
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,8 @@ use events::InputHelperEvent::{self, ChooseNameplate, ChooseWords,
// We emit the following events
use events::InputEvent::{ChooseNameplate as I_ChooseNameplate,
ChooseWords as I_ChooseWords,
RefreshNameplates as I_RefreshNameplates};
RefreshNameplates as I_RefreshNameplates,
Start as I_Start};

pub struct InputHelper {
_all_nameplates: Option<Vec<String>>,
Expand Down Expand Up @@ -73,7 +74,7 @@ impl InputHelper {
(events![], completions)
} else {
// TODO: might not be correct needs fixing.
(events![I_RefreshNameplates], Vec::new())
(events![I_Start, I_RefreshNameplates], Vec::new())
}
}
}
Expand Down

0 comments on commit 1c6ef49

Please sign in to comment.