mirror of
https://github.com/alexpasmantier/television.git
synced 2025-06-06 03:25:23 +00:00
feat(ui): make the top UI help bar toggleable (#41)
This commit is contained in:
parent
75d0bf7b6b
commit
40d5b20c7d
@ -56,6 +56,8 @@ copy_entry_to_clipboard = "ctrl-y"
|
|||||||
toggle_remote_control = "ctrl-r"
|
toggle_remote_control = "ctrl-r"
|
||||||
# Toggle the send to channel mode
|
# Toggle the send to channel mode
|
||||||
toggle_send_to_channel = "ctrl-s"
|
toggle_send_to_channel = "ctrl-s"
|
||||||
|
# Toggle the help bar
|
||||||
|
toggle_help = "ctrl-g"
|
||||||
|
|
||||||
|
|
||||||
# Remote control mode
|
# Remote control mode
|
||||||
@ -70,6 +72,8 @@ select_prev_entry = "up"
|
|||||||
select_entry = "enter"
|
select_entry = "enter"
|
||||||
# Toggle the remote control mode
|
# Toggle the remote control mode
|
||||||
toggle_remote_control = "ctrl-r"
|
toggle_remote_control = "ctrl-r"
|
||||||
|
# Toggle the help bar
|
||||||
|
toggle_help = "ctrl-g"
|
||||||
|
|
||||||
|
|
||||||
# Send to channel mode
|
# Send to channel mode
|
||||||
@ -84,3 +88,5 @@ select_prev_entry = "up"
|
|||||||
select_entry = "enter"
|
select_entry = "enter"
|
||||||
# Toggle the send to channel mode
|
# Toggle the send to channel mode
|
||||||
toggle_send_to_channel = "ctrl-s"
|
toggle_send_to_channel = "ctrl-s"
|
||||||
|
# Toggle the help bar
|
||||||
|
toggle_help = "ctrl-g"
|
||||||
|
@ -87,9 +87,9 @@ pub enum Action {
|
|||||||
/// Quit the application.
|
/// Quit the application.
|
||||||
#[serde(alias = "quit")]
|
#[serde(alias = "quit")]
|
||||||
Quit,
|
Quit,
|
||||||
/// Toggle the help screen.
|
/// Toggle the help bar.
|
||||||
#[serde(skip)]
|
#[serde(alias = "toggle_help")]
|
||||||
Help,
|
ToggleHelp,
|
||||||
/// Signal an error with the given message.
|
/// Signal an error with the given message.
|
||||||
#[serde(skip)]
|
#[serde(skip)]
|
||||||
Error(String),
|
Error(String),
|
||||||
|
@ -360,6 +360,9 @@ impl Television {
|
|||||||
self.mode = Mode::Channel;
|
self.mode = Mode::Channel;
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
Action::ToggleHelp => {
|
||||||
|
self.config.ui.show_help_bar = !self.config.ui.show_help_bar;
|
||||||
|
}
|
||||||
_ => {}
|
_ => {}
|
||||||
}
|
}
|
||||||
Ok(None)
|
Ok(None)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user