aboutsummaryrefslogtreecommitdiffstats
path: root/src/common/errors.rs
diff options
context:
space:
mode:
authorDante Pippi <6619666+dantepippi@users.noreply.github.com>2021-05-07 18:19:23 -0300
committerDante Pippi <6619666+dantepippi@users.noreply.github.com>2021-05-09 17:05:14 -0300
commit9c09cf16587a2b97c63c05d94ff4f18fe557cbf5 (patch)
tree18a8ff8eebbbff0f93eb5af8e270c398ccb65a70 /src/common/errors.rs
parentMerge pull request #473 from zellij-org/bus-business-with-extra-merge-fun (diff)
downloadsl0ppij-9c09cf16587a2b97c63c05d94ff4f18fe557cbf5.tar.gz
sl0ppij-9c09cf16587a2b97c63c05d94ff4f18fe557cbf5.tar.xz
sl0ppij-9c09cf16587a2b97c63c05d94ff4f18fe557cbf5.zip
New behavior for h and l
New behavior for h and l, will change tabs if there are no available panes in the direction. cargo clippy Ensuring atomicity for the MoveFocusOrTab - Blocking the input thread for the action MoveFocusOrTab - Using "unreachable" macro in match arm to make it clear that the directions Up and Down should not be used with the action MoveFocusOrTab Adding tests
Diffstat (limited to 'src/common/errors.rs')
-rw-r--r--src/common/errors.rs6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/common/errors.rs b/src/common/errors.rs
index 148a3a9e..c2caf19d 100644
--- a/src/common/errors.rs
+++ b/src/common/errors.rs
@@ -192,9 +192,11 @@ pub enum ScreenContext {
FocusNextPane,
FocusPreviousPane,
MoveFocusLeft,
+ MoveFocusLeftOrPreviousTab,
MoveFocusDown,
MoveFocusUp,
MoveFocusRight,
+ MoveFocusRightOrNextTab,
Exit,
ScrollUp,
ScrollDown,
@@ -237,9 +239,13 @@ impl From<&ScreenInstruction> for ScreenContext {
ScreenInstruction::FocusNextPane => ScreenContext::FocusNextPane,
ScreenInstruction::FocusPreviousPane => ScreenContext::FocusPreviousPane,
ScreenInstruction::MoveFocusLeft => ScreenContext::MoveFocusLeft,
+ ScreenInstruction::MoveFocusLeftOrPreviousTab => {
+ ScreenContext::MoveFocusLeftOrPreviousTab
+ }
ScreenInstruction::MoveFocusDown => ScreenContext::MoveFocusDown,
ScreenInstruction::MoveFocusUp => ScreenContext::MoveFocusUp,
ScreenInstruction::MoveFocusRight => ScreenContext::MoveFocusRight,
+ ScreenInstruction::MoveFocusRightOrNextTab => ScreenContext::MoveFocusRightOrNextTab,
ScreenInstruction::Exit => ScreenContext::Exit,
ScreenInstruction::ScrollUp => ScreenContext::ScrollUp,
ScreenInstruction::ScrollDown => ScreenContext::ScrollDown,