Desktop: put dive site table in "row selection mode"

This feels more natural than selecting a single cell. Still,
the "delete" cell is not visibly selected, which give a
strange impression.

Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at>
This commit is contained in:
Berthold Stoeger 2019-04-13 09:23:26 +02:00 committed by Lubomir I. Ivanov
parent 8d3982c4da
commit 17e7cc048f

View file

@ -18,6 +18,7 @@ TabDiveSite::TabDiveSite(QWidget *parent) : TabBase(parent)
ui.diveSites->view()->setSortingEnabled(true);
ui.diveSites->view()->horizontalHeader()->setSectionResizeMode(LocationInformationModel::NAME, QHeaderView::Stretch);
ui.diveSites->view()->horizontalHeader()->setSectionResizeMode(LocationInformationModel::DESCRIPTION, QHeaderView::Stretch);
ui.diveSites->view()->setSelectionBehavior(QAbstractItemView::SelectRows);
// Show only the first few columns
for (int i = LocationInformationModel::LOCATION; i < LocationInformationModel::COLUMNS; ++i)