Sorry for the delay - was chased from my town by angry customers. Back to the topic...
Whoops, forgot to mention a little detail - there is no view, the editor is placed on a QWidget and connected to the model through a QDataWidgetMapper. So, it's the editor who knows when the editing is finished.
Can you be more specific? Connect to what object's commitData(), exactly? Delegate does not have a slot with the name "commitData", it has a signal with the same name. But I tried to do like you said - I declared MyEditorClass.editingFinished(QWidget) signal, connected myEditorInstance.editingFinished to myDelegateInstance.commitData, ensured that myEditorInstance.editingFinished.emit(myEditorInst ance) is called, and nothing is happening, i.e., myDelegateInstance.setModelData() is not called.
Tried that too: I declared MyEditorClass.editingFinished(QWidget) signal, declared MyDelegate.testSlot(QWidget), connected them, and inside testSlot() I did commitData.emit(editor). The myDelegateInstance.testSlot(editor) is called correctly, but that's it. Emitting myDelegate.commitData(editor) does not have any result.
Could I see some code, please? An example, a tutorial - anything?





Reply With Quote


Bookmarks