Say I have a QTableWidget and in each row there is a QComboBox and a QSpinBox. Consider that I store their values is a QMap theMap;
When comboBoxes value or spin boxes value is being changed I want to update "theMap". So I should know what was the former value of the combo box in order to replace with the new value of the combo box and also take care of the value of the spin box.
How can I do this?
P.S. I have decided to create a slot that when you click on a table, it stores the current value of the combo box of that row. But this works only when you press on row caption. In other places (clicking on a combo box or on a spin box) itemSelectionChanged() signal of QTableWidget does not work. So in general my problem is to store the value of the combo box of selected row, and the I will get ComboBox or SpinBox change even and will process "theMap" easily.