From f9d24e385d9e02cdd8e0a822e2cc6c5b532f7a8e Mon Sep 17 00:00:00 2001 From: Boris Yumankulov Date: Sat, 23 Aug 2025 11:22:06 +0500 Subject: [PATCH] fix(input_manager): prevent tab switching when using left/right arrows in QLineEdit Signed-off-by: Boris Yumankulov --- portprotonqt/input_manager.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/portprotonqt/input_manager.py b/portprotonqt/input_manager.py index d4fadb4..fea4305 100644 --- a/portprotonqt/input_manager.py +++ b/portprotonqt/input_manager.py @@ -788,8 +788,8 @@ class InputManager(QObject): active_win.show_next() return True # Consume event to prevent tab switching - # Handle tab switching with Left/Right arrow keys when not in GameCard focus - if key in (Qt.Key.Key_Left, Qt.Key.Key_Right) and (not isinstance(focused, GameCard) or focused is None): + # Handle tab switching with Left/Right arrow keys when not in GameCard focus or QLineEdit + if key in (Qt.Key.Key_Left, Qt.Key.Key_Right) and (not isinstance(focused, GameCard | QLineEdit) or focused is None): idx = self._parent.stackedWidget.currentIndex() total = len(self._parent.tabButtons) if key == Qt.Key.Key_Left: