Skip to content

Commit

Permalink
a bit better impl for keypress handle
Browse files Browse the repository at this point in the history
  • Loading branch information
kraanzu committed Sep 23, 2024
1 parent c3d4bf5 commit 1634362
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions dooit/ui/screens/index.py
Original file line number Diff line number Diff line change
Expand Up @@ -56,8 +56,7 @@ def compose(self):

async def handle_key(self, event: events.Key) -> bool:

# TODO: implement this better
if self.app.mode not in ["NORMAL", "INSERT"]:
if self.app.bar_switcher.is_focused:
return await self.app.bar_switcher.handle_key(event)

return await super().handle_key(event)
Expand Down

0 comments on commit 1634362

Please sign in to comment.