Hi,
If Script { source: "a.js" } works for you without any warnings it is because
you are using an old build.
In the latest code, available from http://qt.gitorious.org, we support the
import "a.js" as A syntax. For the time being we are also still supporting the
Script{} tag to give people time to port their code. The latest builds of QML
will output a warning if you use the Script{} tag instructing you to update
your files.
The final 4.7 release will only support the import syntax.
Cheers,
Aaron
On 14/04/10 6:19 PM, "ext Jack Wootton" <[email protected]> wrote:
Script { source: "a.js" }
works for me. Is this because of the "overlap" that's been mentioned or is it
because i'm using a version of Qt that doesn't implement the "import" method?
I'm using 4.7.0 snapshot built form source, downloaded from
http://qt.nokia.com/developer/qt-qtcreator-prerelease#download
On Wed, Apr 14, 2010 at 6:13 AM, <[email protected]> wrote:
> Did the older versions of QML support importing of js files that way
> (import "a.js" as Misc)? I know the old { Script: a.js } way of
> including js files doesn't work anymore, was that replaced with the
> new way, or were both always an option?
The import way replaced the Script{} way, with some overlap.
--
Warwick
_______________________________________________
Qt-qml mailing list
[email protected]
http://lists.trolltech.com/mailman/listinfo/qt-qml
_______________________________________________
Qt-qml mailing list
[email protected]
http://lists.trolltech.com/mailman/listinfo/qt-qml