+
+ AttributeTablesPtr aTablesAttr = myFeature->data()->tables(CollectionPlugin_Field::VALUES_ID());
+ aTablesAttr->setSize(aTablesAttr->rows(), aTablesAttr->columns(), myDataTblList.size());
+
+
+ AttributeSelectionListPtr aSelList =
+ myFeature->data()->selectionList(CollectionPlugin_Field::SELECTED_ID());
+ if (!aSelList->isInitialized())
+ return;
+ int aSelNb = aSelList->size();
+ if (aSelNb == 0)
+ return;
+
+ int aColumns = myNbComponentsSpn->value() + 1;
+ int aRows = aSelNb + 1;
+ QTableWidget* aTable = myDataTblList.last();
+ aTable->setRowCount(aRows);
+ QTableWidgetItem* aItem = 0;
+ for(int i = 0; i < aColumns; i++) {
+ if (i == 0) {
+ for(int j = 1; j < aRows; j++) {
+ aItem = aTable->item(j, i);
+ if (!aItem) {
+ aItem = new QTableWidgetItem();
+ aTable->setItem(j, i, aItem);
+ }
+ AttributeSelectionPtr aAttr = aSelList->value(j - 1);
+ aItem->setText(QString::fromStdWString(aAttr->namingName()));
+ aItem->setToolTip(QString::fromStdWString(aAttr->namingName()));
+ }
+ } else {
+ QString aDefVal = aTable->item(0, i)->text();
+ for(int j = 1; j < aRows; j++) {
+ aItem = aTable->item(j, i);
+ if (!aItem) {
+ aItem = new QTableWidgetItem();
+ aTable->setItem(j, i, aItem);
+ }
+ aItem->setText(aDefVal);
+ }
+ }
+ }
+ emit valuesChanged();