KeyPressEvent while dragging
Hi i have problem with implemented keyPressEvent() function in my custom QGLWidget,
my widget is not responding to this event while dragging.
I even set focus and grab keyboard on dragEnterEvent()
Can anybody pls help? I am pretty desperate.
THX in advance
They are in the same window, but as separate widgets. And I also call setFocus(), and grabKeyboard() on dragEnterEvent(). This gives QGLWidget focus, but keyborad is not responding.
I solve this problem with reprograming this functionality with enter/leaveEvent and mousePress,Release and move events.
Thanks a lot for your time anyway:)
If you want to drag and drop items from tableWidget to QGLWidget u need to override the following methods .
1. Table Widget:
The following examples in the documentation gives an idea about how the drag and drop can be implemented:
1. Draggable Icons Example.
2. Drag and Drop Puzzle Example.
I have also done something similar to what you require but with a listView and a QWidget. If u need any further help feel free to ask :)