Commit c1e8e31f authored by Dmitrii Utkin's avatar Dmitrii Utkin

Fixed folding/unfolding when clicking thumbnail, traversing layers, modifying layer tree

parent 2153f3ba
......@@ -805,21 +805,13 @@ bool NodeDelegate::editorEvent(QEvent *event, QAbstractItemModel *model, const Q
} else if (mouseEvent->modifiers() == (Qt::ControlModifier | Qt::ShiftModifier | Qt::AltModifier)) {
action = SELECTION_INTERSECT;
hasCorrectModifier = true;
} else {
d->view->setItemsExpandable(false);
d->view->setSelectionMode(QAbstractItemView::ExtendedSelection);
QItemSelectionModel *selectionModel = d->view->selectionModel();
selectionModel->select(index, QItemSelectionModel::ToggleCurrent);
return false;
}
if (hasCorrectModifier) {
model->setData(index, QVariant(int(action)), KisNodeModel::SelectOpaqueRole);
}
return true; //If not here then the item is !expanded when reaching return false;
d->view->setCurrentIndex(index);
return hasCorrectModifier; //If not here then the item is !expanded when reaching return false;
}
if (mouseEvent->button() == Qt::LeftButton &&
......
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