diff options
author | Thomas Hartmann <Thomas.Hartmann@digia.com> | 2013-04-02 12:27:45 +0200 |
---|---|---|
committer | Thomas Hartmann <Thomas.Hartmann@digia.com> | 2013-04-02 14:32:09 +0200 |
commit | bb1a76c0a475186103d2276667403dfe18d38788 (patch) | |
tree | 6d64bcaea2a5dfd12be1594a2216d0f81af8a0e2 /src/plugins/qmldesigner/designercore/include/forwardview.h | |
parent | d5e41c08f54bc2ffaff73041290468eb8a4ea92c (diff) |
QmlDesigner.Model: Adding SignalHandlerProperty
SignalHandlerProperty allows editing convenient editing of signal
handlers like onMousePress in the model.
The interface is analogous to BindingProperty.
Since mos views do not care about SignalHandlerProperties and
they should not be mixed up with BindingProperties they are different
types.
I also added the signalHandlerPropertiesChanged() notifier to AbstractView.
Change-Id: I68bc7d2c5d3b991944e8f8d698212a1dfef218bf
Reviewed-by: Marco Bubke <marco.bubke@digia.com>
Diffstat (limited to 'src/plugins/qmldesigner/designercore/include/forwardview.h')
-rw-r--r-- | src/plugins/qmldesigner/designercore/include/forwardview.h | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/src/plugins/qmldesigner/designercore/include/forwardview.h b/src/plugins/qmldesigner/designercore/include/forwardview.h index 82b4398aca..7ebd6ca67d 100644 --- a/src/plugins/qmldesigner/designercore/include/forwardview.h +++ b/src/plugins/qmldesigner/designercore/include/forwardview.h @@ -62,6 +62,7 @@ public: void propertiesRemoved(const QList<AbstractProperty>& propertyList); void variantPropertiesChanged(const QList<VariantProperty>& propertyList, PropertyChangeFlags propertyChange); void bindingPropertiesChanged(const QList<BindingProperty>& propertyList, PropertyChangeFlags propertyChange); + void signalHandlerPropertiesChanged(const QVector<SignalHandlerProperty>& propertyList,PropertyChangeFlags propertyChange); void rootNodeTypeChanged(const QString &type, int majorVersion, int minorVersion); void selectedNodesChanged(const QList<ModelNode> &selectedNodeList, @@ -185,6 +186,12 @@ void ForwardView<ViewType>::bindingPropertiesChanged(const QList<BindingProperty view->bindingPropertiesChanged(adjustedList(propertyList, view.data()), propertyChange); } +void ForwardView::signalHandlerPropertiesChanged(const QVector<SignalHandlerProperty> &propertyList, AbstractView::PropertyChangeFlags propertyChange) +{ + foreach (const ViewTypePointer &view, m_targetViewList) + view->signalHandlerPropertiesChanged(adjustedList(propertyList, view.data()), propertyChange); +} + template <class ViewType> void ForwardView<ViewType>::rootNodeTypeChanged(const QString &type, int majorVersion, int minorVersion) { |