Fix shift click for multiple selection broken in Bin

parent c533d8a0
......@@ -1269,13 +1269,16 @@ bool Bin::eventFilter(QObject *obj, QEvent *event)
std::shared_ptr<AbstractProjectItem> item = m_itemModel->getBinItemByIndex(m_proxyModel->mapToSource(idx));
if (item->itemType() == AbstractProjectItem::FolderItem) {
QTreeView *tView = static_cast<QTreeView *>(m_itemView);
if (!tView->isExpanded(idx)) {
tView->expandAll();
} else {
tView->collapseAll();
QRect r = tView->visualRect(idx);
if (mouseEvent->pos().x() < r.x()) {
if (!tView->isExpanded(idx)) {
tView->expandAll();
} else {
tView->collapseAll();
}
return true;
}
}
return true;
}
}
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment