Skip to content

Commit

Permalink
nodeview: do something when clips are selected
Browse files Browse the repository at this point in the history
  • Loading branch information
itsmattkc committed Mar 19, 2021
1 parent 57b8193 commit 0a17e0f
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 4 deletions.
8 changes: 4 additions & 4 deletions app/panel/node/node.h
Original file line number Diff line number Diff line change
Expand Up @@ -106,11 +106,11 @@ public slots:
node_view_->SelectWithDependencies(nodes);
}

void SelectBlocks(const QVector<Block*>& nodes)
void SelectBlocks(const QVector<Block*>& blocks)
{
Q_UNUSED(nodes)
qDebug() << "Stub";
//node_view_->SelectBlocks(nodes);
QVector<Node*> nodes(blocks.size());
memcpy(nodes.data(), blocks.constData(), blocks.size() * sizeof(Block*));
node_view_->SelectWithDependencies(nodes);
}

void DeselectBlocks(const QVector<Block*>& nodes)
Expand Down
3 changes: 3 additions & 0 deletions app/widget/nodeview/nodeview.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -236,6 +236,9 @@ void NodeView::Select(QVector<Node *> nodes)
}
}

// Center on something
centerOn(scene_.NodeToUIObject(nodes.first()));

ConnectSelectionChangedSignal();

// Emit deselect signal for any nodes that weren't in the list
Expand Down

0 comments on commit 0a17e0f

Please sign in to comment.