trallallero
10th November 2011, 07:27
I would like to permit the user to be in the following situation:
7086
So he understands that he is editing the name of ONE item but he will change the name of all the selected ones (where "enter name" is written).
I've created the situation with the mouse but I cannot do it via software but I guess that, if I can do it with the mouse, it should be possible also via code.
I'm at the point where I have a vector of items that will be selected (QVector<QTableWidgetItem*>) before I call ui->tableWidget->editItem(editItem);
I've tried going through the vector and call
m_ItemsToEdit.at(i)->setSelected(true)
but it doesn't work (it crashes indeed).
I've seen that I should use a selectModel but I cannot find an example...
Somebody knows how to solve the problem ?
7086
So he understands that he is editing the name of ONE item but he will change the name of all the selected ones (where "enter name" is written).
I've created the situation with the mouse but I cannot do it via software but I guess that, if I can do it with the mouse, it should be possible also via code.
I'm at the point where I have a vector of items that will be selected (QVector<QTableWidgetItem*>) before I call ui->tableWidget->editItem(editItem);
I've tried going through the vector and call
m_ItemsToEdit.at(i)->setSelected(true)
but it doesn't work (it crashes indeed).
I've seen that I should use a selectModel but I cannot find an example...
Somebody knows how to solve the problem ?