- Include singletons in the list of sources (former sourceModelNodes)
- Do not suggest sources on bindings that are initialized without a
source node. Prevent constructs like
"property string p: button.qsTr("STREXPR3")".
- Allow changing the name of the target property and update the
delegate properly when doing so.
- Remove superfluous emitCurrentIndex emission from the
dynamicpropertiesmodel.
- Add missing qml imports.
Note that it is still possible to create illegal constructs if the user
wants to.
Change-Id: I084978f2f8d451df076d1b556db15764e17e31fb
Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
Simplified interface for the BindingModel and DynamicPropertiesModel.
Change-Id: I772f31be704afe2a43c6368aefab1b026b85ec8b
Reviewed-by: Qt CI Patch Build Bot <ci_patchbuild_bot@qt.io>
Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
* Ensure a "node" is added to the model if missing, for e.g. Singletons
* Expose targetNode of property
Change-Id: Ifbb131c1d6efaaceb15a6e630ce56023ace63311
Reviewed-by: Henning Gründl <henning.gruendl@qt.io>
Reviewed-by: Qt CI Patch Build Bot <ci_patchbuild_bot@qt.io>
This is still disabled by default until the UI gets polished.
Add roles to models. ConnectionModel, BindingModel and DynamicPropertiesModel.
In QML roles are used in the ListView to "mimic" columns. The columns are only
relevant for the "old" cpp QTableView and can be removed.
Making currentIndex part of the model. If rows are removed and added
again we have to "reset/keep" the currentIndex as part of the model, because
the index is temporarly invalid on the view.
Implementing DynamicPropertiesModelBackendDelegate as reference.
This is a pure "backend delegate" that exposes all relevant properties for
a current row to QML.
Adding StudioQuickWidget and exposing the backend.
Adding StudioQmlTextBackend and StudioQmlComboBoxBackend to
StudioQuickWidget (should be moved into their own files).
Those helper classes make is easy to expose a property to a combobox or
textfield. The backend has to know nothing about the actual frontend
and those classes act as a mini-model for a view in QML.
The API is similar to UI controls.
Change-Id: I7a2c6ad951306fbca1d586fb8f278acdd91a064b
Reviewed-by: Qt CI Patch Build Bot <ci_patchbuild_bot@qt.io>
Reviewed-by: Knud Dollereder <knud.dollereder@qt.io>
Also clean up DynamicPropertiesProxyModel and DynamicPropertiesModel
classes.
Change-Id: I40a2864c1ffbd555dfea9452cd55bbeb23e9fdfa
Reviewed-by: Miikka Heikkinen <miikka.heikkinen@qt.io>
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
Dynamic properties were sorted on initial open, but newly added
properties were just appended.
Fixes: QDS-9019
Change-Id: I20a47e3f3554274c794ee2cdea8b8c925c1c57fd
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
Since we also license under GPL-3.0 WITH Qt-GPL-exception-1.0,
this applies only to a hypothetical newer version of GPL, that doesn't
exist yet. If such a version emerges, we can still decide to relicense...
While at it, replace (deprecated) GPL-3.0 with more explicit GPL-3.0-only
Change was done by running
find . -type f -exec perl -pi -e "s/LicenseRef-Qt-Commercial OR GPL-3.0\+ OR GPL-3.0 WITH Qt-GPL-exception-1.0/LicenseRef-Qt-Commercial OR GPL-3.0-only WITH Qt-GPL-exception-1.0/g" {} \;
Change-Id: I5097e6ce8d10233993ee30d7e25120e2659eb10b
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
We've been requiring C++17 since Qt 6.0, and our qAsConst use finally
starts to bother us (QTBUG-99313), so time to port away from it
now.
Since qAsConst has exactly the same semantics as std::as_const (down
to rvalue treatment, constexpr'ness and noexcept'ness), there's really
nothing more to it than a global search-and-replace.
Task-number: QTBUG-99313
Change-Id: I88edd91395849574436299b8badda21bb93bea39
Reviewed-by: hjk <hjk@qt.io>
* States are now taken into account.
* If name is empty in expressionChanged(), then this
is just a notifier for the QML frontend and has to be ignored.
* When exposing the expression to QML we also have to take into
account states.
* Implementing resetting dynamic properties. We have to hardcode
the default values for the base state
* I also implemented the callbacks in the views for PropertyChanges.
Change-Id: I08247a3c1783a52853db7bf0f7f249520f7edc1c
Reviewed-by: Miikka Heikkinen <miikka.heikkinen@qt.io>
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
This removes dangling PropertyChanges and KeyFrameGroups when removing
a dynamic property.
Change-Id: I333b6a61bec34a0bcde1d19372166b3cfaea195b
Reviewed-by: Miikka Heikkinen <miikka.heikkinen@qt.io>
Added dynamic properties section to property editor and material
editor for all nodes. It shows all dynamic properties defined
for the node with proper editors for the supported types.
Dynamic properties can be added and removed via property editor
as well.
Material editor shows dynamic properties similarly.
Fixes: QDS-7411
Change-Id: Id195f5ca23d55544cea29eb8996690a7eed1cc57
Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
Reviewed-by: Mahmoud Badri <mahmoud.badri@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Replace the current license disclaimer in files by
a SPDX-License-Identifier.
Task-number: QTBUG-67283
Change-Id: I708fd1f9f2b73d60f57cc3568646929117825813
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
It has the advantage to to move the attribute to the declaration instead
of using a workaround.
Change-Id: I08b712f146a0625d0367657c31d6c1e5f7caec41
Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
Because the project storage is integer id based the string based API
isn't fitting well for the new approach. PropertyMetaInfo can be easier
mapped to the project storage.
Task-number: QDS-7197
Change-Id: I49bc650abdaacf4b039d76c2514b5ad05ec84abe
Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
We have to check if the view is actually detached.
Change-Id: I160c1a15f921092ef66999ed6a27ffcdbbe205d9
Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
When nodes are deleted the selection can changes without a notifier.
There is no reason to keep the selection separately.
Change-Id: I166d3695762e3d5cd6ff4808586384fd26bafef4
Reviewed-by: Miikka Heikkinen <miikka.heikkinen@qt.io>
- Allows user to select aliases in connections view
- Seeks signals for aliases
Task: QDS-2411
Change-Id: I69eb875eb99cbf8cd6a842d5f7e166d9990bb255
Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
- Binding Editor support for Binding Properties View
- Binding Editor support for Dynamic Properties View
- Small fix for Binding Editor comboboxes
Task: QDS-2164
Change-Id: I94da14ea97a16d40c5da0b21ff0e6f315f9e84a4
Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
Moved qmldesignerextension into component
Updated build systems
Change-Id: I8d2d0757a1639a472d426b66c0c8ae6fb84cc3d2
Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>