Christian Kamm
9ea0380a4d
QmlJS: Enforce Context always being linked.
...
The default way of creating a Context is through Link.
Change-Id: Ia81f7ce90ba2b33d02eed432a61be836d404bedd
Reviewed-on: http://codereview.qt.nokia.com/1041
Reviewed-by: Fawzi Mohamed <fawzi.mohamed@nokia.com >
2011-07-05 11:52:09 +02:00
Christian Kamm
8b778b266b
QmlJS: Rename Interpreter::Engine -> ValueOwner
...
Also move to a separate file.
Change-Id: I05910e8cf04a533b5d09a1c16e612e3b99b1d606
Reviewed-on: http://codereview.qt.nokia.com/1039
Reviewed-by: Fawzi Mohamed <fawzi.mohamed@nokia.com >
2011-07-05 08:44:16 +02:00
Christian Kamm
a7f4e5fab5
QmlJS: Separate imported types and imported JS scopes.
...
Task-number: QTCREATORBUG-4981
Change-Id: I06d3e428ca4928296a3d5977aeff29fc3217c37c
Reviewed-on: http://codereview.qt.nokia.com/175
Reviewed-by: Fawzi Mohamed <fawzi.mohamed@nokia.com >
2011-05-27 11:48:53 +02:00
Christian Kamm
cf15e14e5e
QmlJS: Add tooltips to imports.
...
Task-number: QTCREATORBUG-4814
2011-05-12 15:29:41 +02:00
Christian Kamm
d0b12f8f19
QmlJS: Remove unused argument for Link helper function.
2011-05-11 09:13:13 +02:00
Friedemann Kleint
ddf4b613f3
Krazy fixes (spelling, single char strings, char constants).
2011-05-10 15:21:41 +02:00
Tobias Hunger
aa2acec14c
Fix/add copyright headers
...
Change-Id: I8b73d583be1ee7183f4074bce49d5390e38631a2
2011-05-06 15:17:05 +02:00
Christian Kamm
d05992d0fa
QmlJS: Stop doing significant work in constructors.
...
To avoid order-of-initialization problems.
Reviewed-by: Thomas Hartmann
2011-05-06 13:48:55 +02:00
Christian Kamm
c504d28eb5
QmlJS: Add semantic errors to task window.
...
Task-number: QTCREATORBUG-4103
Reviewed-by: Leandro Melo
2011-04-21 11:16:50 +02:00
hjk
8397663964
Update license.
2011-04-13 11:49:28 +02:00
Erik Verbruggen
7b25f438c6
Fixed import of "." in a library with a hack.
...
Task-number: QTCREATORBUG-4198
Reviewed-by: Kai Koehne
2011-04-06 10:49:27 +02:00
Christian Kamm
b980a9b964
QmlJS: Fix implicit "." import when . has a QML module.
...
Reviewed-by: Erik Verbruggen
2011-03-10 15:03:36 +01:00
Christian Kamm
aeb8c352ee
QmlJS: Try to implicitly import libraries in the same directory.
...
In QML, the current directory that holds a QML file is imported
implicitly. If it contains a qmldir file, the library is imported.
Since there is no explicit import statement, Creator can't know the URI
of this library. However, if type information is available for it
already - either through a previous dump or a qmltypes file - we can
guess the URI by looking at the contained exports.
Task-number: QTCREATORBUG-3768
2011-02-25 16:23:12 +01:00
Friedemann Kleint
a9a5e3ea17
Exported header cleanup.
2011-01-20 14:03:07 +01:00
con
d1023c7614
It's 2011 now.
...
Reviewed-by: hjk
2011-01-12 09:46:24 +01:00
con
b1bcf081d8
Merge branch '2.1'
...
Conflicts:
src/plugins/coreplugin/basemode.cpp
src/plugins/coreplugin/basemode.h
src/plugins/coreplugin/scriptmanager/qworkbench_wrapper.cpp
src/plugins/coreplugin/scriptmanager/qworkbench_wrapper.h
src/plugins/debugger/cdb/cdbsymbolpathlisteditor.cpp
src/plugins/debugger/debuggeragents.cpp
src/plugins/debugger/debuggeruiswitcher.cpp
src/plugins/debugger/debuggeruiswitcher.h
src/plugins/projectexplorer/buildconfigdialog.cpp
src/plugins/qmldesigner/components/propertyeditor/colorwidget.cpp
src/plugins/qmldesigner/components/propertyeditor/colorwidget.h
src/plugins/qmldesigner/designercore/include/enumeratormetainfo.h
src/plugins/qmldesigner/designercore/include/modelutilities.h
src/plugins/qmldesigner/designercore/include/nodeinstance.h
src/plugins/qmldesigner/designercore/include/propertymetainfo.h
src/plugins/qmldesigner/designercore/instances/graphicsscenenodeinstance.cpp
src/plugins/qmldesigner/designercore/instances/graphicsscenenodeinstance.h
src/plugins/qmldesigner/designercore/instances/graphicsviewnodeinstance.cpp
src/plugins/qmldesigner/designercore/instances/graphicswidgetnodeinstance.cpp
src/plugins/qmldesigner/designercore/instances/graphicswidgetnodeinstance.h
src/plugins/qmldesigner/designercore/instances/nodeinstance.cpp
src/plugins/qmldesigner/designercore/instances/qmlviewnodeinstance.cpp
src/plugins/qmldesigner/designercore/instances/widgetnodeinstance.cpp
src/plugins/qmldesigner/designercore/instances/widgetnodeinstance.h
src/plugins/qmldesigner/designercore/metainfo/enumeratormetainfo.cpp
src/plugins/qmldesigner/designercore/metainfo/propertymetainfo.cpp
src/plugins/qmldesigner/designercore/model/modelutilities.cpp
src/plugins/snippets/inputwidget.cpp
src/plugins/snippets/snippetscompletion.cpp
src/plugins/snippets/snippetscompletion.h
src/plugins/snippets/snippetspec.cpp
src/plugins/snippets/snippetsplugin.cpp
src/plugins/snippets/snippetswindow.cpp
src/plugins/snippets/snippetswindow.h
src/plugins/texteditor/snippetsparser.cpp
src/tools/qml/qmldom/main.cpp
tests/manual/trk/runner.cpp
tests/manual/trk/trkolddevice.cpp
tests/manual/trk/trkolddevice.h
tests/manual/trk/trkserver.cpp
2010-12-17 17:00:53 +01:00
con
04e32b0049
License headers.
2010-12-17 16:03:42 +01:00
Christian Kamm
5dd92328fb
QmlJS: Improve error reporting for failed plugin dumps.
...
Reviewed-by: Erik Verbruggen
2010-11-25 15:06:44 +01:00
Christian Kamm
3f505e9982
QmlJS: Add initial 'Find Usages' support.
2010-09-24 14:11:06 +02:00
Christian Kamm
c7b3e3c81c
QmlJS: Speed up Link significantly, provide more info on imports.
...
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.
2010-09-16 15:51:21 +02:00
Christian Kamm
6ee1027eaa
Add missing license headers.
2010-07-09 15:47:25 +02:00
Christian Kamm
da6b372575
QmlJS: Move Q_DECLARE_TR_FUNCTIONS to the start of class declarations.
...
The documentation requires having it there.
2010-05-19 13:42:56 +02:00
Christian Kamm
50cc55af80
QmlJS: Change to a nicer way of marking strings for translation.
...
Reviewed-by: ossi
2010-05-19 13:32:11 +02:00
Christian Kamm
3286f48504
QmlJS: Remove Link::scopeChainAt, initialize scope chain in constructor.
...
Use ScopeBuilder.push(...) for the same functionality.
Reviewed-by: Erik Verbruggen
2010-04-22 16:36:43 +02:00
Christian Kamm
49416fe888
QmlJS: Add a path->document list hash to Snapshot.
...
Also change the filename->document map to a hash.
Reviewed-by: Roberto Raggi
2010-04-01 11:28:56 +02:00
Erik Verbruggen
21e1db4b5b
Exported classes to use in the QML designer.
2010-03-31 10:03:18 +02:00
Christian Kamm
285e2ffbb2
QmlJS: Only collect linker errors for the current file being checked.
...
Avoids bug where import errors would show up in all files.
Reviewed-by: Roberto Raggi
2010-03-29 11:33:25 +02:00
Christian Kamm
dab558d4fe
Add errors for incorrect imports in Qml.
...
Task-number: QTCREATORBUG-874
Reviewed-by: Erik Verbruggen
2010-03-25 14:55:44 +01:00
Christian Kamm
9ea01cf5fb
Improve Qml code model import handling.
...
* Fill the snapshot with files that could be imported.
* Implement package imports.
* The qmldir file is not parsed yet.
Reviewed-by: Erik Verbruggen
2010-03-18 11:25:37 +01:00
Christian Kamm
08cfc8f28c
Pass in the whole AST path for scope creation.
...
Just the declaring member isn't enough.
2010-02-22 10:22:23 +01:00
Christian Kamm
c289897351
Make QmlJS scope building more flexible.
...
Instead of only maintaining a flat list of scopes, actually store the
global, component chain, root object, scope object, function, id and js
scopes separately.
2010-02-22 10:22:23 +01:00
Christian Kamm
2b1adbf610
Improve building of the Qml/JS scope chain.
...
* For JS files: Add each Qml component that sources the file in a Script
tag to the scope chain.
* For Qml components: Add each component that instantiates the component
to the scope chain.
* Generate the full list of documents required for completion in a
given file. Previously, files that included the file were missing.
2010-02-11 19:08:33 +01:00
Christian Kamm
25e04d8ef1
Make QmlJS::Link private. Use Context::build to set up a context.
2010-02-04 10:34:49 +01:00
Christian Kamm
e984691fe6
Fix prototype reference resolution for Qml objects.
2010-02-04 10:34:49 +01:00
Roberto Raggi
fcf81b22ed
Get rid of BindPtr.
...
There is no reason to store the Bind object in a QSharedPointer because the `binder' has the same
lifetime of its document.
2010-02-03 15:59:15 +01:00
Roberto Raggi
976d74ca73
Add support for lazy prototypes.
...
Done-with: ckamm
2010-02-03 15:42:32 +01:00
Roberto Raggi
1f0b717ad2
Completion for global variables in JS.
...
* Support for lookup JS vs Qml
* Bind global variables.
Done-with: ckamm
2010-02-03 14:34:06 +01:00
Christian Kamm
49c43aaab1
Get rid of Environment, introduce external ScopeChain in Link.
...
Done-with: Roberto
2010-02-03 10:59:52 +01:00
Roberto Raggi
ba18e70034
Introduced QML/JS references.
...
Done with ckamm
2010-02-03 10:24:25 +01:00
Roberto Raggi
95849cb0bd
Store bindings and definitions in one single table.
2010-02-03 09:34:28 +01:00
Roberto Raggi
14ffb1e465
Some refactoring needed to create ranges for JavaScript functions.
2010-02-02 16:36:14 +01:00
Christian Kamm
03fa188b41
Bind each QML document after parsing. Link them before use.
...
Reviewed-by: Roberto Raggi <roberto.raggi@nokia.com >
2010-02-02 16:03:43 +01:00
Christian Kamm
1d39377fb1
Separate bind into bind, link imports and building the scope chain.
2010-01-28 14:53:53 +01:00