mirror of
https://github.com/wassname/sloth.git
synced 2026-07-21 12:51:01 +08:00
forward keyboard events to scene after selecting item with Tab
This commit is contained in:
@@ -172,8 +172,14 @@ class AnnotationScene(QGraphicsScene):
|
||||
# key event handlers
|
||||
#______________________________________________________________________________________________________
|
||||
def selectNextItem(self):
|
||||
# disable inserting
|
||||
# TODO: forward this to the ButtonArea
|
||||
self.inserter_ = None
|
||||
|
||||
# set focus to the view, so that subsequent keyboard events are forwarded to the scene
|
||||
if len(self.views()) > 0:
|
||||
self.views()[0].setFocus(True)
|
||||
|
||||
if len(self.selectedItems()) == 0:
|
||||
for item in self.items():
|
||||
if (item.flags() & QGraphicsItem.ItemIsSelectable):
|
||||
|
||||
Reference in New Issue
Block a user