| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
|
|
| |
QQmlType is now refcounted, and we need to use it by
value, to control it's lifetime properly. This is
required, so we can clean up the QQmlMetaTypeData
cache on engine destruction and with trimComponentCache()
Task-number: QTBUG-61536
Change-Id: If86391c86ea20a646ded7c9925d8f743f628fb91
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
|
|
|
|
|
|
|
|
|
| |
Using nested types means we cannot forward declare them, which is
basically a prerequisite for using these classes anywhere else. As we
want to do that for QQmlTypeLoader, let's untangle the knot.
Change-Id: I05fff3521cda553965ae3368eb3731265bf46a9c
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
For example, the QML Engine is now able to locate QtQml.Models 2.x
in both of the following target/installation paths:
- QT_INSTALL_QML/QtQml/Models.2
- QT_INSTALL_QML/QtQml.2/Models
This is required for QtQuick Controls 2. The target path of the module
is QT_INSTALL_QML/QtQuick/Controls.2. The built-in styles are installed
as sub-directories to be able to locate them from the controls module.
Some of the built-in styles provide their own C++ extensions via style-
specific imports (eg. the Material attached property is imported from
QtQuick.Controls.Material 2.0). The problem is that the QML Engine does
not find the module from QT_INSTALL_QML/QtQuick/Controls.2/Material,
but requires it to be installed outside the main controls module ie.
QT_INSTALL_QML/QtQuick/Controls/Material(.2). This makes it a) hard to
locate the styles from the main controls module, and b) conflicts with
the target path of QtQuick Controls 1.
[ChangeLog][QtQml] Made the QML Engine capable of locating QML sub-
modules from within a versioned parent module path. For example,
QtQml.Models 2.x can be either in QT_INSTALL_QML/QtQml/Models.2 or
in QT_INSTALL_QML/QtQml.2/Models.
Change-Id: I2fe4bbdd6d04dd1e80cbe9b3e7e02617658a0756
Task-number: QTBUG-52556
Reviewed-by: J-P Nurmi <jpnurmi@qt.io>
Reviewed-by: Shawn Rutledge <shawn.rutledge@theqtcompany.com>
Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
|
|
|
|
|
|
|
|
|
|
|
| |
From Qt 5.7 -> LGPL v2.1 isn't an option anymore, see
http://blog.qt.io/blog/2016/01/13/new-agreement-with-the-kde-free-qt-foundation/
Updated license headers to use new LGPL header instead of LGPL21 one
(in those files which will be under LGPL v3)
Change-Id: Ic36f1a0a1436fe6ac6eeca8c2375a79857e9cb12
Reviewed-by: Lars Knoll <lars.knoll@theqtcompany.com>
|
|
|
|
|
|
|
|
| |
Composite singleton types used to always have version -1,-1; regardless
of what is written in qmldir.
Change-Id: Ia193e73695e57095f6a09b97768805f2f23cd56a
Reviewed-by: Erik Verbruggen <erik.verbruggen@theqtcompany.com>
|
|
|
|
|
|
|
|
|
| |
Qt copyrights are now in The Qt Company, so we could update the source
code headers accordingly. In the same go we should also fix the links to
point to qt.io.
Change-Id: I61120571787870c0ed17066afb31779b1e6e30e9
Reviewed-by: Iikka Eklund <iikka.eklund@theqtcompany.com>
|
|
|
|
|
|
|
|
| |
This allows QtQuick.Controls 1.x and 2.x imports to co-exist even
if they are two different plugins with the same module directive.
Change-Id: Idee302439e3c2fd6813ba2f41b69144fbae7902c
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This patch adds a property called "designersupported" to qmldir.
This allows the Qt Quick Designer to only load plugins that
have the line ""designersupported"" in their qmldir file.
So the designer can load sub components without risking to load
plugins that have never been tested in the designer and that might crash.
The check for "designersupported"" is activated by using
QQmlImports::setDesignerSupportRequired().
Change-Id: I4bf07cc163faa47996eacb1365a7961c51c51060
Reviewed-by: Thomas Hartmann <Thomas.Hartmann@digia.com>
Reviewed-by: Tim Jenssen <tim.jenssen@digia.com>
|
|
|
|
|
|
|
|
|
| |
- Renamed LICENSE.LGPL to LICENSE.LGPLv21
- Added LICENSE.LGPLv3 & LICENSE.GPLv2
- Removed LICENSE.GPL
Change-Id: I84a565e2e0caa3b76bf291a7d188a57a4b00e1b0
Reviewed-by: Jani Heikkinen <jani.heikkinen@digia.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This is among other things needed to fix the qml import scanner to detect
dependencies from .js files correctly.
The patch also fixes the use of Q_QML_EXPORT towards Q_QML_PRIVATE_EXPORT
where appropriate and corrects the wrong include path for the double conversion
code to actually be relative to the file it is included from. This worked by
accident because of other include paths present in the build.
Change-Id: I338583dad2f76300819af8ab0dae8e5724c84430
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
|
|
|
|
|
|
|
|
|
|
| |
What remains is the code for removing .pragma from script source code (and
replacing it with white-space to preserve line/column numbers). The previous
code even returned the value of the pragmas, but for the remaining caller sites
that value isn't used, so we can just return void.
Change-Id: I16db15da236970660b817d6c4493005365a7a1af
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
|
|
|
|
|
|
|
| |
Delete all the QmldirCache objects in the linked list
Change-Id: I9948ccce3d72aaed4f8b14b131e040177d7a15ef
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
When loading dynamic plugins, we register them as loaded so that
we don't try to register their types several times if using several
engines. The same was not done for static plugins. This patch
will ensure that we follow the same logic also for static
plugins.
Task-number: QTBUG-36532
Change-Id: Icc1e089ae5d682c38b2d36bf4808f1c753c122a4
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Up til now, QQmlImports would always assume module plugins are
dynamically linked, and as such, go looking for them on the file
system. This would fail for plugins linked in statically.
This patch will hook into QQmlImports at the place where it
iterates through all plugins in a qmldir and try to load them
dynamically. If some plugins cannot be resolved, we now do an
extra interation over static plugins to check if any
of them has the correct uri specified in their metadata.
Hooking into the loading process this late, will ensure that as
much code as possible is shared between dynamic and static plugin loading
so that setting up base urls, namespaces and guards will remain the same.
Note: this patch is one out of several patches that is needed to build
QML2 apps statically, and depends on plugins reporting their URI
through the plugin meta data system. This will be injected
automatically by qmake+moc.
Task-number: QTBUG-28357
Change-Id: If9a204e942ca7003448e188a1a47eec69b34c37b
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This introduces Singleton support for QML (Composite Singleton). For
now, the Singleton support is only availabe for QML types in modules
or (remote and local) directories with qmldir file. However, in the
future this support may be expanded to arbitrary QML file imports
without by leaving out the qmldir requirement.
You define a QML type as a Singleton with the following two steps:
1. By adding a pragma Singleton to a type's QML file:
pragma Singleton
The pragma and import statements can be mixed and their order does
not matter. Singleton is the only supported pragma for now. Others
will generate errors.
2. By specifying a qmldir file for the directory of your imported
type and prepending the type with "singleton" keyword as follows:
singleton TestTypeSingleton TestTypeSingleton.qml
Alternatively you may specify a qmldir file for a module and specify
your type as a singleton as follows:
singleton TestTypeSingleton 1.0 TestTypeSingleton.qml
Composite Singletons may be included in a module and may be used with
a local namespace qualifier when imported with:
"import xxx as NameSpace"
A singleton instance is created at first use and stored into the
QmlEngine (one instance per engine) and eventually released by the
engine's destructor.
CompositeSingletonType has a dual nature and will return true to both
isComposite() and isSingleton() calls. In most cases its enough to
check for just isComposite() or isSingleton(). However, there is a
isCompositeSingleton() available as well.
I used "qlalr --no-debug --no-lines --qt qqmljs.g" to generate the
qqmljsparser and qqmljsgrammar files from qqmljs.g.
Unit tests are included.
Change-Id: I91b303612c5e132143b325b9a8f982e9355bc90e
Reviewed-by: Alan Alpert (Personal) <416365416c@gmail.com>
|
|
|
|
|
|
|
|
|
|
|
| |
Registered types are stored in a global static variable, not on an
engine instance. For applications managing multiple engines over their
lifetime, there needs to be a way to clear the existing types so they
can register new ones and avoid memory leaks.
Task-Number: QTBUG-28572
Change-Id: Ic70a4dd1e29d99399b21fb42eaf10d4a52bf2adf
Reviewed-by: Christopher Adams <chris.adams@jollamobile.com>
|
|
|
|
|
|
|
|
|
| |
When a composite type is loaded from a QML file, it now generates a
QQmlType entry in QQmlMetaTypeData.
Change-Id: I9b127dff7955456aacb25138fa6ea8efb7bb9221
Reviewed-by: Christopher Adams <chris.adams@jollamobile.com>
Reviewed-by: Alan Alpert <aalpert@rim.com>
|
|
|
|
|
|
| |
Change-Id: I6c3bd7bebe3d62d1cfd0fa6334544c9db8398c76
Reviewed-by: Akseli Salovaara <akseli.salovaara@digia.com>
Reviewed-by: Sergio Ahumada <sergio.ahumada@digia.com>
|
|
|
|
|
|
|
| |
Change copyrights and license headers from Nokia to Digia
Change-Id: Ie7f5d49ed8235d7a7845ab68f99ad1c220e64d5c
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
|
|
|
|
|
|
|
|
|
|
|
| |
Previously each singleton type was registered as an implicit separate
import. This commit changes the code so that these types are treated
just like any other type in the registration sense.
It also ensures that singleton types are instantiated per-engine.
Change-Id: I5c81c4ca5bf65210f7125d74a62a282a21838068
Reviewed-by: Matthew Vogt <matthew.vogt@nokia.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Allow a module's qmldir to contain a module directive, which when
present specifies 'strict mode' import processing. In strict mode,
type registrations are only permitted into the namespace identified
in the qmldir file's module directive. In addition, any type
registrations to that namespace originating from other modules are
treated as error conditions.
Task-number: QTBUG-26551
Change-Id: I081bde2d3b83d3f28524440177fb2cd1ccee34ad
Reviewed-by: Chris Adams <christopher.adams@nokia.com>
Reviewed-by: Roberto Raggi <roberto.raggi@nokia.com>
|
|
|
|
|
|
|
|
|
|
|
| |
Probe for installed modules in import path elements which are not local
to the machine. Note that all local paths in the import path list will
be tried before any remote locations are probed.
Task-number: QTBUG-21386
Change-Id: I4f7b9e54e54c1d62a5e7cb7f059ee1e9319ef054
Reviewed-by: Chris Adams <christopher.adams@nokia.com>
|
|
|
|
|
|
|
|
|
| |
Reduce library load time by removing any exports which are not required
by existing clients.
Task-number: QTBUG-24768
Change-Id: Ia5754d6f97bb2ed46e290820a5b092f85a4bc5b0
Reviewed-by: Martin Jones <martin.jones@nokia.com>
|
|
|
|
|
|
|
| |
Faster qmlType() and resolveType() lookup.
Change-Id: I096439f23bf6071e8bfdf0cda366cc71e00293ba
Reviewed-by: Aaron Kennedy <aaron.kennedy@nokia.com>
|
|
|
|
|
| |
Change-Id: Iecbd5c46af00f649b1f1d78cdf5f2b40a2844897
Reviewed-by: Roberto Raggi <roberto.raggi@nokia.com>
|
|
|
|
|
| |
Change-Id: I095249f64ecf4ef1e3fbfb164e3d50edffab61e8
Reviewed-by: Roberto Raggi <roberto.raggi@nokia.com>
|
|
|
|
|
|
|
|
|
| |
When a module exports functionality provided by a script, ensure
that imported script modules inside that script resolve correctly.
Task-number: QTBUG-24596
Change-Id: I3885dcc56946423f0d7cf00afdcdfaa0cb11967a
Reviewed-by: Chris Adams <christopher.adams@nokia.com>
|
|
Symbols beginning with QDeclarative are already exported
by the quick1 module.
Users can apply the bin/rename-qtdeclarative-symbols.sh
script to modify client code using the previous names of the
renamed symbols.
Task-number: QTBUG-23737
Change-Id: Ifaa482663767634931e8711a8e9bf6e404859e66
Reviewed-by: Martin Jones <martin.jones@nokia.com>
|