removed tab_toggle_reverse_windows

changed tab_toggle_reverse to include the SHIFT modifier, as crossterm
now (i.e. since https://github.com/crossterm-rs/crossterm/pull/490)
sends SHIFT modifier for linux, too.
This commit is contained in:
Nils Andresen 2020-11-13 14:58:08 +01:00 committed by Stephan Dilly
parent b769a83bbc
commit f92363a0cf
3 changed files with 3 additions and 8 deletions

View file

@ -15,8 +15,7 @@
tab_stashes: ( code: Char('4'), modifiers: ( bits: 0,),),
tab_toggle: ( code: Tab, modifiers: ( bits: 0,),),
tab_toggle_reverse: ( code: BackTab, modifiers: ( bits: 0,),),
tab_toggle_reverse_windows: ( code: BackTab, modifiers: ( bits: 1,),),
tab_toggle_reverse: ( code: BackTab, modifiers: ( bits: 1,),),
focus_workdir: ( code: Char('w'), modifiers: ( bits: 0,),),
focus_stage: ( code: Char('s'), modifiers: ( bits: 0,),),

View file

@ -224,9 +224,7 @@ impl App {
let new_flags = if k == self.key_config.tab_toggle {
self.toggle_tabs(false)?;
NeedsUpdate::COMMANDS
} else if k == self.key_config.tab_toggle_reverse
|| k == self.key_config.tab_toggle_reverse_windows
{
} else if k == self.key_config.tab_toggle_reverse {
self.toggle_tabs(true)?;
NeedsUpdate::COMMANDS
} else if k == self.key_config.tab_status

View file

@ -23,7 +23,6 @@ pub struct KeyConfig {
pub tab_stashes: KeyEvent,
pub tab_toggle: KeyEvent,
pub tab_toggle_reverse: KeyEvent,
pub tab_toggle_reverse_windows: KeyEvent,
pub focus_workdir: KeyEvent,
pub focus_stage: KeyEvent,
pub focus_right: KeyEvent,
@ -76,8 +75,7 @@ impl Default for KeyConfig {
tab_stashing: KeyEvent { code: KeyCode::Char('3'), modifiers: KeyModifiers::empty()},
tab_stashes: KeyEvent { code: KeyCode::Char('4'), modifiers: KeyModifiers::empty()},
tab_toggle: KeyEvent { code: KeyCode::Tab, modifiers: KeyModifiers::empty()},
tab_toggle_reverse: KeyEvent { code: KeyCode::BackTab, modifiers: KeyModifiers::empty()},
tab_toggle_reverse_windows: KeyEvent { code: KeyCode::BackTab, modifiers: KeyModifiers::SHIFT},
tab_toggle_reverse: KeyEvent { code: KeyCode::BackTab, modifiers: KeyModifiers::SHIFT},
focus_workdir: KeyEvent { code: KeyCode::Char('w'), modifiers: KeyModifiers::empty()},
focus_stage: KeyEvent { code: KeyCode::Char('s'), modifiers: KeyModifiers::empty()},
focus_right: KeyEvent { code: KeyCode::Right, modifiers: KeyModifiers::empty()},