mirror of
https://github.com/sqlitebrowser/sqlitebrowser.git
synced 2026-01-20 11:00:44 -06:00
Fix retrieving list of selected columns for Browse Data tab
When retrieving the list of selected columns of a table in the Browse Data tab only take into account columns which are selected entirely, not columns which have at least a single selected field. Before selecting a row would implicity select all columns. This fixes issues with resizing and with hiding a column. See issue #1999.
This commit is contained in:
@@ -844,7 +844,7 @@ int ExtendedTableWidget::numVisibleRows() const
|
||||
std::unordered_set<int> ExtendedTableWidget::selectedCols() const
|
||||
{
|
||||
std::unordered_set<int> selectedCols;
|
||||
for(const QModelIndex & idx : selectedIndexes())
|
||||
for(const auto& idx : selectionModel()->selectedColumns())
|
||||
selectedCols.insert(idx.column());
|
||||
return selectedCols;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user