Qmljs now keeps a cache of parsed qrc files, and can resolve "qrc:" links.
This breaks the assumption that the name that the qml files has on
the filesystem is the one that qml sees, and that contents of
directories can be found just looking at file whose path starts with the
directory path.
Currently the first file is used when multiple qrc files contain the same
path, but support for strict and weak path resolving is already there.
At the moment only qrc files for projects that call updateQmljsCodeModel
are updated.
ChangeLog: QmljsSupport: Imports using qrc links are resolved.
Task-number: QTCREATORBUG-8953
Change-Id: I695fac2692af2417d49c192c580a1c2e7b4873f4
Reviewed-by: Fawzi Mohamed <fawzi.mohamed@digia.com>
src/plugins and src/libs are included by qtcreator.pri
Change-Id: I15ec19856366661bfa74d00e6278f4eb3854acb2
Reviewed-by: Tobias Hunger <tobias.hunger@digia.com>
Reviewed-by: Eike Ziller <eike.ziller@digia.com>
numerous "3rdparty" libraries have respective #ifdefs, and consequently
the define is added in several places. it's quite a mess with the .pr?
and .qbs files, though. solve the problem by sidestepping it.
Change-Id: I5a6b1ba7cfe96b44f0a4f4ef9738900906a44316
Reviewed-by: Tobias Hunger <tobias.hunger@digia.com>
Reviewed-by: Eike Ziller <eike.ziller@digia.com>
Add a presistent trie to store imports, and provide a better (IMHO)
completion algorithm.
The trie is quite generic and it might be worth while to move it to utils.
Change-Id: I4081346af6215b1ee8ff14bd063c2a021d7c8218
Reviewed-by: Thomas Hartmann <Thomas.Hartmann@digia.com>
qt5 needs a QGuiApp to access fonts (as TextDocument does).
Change-Id: I2779501532ada817dc22f48b5eb9f5af1bb9c3aa
Reviewed-by: Christian Kamm <kamm@incasoftware.de>
Reviewed-by: Erik Verbruggen <erik.verbruggen@digia.com>
* indent expressions (like function defs) in if condition
fixes QTCREATORBUG-7243
Change-Id: I61197317a8dcba72a45b660600711748e2e2b962
Reviewed-by: Christian Kamm <kamm@incasoftware.de>
Reviewed-by: Erik Verbruggen <erik.verbruggen@digia.com>
We export the core functionality of the model allowing
other plugins to use it.
The general functionality was already there, but I had
to rename the macro to avoid name clashes.
Also I renamed the .pri file to avoid confusion.
Change-Id: I88203ce9dbfddc8d734e5e232ff71bc0e244e5b8
Reviewed-by: Marco Bubke <marco.bubke@digia.com>
SimpleReader is a !simple! parser for json like qml files.
SimpleReader only parses literal properties for e.g. configuration
files.
SimpleAbstractStreamReader allows event based parsing and SimpleReader
stores the parsed data in a reference counted tree structure.
Change-Id: I0f6422a97f5c356149c516f227f8bbd7b736a6d0
Reviewed-by: Joerg Bornemann <joerg.bornemann@digia.com>
This corrects commit 112f80. $$QTESTLIB is not needed since both Qt4 and
Qt5 support "QT += testlib".
Change-Id: I776b44825295c86d2d85e9b8dc6a422da6f36ab6
Reviewed-by: Christian Stenger <christian.stenger@digia.com>
"Project WARNING: CONFIG+=qtestlib is deprecated. Use QT+=testlib
instead."
Change-Id: Ia6dcce078736cac0f0b05e0f621a25f97c9dac87
Reviewed-by: Christian Stenger <christian.stenger@digia.com>
Version numbers were not respected in all cases in the meta system.
If we (just) have a QtQuick 2.0 import Rectangle 1.0 is not valid.
Also adding a test.
Change-Id: I2e1dc174aaa180ad1750f0eca04c6879ef6e304d
Reviewed-by: Marco Bubke <marco.bubke@digia.com>
Attaching a second RewriterView is not allowed.
Change-Id: I54055b36f86cd1cff0313edfd405c128c5783705
Reviewed-by: Thomas Hartmann <Thomas.Hartmann@digia.com>
We have to process events to ensure that the correct
data is actually delivered by qmlpuppet.
Change-Id: I5a8b18d20ced5c7b9279868c53fbee698a752b74
Reviewed-by: Thomas Hartmann <Thomas.Hartmann@digia.com>
Image does not exist have a revision 1.1.
Change-Id: I012cf4e3636239665b45369717fba8c3c61c0352
Reviewed-by: Thomas Hartmann <Thomas.Hartmann@digia.com>
This header file is not needed and was moved
by recent refactoring.
Change-Id: I0899de93be4e6f03c42d94e128feaa203a12063d
Reviewed-by: Thomas Hartmann <Thomas.Hartmann@digia.com>
Basic test for Qt Quick 2.0.
This time using Rectangle (different prototype chain).
Change-Id: I5500fa5d1a6e2d049404944be81f0b5657cefe3c
Reviewed-by: Thomas Hartmann <Thomas.Hartmann@digia.com>
Fixing a regression in the meta info system.
We follow now Qthe Declarative1StateOperation convention (note the 1).
Since this data is provided by Qt Creator it is independent from any Qt
version. (4.8/5.1)
Also the type comparison was broken in NodeMetaInfo for <cpp> types.
PackageName() does retrieve the package name of the cpp type which might
be different from the one used in qualfiedTypeName().
Change-Id: I5cdae37c2024cdc89824e68168c16e2050051d06
Reviewed-by: Marco Bubke <marco.bubke@digia.com>
This is needed process all the events created by NodeInstanceView.
Change-Id: Ia2df51f5aafdc670e60a47064092123a1a100049
Reviewed-by: Marco Bubke <marco.bubke@digia.com>
Attaching more then one rewriter is not a good idea.
Change-Id: I3ec000836dc21029b43003c4636927086f267d10
Reviewed-by: Marco Bubke <marco.bubke@digia.com>
We have to respect the meta info. So we create a Flipable.
Change-Id: I427cce93e1cb6fea7ac1c70b0c1020234af3494d
Reviewed-by: Marco Bubke <marco.bubke@digia.com>
Error {} was not an Error anymore since we ignore unknown types.
Rectangle does not have the property test. This triggers an error.
Change-Id: I838b12ba15c394a34f6f9176e5eb5826d54b0f2b
Reviewed-by: Marco Bubke <marco.bubke@digia.com>
We have to respect the meta info. "test" is replaced by
"acnhors.fill" for that reason.
Change-Id: I7b3c9784de0d9d5cbaf2cd811ebb427ffbbf4b70
Reviewed-by: Marco Bubke <marco.bubke@digia.com>
Qt 4.7 is no more. The test was broken for the alias import.
Change-Id: Ia642907802d03d379d6ea3bdeb9745241b6bc7fc
Reviewed-by: Marco Bubke <marco.bubke@digia.com>
We do not set the size of the root item to 100x100.
Since "out of process" the instanceValue of a node has no specfic
meaning anymore.
Change-Id: I953fb32816548a74631fcee8ae50a550514758c0
Reviewed-by: Marco Bubke <marco.bubke@digia.com>
Without qtcreator\plugins\Nokia\ in the path the plugin .dlls
are not found (qmljstools).
Change-Id: If63e6350d8b2e10cc754b914246031dcce47d2bb
Reviewed-by: Marco Bubke <marco.bubke@digia.com>