-// Copyright (C) 2010-2014 CEA/DEN, EDF R&D
+// Copyright (C) 2010-2015 CEA/DEN, EDF R&D
//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
// License as published by the Free Software Foundation; either
-// version 2.1 of the License.
+// version 2.1 of the License, or (at your option) any later version.
//
// This library is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
this->verticalHeader()->setMinimumSectionSize(2);
this->verticalHeader()->setDefaultSectionSize(2);
this->setItemDelegate(_delegate);
+#if QT_VERSION < QT_VERSION_CHECK(5, 0, 0)
this->verticalHeader()->setResizeMode(QHeaderView::ResizeToContents);
this->horizontalHeader()->setResizeMode(QHeaderView::ResizeToContents);
+#else
+ this->verticalHeader()->setSectionResizeMode(QHeaderView::ResizeToContents);
+ this->horizontalHeader()->setSectionResizeMode(QHeaderView::ResizeToContents);
+#endif
this->resizeColumnsToContents();
this->resizeRowsToContents();
//this->verticalHeader()->hide();
m->setData(ind,QVariant(true),Qt::UserRole);
}
QTableView::selectionChanged(selected,deselected);
+ this->clearSelection();
}
void VectBoolSpreadSheet::nbOfRowsHasChanged(int newNbOfRows)