The newline made the linizer add an automatic semicolon after Item,
causing the completion context finder to not recognize it as an object
definition.
Task-number: QTCREATORBUG-2658
Reviewed-by: Roberto Raggi
qtLibraryTarget is only defined if used with TEMPLATE=lib, which makes
it fail in pri files that are used for app pro files. The tests still
don't run because of run time linking issues.
The detection of whether a type or one of its children is exported was
broken when we fixed the type information for the QtQuick module.
Reviewed-by: Erik Verbruggen
In order to determine all components that instantiate a given component,
Bind::usesQmlPrototype was called on each document in the snapshot.
That, in turn, had to iterate over all object definitions inside the
document, resolving their prototype references.
All in all, it lead to a very large amount of fairly expensive lookups
that were slowing down Creator considerably.
Reviewed-by: Erik Verbruggen
Make sure that the 'artifical' URL of the item created actually is
absolute (starts with a file:///). Otherwise an Assert will be hit
when the imports include e.g. a .js file, and the Engine tries to
load it.
Task-number: QTCREATORBUG-2644
Reviewed-by: Olivier Goffart
This is the name that other components will refer to it by. For
instance, MouseArea has a 'drag' property with type 'QDeclarativeDrag',
since QDeclarativeDrag was only exported as Qt.Drag and QtQuick.Drag,
the type lookup didn't manage to resolve the name.
(cherry picked from commit b53ba61248)
Moved qmljsdebugger to a dir under qml/, made qmlobserver compile
without creator dependencies and made it compile with debugging
helpers.
Reviewed-by: hjk
When multiple threads share the Bind instance in a Document and do
lookup on the objects contained inside, that may trigger a new object
creation in some situations - which needs to be synchronized.
Link now caches imports. That means importing the same library (say, Qt)
from more than one file no longer creates an importing namespace for
each one. Instead, a single one is created for the instance of Link.
To make this work, the type environment in ScopeChain has been given its
own type: Interpreter::TypeEnvironment. That has the added benefit of
being able to carry meta-information about imports. You can use
TypeEnvironment::importInfo(qmlComponentName) to get information about
the import node that caused the import of the component.
Now that Contexts are cached, it needs to be copyable. However, the
ScopeChain has a QmlComponentChain member that owns resources and didn't
have a correct copy constructor or copy assignment operator.
I've made QmlComponentChain non-copyable and store a shared pointer to
an instance instead, as it will generally not change for a given
context.
Reviewed-by: Lasse Holmstedt