mirror of
https://github.com/apognu/tuigreet.git
synced 2024-12-02 10:05:01 +03:00
Popup menus do not set previous state, so Esc always returns to the main previous state. Fixes #8 and closes #11.
This commit is contained in:
parent
ec1f8dc386
commit
8a1f7c317c
@ -27,12 +27,10 @@ pub fn handle(greeter: &mut Greeter, events: &Events) -> Result<(), Box<dyn Erro
|
||||
|
||||
Key::F(2) => {
|
||||
greeter.new_command = greeter.command.clone().unwrap_or_default();
|
||||
greeter.previous_mode = greeter.mode;
|
||||
greeter.mode = Mode::Command;
|
||||
}
|
||||
|
||||
Key::F(3) => {
|
||||
greeter.previous_mode = greeter.mode;
|
||||
greeter.mode = Mode::Sessions;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user