From 16bd822d1b600fadf01003f3cc1ac080956f672c Mon Sep 17 00:00:00 2001 From: Knud Dollereder Date: Fri, 29 Nov 2019 16:12:16 +0100 Subject: [PATCH] Move selection related code into SelectionModel And fix a bug where the curves where missing in the graphicsview after opening the AnimationCurveDialog a second time. Change-Id: I4f13bd345afafaa0578a3be28be6326fa232dbe1 Reviewed-by: Mahmoud Badri Reviewed-by: Miikka Heikkinen Reviewed-by: Thomas Hartmann --- src/plugins/qmldesigner/CMakeLists.txt | 1 + .../components/curveeditor/curveeditor.cpp | 4 +- .../components/curveeditor/curveeditor.pri | 2 + .../curveeditor/curveeditormodel.cpp | 8 +- .../curveeditor/detail/curveitem.cpp | 2 + .../curveeditor/detail/graphicsscene.cpp | 5 +- .../curveeditor/detail/selectionmodel.cpp | 116 ++++++++++++++++++ .../curveeditor/detail/selectionmodel.h | 65 ++++++++++ .../curveeditor/detail/treemodel.cpp | 59 ++++++--- .../components/curveeditor/detail/treemodel.h | 20 ++- .../curveeditor/detail/treeview.cpp | 48 ++------ .../components/curveeditor/detail/treeview.h | 6 +- .../components/curveeditor/treeitem.cpp | 14 +++ .../components/curveeditor/treeitem.h | 2 + .../timelineeditor/animationcurvedialog.cpp | 5 +- .../timelineeditor/animationcurvedialog.h | 3 +- .../timelineeditor/timelinetoolbar.cpp | 1 + src/plugins/qmldesigner/qmldesignerplugin.qbs | 2 + 18 files changed, 286 insertions(+), 77 deletions(-) create mode 100644 src/plugins/qmldesigner/components/curveeditor/detail/selectionmodel.cpp create mode 100644 src/plugins/qmldesigner/components/curveeditor/detail/selectionmodel.h diff --git a/src/plugins/qmldesigner/CMakeLists.txt b/src/plugins/qmldesigner/CMakeLists.txt index 4967f757e78..80a03f448c2 100644 --- a/src/plugins/qmldesigner/CMakeLists.txt +++ b/src/plugins/qmldesigner/CMakeLists.txt @@ -626,6 +626,7 @@ extend_qtc_plugin(QmlDesigner detail/keyframeitem.cpp detail/keyframeitem.h detail/playhead.cpp detail/playhead.h detail/selectableitem.cpp detail/selectableitem.h + detail/selectionmodel.cpp detail/selectionmodel.h detail/selector.cpp detail/selector.h detail/shortcut.cpp detail/shortcut.h detail/treeitemdelegate.cpp detail/treeitemdelegate.h diff --git a/src/plugins/qmldesigner/components/curveeditor/curveeditor.cpp b/src/plugins/qmldesigner/components/curveeditor/curveeditor.cpp index 72bdf4be135..3ec613f6ffa 100644 --- a/src/plugins/qmldesigner/components/curveeditor/curveeditor.cpp +++ b/src/plugins/qmldesigner/components/curveeditor/curveeditor.cpp @@ -52,7 +52,7 @@ CurveEditor::CurveEditor(CurveEditorModel *model, QWidget *parent) box->addWidget(splitter); setLayout(box); - connect(m_tree, &TreeView::curvesSelected, m_view, &GraphicsView::reset); + connect(m_tree->selectionModel(), &SelectionModel::curvesSelected, m_view, &GraphicsView::reset); } void CurveEditor::zoomX(double zoom) @@ -67,7 +67,7 @@ void CurveEditor::zoomY(double zoom) void CurveEditor::clearCanvas() { - m_view->reset(m_tree->selection()); + m_view->reset({}); } QToolBar *CurveEditor::createToolBar() diff --git a/src/plugins/qmldesigner/components/curveeditor/curveeditor.pri b/src/plugins/qmldesigner/components/curveeditor/curveeditor.pri index cd377aa2ced..e759ed6bde7 100644 --- a/src/plugins/qmldesigner/components/curveeditor/curveeditor.pri +++ b/src/plugins/qmldesigner/components/curveeditor/curveeditor.pri @@ -14,6 +14,7 @@ HEADERS += \ $$PWD/detail/keyframeitem.h \ $$PWD/detail/playhead.h \ $$PWD/detail/selectableitem.h \ + $$PWD/detail/selectionmodel.h \ $$PWD/detail/selector.h \ $$PWD/detail/shortcut.h \ $$PWD/detail/treeitemdelegate.h \ @@ -36,6 +37,7 @@ SOURCES += \ $$PWD/detail/keyframeitem.cpp \ $$PWD/detail/playhead.cpp \ $$PWD/detail/selectableitem.cpp \ + $$PWD/detail/selectionmodel.cpp \ $$PWD/detail/selector.cpp \ $$PWD/detail/shortcut.cpp \ $$PWD/detail/treeitemdelegate.cpp \ diff --git a/src/plugins/qmldesigner/components/curveeditor/curveeditormodel.cpp b/src/plugins/qmldesigner/components/curveeditor/curveeditormodel.cpp index 274da77ebfe..99f83d3746d 100644 --- a/src/plugins/qmldesigner/components/curveeditor/curveeditormodel.cpp +++ b/src/plugins/qmldesigner/components/curveeditor/curveeditormodel.cpp @@ -26,6 +26,7 @@ #include "curveeditormodel.h" #include "treeitem.h" #include "detail/graphicsview.h" +#include "detail/selectionmodel.h" namespace DesignTools { @@ -53,7 +54,9 @@ void CurveEditorModel::setCurve(unsigned int id, const AnimationCurve &curve) void CurveEditorModel::reset(const std::vector &items) { - std::vector sel = selection(); + std::vector sel; + if (SelectionModel *sm = selectionModel()) + sel = sm->selectedPaths(); beginResetModel(); @@ -67,7 +70,8 @@ void CurveEditorModel::reset(const std::vector &items) endResetModel(); - select(sel); + if (SelectionModel *sm = selectionModel()) + sm->select(sel); } } // End namespace DesignTools. diff --git a/src/plugins/qmldesigner/components/curveeditor/detail/curveitem.cpp b/src/plugins/qmldesigner/components/curveeditor/detail/curveitem.cpp index a7eb612a291..8ecdd54e12d 100644 --- a/src/plugins/qmldesigner/components/curveeditor/detail/curveitem.cpp +++ b/src/plugins/qmldesigner/components/curveeditor/detail/curveitem.cpp @@ -339,6 +339,8 @@ void CurveItem::setInterpolation(Keyframe::Interpolation interpolation) void CurveItem::connect(GraphicsScene *scene) { + QObject::connect(this, &CurveItem::curveChanged, scene, &GraphicsScene::curveChanged); + for (auto *frame : m_keyframes) { QObject::connect(frame, &KeyframeItem::keyframeMoved, scene, &GraphicsScene::keyframeMoved); QObject::connect(frame, &KeyframeItem::handleMoved, scene, &GraphicsScene::handleMoved); diff --git a/src/plugins/qmldesigner/components/curveeditor/detail/graphicsscene.cpp b/src/plugins/qmldesigner/components/curveeditor/detail/graphicsscene.cpp index d29bb849281..1469f2d6899 100644 --- a/src/plugins/qmldesigner/components/curveeditor/detail/graphicsscene.cpp +++ b/src/plugins/qmldesigner/components/curveeditor/detail/graphicsscene.cpp @@ -68,11 +68,8 @@ void GraphicsScene::addCurveItem(CurveItem *item) { m_dirty = true; item->setDirty(false); - - connect(item, &CurveItem::curveChanged, this, &GraphicsScene::curveChanged); - - addItem(item); item->connect(this); + addItem(item); } void GraphicsScene::setComponentTransform(const QTransform &transform) diff --git a/src/plugins/qmldesigner/components/curveeditor/detail/selectionmodel.cpp b/src/plugins/qmldesigner/components/curveeditor/detail/selectionmodel.cpp new file mode 100644 index 00000000000..cddc3efe6ff --- /dev/null +++ b/src/plugins/qmldesigner/components/curveeditor/detail/selectionmodel.cpp @@ -0,0 +1,116 @@ +/**************************************************************************** +** +** Copyright (C) 2019 The Qt Company Ltd. +** Contact: https://www.qt.io/licensing/ +** +** This file is part of the Qt Design Tooling +** +** Commercial License Usage +** Licensees holding valid commercial Qt licenses may use this file in +** accordance with the commercial license agreement provided with the +** Software or, alternatively, in accordance with the terms contained in +** a written agreement between you and The Qt Company. For licensing terms +** and conditions see https://www.qt.io/terms-conditions. For further +** information use the contact form at https://www.qt.io/contact-us. +** +** GNU General Public License Usage +** Alternatively, this file may be used under the terms of the GNU +** General Public License version 3 as published by the Free Software +** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT +** included in the packaging of this file. Please review the following +** information to ensure the GNU General Public License requirements will +** be met: https://www.gnu.org/licenses/gpl-3.0.html. +** +****************************************************************************/ + +#include "selectionmodel.h" +#include "treemodel.h" + +namespace DesignTools { + +SelectionModel::SelectionModel(QAbstractItemModel *model) + : QItemSelectionModel(model) +{ + connect(this, &QItemSelectionModel::selectionChanged, this, &SelectionModel::changeSelection); +} + +std::vector SelectionModel::selectedPaths() const +{ + std::vector out; + for (auto &&item : selectedTreeItems()) + out.push_back(item->path()); + return out; +} + +std::vector SelectionModel::selectedCurveItems() const +{ + std::vector items; + const auto rows = selectedRows(0); + for (auto &&index : rows) { + if (auto *curveItem = TreeModel::curveItem(index)) + items.push_back(curveItem); + } + return items; +} + +std::vector SelectionModel::selectedTreeItems() const +{ + std::vector items; + const auto rows = selectedRows(0); + for (auto &&index : rows) { + if (auto *treeItem = TreeModel::treeItem(index)) + items.push_back(treeItem); + } + return items; +} + +std::vector SelectionModel::selectedNodeItems() const +{ + std::vector items; + const auto rows = selectedRows(0); + for (auto &&index : rows) { + if (auto *ni = TreeModel::nodeItem(index)) + items.push_back(ni); + } + return items; +} + +std::vector SelectionModel::selectedPropertyItems() const +{ + std::vector items; + const auto rows = selectedRows(0); + for (auto &&index : rows) { + if (auto *pi = TreeModel::propertyItem(index)) + items.push_back(pi); + } + return items; +} + +void SelectionModel::select(const std::vector &selection) +{ + for (auto &&path : selection) { + if (auto *treeModel = qobject_cast(model())) { + QModelIndex index = treeModel->indexOf(path); + if (index.isValid()) + QItemSelectionModel::select(index, QItemSelectionModel::Select); + } + } +} + +void SelectionModel::changeSelection(const QItemSelection &selected, + const QItemSelection &deselected) +{ + Q_UNUSED(selected) + Q_UNUSED(deselected) + + std::vector curves; + const auto ids = selectedIndexes(); + for (auto &&index : ids) { + if (auto *curveItem = TreeModel::curveItem(index)) + curves.push_back(curveItem); + } + + emit curvesSelected(curves); +} + +} // End namespace DesignTools. diff --git a/src/plugins/qmldesigner/components/curveeditor/detail/selectionmodel.h b/src/plugins/qmldesigner/components/curveeditor/detail/selectionmodel.h new file mode 100644 index 00000000000..8bb195856c8 --- /dev/null +++ b/src/plugins/qmldesigner/components/curveeditor/detail/selectionmodel.h @@ -0,0 +1,65 @@ +/**************************************************************************** +** +** Copyright (C) 2019 The Qt Company Ltd. +** Contact: https://www.qt.io/licensing/ +** +** This file is part of the Qt Design Tooling +** +** Commercial License Usage +** Licensees holding valid commercial Qt licenses may use this file in +** accordance with the commercial license agreement provided with the +** Software or, alternatively, in accordance with the terms contained in +** a written agreement between you and The Qt Company. For licensing terms +** and conditions see https://www.qt.io/terms-conditions. For further +** information use the contact form at https://www.qt.io/contact-us. +** +** GNU General Public License Usage +** Alternatively, this file may be used under the terms of the GNU +** General Public License version 3 as published by the Free Software +** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT +** included in the packaging of this file. Please review the following +** information to ensure the GNU General Public License requirements will +** be met: https://www.gnu.org/licenses/gpl-3.0.html. +** +****************************************************************************/ + +#pragma once + +#include "treeitem.h" + +#include + +namespace DesignTools { + +class CurveItem; +class TreeItem; +class NodeTreeItem; +class PropertyTreeItem; + +class SelectionModel : public QItemSelectionModel +{ + Q_OBJECT + +signals: + void curvesSelected(const std::vector &curves); + +public: + SelectionModel(QAbstractItemModel *model = nullptr); + + std::vector selectedPaths() const; + + std::vector selectedCurveItems() const; + + std::vector selectedTreeItems() const; + + std::vector selectedNodeItems() const; + + std::vector selectedPropertyItems() const; + + void select(const std::vector &selection); + +private: + void changeSelection(const QItemSelection &selected, const QItemSelection &deselected); +}; + +} // End namespace DesignTools. diff --git a/src/plugins/qmldesigner/components/curveeditor/detail/treemodel.cpp b/src/plugins/qmldesigner/components/curveeditor/detail/treemodel.cpp index c70dcd6edae..81cae4bebf1 100644 --- a/src/plugins/qmldesigner/components/curveeditor/detail/treemodel.cpp +++ b/src/plugins/qmldesigner/components/curveeditor/detail/treemodel.cpp @@ -24,6 +24,7 @@ ****************************************************************************/ #include "treemodel.h" +#include "curveitem.h" #include "detail/graphicsview.h" #include "treeitem.h" #include "treeview.h" @@ -32,6 +33,42 @@ namespace DesignTools { +TreeItem *TreeModel::treeItem(const QModelIndex &index) +{ + if (index.isValid() && index.column() == 0) + return static_cast(index.internalPointer()); + + return nullptr; +} + +NodeTreeItem *TreeModel::nodeItem(const QModelIndex &index) +{ + if (auto *ti = treeItem(index)) + return ti->asNodeItem(); + + return nullptr; +} + +PropertyTreeItem *TreeModel::propertyItem(const QModelIndex &index) +{ + if (auto *ti = treeItem(index)) + return ti->asPropertyItem(); + + return nullptr; +} + +CurveItem *TreeModel::curveItem(const QModelIndex &index) +{ + if (auto *pti = propertyItem(index)) { + auto *citem = new CurveItem(pti->id(), pti->curve()); + citem->setValueType(pti->valueType()); + citem->setComponent(pti->component()); + return citem; + } + + return nullptr; +} + TreeModel::TreeModel(QObject *parent) : QAbstractItemModel(parent) , m_view(nullptr) @@ -141,16 +178,11 @@ GraphicsView *TreeModel::graphicsView() const return m_view; } -std::vector TreeModel::selection() const +SelectionModel *TreeModel::selectionModel() const { - std::vector out; - for (auto &&index : m_tree->selectionModel()->selectedIndexes()) { - if (index.column() == 0) { - TreeItem *item = static_cast(index.internalPointer()); - out.push_back(item->path()); - } - } - return out; + if (m_tree) + return m_tree->selectionModel(); + return nullptr; } QModelIndex TreeModel::findIdx(const QString &name, const QModelIndex &parent) const @@ -178,15 +210,6 @@ QModelIndex TreeModel::indexOf(const TreeItem::Path &path) const return parent; } -void TreeModel::select(const std::vector &selection) -{ - for (auto &&sel : selection) { - QModelIndex idx = indexOf(sel); - if (idx.isValid()) - m_tree->selectionModel()->select(idx, QItemSelectionModel::Select); - } -} - void TreeModel::initialize() { if (m_root) diff --git a/src/plugins/qmldesigner/components/curveeditor/detail/treemodel.h b/src/plugins/qmldesigner/components/curveeditor/detail/treemodel.h index 961ee492335..4cc81d7bc39 100644 --- a/src/plugins/qmldesigner/components/curveeditor/detail/treemodel.h +++ b/src/plugins/qmldesigner/components/curveeditor/detail/treemodel.h @@ -35,12 +35,24 @@ namespace DesignTools { class GraphicsView; class TreeView; +class TreeItem; +class CurveItem; +class PropertyTreeItem; +class SelectionModel; class TreeModel : public QAbstractItemModel { Q_OBJECT public: + static TreeItem *treeItem(const QModelIndex &index); + + static NodeTreeItem *nodeItem(const QModelIndex &index); + + static PropertyTreeItem *propertyItem(const QModelIndex &index); + + static CurveItem *curveItem(const QModelIndex &index); + TreeModel(QObject *parent = nullptr); ~TreeModel() override; @@ -59,6 +71,8 @@ public: int columnCount(const QModelIndex &parent = QModelIndex()) const override; + QModelIndex indexOf(const TreeItem::Path &path) const; + void setTreeView(TreeView *view); void setGraphicsView(GraphicsView *view); @@ -66,9 +80,7 @@ public: protected: GraphicsView *graphicsView() const; - std::vector selection() const; - - void select(const std::vector &selection); + SelectionModel *selectionModel() const; void initialize(); @@ -78,8 +90,6 @@ protected: QModelIndex findIdx(const QString &name, const QModelIndex &parent) const; - QModelIndex indexOf(const TreeItem::Path &path) const; - private: GraphicsView *m_view; diff --git a/src/plugins/qmldesigner/components/curveeditor/detail/treeview.cpp b/src/plugins/qmldesigner/components/curveeditor/detail/treeview.cpp index 37cf791871e..88c17aa6305 100644 --- a/src/plugins/qmldesigner/components/curveeditor/detail/treeview.cpp +++ b/src/plugins/qmldesigner/components/curveeditor/detail/treeview.cpp @@ -25,6 +25,7 @@ #include "treeview.h" #include "curveeditormodel.h" #include "curveitem.h" +#include "selectionmodel.h" #include "treeitem.h" #include "treeitemdelegate.h" @@ -49,16 +50,12 @@ TreeView::TreeView(CurveEditorModel *model, QWidget *parent) auto expandItems = [this]() { expandAll(); }; connect(model, &QAbstractItemModel::modelReset, expandItems); - auto *delegate = new TreeItemDelegate(model->style(), this); - setItemDelegate(delegate); + setItemDelegate(new TreeItemDelegate(model->style(), this)); + setSelectionModel(new SelectionModel(model)); setSelectionBehavior(QAbstractItemView::SelectRows); setSelectionMode(QAbstractItemView::ExtendedSelection); - connect(selectionModel(), - &QItemSelectionModel::selectionChanged, - this, - &TreeView::changeSelection); setStyle(model->style()); header()->setSectionResizeMode(0, QHeaderView::Stretch); @@ -70,6 +67,11 @@ TreeView::TreeView(CurveEditorModel *model, QWidget *parent) header()->resizeSection(2, 20); } +SelectionModel *TreeView::selectionModel() const +{ + return qobject_cast(QTreeView::selectionModel()); +} + void TreeView::setStyle(const CurveEditorStyle &style) { QPalette pal = palette(); @@ -87,46 +89,12 @@ void TreeView::setStyle(const CurveEditorStyle &style) delegate->setStyle(style); } -std::vector TreeView::selection() -{ - std::vector items; - for (auto &&index : selectionModel()->selectedRows(0)) { - if (index.isValid()) { - auto *treeItem = static_cast(index.internalPointer()); - if (auto *propertyItem = treeItem->asPropertyItem()) - items.push_back(new CurveItem(treeItem->id(), propertyItem->curve())); - } - } - return items; -} - void TreeView::changeCurve(unsigned int id, const AnimationCurve &curve) { if (auto *curveModel = qobject_cast(model())) curveModel->setCurve(id, curve); } -void TreeView::changeSelection(const QItemSelection &selected, const QItemSelection &deselected) -{ - Q_UNUSED(selected) - Q_UNUSED(deselected) - - std::vector curves; - for (auto index : selectedIndexes()) { - if (index.isValid() && index.column() == 0) { - auto *treeItem = static_cast(index.internalPointer()); - if (auto *propertyItem = treeItem->asPropertyItem()) { - auto *citem = new CurveItem(treeItem->id(), propertyItem->curve()); - citem->setValueType(propertyItem->valueType()); - citem->setComponent(propertyItem->component()); - curves.push_back(citem); - } - } - } - - emit curvesSelected(curves); -} - QSize TreeView::sizeHint() const { return QSize(170, 300); diff --git a/src/plugins/qmldesigner/components/curveeditor/detail/treeview.h b/src/plugins/qmldesigner/components/curveeditor/detail/treeview.h index 4b53601739a..5cceb31bc5d 100644 --- a/src/plugins/qmldesigner/components/curveeditor/detail/treeview.h +++ b/src/plugins/qmldesigner/components/curveeditor/detail/treeview.h @@ -25,6 +25,8 @@ #pragma once +#include "selectionmodel.h" + #include namespace DesignTools { @@ -45,12 +47,12 @@ signals: public: TreeView(CurveEditorModel *model, QWidget *parent = nullptr); + SelectionModel *selectionModel() const; + void changeCurve(unsigned int id, const AnimationCurve &curve); void setStyle(const CurveEditorStyle &style); - std::vector selection(); - protected: QSize sizeHint() const override; diff --git a/src/plugins/qmldesigner/components/curveeditor/treeitem.cpp b/src/plugins/qmldesigner/components/curveeditor/treeitem.cpp index 4b66f96b56a..9c3f104a79c 100644 --- a/src/plugins/qmldesigner/components/curveeditor/treeitem.cpp +++ b/src/plugins/qmldesigner/components/curveeditor/treeitem.cpp @@ -246,6 +246,20 @@ QIcon NodeTreeItem::icon() const return m_icon; } +std::string toString(ValueType type) +{ + switch (type) { + case ValueType::Bool: + return "Bool"; + case ValueType::Integer: + return "Integer"; + case ValueType::Double: + return "Double"; + default: + return "Undefined"; + } +} + PropertyTreeItem::PropertyTreeItem(const QString &name, const AnimationCurve &curve, const ValueType &type) diff --git a/src/plugins/qmldesigner/components/curveeditor/treeitem.h b/src/plugins/qmldesigner/components/curveeditor/treeitem.h index b7873e22a7c..655672b6608 100644 --- a/src/plugins/qmldesigner/components/curveeditor/treeitem.h +++ b/src/plugins/qmldesigner/components/curveeditor/treeitem.h @@ -133,6 +133,8 @@ enum class ValueType { Double, }; +std::string toString(ValueType type); + class PropertyTreeItem : public TreeItem { public: diff --git a/src/plugins/qmldesigner/components/timelineeditor/animationcurvedialog.cpp b/src/plugins/qmldesigner/components/timelineeditor/animationcurvedialog.cpp index 08269f0a927..2c4fb147b04 100644 --- a/src/plugins/qmldesigner/components/timelineeditor/animationcurvedialog.cpp +++ b/src/plugins/qmldesigner/components/timelineeditor/animationcurvedialog.cpp @@ -56,9 +56,10 @@ void AnimationCurveDialog::setModel(DesignTools::CurveEditorModel *model) setLayout(layout); } -void AnimationCurveDialog::showEvent(QShowEvent *) +void AnimationCurveDialog::refresh() { - m_editor->clearCanvas(); + if (m_editor) + m_editor->clearCanvas(); } } // namespace QmlDesigner diff --git a/src/plugins/qmldesigner/components/timelineeditor/animationcurvedialog.h b/src/plugins/qmldesigner/components/timelineeditor/animationcurvedialog.h index a567adec78b..1bb20a31744 100644 --- a/src/plugins/qmldesigner/components/timelineeditor/animationcurvedialog.h +++ b/src/plugins/qmldesigner/components/timelineeditor/animationcurvedialog.h @@ -42,8 +42,7 @@ public: void setModel(DesignTools::CurveEditorModel *model); -protected: - void showEvent(QShowEvent *event) override; + void refresh(); private: DesignTools::CurveEditor *m_editor; diff --git a/src/plugins/qmldesigner/components/timelineeditor/timelinetoolbar.cpp b/src/plugins/qmldesigner/components/timelineeditor/timelinetoolbar.cpp index a233e19aadf..4c4e1e38f08 100644 --- a/src/plugins/qmldesigner/components/timelineeditor/timelinetoolbar.cpp +++ b/src/plugins/qmldesigner/components/timelineeditor/timelinetoolbar.cpp @@ -232,6 +232,7 @@ void TimelineToolBar::openAnimationCurveEditor() timeline = tlv->timelineForState(tlv->currentState()); } + m_dialog.refresh(); m_curveModel->setTimeline(timeline); m_dialog.show(); } diff --git a/src/plugins/qmldesigner/qmldesignerplugin.qbs b/src/plugins/qmldesigner/qmldesignerplugin.qbs index cc6443b52b2..466ff28a7aa 100644 --- a/src/plugins/qmldesigner/qmldesignerplugin.qbs +++ b/src/plugins/qmldesigner/qmldesignerplugin.qbs @@ -691,6 +691,8 @@ Project { "curveeditor/detail/playhead.h", "curveeditor/detail/selectableitem.cpp", "curveeditor/detail/selectableitem.h", + "curveeditor/detail/selectionmodel.cpp", + "curveeditor/detail/selectionmodel.h", "curveeditor/detail/selector.cpp", "curveeditor/detail/selector.h", "curveeditor/detail/shortcut.cpp",