[Interest] Disable QTableView auto-submit
Ch'Gans
chgans at gna.org
Thu Dec 15 02:36:54 CET 2016
Hi there,
I have a dialog that contains a QTableView, the dialog has the usual
cancel, reset, apply and ok buttons.
I want the user to decide when the model will commit data by pressing
apply or ok and revert data by pressing cancel or reset.
I've spend an hour debugging my code to understand why the model was
commiting data at the wrong moment:
It turns out that each time the selection model emit
currentRowChanged(), my model's submit() slot() is called. I would say
that the QTableView is responsible for this...
Does anyone knows a trick to disable this behaviour?
Thanks,
Chris
More information about the Interest
mailing list