nodeparamview/nodeview: connect selections and enable multi-select in npv
This commit is contained in:
@@ -28,9 +28,10 @@ NodePanel::NodePanel(QWidget *parent) :
|
||||
node_widget_ = new NodeWidget();
|
||||
connect(this, &NodePanel::visibilityChanged, node_widget_->view(), &NodeView::CenterOnItemsBoundingRect);
|
||||
|
||||
// Connect node view signals to this panel - MAY REMOVE
|
||||
connect(node_widget_->view(), &NodeView::NodesSelected, this, &NodePanel::NodesSelected);
|
||||
connect(node_widget_->view(), &NodeView::NodesDeselected, this, &NodePanel::NodesDeselected);
|
||||
connect(node_widget_->view(), &NodeView::NodeSelectionChanged, this, &NodePanel::NodeSelectionChanged);
|
||||
connect(node_widget_->view(), &NodeView::NodeSelectionChangedWithContexts, this, &NodePanel::NodeSelectionChangedWithContexts);
|
||||
connect(node_widget_->view(), &NodeView::NodeGroupOpened, this, &NodePanel::NodeGroupOpened);
|
||||
connect(node_widget_->view(), &NodeView::NodeGroupClosed, this, &NodePanel::NodeGroupClosed);
|
||||
|
||||
|
||||
@@ -105,10 +105,9 @@ public:
|
||||
}
|
||||
|
||||
public slots:
|
||||
void Select(const QVector<Node*>& nodes, bool center_view_on_item)
|
||||
void Select(const QVector<Node::ContextPair> &p)
|
||||
{
|
||||
node_widget_->view()->Select(nodes, center_view_on_item);
|
||||
this->raise();
|
||||
node_widget_->view()->Select(p, true);
|
||||
}
|
||||
|
||||
signals:
|
||||
@@ -116,6 +115,9 @@ signals:
|
||||
|
||||
void NodesDeselected(const QVector<Node*>& nodes);
|
||||
|
||||
void NodeSelectionChanged(const QVector<Node*>& nodes);
|
||||
void NodeSelectionChangedWithContexts(const QVector<Node::ContextPair>& nodes);
|
||||
|
||||
void NodeGroupOpened(NodeGroup *group);
|
||||
|
||||
void NodeGroupClosed();
|
||||
|
||||
Reference in New Issue
Block a user