summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--demos/declarative/calculator/CalcButton.qml10
-rw-r--r--demos/declarative/phonebrowser/content/LikeOMeter.qml6
-rw-r--r--demos/declarative/phonebrowser/content/MediaButton.qml9
-rw-r--r--demos/declarative/phonebrowser/content/PhoneInfoContainer.qml19
-rw-r--r--demos/declarative/phonebrowser/content/ScrollBar.qml5
-rw-r--r--demos/declarative/phonebrowser/content/Star.qml12
-rw-r--r--demos/declarative/phonebrowser/phonebrowser.qml2
-rw-r--r--demos/declarative/webbrowser/webbrowser.qml30
-rw-r--r--doc/src/declarative/animation.qdoc4
-rw-r--r--doc/src/declarative/binding.qdoc8
-rw-r--r--doc/src/declarative/effects.qdoc10
-rw-r--r--doc/src/declarative/elements.qdoc47
-rw-r--r--doc/src/declarative/index.qdoc51
-rw-r--r--doc/src/declarative/qmlfordesign.qdoc42
-rw-r--r--doc/src/declarative/qtdeclarative.qdoc93
-rw-r--r--doc/src/declarative/tutorial.qdoc2
-rw-r--r--doc/src/declarative/tutorial1.qdoc37
-rw-r--r--doc/src/declarative/tutorial2.qdoc106
-rw-r--r--doc/src/declarative/tutorial3.qdoc126
-rw-r--r--doc/src/index.qdoc2
-rw-r--r--doc/src/modules.qdoc1
-rw-r--r--doc/src/snippets/qprocess-environment/main.cpp2
-rw-r--r--doc/src/tutorials/declarative.qdoc8
-rw-r--r--examples/declarative/contacts/main.cpp6
-rw-r--r--examples/declarative/dial/DialLibrary/Dial.qml8
-rw-r--r--examples/declarative/follow/pong.qml8
-rw-r--r--examples/declarative/listview/content/MediaButton.qml9
-rw-r--r--examples/declarative/listview/recipes.qml7
-rw-r--r--examples/declarative/minehunt/Description.qml4
-rw-r--r--examples/declarative/minehunt/Explosion.qml7
-rw-r--r--examples/declarative/minehunt/main.cpp4
-rw-r--r--examples/declarative/minehunt/minehunt.qml14
-rw-r--r--examples/declarative/scrollbar/ScrollBar.qml14
-rw-r--r--examples/declarative/slideswitch/Switch.qml7
-rw-r--r--examples/declarative/tutorials/contacts/1_Drawing_and_Animation/GroupBox.qml10
-rw-r--r--examples/declarative/tutorials/contacts/2_Reuse/3/Contact.qml1
-rw-r--r--examples/declarative/tutorials/contacts/2_Reuse/3/RemoveButton.qml2
-rw-r--r--examples/declarative/tutorials/helloworld/t1/tutorial1.qml (renamed from examples/declarative/tutorials/t1/tutorial1.qml)0
-rw-r--r--examples/declarative/tutorials/helloworld/t2/Cell.qml (renamed from examples/declarative/tutorials/t3/Cell.qml)6
-rw-r--r--examples/declarative/tutorials/helloworld/t2/tutorial2.qml27
-rw-r--r--examples/declarative/tutorials/helloworld/t3/Cell.qml (renamed from examples/declarative/tutorials/t2/Cell.qml)5
-rw-r--r--examples/declarative/tutorials/helloworld/t3/tutorial3.qml (renamed from examples/declarative/tutorials/t3/tutorial3.qml)39
-rw-r--r--examples/declarative/tutorials/t2/tutorial2.qml41
-rw-r--r--examples/declarative/velocity/Day.qml10
-rw-r--r--examples/declarative/webview/content/SpinSquare.qml11
-rw-r--r--src/3rdparty/easing/legal.qdoc2
-rw-r--r--src/corelib/animation/qabstractanimation.cpp2
-rw-r--r--src/corelib/animation/qanimationgroup.cpp2
-rw-r--r--src/corelib/animation/qparallelanimationgroup.cpp2
-rw-r--r--src/corelib/animation/qpauseanimation.cpp2
-rw-r--r--src/corelib/animation/qpropertyanimation.cpp2
-rw-r--r--src/corelib/animation/qsequentialanimationgroup.cpp2
-rw-r--r--src/corelib/animation/qvariantanimation.cpp2
-rw-r--r--src/corelib/kernel/qcoreevent.cpp2
-rw-r--r--src/declarative/extra/qmlsqlconnection.cpp45
-rw-r--r--src/declarative/extra/qmlsqlquery.cpp34
-rw-r--r--src/declarative/extra/qmlxmllistmodel.cpp2
-rw-r--r--src/declarative/fx/qfxanchors.cpp4
-rw-r--r--src/declarative/fx/qfxanimatedimageitem.cpp4
-rw-r--r--src/declarative/fx/qfxblurfilter.cpp35
-rw-r--r--src/declarative/fx/qfxcomponentinstance.cpp6
-rw-r--r--src/declarative/fx/qfxcontentwrapper.cpp41
-rw-r--r--src/declarative/fx/qfxevents.cpp33
-rw-r--r--src/declarative/fx/qfxflickable.cpp2
-rw-r--r--src/declarative/fx/qfxflipable.cpp58
-rw-r--r--src/declarative/fx/qfxfocuspanel.cpp4
-rw-r--r--src/declarative/fx/qfxfocusrealm.cpp2
-rw-r--r--src/declarative/fx/qfxgridview.cpp4
-rw-r--r--src/declarative/fx/qfxhighlightfilter.cpp32
-rw-r--r--src/declarative/fx/qfximage.cpp28
-rw-r--r--src/declarative/fx/qfximageitem.cpp4
-rw-r--r--src/declarative/fx/qfxitem.cpp69
-rw-r--r--src/declarative/fx/qfxkeyactions.cpp34
-rw-r--r--src/declarative/fx/qfxkeyproxy.cpp4
-rw-r--r--src/declarative/fx/qfxlayouts.cpp360
-rw-r--r--src/declarative/fx/qfxlistview.cpp4
-rw-r--r--src/declarative/fx/qfxmouseregion.cpp8
-rw-r--r--src/declarative/fx/qfxpainted.cpp5
-rw-r--r--src/declarative/fx/qfxpainted.h5
-rw-r--r--src/declarative/fx/qfxparticles.cpp166
-rw-r--r--src/declarative/fx/qfxpath.cpp36
-rw-r--r--src/declarative/fx/qfxrect.cpp58
-rw-r--r--src/declarative/fx/qfxreflectionfilter.cpp69
-rw-r--r--src/declarative/fx/qfxrepeater.cpp8
-rw-r--r--src/declarative/fx/qfxshadowfilter.cpp28
-rw-r--r--src/declarative/fx/qfxtext.cpp28
-rw-r--r--src/declarative/fx/qfxtextedit.cpp69
-rw-r--r--src/declarative/fx/qfxtransform.cpp43
-rw-r--r--src/declarative/fx/qfxwebview.cpp50
-rw-r--r--src/declarative/opengl/gltexture.cpp1
-rw-r--r--src/declarative/qml/parser/javascript.g136
-rw-r--r--src/declarative/qml/parser/javascriptast_p.h23
-rw-r--r--src/declarative/qml/parser/javascriptgrammar.cpp1270
-rw-r--r--src/declarative/qml/parser/javascriptgrammar_p.h68
-rw-r--r--src/declarative/qml/parser/javascriptlexer.cpp9
-rw-r--r--src/declarative/qml/parser/javascriptparser.cpp461
-rw-r--r--src/declarative/qml/parser/javascriptparser_p.h4
-rw-r--r--src/declarative/qml/qmlcomponent.cpp24
-rw-r--r--src/declarative/qml/qmlcontext.cpp18
-rw-r--r--src/declarative/qml/qmldom.cpp234
-rw-r--r--src/declarative/qml/qmlscriptparser.cpp87
-rw-r--r--src/declarative/qml/script/qmlbasicscript.cpp1
-rw-r--r--src/declarative/test/qfxtestview.cpp4
-rw-r--r--src/declarative/timeline/qmltimeline.cpp7
-rw-r--r--src/declarative/util/qfxview.cpp41
-rw-r--r--src/declarative/util/qfxview.h16
-rw-r--r--src/declarative/util/qmlanimation.cpp2
-rw-r--r--src/declarative/util/qmlconnection.cpp56
-rw-r--r--tests/auto/declarative/qmldom/tst_qmldom.cpp35
109 files changed, 2681 insertions, 2088 deletions
diff --git a/demos/declarative/calculator/CalcButton.qml b/demos/declarative/calculator/CalcButton.qml
index f4ccdae..8203710 100644
--- a/demos/declarative/calculator/CalcButton.qml
+++ b/demos/declarative/calculator/CalcButton.qml
@@ -1,11 +1,9 @@
Item {
- id: Button; width: 50; height: 30
+ property string operation
+ property bool toggable : false
+ property bool toggled : false
- properties: [
- Property { name: "operation"; type: "string" },
- Property { name: "toggable"; value: false },
- Property { name: "toggled"; value: false }
- ]
+ id: Button; width: 50; height: 30
Script {
function buttonClicked(operation) {
diff --git a/demos/declarative/phonebrowser/content/LikeOMeter.qml b/demos/declarative/phonebrowser/content/LikeOMeter.qml
index 31b8195..d928f48 100644
--- a/demos/declarative/phonebrowser/content/LikeOMeter.qml
+++ b/demos/declarative/phonebrowser/content/LikeOMeter.qml
@@ -1,9 +1,7 @@
Item {
+ property var rating : 2
+
id: Container
- properties: Property {
- name: "rating"
- value: 2
- }
HorizontalLayout {
Star {
rating: 0
diff --git a/demos/declarative/phonebrowser/content/MediaButton.qml b/demos/declarative/phonebrowser/content/MediaButton.qml
index bb2510a..cad36bd 100644
--- a/demos/declarative/phonebrowser/content/MediaButton.qml
+++ b/demos/declarative/phonebrowser/content/MediaButton.qml
@@ -1,11 +1,8 @@
Item {
+ property var text
+ signal clicked
+
id: Container
- signals: Signal {
- name: "clicked"
- }
- properties: Property {
- name: "text"
- }
Image {
id: Image
source: "pics/button.png"
diff --git a/demos/declarative/phonebrowser/content/PhoneInfoContainer.qml b/demos/declarative/phonebrowser/content/PhoneInfoContainer.qml
index da475b1..ea20d4e 100644
--- a/demos/declarative/phonebrowser/content/PhoneInfoContainer.qml
+++ b/demos/declarative/phonebrowser/content/PhoneInfoContainer.qml
@@ -1,17 +1,14 @@
Flipable {
id: Container
- properties: [
- Property { name: "frontContainer"; value: ContainerFront },
- Property { name: "flickableArea"; value: Flickable },
- Property { name: "phoneTitle"; value: "N/A" },
- Property { name: "phoneDescription"; value: "..." },
- Property { name: "phoneSpecifications"; value: "" },
- Property { name: "phoneUrl"; value: "" },
- Property { name: "rating"; value: 2 }
- ]
-
- signals: Signal { name: "closed" }
+ property var frontContainer : ContainerFront
+ property var flickableArea : Flickable
+ property var phoneTitle : "N/A"
+ property var phoneDescription : "..."
+ property var phoneSpecifications : ""
+ property var phoneUrl : ""
+ property var rating : 2
+ signal closed
axis: Axis { startX: Container.width / 2; endX: Container.width / 2; endY: 1 }
diff --git a/demos/declarative/phonebrowser/content/ScrollBar.qml b/demos/declarative/phonebrowser/content/ScrollBar.qml
index a0f2925..e65f92f 100644
--- a/demos/declarative/phonebrowser/content/ScrollBar.qml
+++ b/demos/declarative/phonebrowser/content/ScrollBar.qml
@@ -1,8 +1,7 @@
Item {
+ property var flickableArea
+
id: Container
- properties: Property {
- name: "flickableArea"
- }
Rect {
radius: 5
color: "black"
diff --git a/demos/declarative/phonebrowser/content/Star.qml b/demos/declarative/phonebrowser/content/Star.qml
index ebcd78b..cdbb28b 100644
--- a/demos/declarative/phonebrowser/content/Star.qml
+++ b/demos/declarative/phonebrowser/content/Star.qml
@@ -1,16 +1,12 @@
Item {
+ property var rating
+ property var on
+ signal clicked
+
id: Container
width: 24
height: 24
- properties: [
- Property { name: "rating" },
- Property { name: "on" }
- ]
-
- signals: Signal {
- name: "clicked"
- }
Image {
id: Image
source: "pics/ghns_star.png"
diff --git a/demos/declarative/phonebrowser/phonebrowser.qml b/demos/declarative/phonebrowser/phonebrowser.qml
index 85d352d..ce74367 100644
--- a/demos/declarative/phonebrowser/phonebrowser.qml
+++ b/demos/declarative/phonebrowser/phonebrowser.qml
@@ -3,7 +3,7 @@ import "content"
Item {
id: MainWindow; width: 800; height: 480
- properties: Property { name: "minimized"; value: false }
+ property var minimized : false
Item {
id: Background
diff --git a/demos/declarative/webbrowser/webbrowser.qml b/demos/declarative/webbrowser/webbrowser.qml
index 709d649..c754543 100644
--- a/demos/declarative/webbrowser/webbrowser.qml
+++ b/demos/declarative/webbrowser/webbrowser.qml
@@ -3,10 +3,7 @@ import "content"
Item {
id: WebBrowser
- properties: Property {
- name: "url"
- value: "http://www.qtsoftware.com"
- }
+ property var url : "http://www.qtsoftware.com"
width: 640
height: 480
@@ -163,11 +160,8 @@ Item {
onClicked: { proxy.focus=true }
}
}
- properties: Property {
- name: "progressOff"
- value: 1
- type: "Real"
- }
+
+ property real progressOff : 1
states: [
State {
name: "Normal"
@@ -210,16 +204,8 @@ Item {
anchors.left: parent.left
anchors.right: parent.right
- properties: Property {
- name: "centerX"
- value: 0
- type: "Real"
- }
- properties: Property {
- name: "centerY"
- value: 0
- type: "Real"
- }
+ property real centerX : 0
+ property real centerY : 0
WebView {
id: WebView
@@ -237,11 +223,7 @@ Item {
onUrlChanged: { Flick.xPosition=0; Flick.yPosition=0; zoomOut() }
onDoubleClick: { toggleZoom() }
- properties: Property {
- name: "zoomedOut"
- type: "real"
- value: 1
- }
+ property real zoomedOut : 1
}
Rect {
id: WebViewTint
diff --git a/doc/src/declarative/animation.qdoc b/doc/src/declarative/animation.qdoc
index a143d4c..cd7d1b9 100644
--- a/doc/src/declarative/animation.qdoc
+++ b/doc/src/declarative/animation.qdoc
@@ -1,6 +1,6 @@
/*!
-\page animation.html
-\target animation
+\page qmlanimation.html
+\target qmlanimation
\title QML Animation
QML supports three different forms of animation - basic property animation,
diff --git a/doc/src/declarative/binding.qdoc b/doc/src/declarative/binding.qdoc
index b711a08..1d4f9a1 100644
--- a/doc/src/declarative/binding.qdoc
+++ b/doc/src/declarative/binding.qdoc
@@ -87,16 +87,16 @@ void setBrightness(int b)
Next, make an instance of this class visible to the Qml bind engine:
\code
QFxView *view = new QFxView;
-view->setXml("MyUI.qml");
+view->setUrl("MyUI.qml");
MyScreen *screen = new MyScreen;
-QmlBindContext *ctxt = view->bindContext();
-ctxt->setProperty("screen", screen);
+QmlBindContext *ctxt = view->rootContext();
+ctxt->setContextProperty("screen", screen);
view->execute();
\endcode
-\note Bindings must be made after setXml() but before execute().
+\note Bindings must be made after setUrl() but before execute().
Finally, in Qml you can make the appropriate bindings, so in \c "MyUI.qml":
diff --git a/doc/src/declarative/effects.qdoc b/doc/src/declarative/effects.qdoc
index e3c68bd..6181e20 100644
--- a/doc/src/declarative/effects.qdoc
+++ b/doc/src/declarative/effects.qdoc
@@ -1,17 +1,15 @@
/*!
\page effects.html
-\target effects
+\target qmleffects
\title Visual Effects
-
\section1 Basic Effects
-These effects are currently supported by all canvas backends.
-
\list
\o Scaling (\l Item \bold scale property)
\o Opacity (\l Item \bold opacity property)
-\o Z-Axis Rotation (\l Item \bold rotation property)
+\o Rotation (\l Item \bold rotation property, and Rotation3D)
+\o Affine Transforms (\l Squish)
\endlist
\section1 Advanced Effects
@@ -20,7 +18,7 @@ These effects are currently only supported by the OpenGL canvas backend. Support
backends may be added if the performance can be made acceptable.
\list
-\o X/Y-Axis Rotation (see \l Transform)
+\o Perspective Transforms (\l Perspective, Translation3D)
\o \l Shadow
\o \l Blur
\o \l Reflection
diff --git a/doc/src/declarative/elements.qdoc b/doc/src/declarative/elements.qdoc
index 3e88e5a..b6dec25 100644
--- a/doc/src/declarative/elements.qdoc
+++ b/doc/src/declarative/elements.qdoc
@@ -7,10 +7,11 @@ The following table lists the Qml elements provided by the Qt Declarative module
\bold {Standard Qt Declarative Elements}
-\table 100%
+\table 80%
\header
\o \bold {States}
\o \bold {Animation and Transitions}
+\o \bold {Working with Data}
\o \bold {Utility}
\row
@@ -40,22 +41,30 @@ The following table lists the Qml elements provided by the Qt Declarative module
\o
\list
-\o \l Script
\o \l Bind
-\o \l Connection
-\o \l Component
\o \l ListModel
+\o \l XmlListModel
+\o \l SqlQuery, \l SqlConnection, and \l SqlBind
\o \l DateTimeFormatter
+\o \l NumberFormatter
+\endlist
+
+\o
+\list
+\o \l Script
+\o \l Connection
+\o \l Component
\endlist
\endtable
\bold {Fluid UI Primitives}
-\table 100%
+\table 80%
\header
-\o \bold {Basic Items}
-\o \bold {Utility}
+\o \bold {Basic Visual Items}
+\o \bold {Basic Interaction Items}
\o \bold {Widgets}
+\o \bold {Utility}
\row
\o
@@ -65,20 +74,17 @@ The following table lists the Qml elements provided by the Qt Declarative module
\o \l Text
\o \l TextEdit
\o \l Rect
-\o \l MouseRegion
-\o \l KeyActions
\o \l AnimatedImage
\o \l BlendedImage
\endlist
\o
\list
-\o \l Repeater
-\o \l Content
+\o \l MouseRegion
+\o \l KeyActions
\o \l FocusPanel
\o \l FocusRealm
\o \l KeyProxy
-\o \l ComponentInstance
\endlist
\o
@@ -88,9 +94,18 @@ The following table lists the Qml elements provided by the Qt Declarative module
\o \l WebView
\endlist
+\o
+\list
+\o \l Repeater
+\o \l Content
+\o \l ComponentInstance
+\o \l WidgetContainer
+\endlist
+
\header
\o \bold {Views}
\o \bold {Layouts}
+\o \bold {Transforms}
\o \bold {Effects}
\row
@@ -122,6 +137,14 @@ The following table lists the Qml elements provided by the Qt Declarative module
\o
\list
+\o \l Squish
+\o \l Perspective
+\o \l Rotation3D
+\o \l Translation3D
+\endlist
+
+\o
+\list
\o \l Shadow
\o \l Reflection
\o \l Blur
diff --git a/doc/src/declarative/index.qdoc b/doc/src/declarative/index.qdoc
deleted file mode 100644
index b5e9001..0000000
--- a/doc/src/declarative/index.qdoc
+++ /dev/null
@@ -1,51 +0,0 @@
-/*!
-\page qml.html
-\title 'Qt Declarative' Documentation
-
-\target qtdeclarativemainpage
-
-The Qt Declarative module provides a user interface framework for building
-highly dynamic and fluid applications. It is targetted at the sorts of user
-interface and the sorts of hardware in embedded devices such as phones, media
-players, and set-top boxes. It is also appropriate for highly custom desktop
-user-interfaces, or special elements in more traditional desktop
-user-interfaces.
-
-Building fluid applications is done declaratively, rather than procedurally.
-That is, you specify \e what the UI should look like and how it should behave
-in an declarative format called QML instead of specifying step-by-step \e how to
-build it in a language like C++ or JavaScript. Specifying a UI declaratively
-does not just include the layout of the interface items, but also the way each
-individual item looks and behaves and the overall flow of the application.
-
-Getting Started:
-\list
-\o \l {qmlexamples}{Examples}
-\o \l {tutorial}{Tutorial}
-\o \l {qmlforcpp}{Qt Declarative Markup Language For C++ Programmers}
-\endlist
-
-Core Features:
-\list
-\o \l {binding}{Data Binding}
-\o \l {anchor-layout}{Layout Anchors}
-\o \l {animation}{Animation}
-\o \l {effects}{Visual Effects}
-\o \l {components}{Components}
-\o \l {qmlmodules}{Modules}
-\o \l {qmlfocus}{Keyboard Focus}
-\endlist
-
-QML Reference:
-\list
-\o \l {elements}{Qml Elements}
-\endlist
-
-C++ Reference:
-\list
-\o \l {qtprogrammers}{QML for Qt programmers}
-\o \l {qtbinding}{C++ Data Binding}
-\o \l {cppitem}{C++ Components}
-\endlist
-
-*/
diff --git a/doc/src/declarative/qmlfordesign.qdoc b/doc/src/declarative/qmlfordesign.qdoc
new file mode 100644
index 0000000..35e47df
--- /dev/null
+++ b/doc/src/declarative/qmlfordesign.qdoc
@@ -0,0 +1,42 @@
+/*!
+ \page qmlfordesigners.html
+ \title Qt Declarative for Designers
+
+ \target qtdeclarativemainpage
+
+ The Qt Declarative module provides a declarative framework for building
+ highly dynamic and fluid applications. It is targetted at the sorts of user
+ interface (and the sorts of hardware) in embedded devices such as phones, media
+ players, and set-top boxes. It is also appropriate for highly custom desktop
+ user-interfaces, or special elements in more traditional desktop
+ user-interfaces.
+
+ Building fluid applications is done declaratively, rather than procedurally.
+ That is, you specify \e what the UI should look like and how it should behave
+ rather than specifying step-by-step \e how to build it. Specifying a UI declaratively
+ does not just include the layout of the interface items, but also the way each
+ individual item looks and behaves and the overall flow of the application.
+
+ Getting Started:
+ \list
+ \o \l {qmlexamples}{Examples}
+ \o \l {tutorial}{Tutorial: 'Hello World'}
+ \o \l {tutorials-declarative-contacts.html}{Tutorial: 'Introduction to QML'}
+ \endlist
+
+ Core Features:
+ \list
+ \o \l {binding}{Data Binding}
+ \o \l {anchor-layout}{Layout Anchors}
+ \o \l {qmlanimation}{Animation}
+ \o \l {qmleffects}{Visual Effects}
+ \o \l {components}{Components}
+ \o \l {qmlmodules}{Modules}
+ \o \l {qmlfocus}{Keyboard Focus}
+ \endlist
+
+ QML Reference:
+ \list
+ \o \l {elements}{Qml Elements}
+ \endlist
+*/
diff --git a/doc/src/declarative/qtdeclarative.qdoc b/doc/src/declarative/qtdeclarative.qdoc
new file mode 100644
index 0000000..666c8ae
--- /dev/null
+++ b/doc/src/declarative/qtdeclarative.qdoc
@@ -0,0 +1,93 @@
+/****************************************************************************
+**
+** Copyright (C) 2009 Nokia Corporation and/or its subsidiary(-ies).
+** Contact: Qt Software Information (qt-info@nokia.com)
+**
+** This file is part of the documentation of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** No Commercial Usage
+** This file contains pre-release code and may not be distributed.
+** You may use this file in accordance with the terms and conditions
+** contained in the either Technology Preview License Agreement or the
+** Beta Release License Agreement.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Nokia gives you certain
+** additional rights. These rights are described in the Nokia Qt LGPL
+** Exception version 1.0, included in the file LGPL_EXCEPTION.txt in this
+** package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU
+** General Public License version 3.0 as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU General Public License version 3.0 requirements will be
+** met: http://www.gnu.org/copyleft/gpl.html.
+**
+** If you are unsure which license is appropriate for your use, please
+** contact the sales department at qt-sales@nokia.com.
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+/*!
+ \module QtDeclarative
+ \title QtDeclarative Module
+ \ingroup modules
+
+ \brief The Qt Declarative module provides a declarative framework for building
+ highly dynamic and fluid applications.
+
+ Qt Declarative is targetted at the sorts of user
+ interface (and the sorts of hardware) in embedded devices such as phones, media
+ players, and set-top boxes. It is also appropriate for highly custom desktop
+ user-interfaces, or special elements in more traditional desktop
+ user-interfaces.
+
+ Building fluid applications is done declaratively, rather than procedurally.
+ That is, you specify \e what the UI should look like and how it should behave
+ in an declarative format called QML, rather than specifying step-by-step \e how to
+ build it in a language like C++ or JavaScript. Specifying a UI declaratively
+ does not just include the layout of the interface items, but also the way each
+ individual item looks and behaves and the overall flow of the application.
+
+ Getting Started:
+ \list
+ \o \l {qmlexamples}{Examples}
+ \o \l {tutorial}{Tutorial: 'Hello World'}
+ \o \l {tutorials-declarative-contacts.html}{Tutorial: 'Introduction to QML'}
+ \o \l {qmlforcpp}{Qt Declarative Markup Language For C++ Programmers}
+ \endlist
+
+ Core Features:
+ \list
+ \o \l {binding}{Data Binding}
+ \o \l {anchor-layout}{Layout Anchors}
+ \o \l {qmlanimation}{Animation}
+ \o \l {qmleffects}{Visual Effects}
+ \o \l {components}{Components}
+ \o \l {qmlmodules}{Modules}
+ \o \l {qmlfocus}{Keyboard Focus}
+ \endlist
+
+ QML Reference:
+ \list
+ \o \l {elements}{Qml Elements}
+ \endlist
+
+ C++ Reference:
+ \list
+ \o \l {qtprogrammers}{QML for Qt programmers}
+ \o \l {qtbinding}{C++ Data Binding}
+ \o \l {cppitem}{C++ Components}
+ \endlist
+*/
diff --git a/doc/src/declarative/tutorial.qdoc b/doc/src/declarative/tutorial.qdoc
index 6fe3929..5c855ec 100644
--- a/doc/src/declarative/tutorial.qdoc
+++ b/doc/src/declarative/tutorial.qdoc
@@ -6,7 +6,7 @@ This tutorial gives an introduction to QML and the Fluid UI atoms. It doesn't co
Chapter one starts with a minimal "Hello world" program and the following chapters introduce new concepts.
-The tutorial's source code is located in the $QTDIR/examples/declarative/tutorials directory.
+The tutorial's source code is located in the $QTDIR/examples/declarative/tutorials/helloworld directory.
Tutorial chapters:
diff --git a/doc/src/declarative/tutorial1.qdoc b/doc/src/declarative/tutorial1.qdoc
index aa94c06..c2e3e22 100644
--- a/doc/src/declarative/tutorial1.qdoc
+++ b/doc/src/declarative/tutorial1.qdoc
@@ -10,9 +10,20 @@ This first program is a simple "Hello world" example. The picture below is a scr
Here is the QML code for the application:
\code
-<Rect id="Page" width="480" height="200" color="white">
- <Text id="HelloText" text="Hello world!" font.size="24" font.bold="true" y="30" anchors.horizontalCenter="{Page.horizontalCenter}"/>
-</Rect>
+Rect {
+ id: Page
+ width: 480
+ height: 200
+ color: "white"
+ Text {
+ id: HelloText
+ text: "Hello world!"
+ font.size: 24
+ font.bold: true
+ y: 30
+ anchors.horizontalCenter: Page.horizontalCenter
+ }
+}
\endcode
\section1 Walkthrough
@@ -20,7 +31,12 @@ Here is the QML code for the application:
\section2 Rect element
\code
-<Rect id="Page" width="480" height="200" color="white">
+Rect {
+ id: Page
+ width: 480
+ height: 200
+ color: "white"
+}
\endcode
First, we declare a root element of type \l Rect. It is one of the basic building blocks you can use to create an application in QML.
@@ -30,7 +46,14 @@ The \l Rect element contains many other properties (such as \c x and \c y), but
\section2 Text element
\code
-<Text id="HelloText" text="Hello world!" y="30" font.size="24" font.bold="true" anchors.horizontalCenter="{Page.horizontalCenter}"/>
+Text {
+ id: HelloText
+ text: "Hello world!"
+ font.size: 24
+ font.bold: true
+ y: 30
+ anchors.horizontalCenter: Page.horizontalCenter
+}
\endcode
We add a text element as a child of our root element to display the text 'Hello world!'.
@@ -39,14 +62,14 @@ The \c y property is used to position the text vertically at 30 pixels from the
The \c font.size and \c font.bold properties are related to fonts and use the 'dot' notation (see \l {declarative}{Declarative UI} ).
-The \c anchors.horizontalCenter property refers to the horizontal center of an element. In this case, we bind the center of our text element to the center of the \e Page element. We use braces to indicate that \c Page.horizontalCenter is a bound ECMAScript expression that needs to be evaluated. It also means that if the center of \e Page changes (for example if it is resized) our text will be re-centered automatically (see \l binding).
+The \c anchors.horizontalCenter property refers to the horizontal center of an element. In this case, we specify that our text element should be horizontally centered in the \e Page element.
\section2 Viewing the example
To view what you have created, run the qmlviewer (located in the \c bin directory) with your filename as the first argument. For example, to run the provided completed Tutorial 1 example from the install location, you would type:
\code
-bin/qmlviewer examples/tutorials/t1/tutorial1.qml
+bin/qmlviewer $QTDIR/examples/declarative/tutorials/helloworld/t1/tutorial1.qml
\endcode
[\l tutorial] [Next: \l tutorial2]
diff --git a/doc/src/declarative/tutorial2.qdoc b/doc/src/declarative/tutorial2.qdoc
index db846b8..54f1828 100644
--- a/doc/src/declarative/tutorial2.qdoc
+++ b/doc/src/declarative/tutorial2.qdoc
@@ -12,29 +12,54 @@ Our color picker is made of many cells with different colors. To avoid writing t
Here is the QML code for \c Cell.qml:
\code
-<Item id="CellContainer" width="40" height="25">
- <properties>
- <Property name="color"/>
- </properties>
- <Rect anchors.fill="{parent}" color="{CellContainer.color}"/>
- <MouseRegion anchors.fill="{parent}" onClick="HelloText.color = CellContainer.color" />
-</Item>
+Item {
+ id: CellContainer
+ width: 40
+ height: 25
+ properties: Property {
+ name: "color"
+ }
+ Rect {
+ anchors.fill: parent
+ color: CellContainer.color
+ }
+ MouseRegion {
+ anchors.fill: parent
+ onClicked: { HelloText.color = CellContainer.color }
+ }
+}
\endcode
Then, we use our \c Cell component to create the color picker in the QML code for the application:
\code
-<Rect id="Page" width="480" height="200" color="white">
- <Text id="HelloText" text="Hello world!" font.size="24" font.bold="true" y="30" anchors.horizontalCenter="{Page.horizontalCenter}"/>
- <GridLayout id="ColorPicker" x="0" anchors.bottom="{Page.bottom}" width="120" height="50" columns="3" rows="2">
- <Cell color="#ff0000"/>
- <Cell color="#00ff00"/>
- <Cell color="#0000ff"/>
- <Cell color="#ffff00"/>
- <Cell color="#00ffff"/>
- <Cell color="#ff00ff"/>
- </GridLayout>
-</Rect>
+Rect {
+ id: Page
+ width: 480
+ height: 200
+ color: "white"
+ Text {
+ id: HelloText
+ text: "Hello world!"
+ font.size: 24
+ font.bold: true
+ y: 30
+ anchors.horizontalCenter: Page.horizontalCenter
+ }
+ GridLayout {
+ id: ColorPicker
+ x: 0
+ anchors.bottom: Page.bottom
+ width: 120; height: 50
+ rows: 2; columns: 3
+ Cell { color: "#ff0000" }
+ Cell { color: "#00ff00" }
+ Cell { color: "#0000ff" }
+ Cell { color: "#ffff00" }
+ Cell { color: "#00ffff" }
+ Cell { color: "#ff00ff" }
+ }
+}
\endcode
\section1 Walkthrough
@@ -42,21 +67,28 @@ Then, we use our \c Cell component to create the color picker in the QML code fo
\section2 The Cell Component
\code
-<Item id="CellContainer" width="40" height="25">
+Item {
+ id: CellContainer
+ width: 40
+ height: 25
+}
\endcode
The root element of our component is an \c Item. It is the most basic 'Fx' element in Qml and is often used as a container for other elements.
\code
-<properties>
- <Property name="color"/>
-</properties>
+properties: Property {
+ name: "color"
+}
\endcode
We declare a \c color property. This property is accessible from \e outside our component, this allows us to instantiate the cells with different colors.
\code
-<Rect anchors.fill="{parent}" color="{CellContainer.color}"/>
+Rect {
+ anchors.fill: parent
+ color: CellContainer.color
+}
\endcode
Our cell component is basically a colored rectangle.
@@ -66,24 +98,32 @@ The \c anchors.fill property is a convenient way to set the size of an element.
We bind the \c color property of this \c Rect to the color property of our component.
\code
-<MouseRegion anchors.fill="{parent}" onClick="HelloText.color = CellContainer.color" />
+MouseRegion {
+ anchors.fill: parent
+ onClicked: { HelloText.color = CellContainer.color }
+}
\endcode
In order to change the color of the text when clicking on a cell, we create a \c MouseRegion element with the same size as its parent.
-The \c onClick property sets the \c color property of the element named \e HelloText to our cell color.
+The \c onClicked property sets the \c color property of the element named \e HelloText to our cell color.
\section2 The main QML file
\code
-<GridLayout id="ColorPicker" x="0" anchors.bottom="{Page.bottom}" width="120" height="50" columns="3" rows="2">
- <Cell color="#ff0000"/>
- <Cell color="#00ff00"/>
- <Cell color="#0000ff"/>
- <Cell color="#ffff00"/>
- <Cell color="#00ffff"/>
- <Cell color="#ff00ff"/>
-</GridLayout>
+GridLayout {
+ id: ColorPicker
+ x: 0
+ anchors.bottom: Page.bottom
+ width: 120; height: 50
+ rows: 2; columns: 3
+ Cell { color: "#ff0000" }
+ Cell { color: "#00ff00" }
+ Cell { color: "#0000ff" }
+ Cell { color: "#ffff00" }
+ Cell { color: "#00ffff" }
+ Cell { color: "#ff00ff" }
+}
\endcode
In the main QML file, the only thing we have to do is to create a color picker by putting 6 cells with different colors in a grid layout.
diff --git a/doc/src/declarative/tutorial3.qdoc b/doc/src/declarative/tutorial3.qdoc
index 533e179..3ac22a1 100644
--- a/doc/src/declarative/tutorial3.qdoc
+++ b/doc/src/declarative/tutorial3.qdoc
@@ -12,44 +12,86 @@ We want our text to jump at the bottom of the screen and become red when clicked
Here is the QML code:
\code
-<Rect id="Page" width="480" height="200" color="white">
- <Text id="HelloText" text="Hello world!" font.size="24" font.bold="true" y="30" anchors.horizontalCenter="{Page.horizontalCenter}">
- <states>
- <State name="down" when="{MouseRegion.pressed == true}">
- <SetProperty target="{HelloText}" property="y" value="160"/>
- <SetProperty target="{HelloText}" property="color" value="red"/>
- </State>
- </states>
- <transitions>
- <Transition fromState="*" toState="down" reversible="true">
- <ParallelAnimation>
- <NumericAnimation properties="y" duration="500" easing="easeOutBounce"/>
- <ColorAnimation duration="500"/>
- </ParallelAnimation>
- </Transition>
- </transitions>
- </Text>
- <MouseRegion id="MouseRegion" anchors.fill="{HelloText}"/>
- <GridLayout id="ColorPicker" x="0" anchors.bottom="{Page.bottom}" width="120" height="50" columns="3" rows="2">
- <Cell color="#ff0000"/>
- <Cell color="#00ff00"/>
- <Cell color="#0000ff"/>
- <Cell color="#ffff00"/>
- <Cell color="#00ffff"/>
- <Cell color="#ff00ff"/>
- </GridLayout>
-</Rect>
+Rect {
+ id: Page
+ width: 480
+ height: 200
+ color: "white"
+ Text {
+ id: HelloText
+ text: "Hello world!"
+ font.size: 24
+ font.bold: true
+ y: 30
+ anchors.horizontalCenter: Page.horizontalCenter
+ states: [
+ State {
+ name: "down"
+ when: MouseRegion.pressed == true
+ SetProperty {
+ target: HelloText
+ property: "y"
+ value: 160
+ }
+ SetProperty {
+ target: HelloText
+ property: "color"
+ value: "red"
+ }
+ }
+ ]
+ transitions: [
+ Transition {
+ fromState: "*"
+ toState: "down"
+ reversible: true
+ ParallelAnimation {
+ NumericAnimation {
+ properties: "y"
+ duration: 500
+ easing: "easeOutBounce"
+ }
+ ColorAnimation { duration: 500 }
+ }
+ }
+ ]
+ }
+ MouseRegion { id: MouseRegion; anchors.fill: HelloText }
+ GridLayout {
+ id: ColorPicker
+ x: 0
+ anchors.bottom: Page.bottom
+ width: 120; height: 50
+ rows: 2; columns: 3
+ Cell { color: "#ff0000" }
+ Cell { color: "#00ff00" }
+ Cell { color: "#0000ff" }
+ Cell { color: "#ffff00" }
+ Cell { color: "#00ffff" }
+ Cell { color: "#ff00ff" }
+ }
+}
\endcode
\section1 Walkthrough
\code
-<states>
- <State name="down" when="{MouseRegion.pressed == true}">
- <SetProperty target="{HelloText}" property="y" value="160"/>
- <SetProperty target="{HelloText}" property="color" value="red"/>
- </State>
-</states>
+states: [
+ State {
+ name: "down"
+ when: MouseRegion.pressed == true
+ SetProperty {
+ target: HelloText
+ property: "y"
+ value: 160
+ }
+ SetProperty {
+ target: HelloText
+ property: "color"
+ value: "red"
+ }
+ }
+]
\endcode
First, we create a new state \e down for our text element. This state will be activated when MouseRegion is pressed, and deactivated when it is released.
@@ -57,7 +99,11 @@ First, we create a new state \e down for our text element. This state will be ac
The \e down state includes a set of property changes from our implicit \e {default state} (the items as they were initially defined in the QML). Specifically, we set the \c y property of the text to 160 and the \c color to red.
\code
-<Transition fromState="*" toState="down" reversible="true">
+Transition {
+ fromState: "*"
+ toState: "down"
+ reversible: true
+}
\endcode
Because we don't want the text to appear at the bottom instantly but rather move smoothly, we add a transition between our two states.
@@ -67,10 +113,14 @@ Because we don't want the text to appear at the bottom instantly but rather move
Because we want the same transition to be run in reverse when changing back from the \e down state to the default state, we set \c reversible to \c true. This is equivalent to writing the two transitions separately.
\code
-<ParallelAnimation>
- <NumericAnimation properties="y" duration="500" easing="easeOutBounce"/>
- <ColorAnimation duration="500"/>
-</ParallelAnimation>
+ParallelAnimation {
+ NumericAnimation {
+ properties: "y"
+ duration: 500
+ easing: "easeOutBounce"
+ }
+ ColorAnimation { duration: 500 }
+}
\endcode
The \c ParallelAnimation element makes sure that the two animations (color and position) will start at the same time. We could also run them one after the other by using \c SequentialAnimation instead.
diff --git a/doc/src/index.qdoc b/doc/src/index.qdoc
index 8a856ea..f0debdb 100644
--- a/doc/src/index.qdoc
+++ b/doc/src/index.qdoc
@@ -188,7 +188,7 @@
<li><a href="qtxmlpatterns.html">XML Patterns: XQuery &amp; XPath</a></li>
<li><a href="phonon-module.html">Phonon Multimedia Framework</a></li>
<li><a href="qtscripttools.html">Script Tools Module</a></li>
- <li><a href="qml.html">Qt Markup Language</a></li>
+ <li><a href="qtdeclarative.html">Declarative Module</a></li>
<li><a href="activeqt.html">ActiveQt Framework</a></li>
</ul>
</td>
diff --git a/doc/src/modules.qdoc b/doc/src/modules.qdoc
index 7372994..acfd604 100644
--- a/doc/src/modules.qdoc
+++ b/doc/src/modules.qdoc
@@ -62,6 +62,7 @@
\row \o \l{QtWebKit} \o Classes for displaying and editing Web content
\row \o \l{QtXml} \o Classes for handling XML
\row \o \l{QtXmlPatterns} \o An XQuery & XPath engine for XML and custom data models
+ \row \o \l{QtDeclarative} \o An engine for declaratively building fluid user interfaces.
\row \o \l{Phonon Module}{Phonon} \o Multimedia framework classes
\row \o \l{Qt3Support} \o Qt 3 compatibility classes
\endtable
diff --git a/doc/src/snippets/qprocess-environment/main.cpp b/doc/src/snippets/qprocess-environment/main.cpp
index 148518b..c8681e7 100644
--- a/doc/src/snippets/qprocess-environment/main.cpp
+++ b/doc/src/snippets/qprocess-environment/main.cpp
@@ -62,7 +62,7 @@ env.insert("TMPDIR", "C:\\MyApp\\temp"); // Add an environment variable
env["PATH"] += ";C:\\Bin";
process.setEnvironment(env);
process.start("myapp");
-//! [0]
+//! [1]
}
}
diff --git a/doc/src/tutorials/declarative.qdoc b/doc/src/tutorials/declarative.qdoc
index 16dad6e..bde71da 100644
--- a/doc/src/tutorials/declarative.qdoc
+++ b/doc/src/tutorials/declarative.qdoc
@@ -404,7 +404,7 @@
These properties and signals are accessed from the contact field the same
way standard system components are accessed.
- \snippet declarative/tutorials/contacts/2_Reuse/2/RemoveButton.qml use properties and signals
+ \snippet declarative/tutorials/contacts/2_Reuse/2/ContactField.qml use properties and signals
Now when the remove button is expanded, it will expand to the width of the
contact field. Also when the user confirms the remove action, the
@@ -438,7 +438,7 @@
that state. In the FieldText element a similar approach is used to fade
out the label of the FieldText when the user enters some text of their own.
- \snippet declarative/tutorials/contacts/3_Reuse/2/FieldText.qml behavior
+ \snippet declarative/tutorials/contacts/2_Reuse/3/FieldText.qml behavior
fieldText is the enclosing component and textEdit is a TextEdit element
provided by Qt. In the QML code above, the opacity of the textLabel is
@@ -587,7 +587,7 @@
We then add a transition so that this becomes animated:
- \snippet declarative/tutorials/contacts/3_Collections/2/ContactView.qml transition
+ \snippet declarative/tutorials/contacts/3_Collections/2/ContactView.qml transitions
This allows the user to click on an item to enter the open state.
@@ -600,7 +600,7 @@
And connect it's clicked value to some script to set the state of the delegate
back to its default state.
- \snippet declarative/tutorials/contacts/3_Collections/2/ContactView.qml connection
+ \snippet declarative/tutorials/contacts/3_Collections/2/ContactView.qml connections
Something worth noting at this point is that every delegate created has this connection.
It is important to check whether the delegate is the one in the open state, and
diff --git a/examples/declarative/contacts/main.cpp b/examples/declarative/contacts/main.cpp
index 6bf9daf..bda6565 100644
--- a/examples/declarative/contacts/main.cpp
+++ b/examples/declarative/contacts/main.cpp
@@ -7,7 +7,7 @@
#include <QTime>
#include <QVBoxLayout>
-const char *defaultFileName("contacts.xml");
+const char *defaultFileName("contacts.qml");
class Contacts : public QWidget
{
@@ -43,8 +43,8 @@ Contacts::Contacts(const QString &fileName, int width, int height, QWidget *pare
QFile file(fileName);
file.open(QFile::ReadOnly);
- QString xml = file.readAll();
- canvas->setXml(xml, fileName);
+ QString qml = file.readAll();
+ canvas->setQml(qml, fileName);
canvas->execute();
}
diff --git a/examples/declarative/dial/DialLibrary/Dial.qml b/examples/declarative/dial/DialLibrary/Dial.qml
index fe8528d..485188a 100644
--- a/examples/declarative/dial/DialLibrary/Dial.qml
+++ b/examples/declarative/dial/DialLibrary/Dial.qml
@@ -1,11 +1,9 @@
Item {
+ property real value : 0
+
width: 210
height: 210
- properties: Property {
- name: "value"
- type: "real"
- value: 0
- }
+
Image {
id: Background
source: "background.svg"
diff --git a/examples/declarative/follow/pong.qml b/examples/declarative/follow/pong.qml
index 32ee049..582b04c 100644
--- a/examples/declarative/follow/pong.qml
+++ b/examples/declarative/follow/pong.qml
@@ -5,14 +5,14 @@ Rect {
// Make a ball to bounce
Rect {
+ // Add a property for the target y coordinate
+ property var targetY : Page.height-10
+ property var direction : "right"
+
id: Ball
color: "#00ee00"
x: 20; width: 20; height: 20; z: 1
- // Add a property for the target y coordinate
- properties: Property { name: "targetY"; value: Page.height-10 }
- properties: Property { name: "direction"; value: "right" }
-
// Move the ball to the right and back to the left repeatedly
x: SequentialAnimation {
running: true; repeat: true
diff --git a/examples/declarative/listview/content/MediaButton.qml b/examples/declarative/listview/content/MediaButton.qml
index bb2510a..cad36bd 100644
--- a/examples/declarative/listview/content/MediaButton.qml
+++ b/examples/declarative/listview/content/MediaButton.qml
@@ -1,11 +1,8 @@
Item {
+ property var text
+ signal clicked
+
id: Container
- signals: Signal {
- name: "clicked"
- }
- properties: Property {
- name: "text"
- }
Image {
id: Image
source: "pics/button.png"
diff --git a/examples/declarative/listview/recipes.qml b/examples/declarative/listview/recipes.qml
index db9ef61..28785f1 100644
--- a/examples/declarative/listview/recipes.qml
+++ b/examples/declarative/listview/recipes.qml
@@ -16,11 +16,8 @@ Rect {
// We can bind multiple element's opacity to this one property,
// rather than having a "SetProperty" line for each element we
// want to fade.
- properties: Property {
- name: "detailsOpacity"
- value: 0
- type: "real"
- }
+ property real detailsOpacity : 0
+
// A simple rounded rectangle for the background
Rect {
id: background
diff --git a/examples/declarative/minehunt/Description.qml b/examples/declarative/minehunt/Description.qml
index f59c8f9..0241ae5 100644
--- a/examples/declarative/minehunt/Description.qml
+++ b/examples/declarative/minehunt/Description.qml
@@ -1,9 +1,7 @@
Item {
id: Page
height: MyText.height + 20
- properties: Property {
- name: "text"
- }
+ property var text
MouseRegion {
anchors.fill: parent
drag.target: Page
diff --git a/examples/declarative/minehunt/Explosion.qml b/examples/declarative/minehunt/Explosion.qml
index 8d868bc..2886559 100644
--- a/examples/declarative/minehunt/Explosion.qml
+++ b/examples/declarative/minehunt/Explosion.qml
@@ -1,9 +1,6 @@
Item {
- properties: Property {
- name: "explode"
- type: "Bool"
- value: false
- }
+ property bool explode : false
+
Particles {
width: 38
height: 21
diff --git a/examples/declarative/minehunt/main.cpp b/examples/declarative/minehunt/main.cpp
index 9db717b..7f10757 100644
--- a/examples/declarative/minehunt/main.cpp
+++ b/examples/declarative/minehunt/main.cpp
@@ -130,8 +130,8 @@ MyWidget::MyWidget(int width, int height, QWidget *parent, Qt::WindowFlags flags
QFile file(fileName);
file.open(QFile::ReadOnly);
- QString xml = file.readAll();
- canvas->setXml(xml, fileName);
+ QString qml = file.readAll();
+ canvas->setQml(qml, fileName);
QmlContext *ctxt = canvas->rootContext();
ctxt->activate();
diff --git a/examples/declarative/minehunt/minehunt.qml b/examples/declarative/minehunt/minehunt.qml
index cde2612..58397b0 100644
--- a/examples/declarative/minehunt/minehunt.qml
+++ b/examples/declarative/minehunt/minehunt.qml
@@ -2,16 +2,10 @@ Item {
id: field
width: 370
height: 480
- properties: Property {
- name: "clickx"
- type: "Int"
- value: 0
- }
- properties: Property {
- name: "clicky"
- type: "Int"
- value: 0
- }
+
+ property int clickx : 0
+ property int clicky : 0
+
resources: [
Component {
id: tile
diff --git a/examples/declarative/scrollbar/ScrollBar.qml b/examples/declarative/scrollbar/ScrollBar.qml
index e3ca0c2..929c72a 100644
--- a/examples/declarative/scrollbar/ScrollBar.qml
+++ b/examples/declarative/scrollbar/ScrollBar.qml
@@ -5,16 +5,10 @@ Item {
// height of the page, i.e. a pageSize of 0.5 means that you can see 50%
// of the height of the view.
// orientation can be either 'Vertical' or 'Horizontal'
- properties: Property {
- name: "position"
- }
- properties: Property {
- name: "pageSize"
- }
- properties: Property {
- name: "orientation"
- value: "Vertical"
- }
+ property var position
+ property var pageSize
+ property var orientation : "Vertical"
+
// A light, semi-transparent background
Rect {
id: Background
diff --git a/examples/declarative/slideswitch/Switch.qml b/examples/declarative/slideswitch/Switch.qml
index 5862646..6777277 100644
--- a/examples/declarative/slideswitch/Switch.qml
+++ b/examples/declarative/slideswitch/Switch.qml
@@ -2,9 +2,9 @@ Item {
id: Switch
width: Groove.width
height: Groove.height
- properties: Property {
- name: "on"
- }
+
+ property var on
+
Script {
function toggle() {
@@ -14,7 +14,6 @@ Item {
Switch.state = "On";
}
function dorelease() {
- print(Knob.x);
if(Knob.x == 1) {
if(Switch.state == "Off")
return;
diff --git a/examples/declarative/tutorials/contacts/1_Drawing_and_Animation/GroupBox.qml b/examples/declarative/tutorials/contacts/1_Drawing_and_Animation/GroupBox.qml
index 665c072..edaae72 100644
--- a/examples/declarative/tutorials/contacts/1_Drawing_and_Animation/GroupBox.qml
+++ b/examples/declarative/tutorials/contacts/1_Drawing_and_Animation/GroupBox.qml
@@ -2,12 +2,10 @@ FocusRealm {
id: groupBox
width: Math.max(270, subItem.width+40)
height: Math.max(70, subItem.height+40)
- properties: Property {
- name: "contents"
- }
- properties: Property {
- name: "label"
- }
+
+ property var contents
+ property var label
+
Rect {
id: wrapper
x: 5
diff --git a/examples/declarative/tutorials/contacts/2_Reuse/3/Contact.qml b/examples/declarative/tutorials/contacts/2_Reuse/3/Contact.qml
index 33ac627..23560ce 100644
--- a/examples/declarative/tutorials/contacts/2_Reuse/3/Contact.qml
+++ b/examples/declarative/tutorials/contacts/2_Reuse/3/Contact.qml
@@ -2,6 +2,7 @@ Item {
id: contactDetails
width: 230
height: layout.height
+
properties: Property {
name: "contactid"
value: ""
diff --git a/examples/declarative/tutorials/contacts/2_Reuse/3/RemoveButton.qml b/examples/declarative/tutorials/contacts/2_Reuse/3/RemoveButton.qml
index 309ee5a..8d82e89 100644
--- a/examples/declarative/tutorials/contacts/2_Reuse/3/RemoveButton.qml
+++ b/examples/declarative/tutorials/contacts/2_Reuse/3/RemoveButton.qml
@@ -1,3 +1,4 @@
+//! [all]
Rect {
id: removeButton
width: 30
@@ -120,3 +121,4 @@ Rect {
}
]
}
+//! [all]
diff --git a/examples/declarative/tutorials/t1/tutorial1.qml b/examples/declarative/tutorials/helloworld/t1/tutorial1.qml
index ec29f4f..ec29f4f 100644
--- a/examples/declarative/tutorials/t1/tutorial1.qml
+++ b/examples/declarative/tutorials/helloworld/t1/tutorial1.qml
diff --git a/examples/declarative/tutorials/t3/Cell.qml b/examples/declarative/tutorials/helloworld/t2/Cell.qml
index bd5bbe7..0109251 100644
--- a/examples/declarative/tutorials/t3/Cell.qml
+++ b/examples/declarative/tutorials/helloworld/t2/Cell.qml
@@ -1,10 +1,10 @@
Item {
+ property var color
+
id: CellContainer
width: 40
height: 25
- properties: Property {
- name: "color"
- }
+
Rect {
anchors.fill: parent
color: CellContainer.color
diff --git a/examples/declarative/tutorials/helloworld/t2/tutorial2.qml b/examples/declarative/tutorials/helloworld/t2/tutorial2.qml
new file mode 100644
index 0000000..4630435
--- /dev/null
+++ b/examples/declarative/tutorials/helloworld/t2/tutorial2.qml
@@ -0,0 +1,27 @@
+Rect {
+ id: Page
+ width: 480
+ height: 200
+ color: "white"
+ Text {
+ id: HelloText
+ text: "Hello world!"
+ font.size: 24
+ font.bold: true
+ y: 30
+ anchors.horizontalCenter: Page.horizontalCenter
+ }
+ GridLayout {
+ id: ColorPicker
+ x: 0
+ anchors.bottom: Page.bottom
+ width: 120; height: 50
+ rows: 2; columns: 3
+ Cell { color: "#ff0000" }
+ Cell { color: "#00ff00" }
+ Cell { color: "#0000ff" }
+ Cell { color: "#ffff00" }
+ Cell { color: "#00ffff" }
+ Cell { color: "#ff00ff" }
+ }
+}
diff --git a/examples/declarative/tutorials/t2/Cell.qml b/examples/declarative/tutorials/helloworld/t3/Cell.qml
index bd5bbe7..e779406 100644
--- a/examples/declarative/tutorials/t2/Cell.qml
+++ b/examples/declarative/tutorials/helloworld/t3/Cell.qml
@@ -1,10 +1,9 @@
Item {
+ property var color
+
id: CellContainer
width: 40
height: 25
- properties: Property {
- name: "color"
- }
Rect {
anchors.fill: parent
color: CellContainer.color
diff --git a/examples/declarative/tutorials/t3/tutorial3.qml b/examples/declarative/tutorials/helloworld/t3/tutorial3.qml
index 8e2b697..3ca7a2f 100644
--- a/examples/declarative/tutorials/t3/tutorial3.qml
+++ b/examples/declarative/tutorials/helloworld/t3/tutorial3.qml
@@ -37,42 +37,23 @@ Rect {
duration: 500
easing: "easeOutBounce"
}
- ColorAnimation {
- duration: 500
- }
+ ColorAnimation { duration: 500 }
}
}
]
}
- MouseRegion {
- id: MouseRegion
- anchors.fill: HelloText
- }
+ MouseRegion { id: MouseRegion; anchors.fill: HelloText }
GridLayout {
id: ColorPicker
x: 0
anchors.bottom: Page.bottom
- width: 120
- height: 50
- columns: 3
- rows: 2
- Cell {
- color: "#ff0000"
- }
- Cell {
- color: "#00ff00"
- }
- Cell {
- color: "#0000ff"
- }
- Cell {
- color: "#ffff00"
- }
- Cell {
- color: "#00ffff"
- }
- Cell {
- color: "#ff00ff"
- }
+ width: 120; height: 50
+ rows: 2; columns: 3
+ Cell { color: "#ff0000" }
+ Cell { color: "#00ff00" }
+ Cell { color: "#0000ff" }
+ Cell { color: "#ffff00" }
+ Cell { color: "#00ffff" }
+ Cell { color: "#ff00ff" }
}
}
diff --git a/examples/declarative/tutorials/t2/tutorial2.qml b/examples/declarative/tutorials/t2/tutorial2.qml
deleted file mode 100644
index 08ea9eb..0000000
--- a/examples/declarative/tutorials/t2/tutorial2.qml
+++ /dev/null
@@ -1,41 +0,0 @@
-Rect {
- id: Page
- width: 480
- height: 200
- color: "white"
- Text {
- id: HelloText
- text: "Hello world!"
- font.size: 24
- font.bold: true
- y: 30
- anchors.horizontalCenter: Page.horizontalCenter
- }
- GridLayout {
- id: ColorPicker
- x: 0
- anchors.bottom: Page.bottom
- width: 120
- height: 50
- columns: 3
- rows: 2
- Cell {
- color: "#ff0000"
- }
- Cell {
- color: "#00ff00"
- }
- Cell {
- color: "#0000ff"
- }
- Cell {
- color: "#ffff00"
- }
- Cell {
- color: "#00ffff"
- }
- Cell {
- color: "#ff00ff"
- }
- }
-}
diff --git a/examples/declarative/velocity/Day.qml b/examples/declarative/velocity/Day.qml
index 7d26e88..c70a211 100644
--- a/examples/declarative/velocity/Day.qml
+++ b/examples/declarative/velocity/Day.qml
@@ -1,16 +1,12 @@
Rect {
+ property string day
+ property var stickies
+
width: 400
height: 500
radius: 7
pen.color: "black"
id: Page
- properties: Property {
- name: "day"
- type: "string"
- }
- properties: Property {
- name: "stickies"
- }
Image {
x: 10
y: 10
diff --git a/examples/declarative/webview/content/SpinSquare.qml b/examples/declarative/webview/content/SpinSquare.qml
index 5c14506..5e4735e 100644
--- a/examples/declarative/webview/content/SpinSquare.qml
+++ b/examples/declarative/webview/content/SpinSquare.qml
@@ -1,13 +1,8 @@
Item {
+ properties var period : 250
+ properties var color : "black"
id: Root
- properties: Property {
- name: "period"
- value: 250
- }
- properties: Property {
- name: "color"
- value: "black"
- }
+
Item {
x: Root.width/2
y: Root.height/2
diff --git a/src/3rdparty/easing/legal.qdoc b/src/3rdparty/easing/legal.qdoc
index 25f67e1..1be5f66 100644
--- a/src/3rdparty/easing/legal.qdoc
+++ b/src/3rdparty/easing/legal.qdoc
@@ -1,7 +1,7 @@
/*!
\page legal-easing.html
\title Easing Equations by Robert Penner
-\ingroup animation
+\ingroup group_animation
\legalese
\code
diff --git a/src/corelib/animation/qabstractanimation.cpp b/src/corelib/animation/qabstractanimation.cpp
index 6c55a77..f2d8668 100644
--- a/src/corelib/animation/qabstractanimation.cpp
+++ b/src/corelib/animation/qabstractanimation.cpp
@@ -41,7 +41,7 @@
/*!
\class QAbstractAnimation
- \ingroup animation
+ \ingroup group_animation
\brief The QAbstractAnimation class provides an abstract base class for animations.
\since 4.5
\preliminary
diff --git a/src/corelib/animation/qanimationgroup.cpp b/src/corelib/animation/qanimationgroup.cpp
index c4066ce..8c9f358 100644
--- a/src/corelib/animation/qanimationgroup.cpp
+++ b/src/corelib/animation/qanimationgroup.cpp
@@ -43,7 +43,7 @@
\class QAnimationGroup
\brief The QAnimationGroup class is an abstract base class for group of animations.
\since 4.5
- \ingroup animation
+ \ingroup group_animation
\preliminary
QAnimationGroup represents a group of animations, such as parallel or sequential,
diff --git a/src/corelib/animation/qparallelanimationgroup.cpp b/src/corelib/animation/qparallelanimationgroup.cpp
index 407ffde..a75f85c 100644
--- a/src/corelib/animation/qparallelanimationgroup.cpp
+++ b/src/corelib/animation/qparallelanimationgroup.cpp
@@ -43,7 +43,7 @@
\class QParallelAnimationGroup
\brief The QParallelAnimationGroup class provides a parallel group of animations.
\since 4.5
- \ingroup animation
+ \ingroup group_animation
\preliminary
The animations are all started at the same time, and run in parallel. The animation group
diff --git a/src/corelib/animation/qpauseanimation.cpp b/src/corelib/animation/qpauseanimation.cpp
index 30ea92c..86c3049 100644
--- a/src/corelib/animation/qpauseanimation.cpp
+++ b/src/corelib/animation/qpauseanimation.cpp
@@ -43,7 +43,7 @@
\class QPauseAnimation
\brief The QPauseAnimation class provides a pause for QSequentialAnimationGroup.
\since 4.5
- \ingroup animation
+ \ingroup group_animation
\preliminary
*/
diff --git a/src/corelib/animation/qpropertyanimation.cpp b/src/corelib/animation/qpropertyanimation.cpp
index 9a0c5bc..6b03c33 100644
--- a/src/corelib/animation/qpropertyanimation.cpp
+++ b/src/corelib/animation/qpropertyanimation.cpp
@@ -42,7 +42,7 @@
/*!
\class QPropertyAnimation
\brief The QPropertyAnimation class animates properties for QObject(and QWidget)
- \ingroup animation
+ \ingroup group_animation
\preliminary
This class is part of {The Animation Framework}. You can use QPropertyAnimation
diff --git a/src/corelib/animation/qsequentialanimationgroup.cpp b/src/corelib/animation/qsequentialanimationgroup.cpp
index 61ff98d..45673c2 100644
--- a/src/corelib/animation/qsequentialanimationgroup.cpp
+++ b/src/corelib/animation/qsequentialanimationgroup.cpp
@@ -43,7 +43,7 @@
\class QSequentialAnimationGroup
\brief The QSequentialAnimationGroup class provides a sequential group of animations.
\since 4.5
- \ingroup animation
+ \ingroup group_animation
\preliminary
The first animation in the group is started first, and when it finishes, the next animation
diff --git a/src/corelib/animation/qvariantanimation.cpp b/src/corelib/animation/qvariantanimation.cpp
index 9f8cbf0..29819e5 100644
--- a/src/corelib/animation/qvariantanimation.cpp
+++ b/src/corelib/animation/qvariantanimation.cpp
@@ -54,7 +54,7 @@ QT_BEGIN_NAMESPACE
/*!
\class QVariantAnimation
- \ingroup animation
+ \ingroup group_animation
\brief The QVariantAnimation class provides an abstract base class for animations.
\since 4.5
\preliminary
diff --git a/src/corelib/kernel/qcoreevent.cpp b/src/corelib/kernel/qcoreevent.cpp
index 4b4dfe5..efd0938 100644
--- a/src/corelib/kernel/qcoreevent.cpp
+++ b/src/corelib/kernel/qcoreevent.cpp
@@ -291,7 +291,7 @@ QEvent::~QEvent()
/*!
\property QEvent::accepted
- the accept flag of the event object
+ \brief The accept flag of the event object
Setting the accept parameter indicates that the event receiver
wants the event. Unwanted events might be propagated to the parent
diff --git a/src/declarative/extra/qmlsqlconnection.cpp b/src/declarative/extra/qmlsqlconnection.cpp
index 7f1fec2..a39aa6f 100644
--- a/src/declarative/extra/qmlsqlconnection.cpp
+++ b/src/declarative/extra/qmlsqlconnection.cpp
@@ -67,6 +67,26 @@ public:
/*!
\qmlclass SqlConnection QmlSqlConnection
\brief The SqlConnection element describes a connection to an SQL database.
+
+ The SqlConnection element works in a similar way to
+ QSqlDatabase::addDatabase(). It allows setting the database properties
+ such that the connection does not need to be set up in C++ code.
+ It differs from QSqlDatabase::addDatabase() in that it will automatically
+ open the database.
+
+ The database can then either be used from an SqlQuery element using its id
+ as a bind, or using its name. If the database is set up externally to
+ Qml the query should connect using its name.
+
+ \qml
+ <SqlConnection id="myConnection">
+ <name>qmlConnection</name>
+ <driver>QSQLITE</driver>
+ <databaseName>"mydb.sqlite"</databaseName>
+ </SqlConnection>
+ <SqlQuery id="listmodel" connection="{myConnection}">SELECT * FROM mytable</SqlQuery>
+ <SqlQuery id="othermodel" connection="qmlConnection">SELECT * FROM myothertable</SqlQuery>
+ \endqml
*/
/*!
@@ -142,32 +162,9 @@ public:
*/
/*!
+ \internal
\class QmlSqlConnection
\brief The QmlSqlConnection class manages a connection to an SQL database.
-
- \qmltext
-
- The SqlConnection element works in a similar way to
- QSqlDatabase::addDatabase(). It allows setting the database properties
- such that the connection does not need to be set up in C++ code.
- It differs from QSqlDatabase::addDatabase() in that it will automatically
- open the database.
-
- The database can then either be used from an SqlQuery element using its id
- as a bind, or using its name. If the database is set up externally to
- Qml the query should connect using its name.
-
- \qml
- <SqlConnection id="myConnection">
- <name>qmlConnection</name>
- <driver>QSQLITE</driver>
- <databaseName>"mydb.sqlite"</databaseName>
- </SqlConnection>
- <SqlQuery id="listmodel" connection="{myConnection}">SELECT * FROM mytable</SqlQuery>
- <SqlQuery id="othermodel" connection="qmlConnection">SELECT * FROM myothertable</SqlQuery>
- \endqml
-
- \endqmltext
*/
/*!
diff --git a/src/declarative/extra/qmlsqlquery.cpp b/src/declarative/extra/qmlsqlquery.cpp
index 39f4c1e..70b3bdd 100644
--- a/src/declarative/extra/qmlsqlquery.cpp
+++ b/src/declarative/extra/qmlsqlquery.cpp
@@ -67,16 +67,8 @@ public:
/*!
\qmlclass SqlBind QmlSqlBind
- \brief the SqlBind element specifies a value binding for an SqlQuery element.
-*/
+ \brief The SqlBind element specifies a value binding for an SqlQuery element.
-/*!
- \class QmlSqlBind
- \brief The QmlSqlBind class specifies a value binding for a QmlSqlQuery.
-
- \qmltext
-
- \qml
By using bindings its possible to cause a SqlQuery to update itself
when values bound through the SqlBind change. Hence in the example
below the results for the SqlQuery will change as searchText changes.
@@ -84,6 +76,7 @@ public:
If the query is not a SELECT statement, the effects of the bound
values will only apply when the SqlQuery exec() slot is called.
+ \qml
<SqlQuery>
SELECT * FROM mytable WHERE name LIKE :value
<bindings>
@@ -97,7 +90,12 @@ public:
</bindings>
<SqlQuery>
\endqml
- \endqmltext
+*/
+
+/*!
+ \internal
+ \class QmlSqlBind
+ \brief The QmlSqlBind class specifies a value binding for a QmlSqlQuery.
*/
/*!
@@ -235,13 +233,7 @@ public:
/*!
\qmlclass SqlQuery QmlSqlQuery
\brief The SqlQuery element describes a query into an SQL database.
-*/
-
-/*
- \class QmlSqlQuery
- \brief the QmlSqlQuery class manages a query into an SQL database.
- \qmltext
The SqlQuery element has three parts. The first is the query itself,
which can either be specified using the query property or by the
default text for the element. The second specifies the connection
@@ -256,11 +248,11 @@ public:
the query.
If the query is a select statement it can be used as a model for a ListView.
- The roles will be the columns of the result set. Use the SQL AS keyword
+ The roles will be the columns of the result set. Use the SQL AS keyword
in the query if you want to override the column names from that of the
table selected. You should also use the AS keyword if there is no
appropriate table column name for the result column.
-
+
\qml
<SqlQuery connection="{qmlConnectionId}" query="DELETE FROM mytable"/>
<SqlQuery connection="connectionName">
@@ -268,7 +260,11 @@ public:
</SqlQuery>
<SqlQuery>SELECT id AS recordId, (firstName || ' ' || lastName) AS fullName FROM mytable</SqlQuery>
\endqml
- \endqmltext
+*/
+
+/*
+ \class QmlSqlQuery
+ \brief the QmlSqlQuery class manages a query into an SQL database.
*/
/*!
diff --git a/src/declarative/extra/qmlxmllistmodel.cpp b/src/declarative/extra/qmlxmllistmodel.cpp
index 6b8f285..badc6fb 100644
--- a/src/declarative/extra/qmlxmllistmodel.cpp
+++ b/src/declarative/extra/qmlxmllistmodel.cpp
@@ -346,7 +346,7 @@ void QmlXmlListModel::doSubquery(int index) const
s.replace(QLatin1String("&gt;"), QLatin1String(">"));
s.replace(QLatin1String("&amp;"), QLatin1String("&"));
}
- resultList << s;
+ resultList << s.trimmed();
//qDebug() << s;
}
b.seek(0);
diff --git a/src/declarative/fx/qfxanchors.cpp b/src/declarative/fx/qfxanchors.cpp
index f537da9..540e1cb 100644
--- a/src/declarative/fx/qfxanchors.cpp
+++ b/src/declarative/fx/qfxanchors.cpp
@@ -151,7 +151,7 @@ void QFxAnchors::fillChanged()
/*!
\property QFxAnchors::fill
- \brief what item the item should fill.
+ \brief which item the item should fill.
This is a convenience property. It is the same as anchoring the left, right, top, and bottom
to another item's left, right, top, and bottom.
@@ -200,7 +200,7 @@ void QFxAnchors::setFill(QFxItem *f)
/*!
\property QFxAnchors::centeredIn
- \brief what item the item should stay centered in the middle of.
+ \brief which item the item should stay centered in.
This is a convenience property. It is the same as anchoring the horizontalCenter
and verticalCenter to another item's horizontalCenter and verticalCenter.
diff --git a/src/declarative/fx/qfxanimatedimageitem.cpp b/src/declarative/fx/qfxanimatedimageitem.cpp
index 5a495e9..7a1cb7f 100644
--- a/src/declarative/fx/qfxanimatedimageitem.cpp
+++ b/src/declarative/fx/qfxanimatedimageitem.cpp
@@ -66,7 +66,7 @@ QT_BEGIN_NAMESPACE
\row
\o \image animatedimageitem.gif
\o
- \code
+ \qml
Item {
width: anim.width; height: anim.height+8
AnimatedImage { id: anim; source: "pics/games-anim.gif" }
@@ -74,7 +74,7 @@ Item {
x: (anim.width-width)*anim.currentFrame/(anim.frameCount-1)
}
}
- \endcode
+ \endqml
\endtable
*/
QML_DEFINE_TYPE(QFxAnimatedImageItem, AnimatedImage);
diff --git a/src/declarative/fx/qfxblurfilter.cpp b/src/declarative/fx/qfxblurfilter.cpp
index ad3eebc..baa2253 100644
--- a/src/declarative/fx/qfxblurfilter.cpp
+++ b/src/declarative/fx/qfxblurfilter.cpp
@@ -64,25 +64,28 @@ public:
\brief The Blur filter blurs an item and its contents.
\inherits Filter
- Blurring reduces the clarity of a visual element. The following example
+ Blurring reduces the clarity of a visual item. The following example
shows an icon at a blur radius of 0, 5 and 10.
\table
\row
\o
- \code
- <HorizontalLayout>
- <Image src="icon.png">
- <filter><Blur radius="0" /></filter>
- </Image>
- <Image src="icon.png">
- <filter><Blur radius="5" /></filter>
- </Image>
- <Image src="icon.png">
- <filter><Blur radius="10" /></filter>
- </Image>
- </HorizontalLayout>
- \endcode
+ \qml
+HorizontalLayout {
+ Image {
+ source: "icon.png"
+ filter: Blur { radius: 0 }
+ }
+ Image {
+ source: "icon.png"
+ filter: Blur { radius: 5 }
+ }
+ Image {
+ source: "icon.png"
+ filter: Blur { radius: 10 }
+ }
+}
+ \endqml
\row
\o \image blur_example.png
\endtable
@@ -110,7 +113,9 @@ QFxBlurFilter::~QFxBlurFilter()
/*!
\qmlproperty real Blur::radius
- Sets the blur kernel radius. The larger the radius the more blurry the item will appear. A radius of 0 (or less) is equivalent to no blur.
+ Sets the blur kernel radius.
+ The larger the radius the more blurry the item will appear.
+ A radius of 0 (or less) is equivalent to no blur.
*/
/*!
diff --git a/src/declarative/fx/qfxcomponentinstance.cpp b/src/declarative/fx/qfxcomponentinstance.cpp
index 5fb5466..9645e77 100644
--- a/src/declarative/fx/qfxcomponentinstance.cpp
+++ b/src/declarative/fx/qfxcomponentinstance.cpp
@@ -58,9 +58,9 @@ QML_DEFINE_TYPE(QFxComponentInstance,ComponentInstance);
/*!
\qmlclass ComponentInstance QFxComponentInstance
- \brief The ComponentInstance element allows you to instantiate a \l{qml-component.html} {Component}.
+ \brief The ComponentInstance item allows you to instantiate a \l{qml-component.html} {Component}.
- \code
+ \qml
Item {
Component {
id: RedSquare
@@ -69,7 +69,7 @@ QML_DEFINE_TYPE(QFxComponentInstance,ComponentInstance);
ComponentInstance { component: RedSquare }
}
- \endcode
+ \endqml
*/
QFxComponentInstance::QFxComponentInstance(QFxItem *parent)
: QFxItem(*(new QFxComponentInstancePrivate), parent)
diff --git a/src/declarative/fx/qfxcontentwrapper.cpp b/src/declarative/fx/qfxcontentwrapper.cpp
index a155d2b..2b95ff6 100644
--- a/src/declarative/fx/qfxcontentwrapper.cpp
+++ b/src/declarative/fx/qfxcontentwrapper.cpp
@@ -108,22 +108,31 @@ QML_DEFINE_TYPE(QFxContent,Content);
specified by Content.
Example:
- \code
- <!--GroupBox component definition-->
- <Rect width="{parent.width}" color="white" pen.width="2" pen.color="#adaeb0" radius="10" clip="false" height="{contents.height}">
- <VerticalLayout id="layout" width="{parent.width}">
- <Content/>
- </VerticalLayout>
- </Rect>
-
- <!--component use-->
- <GroupBox>
- <content>
- <Text text="First Item"/>
- ...
- </content>
- </GroupBox>
- \endcode
+ \qml
+// GroupBox component definition
+Rect {
+ width: parent.width
+ color: "white"
+ pen.width: 2
+ pen.color: "#adaeb0"
+ radius: 10
+ clip: false
+ height: contents.height
+ VerticalLayout {
+ id: layout
+ width: parent.width
+ Content { } // content property will go here
+ }
+}
+
+// component use
+GroupBox {
+ content: Text {
+ text: "First Item"
+ ...
+ }
+}
+ \endqml
*/
QT_END_NAMESPACE
diff --git a/src/declarative/fx/qfxevents.cpp b/src/declarative/fx/qfxevents.cpp
index 7d04f5d..195d1e5 100644
--- a/src/declarative/fx/qfxevents.cpp
+++ b/src/declarative/fx/qfxevents.cpp
@@ -44,17 +44,18 @@
QT_BEGIN_NAMESPACE
/*!
\qmlclass KeyEvent QFxKeyEvent
- \brief The KeyEvent element provides information about a key event.
+ \brief The KeyEvent object provides information about a key event.
For example, the following changes the Item's state property when the Enter
key is pressed:
- \code
- <Item focus="true">
- <onKeyPress>if (event.key == Qt.Key_Enter) state = 'ShowDetails';</onKeyPress>
- </Item>
- \endcode
-
- The \l KeyActions element could also be used to achieve the above with
+ \qml
+Item {
+ focus: true
+ onKeyPress: { if (event.key == Qt.Key_Enter) state = 'ShowDetails'; }
+}
+ \endqml
+
+ The \l KeyActions object could also be used to achieve the above with
a clearer syntax.
\sa KeyActions
@@ -106,7 +107,7 @@ QT_BEGIN_NAMESPACE
/*!
\qmlclass MouseEvent QFxMouseEvent
- \brief The MouseEvent element provides information about a mouse event.
+ \brief The MouseEvent object provides information about a mouse event.
The position of the mouse can be found via the x and y properties.
The button that caused the event is available via the button property.
@@ -168,15 +169,11 @@ QT_BEGIN_NAMESPACE
\endlist
For example, to react to a Shift key + Left mouse button click:
- \code
- <MouseRegion>
- <onClick>
- <![CDATA[
- if (mouse.button == Qt.LeftButton && mouse.modifiers & Qt.ShiftModifier) doSomething();
- ]]>
- </onclick>
- </MouseRegion>
- \endcode
+ \qml
+MouseRegion {
+ onClick: { if (mouse.button == Qt.LeftButton && mouse.modifiers & Qt.ShiftModifier) doSomething(); }
+}
+ \endqml
*/
QML_DEFINE_NOCREATE_TYPE(QFxKeyEvent);
diff --git a/src/declarative/fx/qfxflickable.cpp b/src/declarative/fx/qfxflickable.cpp
index 17e44e1..52b142b 100644
--- a/src/declarative/fx/qfxflickable.cpp
+++ b/src/declarative/fx/qfxflickable.cpp
@@ -226,7 +226,7 @@ QML_DEFINE_TYPE(QFxFlickable,Flickable);
/*!
\qmlclass Flickable
- \brief The Flickable element provides a surface that can be "flicked".
+ \brief The Flickable item provides a surface that can be "flicked".
\inherits Item
Flickable places its children on a surface that can be dragged and flicked.
diff --git a/src/declarative/fx/qfxflipable.cpp b/src/declarative/fx/qfxflipable.cpp
index 81ed750..db390d2 100644
--- a/src/declarative/fx/qfxflipable.cpp
+++ b/src/declarative/fx/qfxflipable.cpp
@@ -64,34 +64,44 @@ public:
/*!
\qmlclass Flipable QFxFlipable
- \brief The Flipable element provides a surface that can be flipped.
+ \brief The Flipable item provides a surface that can be flipped.
\inherits Item
Flipable allows you to specify a front and a back and then flip between those sides.
- \code
- <Flipable id="flipable" width="40" height="40">
- <axis>
- <Axis startX="20" startY="0" endX="20" endY="40" />
- </axis>
- <front>
- <Image src="front.png"/>
- </front>
- <back>
- <Image src="back.png"/>
- </back>
- <states>
- <State name="back">
- <SetProperty target="{flipable}" property="rotation" value="180" />
- </State>
- </states>
- <transitions>
- <Transition>
- <NumericAnimation easing="easeInOutQuad" properties="rotation"/>
- </Transition>
- </transitions>
- </Flipable>
- \endcode
+ \qml
+Flipable {
+ id: flipable
+ width: 40
+ height: 40
+ axis: Axis {
+ startX: 20
+ startY: 0
+ endX: 20
+ endY: 40
+ }
+ front: Image { src: "front.png" }
+ back: Image { src: "back.png" }
+ states: [
+ State {
+ name: "back"
+ SetProperty {
+ target: flipable
+ property: "rotation"
+ value: 180
+ }
+ }
+ ]
+ transitions: [
+ Transition {
+ NumericAnimation {
+ easing: "easeInOutQuad"
+ properties: "rotation"
+ }
+ }
+ ]
+}
+ \endqml
\image flipable.gif
*/
diff --git a/src/declarative/fx/qfxfocuspanel.cpp b/src/declarative/fx/qfxfocuspanel.cpp
index 67c456e..5d62e66 100644
--- a/src/declarative/fx/qfxfocuspanel.cpp
+++ b/src/declarative/fx/qfxfocuspanel.cpp
@@ -47,7 +47,7 @@ QML_DEFINE_TYPE(QFxFocusPanel,FocusPanel);
/*!
\qmlclass FocusPanel
- \brief The FocusPanel element explicitly creates a focus panel.
+ \brief The FocusPanel object explicitly creates a focus panel.
\inherits Item
Focus panels assist in keyboard focus handling when building QML
@@ -73,7 +73,7 @@ QFxFocusPanel::~QFxFocusPanel()
/*!
\qmlproperty bool FocusPanel::active
- Sets whether the element is the active focus panel.
+ Sets whether the object is the active focus panel.
*/
bool QFxFocusPanel::isActive() const
diff --git a/src/declarative/fx/qfxfocusrealm.cpp b/src/declarative/fx/qfxfocusrealm.cpp
index da3f1b2..07849fa 100644
--- a/src/declarative/fx/qfxfocusrealm.cpp
+++ b/src/declarative/fx/qfxfocusrealm.cpp
@@ -47,7 +47,7 @@ QML_DEFINE_TYPE(QFxFocusRealm,FocusRealm);
/*!
\qmlclass FocusRealm
- \brief The FocusRealm element explicitly creates a focus realm.
+ \brief The FocusRealm object explicitly creates a focus realm.
\inherits Item
Focus realms assist in keyboard focus handling when building reusable QML
diff --git a/src/declarative/fx/qfxgridview.cpp b/src/declarative/fx/qfxgridview.cpp
index b8acea2..8416234 100644
--- a/src/declarative/fx/qfxgridview.cpp
+++ b/src/declarative/fx/qfxgridview.cpp
@@ -647,7 +647,7 @@ void QFxGridViewPrivate::updateCurrent(int modelIndex)
/*!
\qmlclass GridView
\inherits Flickable
- \brief The GridView element provides a grid view of items provided by a model.
+ \brief The GridView item provides a grid view of items provided by a model.
The model is typically provided by a QAbstractListModel "C++ model object",
but can also be created directly in QML.
@@ -706,7 +706,7 @@ QFxGridView::~QFxGridView()
The C++ model object must be a \l QListModelInterface subclass, a \l VisualModel,
or a simple list.
- Models can also be created directly in QML, using the \l ListModel element. For example:
+ Models can also be created directly in QML, using the \l ListModel object. For example:
\code
<ListModel id="contactModel">
<Contact>
diff --git a/src/declarative/fx/qfxhighlightfilter.cpp b/src/declarative/fx/qfxhighlightfilter.cpp
index 70b50cd..862a698 100644
--- a/src/declarative/fx/qfxhighlightfilter.cpp
+++ b/src/declarative/fx/qfxhighlightfilter.cpp
@@ -73,18 +73,24 @@ public:
\brief The Highlight filter adds a highlight to an item.
\inherits Filter
- \code
-<Text id="highlighttext" color="red" font.size="32" text="Highlight">
- <filter>
- <Highlight src="pics/highlight.png">
- <xOffset>
- <NumericAnimation running="true" repeat="true"
- from="320" to="-320" duration="2000"/>
- </xOffset>
- </Highlight>
- </filter>
-</Text>
- \endcode
+ \qml
+Text {
+ id: highlighttext
+ color: "red"
+ font.size: 32
+ text: "Highlight"
+ filter: Highlight {
+ source: "pics/highlight.png"
+ xOffset: NumericAnimation {
+ running: true
+ repeat: true
+ from: 320
+ to: -320
+ duration: 2000
+ }
+ }
+}
+ \endqml
\image highlight.gif
Highlighting is only supported when Qt Declarative is compiled for OpenGL ES 2.0.
@@ -114,7 +120,7 @@ QFxHighlightFilter::~QFxHighlightFilter()
}
/*!
- \qmlproperty string Highlight::src
+ \qmlproperty string Highlight::source
This property holds the URL of the image to be used as the highlight.
*/
diff --git a/src/declarative/fx/qfximage.cpp b/src/declarative/fx/qfximage.cpp
index 1361d68..53c6137 100644
--- a/src/declarative/fx/qfximage.cpp
+++ b/src/declarative/fx/qfximage.cpp
@@ -60,36 +60,38 @@ QML_DEFINE_TYPE(QFxImage,Image);
\brief The Image element allows you to add bitmaps to a scene.
\inherits Item
- The Image element supports untransformed, stretched, grid-scaled and tiled images. For an explanation of grid-scaling see the scaleGrid property description or the QFxScaleGrid class description.
+ The Image element supports untransformed, stretched, grid-scaled and tiled images.
+ For an explanation of grid-scaling see the scaleGrid property description
+ or the QFxScaleGrid class description.
Examples:
\table
\row
\o \image declarative-qtlogo1.png
\o Untransformed
- \code
+ \qml
Image { source: "pics/qtlogo.png" }
- \endcode
+ \endqml
\row
\o \image declarative-qtlogo2.png
\o Stretched
- \code
+ \qml
Image { width: 160; height: 160; source: "pics/qtlogo.png" }
- \endcode
+ \endqml
\row
\o \image declarative-qtlogo4.png
\o Grid-scaled
- \code
+ \qml
Image { scaleGrid.left: 20; scaleGrid.right: 10
scaleGrid.top: 14; scaleGrid.bottom: 14
width: 160; height: 160; source: "pics/qtlogo.png" }
- \endcode
+ \endqml
\row
\o \image declarative-qtlogo3.png
\o Tiled
- \code
+ \qml
Image { tile: true; width: 160; height: 160; source: "pics/qtlogo.png" }
- \endcode
+ \endqml
\endtable
*/
@@ -101,9 +103,9 @@ QML_DEFINE_TYPE(QFxImage,Image);
\ingroup group_coreitems
Example:
- \code
+ \qml
Image { source: "pics/star.png" }
- \endcode
+ \endqml
A QFxImage object can be instantiated in Qml using the tag \l Image.
*/
@@ -198,13 +200,13 @@ QFxScaleGrid *QFxImage::scaleGrid()
bitmap file to its size. If tiling is enabled, the bitmap is repeated as a set
of unscaled tiles, clipped to the size of the Image.
- \code
+ \qml
Item {
Image { source: "tile.png" }
Image { x: 80; width: 100; height: 100; src: "tile.png" }
Image { x: 190; width: 100; height: 100; tile: true; src: "tile.png" }
}
- \endcode
+ \endqml
\image declarative-image_tile.png
If both tiling and the scaleGrid are set, tiling takes precedence.
diff --git a/src/declarative/fx/qfximageitem.cpp b/src/declarative/fx/qfximageitem.cpp
index 52ab009..d751845 100644
--- a/src/declarative/fx/qfximageitem.cpp
+++ b/src/declarative/fx/qfximageitem.cpp
@@ -58,10 +58,10 @@ QT_BEGIN_NAMESPACE
/*!
\class QFxImageItem
- \brief The QFxImageItem class is an abstract base class for QFxView items that render using QPainter.
+ \brief The QFxImageItem class is an abstract base class for QFxView items that want cached painting.
\ingroup group_coreitems
- This is a convenience class allowing easy use of a QPainter within a custom
+ This is a convenience class allowing easy use of cached painting within a custom
item. The contents of the item are are cached behind the scenes.
The dirtyCache() function should be called if the contents change to
ensure the cache is refreshed the next time painting occurs.
diff --git a/src/declarative/fx/qfxitem.cpp b/src/declarative/fx/qfxitem.cpp
index 38b5713..84dc484 100644
--- a/src/declarative/fx/qfxitem.cpp
+++ b/src/declarative/fx/qfxitem.cpp
@@ -206,7 +206,7 @@ void QFxContents::setItem(QFxItem *item)
/*!
\qmlclass Item QFxItem
- \brief The Item element is the most basic of all visual canvas members.
+ \brief The Item is the most basic of all visual items in QML.
*/
/*!
@@ -214,19 +214,32 @@ void QFxContents::setItem(QFxItem *item)
\brief The QFxItem class is a generic QFxView item. It is the base class for all other view items.
\qmltext
- All visual elements in Qt Declarative inherit from QFxItem. Although QFxItem
+ All visual items in Qt Declarative inherit from QFxItem. Although QFxItem
has no visual appearance, it defines all the properties that are
- common across visual elements - like the x and y position, and the
+ common across visual items - like the x and y position, and the
width and height.
- QFxItem is also useful for grouping elements together.
+ QFxItem is also useful for grouping items together.
\qml
- <Item>
- <Image file="tile.png" />
- <Image x="80" width="100" height="100" file="tile.png" />
- <Image x="190" width="100" height="100" tile="true" file="tile.png" />
- </Item>
+ Item {
+ Image {
+ file: "tile.png"
+ }
+ Image {
+ x: 80
+ width: 100
+ height: 100
+ file: "tile.png"
+ }
+ Image {
+ x: 190
+ width: 100
+ height: 100
+ tile: true
+ file: "tile.png"
+ }
+ }
\endqml
\endqmltext
@@ -260,7 +273,7 @@ void QFxContents::setItem(QFxItem *item)
via the baselineOffset property.
The baseline corresponds to the baseline of the text contained in
- the element. It is useful for aligning the text in items placed
+ the item. It is useful for aligning the text in items placed
beside each other. The default baseline is positioned at
2/3 of the height of the item.
*/
@@ -335,7 +348,9 @@ void QFxContents::setItem(QFxItem *item)
The key event is available via the KeyEvent \a event.
\qml
- <Item onKeyPress="if (event.key == Qt.Key_Enter) state='Enter'"/>
+ Item {
+ onKeyPress: { if (event.key == Qt.Key_Enter) state='Enter' }
+ }
\endqml
*/
@@ -347,7 +362,9 @@ void QFxContents::setItem(QFxItem *item)
The key event is available in via the KeyEvent \a event.
\qml
- <Item onKeyRelease="if (event.key == Qt.Key_Enter) state='Enter'"/>
+ Item {
+ onKeyRelease: { if (event.key == Qt.Key_Enter) state='Enter' }
+ }
\endqml
*/
@@ -429,9 +446,13 @@ QFxItem::~QFxItem()
\image declarative-transformorigin.png
This example scales an image about its center.
- \code
- <Image src="myimage.png" transformOrigin="Center" scale="4" />
- \endcode
+ \qml
+ Image {
+ src: "myimage.png"
+ transformOrigin: "Center"
+ scale: 4
+ }
+ \endqml
The default transform origin is \c TopLeft.
*/
@@ -522,7 +543,7 @@ QFxItem *QFxItem::itemParent() const
\qmlproperty list<Item> Item::children
\qmlproperty list<Object> Item::resources
- The children property contains the list of visual children of this element.
+ The children property contains the list of visual children of this item.
The resources property contains non-visual resources that you want to
reference by name.
@@ -702,7 +723,7 @@ void QFxItemPrivate::children_clear()
\default
The data property is allows you to freely mix visual children and resources
- of an element. If you assign a visual element to the data list it becomes
+ of an item. If you assign a visual item to the data list it becomes
a child and if you assign any other object type, it is added as a resource.
So you can write:
@@ -1583,12 +1604,20 @@ void QFxItem::setKeepMouseGrab(bool keep)
d->_keepMouse = keep;
}
-void QFxItem::activeFocusChanged(bool)
+/*!
+ This function emits the \e activeFocusChanged signal.
+ \a flag is not used.
+ */
+void QFxItem::activeFocusChanged(bool flag)
{
emit activeFocusChanged();
}
-void QFxItem::focusChanged(bool)
+/*!
+ This function emits the \e focusChanged signal.
+ \a flag is not used.
+ */
+void QFxItem::focusChanged(bool flag)
{
emit focusChanged();
}
@@ -1926,7 +1955,7 @@ void QFxItem::classComplete()
}
/*!
- componentComplete() is called when all elements in the component
+ componentComplete() is called when all items in the component
have been constructed. It is often desireable to delay some
processing until the component is complete an all bindings in the
component have been resolved.
diff --git a/src/declarative/fx/qfxkeyactions.cpp b/src/declarative/fx/qfxkeyactions.cpp
index 52a013a..a07f047 100644
--- a/src/declarative/fx/qfxkeyactions.cpp
+++ b/src/declarative/fx/qfxkeyactions.cpp
@@ -169,22 +169,22 @@ void QFxKeyActionsPrivate::setBit(int b, bool v)
/*!
\qmlclass KeyActions
- \brief The KeyActions element enables simple key handling.
+ \brief The KeyActions item enables simple key handling.
\inherits Item
KeyActions is typically used in basic key handling scenarios where writing
JavaScript key handling routines would be unnecessarily complicated. The
- KeyActions element has a collection of properties that correspond to a
- selection of common keys. When a given key is pressed, the element executes
+ KeyActions item has a collection of properties that correspond to a
+ selection of common keys. When a given key is pressed, the item executes
the action script assigned to the matching property. If no action has
- been set the KeyActions element does nothing.
+ been set the KeyActions item does nothing.
To receive (and susequently respond to) key presses, the KeyActions class
- must be in the current focus chain, just like any other element.
+ must be in the current focus chain, just like any other item.
For basic mouse handling, see \l MouseRegion.
- KeyActions is an invisible element: it is never painted.
+ KeyActions is an invisible item: it is never painted.
*/
QFxKeyActions::QFxKeyActions(QFxItem *parent)
: QFxItem(parent), d(new QFxKeyActionsPrivate)
@@ -221,7 +221,7 @@ void QFxKeyActionsPrivate::setKeyExpr(Qt::Key k, const QString &expr)
\qmlproperty bool KeyActions::enabled
Enables or disables KeyActions' key handling. When not enabled, the
- KeyActions instance does not respond to any key presses. The element is
+ KeyActions instance does not respond to any key presses. The item is
enabled by default.
*/
bool QFxKeyActions::enabled() const
@@ -244,9 +244,9 @@ void QFxKeyActions::setEnabled(bool e)
The action to take for the given letter.
The following example sets actions for the 'c' and 'x' keys.
- \code
+ \qml
KeyActions { keyC: "print('c is for cookie')"; keyX: "print('I like cookies')" }
- \endcode
+ \endqml
*/
QString QFxKeyActions::key_A() const
{
@@ -518,9 +518,9 @@ void QFxKeyActions::setKey_Z(const QString &s)
The action to take for the given arrow key.
The following example sets actions for the left and right arrow keys.
- \code
+ \qml
KeyActions { leftArrow: "print('You pressed left')"; rightArrow: "print('You pressed right')" }
- \endcode
+ \endqml
*/
QString QFxKeyActions::key_Left() const
@@ -569,9 +569,9 @@ void QFxKeyActions::setKey_Down(const QString &s)
The action to take for the given number key.
The following example sets actions for the '5' and '6' keys.
- \code
+ \qml
KeyActions { digit5: "print('5 is a prime number')"; digit6: "print('6 is a composite number')"; focus: true }
- \endcode
+ \endqml
*/
QString QFxKeyActions::key_0() const
@@ -744,9 +744,9 @@ void QFxKeyActions::setKey_Space(const QString &s)
The action to take for the given utility key.
The following example sets an action for the space key.
- \code
+ \qml
KeyActions { space: "print('Space pressed')" }
- \endcode
+ \endqml
*/
/*!
@@ -765,9 +765,9 @@ void QFxKeyActions::setKey_Space(const QString &s)
The action to take for the given device key.
The following example sets an action for the hangup key.
- \code
+ \qml
KeyActions { hangup: "print('Go away now')" }
- \endcode
+ \endqml
*/
QString QFxKeyActions::key_Back() const
diff --git a/src/declarative/fx/qfxkeyproxy.cpp b/src/declarative/fx/qfxkeyproxy.cpp
index 6d92441..6d9c6ab 100644
--- a/src/declarative/fx/qfxkeyproxy.cpp
+++ b/src/declarative/fx/qfxkeyproxy.cpp
@@ -47,7 +47,7 @@ QML_DEFINE_TYPE(QFxKeyProxy,KeyProxy);
/*!
\qmlclass KeyProxy
- \brief The KeyProxy element proxies key presses to a number of other elements.
+ \brief The KeyProxy item proxies key presses to a number of other items.
\inherits Item
*/
@@ -55,7 +55,7 @@ QML_DEFINE_TYPE(QFxKeyProxy,KeyProxy);
/*!
\internal
\class QFxKeyProxy
- \brief The QFxKeyProxy class proxies key presses to a number of other elements.
+ \brief The QFxKeyProxy class proxies key presses to a number of other items.
\ingroup group_utility
*/
diff --git a/src/declarative/fx/qfxlayouts.cpp b/src/declarative/fx/qfxlayouts.cpp
index 76afeb0..85b198e 100644
--- a/src/declarative/fx/qfxlayouts.cpp
+++ b/src/declarative/fx/qfxlayouts.cpp
@@ -127,15 +127,18 @@ void QFxBaseLayout::setMargin(int s)
\property QFxBaseLayout::move
\brief the transition when moving an item.
- \code
- <BaseLayout id="layout" y="0">
- <move>
- <Transition>
- <NumericAnimation properties="y" ease="easeOutBounce" />
- </Transition>
- </move>
- </BaseLayout>
- \endcode
+ \qml
+BaseLayout {
+ id: layout
+ y: 0
+ move: Transition {
+ NumericAnimation {
+ properties: "y"
+ ease: "easeOutBounce"
+ }
+ }
+}
+ \endqml
*/
QmlTransition *QFxBaseLayout::move() const
{
@@ -153,15 +156,21 @@ void QFxBaseLayout::setMove(QmlTransition *mt)
\property QFxBaseLayout::add
\brief the transition when adding an item.
- \code
- <BaseLayout id="layout" y="0">
- <add>
- <Transition >
- <NumericAnimation target="{layout.item}" properties="opacity" from="0" to="1" duration="500" />
- </Transition>
- </add>
- </BaseLayout>
- \endcode
+ \qml
+BaseLayout {
+ id: layout
+ y: 0
+ add: Transition {
+ NumericAnimation {
+ target: layout.item
+ properties: "opacity"
+ from: 0
+ to: 1
+ duration: 500
+ }
+ }
+}
+ \endqml
*/
QmlTransition *QFxBaseLayout::add() const
{
@@ -182,15 +191,21 @@ void QFxBaseLayout::setAdd(QmlTransition *add)
Note that the item may be 'removed' because its opacity is zero. This can make certain
transitions difficult to see.
- \code
- <BaseLayout id="layout" y="0">
- <remove>
- <Transition >
- <NumericAnimation target="{layout.item}" properties="opacity" from="1" to="0" duration="500" />
- </Transition>
- </remove>
- </BaseLayout>
- \endcode
+ \qml
+BaseLayout {
+ id: layout
+ y: 0
+ remove: Transition {
+ NumericAnimation {
+ target: layout.item
+ properties: "opacity"
+ from: 1
+ to: 0
+ duration: 500
+ }
+ }
+}
+ \endqml
*/
QmlTransition *QFxBaseLayout::remove() const
{
@@ -433,10 +448,10 @@ void QFxBaseLayout::applyRemove(const QList<QPair<QString, QVariant> >& changes,
QML_DEFINE_TYPE(QFxVerticalLayout, VerticalLayout);
/*!
\qmlclass VerticalLayout
- \brief The VerticalLayout element arranges its children in a vertical layout.
+ \brief The VerticalLayout item arranges its children in a vertical layout.
\inherits Item
- The VerticalLayout element arranges its child elements so that they are vertically
+ The VerticalLayout item arranges its child items so that they are vertically
aligned and not overlapping. Spacing between items can be added, as can a margin around all the items.
The below example lays out differently shaped rectangles using a VerticalLayout.
@@ -444,32 +459,34 @@ QML_DEFINE_TYPE(QFxVerticalLayout, VerticalLayout);
\row
\o \image verticalLayout_example.png
\o
- \code
- <VerticalLayout spacing="2">
- <Rect color="red" width="50" height="50"/>
- <Rect color="green" width="20" height="50"/>
- <Rect color="blue" width="50" height="20"/>
- </VerticalLayout>
- \endcode
+ \qml
+VerticalLayout {
+ spacing: 2
+ Rect { color: "red"; width: 50; height: 50 }
+ Rect { color: "green"; width: 20; height: 50 }
+ Rect { color: "blue"; width: 50; height: 20 }
+}
+ \endqml
\endtable
VerticalLayout also provides for transitions to be set when items are added, moved,
- or removed in the layout. Adding and removing apply both to elements which are deleted
+ or removed in the layout. Adding and removing apply both to items which are deleted
or have their position in the document changed so as to no longer be children of the layout,
- as well as to elements which have their opacity set to or from zero so as to appear or disappear.
+ as well as to items which have their opacity set to or from zero so as to appear or disappear.
\table
\row
\o \image verticalLayout_transition.gif
\o
- \code
- <VerticalLayout spacing="2">
- ...
- <remove>...</remove>
- <add>...</add>
- <move>...</move>
- </VerticalLayout>
- \endcode
+ \qml
+VerticalLayout {
+ spacing: 2
+ remove: ...
+ add: ...
+ move: ...
+ ...
+}
+ \endqml
\endtable
@@ -486,17 +503,20 @@ QML_DEFINE_TYPE(QFxVerticalLayout, VerticalLayout);
\row
\o \image layout-remove.gif
\o
- \code
- <VerticalLayout id="layout">
- <remove>
- <Transition >
- <NumericAnimation target="{layout.item}"
- properties="opacity" from="1" to="0"
- duration="500" />
- </Transition>
- </remove>
- </VerticalLayout>
- \endcode
+ \qml
+VerticalLayout {
+ id: layout
+ remove: Transition {
+ NumericAnimation {
+ target: layout.item
+ properties: "opacity"
+ from: 1
+ to: 0
+ duration: 500
+ }
+ }
+}
+ \endqml
\endtable
*/
@@ -510,17 +530,20 @@ QML_DEFINE_TYPE(QFxVerticalLayout, VerticalLayout);
\row
\o \image layout-add.gif
\o
- \code
- <VerticalLayout id="layout">
- <add>
- <Transition >
- <NumericAnimation target="{layout.item}"
- properties="opacity" from="0" to="1"
- duration="500" />
- </Transition>
- </add>
- </VerticalLayout>
- \endcode
+ \qml
+VerticalLayout {
+ id: layout
+ add: Transition {
+ NumericAnimation {
+ target: layout.item
+ properties: "opacity"
+ from: 0
+ to: 1
+ duration: 500
+ }
+ }
+}
+ \endqml
\endtable
*/
@@ -534,15 +557,17 @@ QML_DEFINE_TYPE(QFxVerticalLayout, VerticalLayout);
\row
\o \image layout-move.gif
\o
- \code
- <VerticalLayout id="layout">
- <move>
- <Transition>
- <NumericAnimation properties="y" ease="easeOutBounce" />
- </Transition>
- </move>
- </VerticalLayout>
- \endcode
+ \qml
+VerticalLayout {
+ id: layout
+ move: Transition {
+ NumericAnimation {
+ properties: "y"
+ ease: "easeOutBounce"
+ }
+ }
+}
+ \endqml
\endtable
*/
/*!
@@ -624,19 +649,20 @@ void QFxVerticalLayout::doLayout()
QML_DEFINE_TYPE(QFxHorizontalLayout,HorizontalLayout);
/*!
\qmlclass HorizontalLayout
- \brief The HorizontalLayout element arranges its children in a horizontal layout.
+ \brief The HorizontalLayout item arranges its children in a horizontal layout.
\inherits Item
- The HorizontalLayout element arranges its child elements so that they are horizontally aligned and not overlapping. Spacing can be added between the items, and a margin around all items can also be added. It also provides for transitions to be set when items are added, moved, or removed in the layout. Adding and removing apply both to elements which are deleted or have their position in the document changed so as to no longer be children of the layout, as well as to elements which have their opacity set to or from zero so as to appear or disappear.
+ The HorizontalLayout item arranges its child items so that they are horizontally aligned and not overlapping. Spacing can be added between the items, and a margin around all items can also be added. It also provides for transitions to be set when items are added, moved, or removed in the layout. Adding and removing apply both to items which are deleted or have their position in the document changed so as to no longer be children of the layout, as well as to items which have their opacity set to or from zero so as to appear or disappear.
The below example lays out differently shaped rectangles using a HorizontalLayout.
- \code
- <HorizontalLayout spacing="2">
- <Rect color="red" width="50" height="50"/>
- <Rect color="green" width="20" height="50"/>
- <Rect color="blue" width="50" height="20"/>
- </HorizontalLayout>
- \endcode
+ \qml
+HorizontalLayout {
+ spacing: 2
+ Rect { color: "red"; width: 50; height: 50 }
+ Rect { color: "green"; width: 20; height: 50 }
+ Rect { color: "blue"; width: 50; height: 20 }
+}
+ \endqml
\image horizontalLayout_example.png
*/
@@ -648,15 +674,20 @@ QML_DEFINE_TYPE(QFxHorizontalLayout,HorizontalLayout);
Note that if the item counts as removed because its opacity is zero it will not be visible during the transition unless you set the opacity in the transition, like in the below example.
- \code
- <HorizontalLayout id="layout">
- <remove>
- <Transition >
- <NumericAnimation target="{layout.item}" properties="opacity" from="1" to="0" duration="500" />
- </Transition>
- </remove>
- </HorizontalLayout>
- \endcode
+ \qml
+HorizontalLayout {
+ id: layout
+ remove: Transition {
+ NumericAnimation {
+ target: layout.item
+ properties: "opacity"
+ from: 1
+ to: 0
+ duration: 500
+ }
+ }
+}
+ \endqml
*/
/*!
@@ -665,15 +696,20 @@ QML_DEFINE_TYPE(QFxHorizontalLayout,HorizontalLayout);
Added can mean that either the object has been created or reparented, and thus is now a child or the layout, or that the object has had its opacity increased from zero, and thus is now visible.
- \code
- <HorizontalLayout id="layout">
- <add>
- <Transition >
- <NumericAnimation target="{layout.item}" properties="opacity" from="0" to="1" duration="500" />
- </Transition>
- </add>
- </HorizontalLayout>
- \endcode
+ \qml
+HorizontalLayout {
+ id: layout
+ add: Transition {
+ NumericAnimation {
+ target: layout.item
+ properties: "opacity"
+ from: 0
+ to: 1
+ duration: 500
+ }
+ }
+}
+ \endqml
*/
/*!
@@ -682,15 +718,17 @@ QML_DEFINE_TYPE(QFxHorizontalLayout,HorizontalLayout);
This can happen when other items are added or removed from the layout, or when items resize themselves.
- \code
- <HorizontalLayout id="layout">
- <move>
- <Transition>
- <NumericAnimation properties="x" ease="easeOutBounce" />
- </Transition>
- </move>
- </HorizontalLayout>
- \endcode
+ \qml
+HorizontalLayout {
+ id: layout
+ move: Transition {
+ NumericAnimation {
+ properties: "x"
+ ease: "easeOutBounce"
+ }
+ }
+}
+ \endqml
*/
/*!
@@ -776,21 +814,21 @@ QML_DEFINE_TYPE(QFxGridLayout,GridLayout);
/*!
\qmlclass GridLayout QFxGridLayout
- \brief The GridLayout element arranges its children in a grid layout.
+ \brief The GridLayout item arranges its children in a grid layout.
\inherits Item
- The GridLayout element arranges its child elements so that they are
+ The GridLayout item arranges its child items so that they are
aligned in a grid and are not overlapping. Spacing can be added
between the items, and a margin around all the items can also be
defined. It also provides for transitions to be set when items are
added, moved, or removed in the layout. Adding and removing apply
- both to elements which are deleted or have their position in the
+ both to items which are deleted or have their position in the
document changed so as to no longer be children of the layout, as
- well as to elements which have their opacity set to or from zero so
+ well as to items which have their opacity set to or from zero so
as to appear or disappear.
The GridLayout defaults to using four columns, and as many rows as
- are necessary to fit all the child elements. The number of rows
+ are necessary to fit all the child items. The number of rows
and/or the number of columns can be constrained by setting the rows
or columns properties. The grid layout calculates a grid with
rectangular cells of sufficient size to hold all items, and then
@@ -802,15 +840,17 @@ QML_DEFINE_TYPE(QFxGridLayout,GridLayout);
\row
\o \image gridLayout_example.png
\o
- \code
- <GridLayout columns="3" spacing="2">
- <Rect color="red" width="50" height="50"/>
- <Rect color="green" width="20" height="50"/>
- <Rect color="blue" width="50" height="20"/>
- <Rect color="cyan" width="50" height="50"/>
- <Rect color="magenta" width="10" height="10"/>
- </GridLayout>
- \endcode
+ \qml
+GridLayout {
+ columns: 3
+ spacing: 2
+ Rect { color: "red"; width: 50; height: 50 }
+ Rect { color: "green"; width: 20; height: 50 }
+ Rect { color: "blue"; width: 50; height: 20 }
+ Rect { color: "cyan"; width: 50; height: 50 }
+ Rect { color: "magenta"; width: 10; height: 10 }
+}
+ \endqml
\endtable
*/
/*!
@@ -826,15 +866,20 @@ QML_DEFINE_TYPE(QFxGridLayout,GridLayout);
zero it will not be visible during the transition unless you set
the opacity in the transition, like in the below example.
- \code
- <GridLayout id="layout">
- <remove>
- <Transition >
- <NumericAnimation target="{layout.item}" properties="opacity" from="1" to="0" duration="500" />
- </Transition>
- </remove>
- </GridLayout>
- \endcode
+ \qml
+GridLayout {
+ id: layout
+ remove: Transition {
+ NumericAnimation {
+ target: layout.item
+ properties: "opacity"
+ from: 1
+ to: 0
+ duration: 500
+ }
+ }
+}
+ \endqml
*/
/*!
@@ -846,15 +891,20 @@ QML_DEFINE_TYPE(QFxGridLayout,GridLayout);
object has had its opacity increased from zero, and thus is now
visible.
- \code
- <GridLayout id="layout">
- <add>
- <Transition >
- <NumericAnimation target="{layout.item}" properties="opacity" from="0" to="1" duration="500" />
- </Transition>
- </add>
- </GridLayout>
- \endcode
+ \qml
+GridLayout {
+ id: layout
+ add: Transition {
+ NumericAnimation {
+ target: layout.item
+ properties: "opacity"
+ from: 0
+ to: 1
+ duration: 500
+ }
+ }
+}
+ \endqml
*/
/*!
@@ -864,15 +914,17 @@ QML_DEFINE_TYPE(QFxGridLayout,GridLayout);
This can happen when other items are added or removed from the layout, or
when items resize themselves.
- \code
- <GridLayout id="layout">
- <move>
- <Transition>
- <NumericAnimation properties="x,y" ease="easeOutBounce" />
- </Transition>
- </move>
- </GridLayout>
- \endcode
+ \qml
+GridLayout {
+ id: layout
+ move: Transition {
+ NumericAnimation {
+ properties: "x,y"
+ ease: "easeOutBounce"
+ }
+ }
+}
+ \endqml
*/
/*!
diff --git a/src/declarative/fx/qfxlistview.cpp b/src/declarative/fx/qfxlistview.cpp
index 98fa606..9d076d0 100644
--- a/src/declarative/fx/qfxlistview.cpp
+++ b/src/declarative/fx/qfxlistview.cpp
@@ -795,7 +795,7 @@ void QFxListViewPrivate::fixupX()
/*!
\qmlclass ListView
\inherits Flickable
- \brief The ListView element provides a list view of items provided by a model.
+ \brief The ListView item provides a list view of items provided by a model.
The model is typically provided by a QAbstractListModel "C++ model object", but can also be created directly in QML.
The items are laid out vertically or horizontally and may be flicked to scroll.
@@ -840,7 +840,7 @@ QFxListView::~QFxListView()
The C++ model object must be a \l QAbstractItemModel subclass, a \l VisualModel,
or a simple list.
- Models can also be created directly in QML, using the \l ListModel element.
+ Models can also be created directly in QML, using a \l ListModel.
*/
QVariant QFxListView::model() const
{
diff --git a/src/declarative/fx/qfxmouseregion.cpp b/src/declarative/fx/qfxmouseregion.cpp
index 3b318e3..a60ddc4 100644
--- a/src/declarative/fx/qfxmouseregion.cpp
+++ b/src/declarative/fx/qfxmouseregion.cpp
@@ -145,12 +145,12 @@ void QFxDrag::setYmax(int m)
/*!
\qmlclass MouseRegion
- \brief The MouseRegion element enables simple mouse handling.
+ \brief The MouseRegion item enables simple mouse handling.
\inherits Item
- A MouseRegion is typically used in conjunction with a visible element,
+ A MouseRegion is typically used in conjunction with a visible item,
where the MouseRegion effectively 'proxies' mouse handling for that
- element. For example, we can put a MouseRegion in a Rect that changes
+ item. For example, we can put a MouseRegion in a Rect that changes
the Rect color to red when clicked:
\snippet doc/src/snippets/declarative/mouseregion.qml 0
@@ -164,7 +164,7 @@ void QFxDrag::setYmax(int m)
For basic key handling, see \l KeyActions.
- MouseRegion is an invisible element: it is never painted.
+ MouseRegion is an invisible item: it is never painted.
\sa MouseEvent
*/
diff --git a/src/declarative/fx/qfxpainted.cpp b/src/declarative/fx/qfxpainted.cpp
index 7c88ce3..68918c3 100644
--- a/src/declarative/fx/qfxpainted.cpp
+++ b/src/declarative/fx/qfxpainted.cpp
@@ -45,12 +45,13 @@
QT_BEGIN_NAMESPACE
/*!
+ \internal
\class QFxPainted
- \brief The QFxPainted class is an abstract base class for QFxView items that paint using QPainter.
+ \brief The QFxPainted class is an abstract base class for QFxView items that want cached painting.
\ingroup group_coreitems
- This is a convenience class allowing easy use of QPainter within a custom item.
+ This is a convenience class allowing easy use of cached painting within a custom item.
The contents of the item are cached behind the scenes. Any time you change the contents
you should call markDirty to make sure the cache is refreshed the next time painting occurs.
diff --git a/src/declarative/fx/qfxpainted.h b/src/declarative/fx/qfxpainted.h
index 32f5dcb..1f22414 100644
--- a/src/declarative/fx/qfxpainted.h
+++ b/src/declarative/fx/qfxpainted.h
@@ -44,12 +44,15 @@
#include <qfxitem.h>
-
QT_BEGIN_HEADER
QT_BEGIN_NAMESPACE
QT_MODULE(Declarative)
+/*
+WARNING: INTENDED TO MERGE WITH QFxImageItem
+*/
+
class QFxPaintedPrivate;
class Q_DECLARATIVE_EXPORT QFxPainted : public QFxItem
{
diff --git a/src/declarative/fx/qfxparticles.cpp b/src/declarative/fx/qfxparticles.cpp
index 16b3570..45de1a3 100644
--- a/src/declarative/fx/qfxparticles.cpp
+++ b/src/declarative/fx/qfxparticles.cpp
@@ -151,7 +151,7 @@ void QFxParticleMotion::destroy(QFxParticle &particle)
/*!
\qmlclass ParticleMotionLinear
- \brief The ParticleMotionLinear element moves particles linearly.
+ \brief The ParticleMotionLinear object moves particles linearly.
\sa Particles
*/
@@ -175,7 +175,7 @@ void QFxParticleMotionLinear::advance(QFxParticle &p, int interval)
/*!
\qmlclass ParticleMotionGravity
- \brief The ParticleMotionGravity element moves particles towards a point.
+ \brief The ParticleMotionGravity object moves particles towards a point.
\sa Particles
*/
@@ -234,23 +234,37 @@ void QFxParticleMotionGravity::advance(QFxParticle &p, int interval)
/*!
\qmlclass ParticleMotionWander
- \brief The ParticleMotionWander element moves particles in a somewhat random fashion.
+ \brief The ParticleMotionWander object moves particles in a somewhat random fashion.
The particles will continue roughly in the original direction, however will randomly
drift to each side.
The code below produces an effect similar to falling snow.
- \code
- <Rect width="240" height="320" color="black">
- <Particles y="0" width="{parent.width}" height="30"
- src="star.png" lifeSpan="5000" count="50"
- angle="70" angleDeviation="36"
- velocity="30" velocityDeviation="10">
- <ParticleMotionWander xvariance="30" pace="100"/>
- </Particles>
- </Rect>
- \endcode
+ \qml
+Rect {
+ width: 240
+ height: 320
+ color: "black"
+
+ Particles {
+ y: 0
+ width: parent.width
+ height: 30
+ src: "star.png"
+ lifeSpan: 5000
+ count: 50
+ angle: 70
+ angleDeviation: 36
+ velocity: 30
+ velocityDeviation: 10
+ ParticleMotionWander {
+ xvariance: 30
+ pace: 100
+ }
+ }
+}
+ \endqml
\sa Particles
*/
@@ -508,35 +522,59 @@ QML_DEFINE_TYPE(QFxParticles,Particles);
/*!
\qmlclass Particles
- \brief The Particles element generates and moves particles.
+ \brief The Particles object generates and moves particles.
\inherits Item
- The particles created by this element cannot be dealt with directly, they can only be controlled through the parameters of the Particles element. The particles are all the same pixmap, specified by the user.
+ The particles created by this object cannot be dealt with directly, they can only be controlled through the parameters of the Particles object. The particles are all the same pixmap, specified by the user.
- The particles are painted relative to the parent of the Particles element. Moving the
- Particles element will not move the particles already emitted.
+ The particles are painted relative to the parent of the Particles object. Moving the
+ Particles object will not move the particles already emitted.
The below example creates two differently behaving particle sources.
The top one has particles falling from the top like snow,
the lower one has particles expelled up like a fountain.
- \code
- <Rect width="240" height="320" color="black">
- <Particles y="0" width="{parent.width}" height="30"
- src="star.png" lifeSpan="5000" count="50"
- angle="70" angleDeviation="36"
- velocity="30" velocityDeviation="10">
- <ParticleMotionWander xvariance="30" pace="100"/>
- </Particles>
- <Particles y="300" x="120" width="1" height="1"
- src="star.png" lifeSpan="5000" count="200"
- angle="270" angleDeviation="45"
- velocity="50" velocityDeviation="30">
- <ParticleMotionGravity yattractor="1000"
- xattractor="0" acceleration="25"/>
- </Particles>
- </Rect>
- \endcode
+ \qml
+Rect {
+ width: 240
+ height: 320
+ color: "black"
+ Particles {
+ y: 0
+ width: parent.width
+ height: 30
+ src: "star.png"
+ lifeSpan: 5000
+ count: 50
+ angle: 70
+ angleDeviation: 36
+ velocity: 30
+ velocityDeviation: 10
+ ParticleMotionWander {
+ xvariance: 30
+ pace: 100
+ }
+ }
+ Particles {
+ y: 300
+ x: 120
+ width: 1
+ height: 1
+ src: "star.png"
+ lifeSpan: 5000
+ count: 200
+ angle: 270
+ angleDeviation: 45
+ velocity: 50
+ velocityDeviation: 30
+ ParticleMotionGravity {
+ yattractor: 1000
+ xattractor: 0
+ acceleration: 25
+ }
+ }
+}
+ \endqml
\image particles.gif
*/
@@ -658,9 +696,13 @@ void QFxParticles::setCount(int cnt)
example, the following creates particles whose lifeSpan will vary
from 150ms to 250ms:
- \code
- <Particles src="star.png" lifeSpan="200" lifeSpanDeviation="100"/>
- \endcode
+ \qml
+Particles {
+ src: "star.png"
+ lifeSpan: 200
+ lifeSpanDeviation: 100
+}
+ \endqml
*/
/*!
@@ -691,9 +733,13 @@ void QFxParticles::setLifeSpan(int ls)
example, the following creates particles whose lifeSpan will vary
from 150ms to 250ms:
-\code
-<Particles src="star.png" lifeSpan="200" lifeSpanDeviation="100"/>
-\endcode
+\qml
+Particles {
+ src: "star.png"
+ lifeSpan: 200
+ lifeSpanDeviation: 100
+}
+\endqml
\sa QFxParticles::lifeSpan
*/
@@ -765,9 +811,13 @@ void QFxParticles::setFadeOutDuration(int dur)
example, the following creates particles whose initial direction will
vary from 15 degrees to 105 degrees:
- \code
- <Particles src="star.png" angle="60" angleDeviation="90"/>
- \endcode
+ \qml
+Particles {
+ src: "star.png"
+ angle: 60
+ angleDeviation: 90
+}
+ \endqml
*/
/*!
@@ -796,9 +846,13 @@ void QFxParticles::setAngle(qreal angle)
example, the following creates particles whose initial direction will
vary from 15 degrees to 105 degrees:
-\code
-<Particles src="star.png" angle="60" angleDeviation="90"/>
-\endcode
+\qml
+Particles {
+ src: "star.png"
+ angle: 60
+ angleDeviation: 90
+}
+\endqml
\sa QFxParticles::angle
*/
@@ -824,9 +878,13 @@ void QFxParticles::setAngleDeviation(qreal dev)
example, the following creates particles whose initial velocity will
vary from 40 to 60.
- \code
- <Particles src="star.png" velocity="50" velocityDeviation="20"/>
- \endcode
+ \qml
+Particles {
+ src: "star.png"
+ velocity: 50
+ velocityDeviation: 20
+}
+ \endqml
*/
/*!
@@ -855,9 +913,13 @@ void QFxParticles::setVelocity(qreal velocity)
example, the following creates particles whose initial velocity will
vary from 40 to 60.
-\code
-<Particles src="star.png" velocity="50" velocityDeviation="20"/>
-\endcode
+\qml
+Particles {
+ src: "star.png"
+ velocity: 50
+ velocityDeviation: 20
+}
+\endqml
\sa QFxParticles::velocity
*/
diff --git a/src/declarative/fx/qfxpath.cpp b/src/declarative/fx/qfxpath.cpp
index 26aa10e..e11658c 100644
--- a/src/declarative/fx/qfxpath.cpp
+++ b/src/declarative/fx/qfxpath.cpp
@@ -57,9 +57,9 @@ QML_DEFINE_TYPE(QFxPathCubic,PathCubic);
/*!
\qmlclass PathElement
- \brief PathElement is the base path element.
+ \brief PathElement is the base path type.
- This element is the base for all path elements. It cannot
+ This type is the base for all path types. It cannot
be instantiated.
\sa Path, PathAttribute, PathPercent, PathLine, PathQuad, PathCubic
@@ -73,13 +73,13 @@ QML_DEFINE_TYPE(QFxPathCubic,PathCubic);
/*!
\qmlclass Path QFxPath
- \brief The Path element defines a path for use by \l PathView.
+ \brief A Path object defines a path for use by \l PathView.
A Path is composed of one or more path segments - PathLine, PathQuad,
PathCubic.
- The spacing of the items along the Path can be adjusted via the
- PathPercent element.
+ The spacing of the items along the Path can be adjusted via a
+ PathPercent object.
PathAttribute allows named attributes with values to be defined
along the path.
@@ -151,11 +151,11 @@ void QFxPath::setStartY(qreal y)
/*!
\qmlproperty list<PathElement> Path::pathElements
- This property holds the elements composing the path.
+ This property holds the objects composing the path.
\default
- A path can contain the following path elements:
+ A path can contain the following path objects:
\list
\i \l PathLine - a straight line to a given position.
\i \l PathQuad - a quadratic Bezier curve to a given position with a control point.
@@ -478,7 +478,7 @@ void QFxCurve::setY(qreal y)
\qmlclass PathAttribute
\brief The PathAttribute allows setting an attribute at a given position in a Path.
- The PathAttribute element allows attibutes consisting of a name and a
+ The PathAttribute object allows attibutes consisting of a name and a
value to be specified for the endpoints of path segments. The attributes
are exposed to the delegate as \l {Attached Properties}. The value of
an attribute at any particular point is interpolated from the PathAttributes
@@ -557,12 +557,12 @@ void QFxPathAttribute::setValue(qreal value)
The example below creates a path consisting of a straight line from
0,100 to 200,100:
- \code
+ \qml
Path {
startX: 0; startY: 100
PathLine { x: 200; y: 100 }
}
- \endcode
+ \endqml
\sa Path, PathQuad, PathCubic
*/
@@ -599,12 +599,12 @@ void QFxPathLine::addToPath(QPainterPath &path)
\row
\o \image declarative-pathquad.png
\o
- \code
+ \qml
Path {
startX: 0; startY: 0
PathQuad x: 200; y: 0; controlX: 100; controlY: 150 }
}
- \endcode
+ \endqml
\endtable
\sa Path, PathCubic, PathLine
@@ -683,7 +683,7 @@ void QFxPathQuad::addToPath(QPainterPath &path)
\row
\o \image declarative-pathcubic.png
\o
- \code
+ \qml
Path {
startX: 20; startY: 0
PathCubic {
@@ -691,7 +691,7 @@ void QFxPathQuad::addToPath(QPainterPath &path)
control2X: 210; control2Y: 90
}
}
- \endcode
+ \endqml
\endtable
\sa Path, PathQuad, PathLine
@@ -813,18 +813,18 @@ void QFxPathCubic::addToPath(QPainterPath &path)
\row
\o \image declarative-nopercent.png
\o
- \code
+ \qml
Path {
startX: 20; startY: 0
PathQuad { x: 50; y: 80; controlX: 0; controlY: 80 }
PathLine { x: 150; y: 80 }
PathQuad { x: 180; y: 0; controlX: 200; controlY: 80 }
}
- \endcode
+ \endqml
\row
\o \image declarative-percent.png
\o
- \code
+ \qml
Path {
startX: 20; startY: 0
PathQuad { x: 50; y: 80; controlX: 0; controlY: 80 }
@@ -834,7 +834,7 @@ void QFxPathCubic::addToPath(QPainterPath &path)
PathQuad { x: 180; y: 0; controlX: 200; controlY: 80 }
PathPercent { value: 1 }
}
- \endcode
+ \endqml
\endtable
\sa Path
diff --git a/src/declarative/fx/qfxrect.cpp b/src/declarative/fx/qfxrect.cpp
index 8aaddba..371aa0c 100644
--- a/src/declarative/fx/qfxrect.cpp
+++ b/src/declarative/fx/qfxrect.cpp
@@ -53,9 +53,9 @@ QML_DEFINE_TYPE(QFxPen,Pen);
\brief The QFxPen class provides a pen used for drawing rect borders on a QFxView.
Example:
- \code
+ \qml
Rect { pen.width: 2; pen.color: "red" ... }
- \endcode
+ \endqml
*/
/*! \property QFxPen::width
@@ -72,13 +72,13 @@ QML_DEFINE_TYPE(QFxPen,Pen);
color is most commonly specified in hexidecimal notation (#RRGGBB)
or as an \l {http://www.w3.org/TR/SVG/types.html#ColorKeywords}{SVG color keyword name}
(as defined by the World Wide Web Consortium). For example:
- \code
+ \qml
// rect with green border using hexidecimal notation
Rect { pen.color: "#00FF00" }
// rect with steelblue border using SVG color name
Rect { pen.color: "steelblue" }
- \endcode
+ \endqml
For the full set of ways to specify color, see Qt's QColor::setNamedColor documentation.
*/
@@ -96,14 +96,22 @@ QML_DEFINE_TYPE(QFxRect,Rect);
/*!
\qmlclass Rect QFxRect
- \brief The Rect element allows you to add rectangles to a scene.
+ \brief The Rect item allows you to add rectangles to a scene.
\inherits Item
- A Rect is painted having a solid fill (color) and an optional border (pen). You can also create rounded rectangles using the radius property.
-
- \code
- Rect { width: 100; height: 100; color: "red"; pen.color: "black"; pen.width: 5; radius: 10 }
- \endcode
+ A Rect is painted having a solid fill (color) and an optional border (pen).
+ You can also create rounded rectangles using the radius property.
+
+ \qml
+ Rect {
+ width: 100
+ height: 100
+ color: "red"
+ pen.color: "black"
+ pen.width: 5
+ radius: 10
+ }
+ \endqml
\image declarative-rect.png
*/
@@ -113,11 +121,19 @@ QML_DEFINE_TYPE(QFxRect,Rect);
\class QFxRect
\brief The QFxRect class provides a rect item that you can add to a QFxView.
- A Rect is painted having a solid fill (color) and an optional border (pen). You can also create rounded rectangles using the radius property.
-
- \code
- Rect { width: 100; height: 100; color: "red"; pen.color: "black"; pen.width: 5; radius: 10 }
- \endcode
+ A Rect is painted having a solid fill (color) and an optional border (pen).
+ You can also create rounded rectangles using the radius property.
+
+ \qml
+ Rect {
+ width: 100
+ height: 100
+ color: "red"
+ pen.color: "black"
+ pen.width: 5
+ radius: 10
+ }
+ \endqml
\image declarative-rect.png
@@ -216,13 +232,13 @@ void QFxRect::dump(int depth)
\qmlproperty color Rect::color
This property holds the color used to fill the rect.
- \code
+ \qml
// green rect using hexidecimal notation
Rect { color: "#00FF00" }
// steelblue rect using SVG color name
Rect { color: "steelblue" }
- \endcode
+ \endqml
*/
/*!
@@ -259,10 +275,10 @@ void QFxRect::setColor(const QColor &c)
This color will be drawn over the rect's color when the rect is painted. The tint color should usually be mostly transparent, or you will not be able to see the underlying color. The below example provides a slight red tint by having the tint color be pure red which is only 1/16th opaque.
- \code
+ \qml
Rect { x: 0; width: 80; height: 80; color: "lightsteelblue" }
Rect { x: 100; width: 80; height: 80; color: "lightsteelblue"; tintColor: "#10FF0000" }
- \endcode
+ \endqml
\image declarative-rect_tint.png
This attribute is not intended to be used with a single color over the lifetime of an user interface. It is most useful when a subtle change is intended to be conveyed due to some event; you can then use the tint color to more effectively tune the visible color.
@@ -320,13 +336,13 @@ QColor QFxRectPrivate::getColor()
This property allows for the easy construction of simple horizontal gradients. Other gradients may by formed by adding rotation to the rect. The gradient will blend linearly from the rect's main color to the color specified for gradient color.
- \code
+ \qml
Rect { y: 0; width: 80; height: 80; color: "lightsteelblue" }
Rect { y: 100; width: 80; height: 80; color: "lightsteelblue"; gradientColor="blue" }
Rect { rotation: 90; x: 80; y: 200; width: 80; height: 80; color="lightsteelblue"
gradientColor: "blue" }
// The x offset is needed because the rotation is from the top left corner
- \endcode
+ \endqml
\image declarative-rect_gradient.png
*/
diff --git a/src/declarative/fx/qfxreflectionfilter.cpp b/src/declarative/fx/qfxreflectionfilter.cpp
index e02bc16..a55f374 100644
--- a/src/declarative/fx/qfxreflectionfilter.cpp
+++ b/src/declarative/fx/qfxreflectionfilter.cpp
@@ -69,35 +69,30 @@ public:
Here is an example of various Reflections applied to an image.
- \code
- <HorizontalLayout>
- <Image src="icon.png" >
- <filter>
- <Reflection />
- </filter>
- </Image>
- <Image src="icon.png" >
- <filter>
- <Reflection offset="1" />
- </filter>
- </Image>
- <Image src="icon.png" >
- <filter>
- <Reflection offset="1" alpha="0.5" />
- </filter>
- </Image>
- <Image src="icon.png" >
- <filter>
- <Reflection offset="1" alpha="0.5" height="50" />
- </filter>
- </Image>
- <Image src="icon.png" >
- <filter>
- <Reflection offset="1" alpha="0.5" height="50" scale="0.5" />
- </filter>
- </Image>
- </HorizontalLayout>
- \endcode
+ \qml
+HorizontalLayout {
+ Image {
+ src: "icon.png"
+ filter: Reflection { }
+ }
+ Image {
+ src: "icon.png"
+ filter: Reflection { offset: 1 }
+ }
+ Image {
+ src: "icon.png"
+ filter: Reflection { offset: 1; alpha: 0.5 }
+ }
+ Image {
+ src: "icon.png"
+ filter: Reflection { offset: 1; alpha: 0.5; height: 50 }
+ }
+ Image {
+ src: "icon.png"
+ filter: Reflection { offset: 1; alpha: 0.5; height: 50; scale: 0.5 }
+ }
+}
+ \endqml
\image reflection_example.png
@@ -149,13 +144,15 @@ void QFxReflectionFilter::setAlpha(qreal a)
it is set to 50, the bottom 50 pixels of the item are reflected. Data
binding could be used to reflect a percentage of the item.
- \code
- <Image id="myImage" src="album.png">
- <filter>
- <Reflection height="{myImage.height * 0.5}" />
- </filter>
- </Image>
- \endcode
+ \qml
+Image {
+ id: myImage
+ src: "album.png"
+ filter: Reflection {
+ height: myImage.height * 0.5
+ }
+}
+ \endqml
*/
/*!
\qmlproperty int Reflection::offset
diff --git a/src/declarative/fx/qfxrepeater.cpp b/src/declarative/fx/qfxrepeater.cpp
index f9fc878..23b4e01 100644
--- a/src/declarative/fx/qfxrepeater.cpp
+++ b/src/declarative/fx/qfxrepeater.cpp
@@ -77,13 +77,13 @@ QML_DEFINE_TYPE(QFxRepeater,Repeater);
\qmlclass Repeater
\inherits Item
- \brief The Repeater element allows you to repeat a component based on a data source.
+ \brief The Repeater item allows you to repeat a component based on a data source.
- The Repeater element is used when you want to create a large number of
+ The Repeater item is used when you want to create a large number of
similar items. For each entry in the data source, an item is instantiated
in a context seeded with data from the data source. If the repeater will
be instantiating a large number of instances, it may be more efficient to
- use one of Qt Declarative's \l {xmlViews}{view elements}.
+ use one of Qt Declarative's \l {xmlViews}{view items}.
The data source may be either an object list, a string list or a Qt model.
In each case, the data element and the index is exposed to each instantiated
@@ -92,7 +92,7 @@ QML_DEFINE_TYPE(QFxRepeater,Repeater);
or object) is available as the \c modelData property. In the case of a Qt model,
all roles are available as named properties just like in the view classes.
- Items instantiated by the Repeater elemented are inserted, in order, as
+ Items instantiated by the Repeater are inserted, in order, as
children of the Repeater's parent. The insertion starts immediately after
the repeater's position in its parent stacking list. This is to allow
you to use a Repeater inside a layout. The following QML example shows how
diff --git a/src/declarative/fx/qfxshadowfilter.cpp b/src/declarative/fx/qfxshadowfilter.cpp
index 38d1c31..4d34f74 100644
--- a/src/declarative/fx/qfxshadowfilter.cpp
+++ b/src/declarative/fx/qfxshadowfilter.cpp
@@ -73,14 +73,26 @@ public:
\row
\o \image shadow_example.png
\o
- \code
- <Rect radius="5" color="lightsteelblue" width="100" height="100">
- <filter><Shadow yOffset="8" xOffset="8" /></filter>
- </Rect>
- <Image src="pics/qtlogo.png">
- <filter><Shadow yOffset="8" xOffset="8" /></filter>
- </Image>
- \endcode
+ \qml
+Rect {
+ radius: 5
+ color: "lightsteelblue"
+ width: 100
+ height: 100
+ filter: Shadow {
+ yOffset: 8
+ xOffset: 8
+ }
+}
+
+Image {
+ src: "pics/qtlogo.png"
+ filter: Shadow {
+ yOffset: 8
+ xOffset: 8
+ }
+}
+ \endqml
\endtable
Shadows are only supported when Qt Qt Declarative is compiled for OpenGL ES 2.0.
diff --git a/src/declarative/fx/qfxtext.cpp b/src/declarative/fx/qfxtext.cpp
index f1aefb9..a43219d 100644
--- a/src/declarative/fx/qfxtext.cpp
+++ b/src/declarative/fx/qfxtext.cpp
@@ -61,15 +61,15 @@ QML_DEFINE_TYPE(QFxText,Text);
/*!
\qmlclass Text QFxText
- \brief The Text element allows you to add formatted text to a scene.
+ \brief The Text item allows you to add formatted text to a scene.
\inherits Item
It can display both plain and rich text. For example:
- \code
+ \qml
Text { text: "Hello World!"; font.family: "Helvetica"; font.size: 24; color: "red" }
Text { text: "<b>Hello</b> <i>World!</i>" }
- \endcode
+ \endqml
\image declarative-text.png
@@ -94,10 +94,10 @@ QML_DEFINE_TYPE(QFxText,Text);
Text was designed for read-only text; it does not allow for any text editing.
It can display both plain and rich text. For example:
- \code
+ \qml
Text { text: "Hello World!"; font.family: "Helvetica"; font.size: 24; color: "red" }
Text { text: "<b>Hello</b> <i>World!</i>" }
- \endcode
+ \endqml
\image text.png
@@ -105,7 +105,7 @@ QML_DEFINE_TYPE(QFxText,Text);
much room is needed and set it accordingly. Unless \c wrap is set, it will always
prefer width to height (all text will be placed on a single line).
- The \c elideMode can alternatively be used to fit a line of plain text to a set width.
+ The \c elide property can alternatively be used to fit a line of plain text to a set width.
A QFxText object can be instantiated in Qml using the tag \c Text.
*/
@@ -212,13 +212,13 @@ void QFxText::setColor(const QColor &color)
The text color.
- \code
+ \qml
//green text using hexadecimal notation
Text { color: "#00FF00"; ... }
//steelblue text using SVG color name
Text { color: "steelblue"; ... }
- \endcode
+ \endqml
*/
QColor QFxText::color() const
@@ -234,14 +234,14 @@ QColor QFxText::color() const
Supported text styles are \c Normal, \c Outline, \c Raised and \c Sunken.
- \code
+ \qml
HorizontalLayout {
Text { font.size: 24; text: "Normal" }
Text { font.size: 24; text: "Raised"; style: "Raised"; styleColor: "#AAAAAA" }
Text { font.size: 24; text: "Outline"; style: "Outline"; styleColor: "red" }
Text { font.size: 24; text: "Sunken"; style: "Sunken"; styleColor: "#AAAAAA" }
}
- \endcode
+ \endqml
\image declarative-textstyle.png
*/
@@ -302,7 +302,7 @@ QColor QFxText::styleColor() const
\qmlproperty enumeration Text::hAlign
\qmlproperty enumeration Text::vAlign
- Sets the horizontal and vertical alignment of the text within the Text elements
+ Sets the horizontal and vertical alignment of the text within the Text items
width and height. By default, the text is top-left aligned.
The valid values for \c hAlign are \c AlignLeft, \c AlignRight and
@@ -349,7 +349,7 @@ void QFxText::setVAlign(VAlignment align)
/*!
\qmlproperty bool Text::wrap
- Set this property to wrap the text to the Text element's width. The text will only
+ Set this property to wrap the text to the Text item's width. The text will only
wrap if an explicit width has been set.
Wrapping is done on word boundaries (i.e. it is a "word-wrap"). If the text cannot be
@@ -378,9 +378,9 @@ void QFxText::setWrap(bool w)
}
/*!
- \qmlproperty Qt::TextElideMode Text::elideMode
+ \qmlproperty Qt::TextElideMode Text::elide
- Set this property to elide parts of the text fit to the Text element's width.
+ Set this property to elide parts of the text fit to the Text item's width.
The text will only elide if an explicit width has been set.
This property cannot be used with wrap enabled or with rich text.
diff --git a/src/declarative/fx/qfxtextedit.cpp b/src/declarative/fx/qfxtextedit.cpp
index 807fcbf..84e209b 100644
--- a/src/declarative/fx/qfxtextedit.cpp
+++ b/src/declarative/fx/qfxtextedit.cpp
@@ -62,15 +62,21 @@ QML_DEFINE_TYPE(QFxTextEdit, TextEdit);
/*!
\qmlclass TextEdit
- \brief The TextEdit element allows you to add editable formatted text to a scene.
+ \brief The TextEdit item allows you to add editable formatted text to a scene.
It can display both plain and rich text. For example:
\qml
- <TextEdit id="edit" focus="true" focusable="true"
- font.family="Helvetica" font.size="20" color="blue" width="240">
- <![CDATA[<b>Hello</b> <i>World!</i>]]/>
- </TextEdit>
+TextEdit {
+ id: edit
+ text: "<b>Hello</b> <i>World!</i>"
+ focus: true
+ focusable: true
+ font.family: "Helvetica"
+ font.size: 20
+ color: "blue"
+ width: 240
+}
\endqml
\image declarative-textedit.gif
@@ -177,19 +183,24 @@ void QFxTextEdit::setText(const QString &text)
\table
\row
\o
- \code
- <VerticalLayout>
- <TextEdit font.size="24">
- <![CDATA[<b>Hello</b> <i>World!</i>]]]]><![CDATA[>
- </TextEdit>
- <TextEdit font.size="24" textFormat="RichText">
- <![CDATA[<b>Hello</b> <i>World!</i>]]]]><![CDATA[>
- </TextEdit>
- <TextEdit font.size="24" textFormat="PlainText">
- <![CDATA[<b>Hello</b> <i>World!</i>]]]]><![CDATA[>
- </TextEdit>
- </VerticalLayout>
- \endcode
+ \qml
+VerticalLayout {
+ TextEdit {
+ font.size: 24
+ text: "<b>Hello</b> <i>World!</i>"
+ }
+ TextEdit {
+ font.size: 24
+ textFormat: "RichText"
+ text: "<b>Hello</b> <i>World!</i>"
+ }
+ TextEdit {
+ font.size: 24
+ textFormat: "PlainText"
+ text: "<b>Hello</b> <i>World!</i>"
+ }
+}
+ \endqml
\o \image declarative-textformat.png
\endtable
*/
@@ -247,13 +258,13 @@ QmlFont *QFxTextEdit::font()
The text color.
- \code
- <!-- green text using hexadecimal notation -->
- <TextEdit color="#00FF00" .../>
+ \qml
+// green text using hexadecimal notation
+TextEdit { color: "#00FF00"; ... }
- <!-- steelblue text using SVG color name-->
- <TextEdit color="steelblue" .../>
- \endcode
+// steelblue text using SVG color name
+TextEdit { color: "steelblue"; ... }
+ \endqml
*/
/*!
@@ -284,7 +295,7 @@ void QFxTextEdit::setColor(const QColor &color)
\qmlproperty enumeration TextEdit::hAlign
\qmlproperty enumeration TextEdit::vAlign
- Sets the horizontal and vertical alignment of the text within the TextEdit elements
+ Sets the horizontal and vertical alignment of the text within the TextEdit items
width and height. By default, the text is top-left aligned.
The valid values for \c hAlign are \c AlignLeft, \c AlignRight and
@@ -345,7 +356,8 @@ bool QFxTextEdit::wrap() const
/*!
\qmlproperty bool TextEdit::wrap
- Set this property to wrap the text to the TextEdit element's width. The text will only wrap if an explicit width has been set.
+ Set this property to wrap the text to the TextEdit item's width.
+ The text will only wrap if an explicit width has been set.
Wrapping is done on word boundaries (i.e. it is a "word-wrap"). Wrapping is off by default.
*/
@@ -410,7 +422,7 @@ void QFxTextEdit::componentComplete()
/*!
\qmlproperty bool TextEdit::readOnly
- Whether the user an interact with the TextEdit element. If this
+ Whether the user an interact with the TextEdit item. If this
property is set to true the text cannot be edited by user interaction.
By default this property is false.
@@ -418,8 +430,7 @@ void QFxTextEdit::componentComplete()
/*!
\property QFxTextEdit::readOnly
- \brief If this property is true the text can not be edited by
- user interaction.
+ \brief If this property is true the text can not be edited by user interaction.
Changing this property will modify the text interaction flags. If
you require more specific control about how user interaction
diff --git a/src/declarative/fx/qfxtransform.cpp b/src/declarative/fx/qfxtransform.cpp
index 8ff4c54..1fe02d1 100644
--- a/src/declarative/fx/qfxtransform.cpp
+++ b/src/declarative/fx/qfxtransform.cpp
@@ -85,16 +85,16 @@ void QFxTransform::update()
/*!
\qmlclass Axis
- \brief The Axis element defines an axis that can be used for rotation or translation.
+ \brief A Axis object defines an axis that can be used for rotation or translation.
An axis is specified by 2 points in 3D space: a start point and
an end point. While technically the axis is the line running through these two points
(and thus many different sets of two points could define the same axis), the distance
between the points does matter for translation along an axis.
- \code
+ \qml
Axis { startX: 0; startY: 0; endX: 20; endY: 30 }
- \endcode
+ \endqml
*/
QML_DEFINE_TYPE(QFxAxis, Axis);
@@ -179,7 +179,7 @@ void QFxAxis::setEndZ(qreal z)
/*!
\qmlclass Rotation3D
- \brief The Rotation3D element provides a way to rotate an Item around an axis.
+ \brief A Rotation3D object provides a way to rotate an Item around an axis.
Here is an example of various rotations applied to an \l Image.
\snippet doc/src/snippets/declarative/rotation.qml 0
@@ -317,16 +317,23 @@ void QFxRotation3D::update()
/*!
\qmlclass Translation3D
- \brief The Translation3D element provides a way to move an Item along an axis.
+ \brief A Translation3D object provides a way to move an Item along an axis.
The following example translates the image to 10, 3.
- \code
- <Image src="logo.png">
- <transform>
- <Translation3D axis.startX="0" axis.startY="0" axis.endX="1" axis.endY=".3" distance="10"/>
- </transform>
- </Image>
- \endcode
+ \qml
+Image {
+ src: "logo.png"
+ transform: [
+ Translation3D {
+ axis.startX: 0
+ axis.startY: 0
+ axis.endX: 1
+ axis.endY: .3
+ distance: 10
+ }
+ ]
+}
+ \endqml
*/
QML_DEFINE_TYPE(QFxTranslation3D,Translation3D);
@@ -367,9 +374,9 @@ QFxAxis *QFxTranslation3D::axis()
in the example below, a distance of 1 would translate to 100, 50, while a distance
of 0.5 would translate to 50, 25.
- \code
+ \qml
Translation3D { axis.startX: 0; axis.startY: 0; axis.endX: 100; axis.endY: 50 }
- \endcode
+ \endqml
*/
qreal QFxTranslation3D::distance() const
{
@@ -444,7 +451,7 @@ void QFxTranslation3D::update()
/*!
\qmlclass Perspective
- \brief The Perspective element specifies a perspective transformation.
+ \brief A Perspective object specifies a perspective transformation.
A Perspective transform only affects an item when running under OpenGL; when running under software
rasterization it has no effect.
@@ -501,10 +508,10 @@ QMatrix4x4 QFxPerspective::transform() const
/*!
\qmlclass Squish
- \brief The Squish element allows you to distort an items appearance by 'squishing' it.
+ \brief A Squish object allows you to distort an items appearance by 'squishing' it.
Here is an example of various \l Image squishes.
- \code
+ \qml
Rect {
id: Screen
width: 360; height: 80
@@ -556,7 +563,7 @@ QMatrix4x4 QFxPerspective::transform() const
}
}
}
- \endcode
+ \endqml
\image squish.png
*/
diff --git a/src/declarative/fx/qfxwebview.cpp b/src/declarative/fx/qfxwebview.cpp
index fe694ea..dac8ced 100644
--- a/src/declarative/fx/qfxwebview.cpp
+++ b/src/declarative/fx/qfxwebview.cpp
@@ -204,12 +204,12 @@ public:
/*!
\qmlclass WebView
- \brief The WebView element allows you to add web content to a canvas.
+ \brief The WebView item allows you to add web content to a canvas.
\inherits Item
A WebView renders web content based on a URL.
- If the width and height of the element is not set, they will
+ If the width and height of the item is not set, they will
dynamically adjust to a size appropriate for the content.
This width may be large (eg. 980) for typical online web pages.
@@ -220,7 +220,7 @@ public:
Due to WebKit limitations, the height may be more than necessary
if the idealHeight is changed after the content is loaded.
- \code
+ \qml
WebView {
url: "http://www.nokia.com"
width: 490
@@ -228,11 +228,11 @@ public:
scale: 0.5
smooth: true
}
- \endcode
+ \endqml
\image webview.png
- The element includes no scrolling, scaling,
+ The item includes no scrolling, scaling,
toolbars, etc., those must be implemented around WebView. See the WebBrowser example
for a demonstration of this.
*/
@@ -246,7 +246,7 @@ public:
\image webview.png
- The element includes no scrolling, scaling,
+ The item includes no scrolling, scaling,
toolbars, etc., those must be implemented around WebView. See the WebBrowser example
for a demonstration of this.
@@ -934,7 +934,7 @@ QWebPage *QFxWebView::page() const
QFxWebView *self = const_cast<QFxWebView*>(this);
QWebPage *wp = new QFxWebPage(self);
- // QML elements don't default to having a background,
+ // QML items don't default to having a background,
// even though most we pages will set one anyway.
QPalette pal = QApplication::palette();
pal.setBrush(QPalette::Base, QColor::fromRgbF(0, 0, 0, 0));
@@ -950,7 +950,35 @@ QWebPage *QFxWebView::page() const
return d->page;
}
+
// The QObject interface to settings().
+/*!
+ \qmlproperty bool WebView::settings::autoLoadImages
+ \qmlproperty bool WebView::settings::javascriptEnabled
+ \qmlproperty bool WebView::settings::javaEnabled
+ \qmlproperty bool WebView::settings::pluginsEnabled
+ \qmlproperty bool WebView::settings::privateBrowsingEnabled
+ \qmlproperty bool WebView::settings::javascriptCanOpenWindows
+ \qmlproperty bool WebView::settings::javascriptCanAccessClipboard
+ \qmlproperty bool WebView::settings::developerExtrasEnabled
+ \qmlproperty bool WebView::settings::linksIncludedInFocusChain
+ \qmlproperty bool WebView::settings::zoomTextOnly
+ \qmlproperty bool WebView::settings::printElementBackgrounds
+ \qmlproperty bool WebView::settings::offlineStorageDatabaseEnabled
+ \qmlproperty bool WebView::settings::offlineWebApplicationCacheEnabled
+ \qmlproperty bool WebView::settings::localStorageDatabaseEnabled
+
+ These properties give access to the settings controlling the web view.
+
+ See QWebSettings for the list of sub-properties.
+
+ \qml
+ WebView {
+ settings.pluginsEnabled: true
+ ...
+ }
+ \endqml
+*/
QObject *QFxWebView::settingsObject() const
{
Q_D(const QFxWebView);
@@ -1006,11 +1034,11 @@ QString QFxWebView::html() const
The html property can be set as a string.
- \code
+ \qml
WebView {
html: "<p>This is <b>HTML</b>."
}
- \endcode
+ \endqml
*/
void QFxWebView::setHtml(const QString &html, const QUrl &baseUrl)
{
@@ -1019,7 +1047,7 @@ void QFxWebView::setHtml(const QString &html, const QUrl &baseUrl)
d->idealwidth>0 ? d->idealwidth : width(),
d->idealheight>0 ? d->idealheight : height()));
if (isComponentComplete())
- page()->mainFrame()->setHtml(html, baseUrl);
+ page()->mainFrame()->setHtml(html, qmlContext(this)->resolvedUrl(baseUrl));
else {
d->pending = d->PendingHtml;
d->pending_url = baseUrl;
@@ -1035,7 +1063,7 @@ void QFxWebView::setContent(const QByteArray &data, const QString &mimeType, con
d->idealheight>0 ? d->idealheight : height()));
if (isComponentComplete())
- page()->mainFrame()->setContent(data,mimeType,baseUrl);
+ page()->mainFrame()->setContent(data,mimeType,qmlContext(this)->resolvedUrl(baseUrl));
else {
d->pending = d->PendingContent;
d->pending_url = baseUrl;
diff --git a/src/declarative/opengl/gltexture.cpp b/src/declarative/opengl/gltexture.cpp
index 6d737ad..199b362 100644
--- a/src/declarative/opengl/gltexture.cpp
+++ b/src/declarative/opengl/gltexture.cpp
@@ -45,6 +45,7 @@
QT_BEGIN_NAMESPACE
/*!
+ \internal
\class GLTexture
\brief The GLTexture class simplifies the use of OpenGL textures.
*/
diff --git a/src/declarative/qml/parser/javascript.g b/src/declarative/qml/parser/javascript.g
index 59ab529..5482392 100644
--- a/src/declarative/qml/parser/javascript.g
+++ b/src/declarative/qml/parser/javascript.g
@@ -70,6 +70,7 @@
%token T_REMAINDER_EQ "%=" T_RETURN "return" T_RPAREN ")"
%token T_SEMICOLON ";" T_AUTOMATIC_SEMICOLON T_STAR "*"
%token T_STAR_EQ "*=" T_STRING_LITERAL "string literal"
+%token T_PROPERTY "property" T_SIGNAL "signal"
%token T_SWITCH "switch" T_THIS "this" T_THROW "throw"
%token T_TILDE "~" T_TRY "try" T_TYPEOF "typeof"
%token T_VAR "var" T_VOID "void" T_WHILE "while"
@@ -85,7 +86,7 @@
%token T_IMPORT "import"
%nonassoc SHIFT_THERE
-%nonassoc T_IDENTIFIER T_COLON
+%nonassoc T_IDENTIFIER T_COLON T_SIGNAL T_PROPERTY
%nonassoc REDUCE_HERE
%start UiProgram
@@ -645,50 +646,78 @@ case $rule_number: {
} break;
./
-UiObjectMember: T_PUBLIC T_IDENTIFIER T_IDENTIFIER ;
+UiPropertyType: T_VAR ;
+/.
+case $rule_number:
+./
+UiPropertyType: T_RESERVED_WORD ;
+/.
+case $rule_number: {
+ sym(1).sval = driver->intern(lexer->characterBuffer(), lexer->characterCount());
+ break;
+}
+./
+
+UiPropertyType: T_IDENTIFIER ;
+
+UiObjectMember: T_SIGNAL T_IDENTIFIER ;
+/.
+case $rule_number: {
+ AST::UiPublicMember *node = makeAstNode<AST::UiPublicMember> (driver->nodePool(), (JavaScriptNameIdImpl *)0, sym(2).sval);
+ node->type = AST::UiPublicMember::Signal;
+ node->propertyToken = loc(1);
+ node->typeToken = loc(2);
+ node->identifierToken = loc(3);
+ sym(1).Node = node;
+} break;
+./
+
+UiObjectMember: T_PROPERTY UiPropertyType T_IDENTIFIER ;
/.
case $rule_number: {
AST::UiPublicMember *node = makeAstNode<AST::UiPublicMember> (driver->nodePool(), sym(2).sval, sym(3).sval);
- node->publicToken = loc(1);
- node->attributeTypeToken = loc(2);
+ node->propertyToken = loc(1);
+ node->typeToken = loc(2);
node->identifierToken = loc(3);
sym(1).Node = node;
} break;
./
-UiObjectMember: T_PUBLIC T_DEFAULT T_IDENTIFIER T_IDENTIFIER ;
+UiObjectMember: T_DEFAULT T_PROPERTY UiPropertyType T_IDENTIFIER ;
/.
case $rule_number: {
AST::UiPublicMember *node = makeAstNode<AST::UiPublicMember> (driver->nodePool(), sym(3).sval, sym(4).sval);
node->isDefaultMember = true;
- node->publicToken = loc(1);
- node->attributeTypeToken = loc(3);
+ node->defaultToken = loc(1);
+ node->propertyToken = loc(2);
+ node->typeToken = loc(3);
node->identifierToken = loc(4);
sym(1).Node = node;
} break;
./
-UiObjectMember: T_PUBLIC T_IDENTIFIER T_IDENTIFIER T_COLON Expression ;
+UiObjectMember: T_PROPERTY UiPropertyType T_IDENTIFIER T_COLON Expression ;
/.
case $rule_number: {
AST::UiPublicMember *node = makeAstNode<AST::UiPublicMember> (driver->nodePool(), sym(2).sval, sym(3).sval,
sym(5).Expression);
- node->publicToken = loc(1);
- node->attributeTypeToken = loc(2);
+ node->propertyToken = loc(1);
+ node->typeToken = loc(2);
node->identifierToken = loc(3);
node->colonToken = loc(4);
sym(1).Node = node;
} break;
./
-UiObjectMember: T_PUBLIC T_DEFAULT T_IDENTIFIER T_IDENTIFIER T_COLON Expression ;
+UiObjectMember: T_DEFAULT T_PROPERTY UiPropertyType T_IDENTIFIER T_COLON Expression ;
/.
case $rule_number: {
AST::UiPublicMember *node = makeAstNode<AST::UiPublicMember> (driver->nodePool(), sym(3).sval, sym(4).sval,
sym(6).Expression);
node->isDefaultMember = true;
- node->publicToken = loc(1);
- node->attributeTypeToken = loc(3);
+ node->defaultToken = loc(1);
+ node->propertyToken = loc(2);
+ node->typeToken = loc(3);
node->identifierToken = loc(4);
node->colonToken = loc(5);
sym(1).Node = node;
@@ -710,9 +739,8 @@ case $rule_number: {
./
UiQualifiedId: T_RESERVED_WORD ;
-/.
-case $rule_number:
-./
+/.case $rule_number: ./
+
UiQualifiedId: T_RETURN ;
/.
case $rule_number:
@@ -723,7 +751,27 @@ case $rule_number:
} break;
./
-UiQualifiedId: T_IDENTIFIER ;
+JsIdentifier: T_IDENTIFIER;
+
+JsIdentifier: T_PROPERTY ;
+/.
+case $rule_number: {
+ QString s = QLatin1String(JavaScriptGrammar::spell[T_PROPERTY]);
+ sym(1).sval = driver->intern(s.constData(), s.length());
+ break;
+}
+./
+
+JsIdentifier: T_SIGNAL ;
+/.
+case $rule_number: {
+ QString s = QLatin1String(JavaScriptGrammar::spell[T_SIGNAL]);
+ sym(1).sval = driver->intern(s.constData(), s.length());
+ break;
+}
+./
+
+UiQualifiedId: JsIdentifier ;
/.
case $rule_number: {
AST::UiQualifiedId *node = makeAstNode<AST::UiQualifiedId> (driver->nodePool(), sym(1).sval);
@@ -732,7 +780,7 @@ case $rule_number: {
} break;
./
-UiQualifiedId: UiQualifiedId T_DOT T_IDENTIFIER ;
+UiQualifiedId: UiQualifiedId T_DOT JsIdentifier ;
/.
case $rule_number: {
AST::UiQualifiedId *node = makeAstNode<AST::UiQualifiedId> (driver->nodePool(), sym(1).UiQualifiedId, sym(3).sval);
@@ -745,6 +793,7 @@ case $rule_number: {
--------------------------------------------------------------------------------------------------------
-- Expressions
--------------------------------------------------------------------------------------------------------
+
PrimaryExpression: T_THIS ;
/.
case $rule_number: {
@@ -754,7 +803,7 @@ case $rule_number: {
} break;
./
-PrimaryExpression: T_IDENTIFIER ;
+PrimaryExpression: JsIdentifier ;
/.
case $rule_number: {
AST::IdentifierExpression *node = makeAstNode<AST::IdentifierExpression> (driver->nodePool(), sym(1).sval);
@@ -996,6 +1045,18 @@ case $rule_number: {
} break;
./
+PropertyName: T_SIGNAL ;
+/.case $rule_number:./
+
+PropertyName: T_PROPERTY ;
+/.
+case $rule_number: {
+ AST::IdentifierPropertyName *node = makeAstNode<AST::IdentifierPropertyName> (driver->nodePool(), driver->intern(lexer->characterBuffer(), lexer->characterCount()));
+ node->propertyNameToken = loc(1);
+ sym(1).Node = node;
+} break;
+./
+
PropertyName: T_STRING_LITERAL ;
/.
case $rule_number: {
@@ -1151,7 +1212,7 @@ case $rule_number:
} break;
./
-PropertyIdentifier: T_IDENTIFIER ;
+PropertyIdentifier: JsIdentifier ;
PropertyIdentifier: ReservedIdentifier ;
MemberExpression: PrimaryExpression ;
@@ -2064,7 +2125,7 @@ case $rule_number: {
} break;
./
-VariableDeclaration: T_IDENTIFIER InitialiserOpt ;
+VariableDeclaration: JsIdentifier InitialiserOpt ;
/.
case $rule_number: {
AST::VariableDeclaration *node = makeAstNode<AST::VariableDeclaration> (driver->nodePool(), sym(1).sval, sym(2).Expression);
@@ -2073,7 +2134,7 @@ case $rule_number: {
} break;
./
-VariableDeclarationNotIn: T_IDENTIFIER InitialiserNotInOpt ;
+VariableDeclarationNotIn: JsIdentifier InitialiserNotInOpt ;
/.
case $rule_number: {
AST::VariableDeclaration *node = makeAstNode<AST::VariableDeclaration> (driver->nodePool(), sym(1).sval, sym(2).Expression);
@@ -2252,8 +2313,8 @@ case $rule_number: {
} break;
./
-ContinueStatement: T_CONTINUE T_IDENTIFIER T_AUTOMATIC_SEMICOLON ; -- automatic semicolon
-ContinueStatement: T_CONTINUE T_IDENTIFIER T_SEMICOLON ;
+ContinueStatement: T_CONTINUE JsIdentifier T_AUTOMATIC_SEMICOLON ; -- automatic semicolon
+ContinueStatement: T_CONTINUE JsIdentifier T_SEMICOLON ;
/.
case $rule_number: {
AST::ContinueStatement *node = makeAstNode<AST::ContinueStatement> (driver->nodePool(), sym(2).sval);
@@ -2275,8 +2336,8 @@ case $rule_number: {
} break;
./
-BreakStatement: T_BREAK T_IDENTIFIER T_AUTOMATIC_SEMICOLON ; -- automatic semicolon
-BreakStatement: T_BREAK T_IDENTIFIER T_SEMICOLON ;
+BreakStatement: T_BREAK JsIdentifier T_AUTOMATIC_SEMICOLON ; -- automatic semicolon
+BreakStatement: T_BREAK JsIdentifier T_SEMICOLON ;
/.
case $rule_number: {
AST::BreakStatement *node = makeAstNode<AST::BreakStatement> (driver->nodePool(), sym(2).sval);
@@ -2388,6 +2449,19 @@ case $rule_number: {
} break;
./
+LabelledStatement: T_SIGNAL T_COLON Statement ;
+/.case $rule_number:./
+
+LabelledStatement: T_PROPERTY T_COLON Statement ;
+/.
+case $rule_number: {
+ AST::LabelledStatement *node = makeAstNode<AST::LabelledStatement> (driver->nodePool(), driver->intern(lexer->characterBuffer(), lexer->characterCount()), sym(3).Statement);
+ node->identifierToken = loc(1);
+ node->colonToken = loc(2);
+ sym(1).Node = node;
+} break;
+./
+
LabelledStatement: T_IDENTIFIER T_COLON Statement ;
/.
case $rule_number: {
@@ -2436,7 +2510,7 @@ case $rule_number: {
} break;
./
-Catch: T_CATCH T_LPAREN T_IDENTIFIER T_RPAREN Block ;
+Catch: T_CATCH T_LPAREN JsIdentifier T_RPAREN Block ;
/.
case $rule_number: {
AST::Catch *node = makeAstNode<AST::Catch> (driver->nodePool(), sym(3).sval, sym(5).Block);
@@ -2468,7 +2542,7 @@ case $rule_number: {
} break;
./
-FunctionDeclaration: T_FUNCTION T_IDENTIFIER T_LPAREN FormalParameterListOpt T_RPAREN T_LBRACE FunctionBodyOpt T_RBRACE ;
+FunctionDeclaration: T_FUNCTION JsIdentifier T_LPAREN FormalParameterListOpt T_RPAREN T_LBRACE FunctionBodyOpt T_RBRACE ;
/.
case $rule_number: {
AST::FunctionDeclaration *node = makeAstNode<AST::FunctionDeclaration> (driver->nodePool(), sym(2).sval, sym(4).FormalParameterList, sym(7).FunctionBody);
@@ -2497,7 +2571,7 @@ case $rule_number: {
} break;
./
-FormalParameterList: T_IDENTIFIER ;
+FormalParameterList: JsIdentifier ;
/.
case $rule_number: {
AST::FormalParameterList *node = makeAstNode<AST::FormalParameterList> (driver->nodePool(), sym(1).sval);
@@ -2506,7 +2580,7 @@ case $rule_number: {
} break;
./
-FormalParameterList: FormalParameterList T_COMMA T_IDENTIFIER ;
+FormalParameterList: FormalParameterList T_COMMA JsIdentifier ;
/.
case $rule_number: {
AST::FormalParameterList *node = makeAstNode<AST::FormalParameterList> (driver->nodePool(), sym(1).FormalParameterList, sym(3).sval);
@@ -2589,7 +2663,7 @@ case $rule_number: {
} break;
./
-IdentifierOpt: T_IDENTIFIER ;
+IdentifierOpt: JsIdentifier ;
PropertyNameAndValueListOpt: ;
/.
diff --git a/src/declarative/qml/parser/javascriptast_p.h b/src/declarative/qml/parser/javascriptast_p.h
index 4aa89c9..ad317e8 100644
--- a/src/declarative/qml/parser/javascriptast_p.h
+++ b/src/declarative/qml/parser/javascriptast_p.h
@@ -2326,17 +2326,22 @@ public:
UiPublicMember(JavaScriptNameIdImpl *memberType,
JavaScriptNameIdImpl *name)
- : memberType(memberType), name(name), expression(0), isDefaultMember(false)
+ : type(Property), memberType(memberType), name(name), expression(0), isDefaultMember(false)
{ kind = K; }
UiPublicMember(JavaScriptNameIdImpl *memberType,
JavaScriptNameIdImpl *name,
ExpressionNode *expression)
- : memberType(memberType), name(name), expression(expression), isDefaultMember(false)
+ : type(Property), memberType(memberType), name(name), expression(expression), isDefaultMember(false)
{ kind = K; }
virtual SourceLocation firstSourceLocation() const
- { return publicToken; }
+ {
+ if (defaultToken.isValid())
+ return defaultToken;
+
+ return propertyToken;
+ }
virtual SourceLocation lastSourceLocation() const
{
@@ -2346,20 +2351,22 @@ public:
return colonToken;
else if (identifierToken.isValid())
return identifierToken;
- else if (attributeTypeToken.isValid())
- return attributeTypeToken;
- return publicToken;
+ else if (typeToken.isValid())
+ return typeToken;
+ return propertyToken;
}
virtual void accept0(Visitor *visitor);
// attributes
+ enum { Signal, Property } type;
JavaScriptNameIdImpl *memberType;
JavaScriptNameIdImpl *name;
ExpressionNode *expression;
bool isDefaultMember;
- SourceLocation publicToken;
- SourceLocation attributeTypeToken;
+ SourceLocation defaultToken;
+ SourceLocation propertyToken;
+ SourceLocation typeToken;
SourceLocation identifierToken;
SourceLocation colonToken;
};
diff --git a/src/declarative/qml/parser/javascriptgrammar.cpp b/src/declarative/qml/parser/javascriptgrammar.cpp
index 9fceeb8..a33f343 100644
--- a/src/declarative/qml/parser/javascriptgrammar.cpp
+++ b/src/declarative/qml/parser/javascriptgrammar.cpp
@@ -49,636 +49,637 @@ const char *const JavaScriptGrammar::spell [] = {
"if", "in", "instanceof", "{", "[", "<=", "(", "<", "<<", "<<=",
"-", "-=", "--", "new", "!", "!=", "!==", "numeric literal", "|", "|=",
"||", "+", "+=", "++", "?", "}", "]", "%", "%=", "return",
- ")", ";", 0, "*", "*=", "string literal", "switch", "this", "throw", "~",
- "try", "typeof", "var", "void", "while", "with", "^", "^=", "null", "true",
- "false", "const", "debugger", "reserved word", "multiline string literal", "public", "import", 0, 0};
+ ")", ";", 0, "*", "*=", "string literal", "property", "signal", "switch", "this",
+ "throw", "~", "try", "typeof", "var", "void", "while", "with", "^", "^=",
+ "null", "true", "false", "const", "debugger", "reserved word", "multiline string literal", "public", "import", 0,
+ 0};
const int JavaScriptGrammar::lhs [] = {
- 89, 90, 90, 93, 93, 94, 94, 92, 91, 91,
- 96, 96, 98, 98, 97, 95, 97, 95, 97, 95,
- 100, 101, 101, 95, 97, 95, 95, 95, 95, 95,
- 95, 95, 99, 99, 99, 99, 106, 106, 106, 106,
- 106, 106, 106, 106, 106, 106, 106, 106, 106, 106,
- 106, 108, 108, 112, 112, 107, 107, 110, 110, 113,
- 113, 113, 113, 114, 114, 114, 114, 114, 114, 114,
- 114, 114, 114, 114, 114, 114, 114, 114, 114, 114,
- 114, 114, 114, 114, 114, 114, 114, 114, 114, 114,
- 114, 114, 114, 114, 115, 115, 116, 116, 116, 116,
- 116, 119, 119, 120, 120, 120, 120, 118, 118, 121,
- 121, 122, 122, 123, 123, 123, 124, 124, 124, 124,
- 124, 124, 124, 124, 124, 124, 125, 125, 125, 125,
- 126, 126, 126, 127, 127, 127, 127, 128, 128, 128,
- 128, 128, 128, 128, 129, 129, 129, 129, 129, 129,
- 130, 130, 130, 130, 130, 131, 131, 131, 131, 131,
- 132, 132, 133, 133, 134, 134, 135, 135, 136, 136,
- 137, 137, 138, 138, 139, 139, 140, 140, 141, 141,
- 142, 142, 143, 143, 111, 111, 144, 144, 145, 145,
- 145, 145, 145, 145, 145, 145, 145, 145, 145, 145,
- 103, 103, 146, 146, 147, 147, 148, 148, 102, 102,
- 102, 102, 102, 102, 102, 102, 102, 102, 102, 102,
- 102, 102, 102, 149, 164, 164, 163, 163, 105, 105,
- 165, 165, 166, 166, 168, 168, 167, 169, 172, 170,
- 170, 173, 171, 171, 150, 151, 151, 152, 152, 153,
- 153, 153, 153, 153, 153, 153, 154, 154, 154, 154,
- 155, 155, 155, 155, 156, 156, 157, 159, 174, 174,
- 177, 177, 175, 175, 178, 176, 158, 160, 160, 161,
- 161, 161, 179, 180, 162, 162, 104, 117, 184, 184,
- 181, 181, 182, 182, 185, 186, 186, 187, 187, 183,
- 183, 109, 109, 188};
+ 91, 92, 92, 95, 95, 96, 96, 94, 93, 93,
+ 98, 98, 100, 100, 99, 97, 99, 97, 99, 97,
+ 102, 103, 103, 97, 99, 97, 105, 105, 105, 97,
+ 97, 97, 97, 97, 97, 97, 101, 101, 109, 109,
+ 109, 101, 101, 110, 110, 110, 110, 110, 110, 110,
+ 110, 110, 110, 110, 110, 110, 110, 110, 112, 112,
+ 116, 116, 111, 111, 114, 114, 117, 117, 117, 117,
+ 117, 117, 118, 118, 118, 118, 118, 118, 118, 118,
+ 118, 118, 118, 118, 118, 118, 118, 118, 118, 118,
+ 118, 118, 118, 118, 118, 118, 118, 118, 118, 118,
+ 118, 118, 118, 119, 119, 120, 120, 120, 120, 120,
+ 123, 123, 124, 124, 124, 124, 122, 122, 125, 125,
+ 126, 126, 127, 127, 127, 128, 128, 128, 128, 128,
+ 128, 128, 128, 128, 128, 129, 129, 129, 129, 130,
+ 130, 130, 131, 131, 131, 131, 132, 132, 132, 132,
+ 132, 132, 132, 133, 133, 133, 133, 133, 133, 134,
+ 134, 134, 134, 134, 135, 135, 135, 135, 135, 136,
+ 136, 137, 137, 138, 138, 139, 139, 140, 140, 141,
+ 141, 142, 142, 143, 143, 144, 144, 145, 145, 146,
+ 146, 147, 147, 115, 115, 148, 148, 149, 149, 149,
+ 149, 149, 149, 149, 149, 149, 149, 149, 149, 106,
+ 106, 150, 150, 151, 151, 152, 152, 104, 104, 104,
+ 104, 104, 104, 104, 104, 104, 104, 104, 104, 104,
+ 104, 104, 153, 168, 168, 167, 167, 108, 108, 169,
+ 169, 170, 170, 172, 172, 171, 173, 176, 174, 174,
+ 177, 175, 175, 154, 155, 155, 156, 156, 157, 157,
+ 157, 157, 157, 157, 157, 158, 158, 158, 158, 159,
+ 159, 159, 159, 160, 160, 161, 163, 178, 178, 181,
+ 181, 179, 179, 182, 180, 162, 162, 162, 164, 164,
+ 165, 165, 165, 183, 184, 166, 166, 107, 121, 188,
+ 188, 185, 185, 186, 186, 189, 190, 190, 191, 191,
+ 187, 187, 113, 113, 192};
const int JavaScriptGrammar:: rhs[] = {
2, 1, 1, 1, 2, 3, 3, 0, 1, 2,
1, 3, 2, 3, 4, 4, 2, 2, 5, 5,
- 1, 2, 2, 3, 3, 3, 3, 4, 5, 6,
- 1, 1, 1, 1, 1, 3, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 3, 3, 5, 3, 4,
- 3, 2, 4, 1, 2, 0, 1, 3, 5, 1,
+ 1, 2, 2, 3, 3, 3, 1, 1, 1, 2,
+ 3, 4, 5, 6, 1, 1, 1, 1, 1, 1,
+ 1, 1, 3, 1, 1, 1, 1, 1, 1, 1,
+ 1, 1, 3, 3, 5, 3, 4, 3, 2, 4,
+ 1, 2, 0, 1, 3, 5, 1, 1, 1, 1,
1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 4, 3,
- 5, 1, 2, 4, 4, 4, 3, 0, 1, 1,
- 3, 1, 1, 1, 2, 2, 1, 2, 2, 2,
- 2, 2, 2, 2, 2, 2, 1, 3, 3, 3,
- 1, 3, 3, 1, 3, 3, 3, 1, 3, 3,
- 3, 3, 3, 3, 1, 3, 3, 3, 3, 3,
- 1, 3, 3, 3, 3, 1, 3, 3, 3, 3,
- 1, 3, 1, 3, 1, 3, 1, 3, 1, 3,
- 1, 3, 1, 3, 1, 3, 1, 3, 1, 3,
- 1, 5, 1, 5, 1, 3, 1, 3, 1, 1,
+ 1, 1, 1, 1, 1, 1, 1, 4, 3, 5,
+ 1, 2, 4, 4, 4, 3, 0, 1, 1, 3,
+ 1, 1, 1, 2, 2, 1, 2, 2, 2, 2,
+ 2, 2, 2, 2, 2, 1, 3, 3, 3, 1,
+ 3, 3, 1, 3, 3, 3, 1, 3, 3, 3,
+ 3, 3, 3, 1, 3, 3, 3, 3, 3, 1,
+ 3, 3, 3, 3, 1, 3, 3, 3, 3, 1,
+ 3, 1, 3, 1, 3, 1, 3, 1, 3, 1,
+ 3, 1, 3, 1, 3, 1, 3, 1, 3, 1,
+ 5, 1, 5, 1, 3, 1, 3, 1, 1, 1,
1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 3, 0, 1, 1, 3, 0, 1, 1, 1,
+ 3, 0, 1, 1, 3, 0, 1, 1, 1, 1,
1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 3, 1, 2, 0, 1, 3, 3,
- 1, 1, 1, 3, 1, 3, 2, 2, 2, 0,
- 1, 2, 0, 1, 1, 2, 2, 7, 5, 7,
- 7, 5, 9, 10, 7, 8, 2, 2, 3, 3,
- 2, 2, 3, 3, 3, 3, 5, 5, 3, 5,
- 1, 2, 0, 1, 4, 3, 3, 3, 3, 3,
- 3, 4, 5, 2, 2, 2, 8, 8, 1, 3,
- 0, 1, 0, 1, 1, 1, 2, 1, 1, 0,
- 1, 0, 1, 2};
+ 1, 1, 3, 1, 2, 0, 1, 3, 3, 1,
+ 1, 1, 3, 1, 3, 2, 2, 2, 0, 1,
+ 2, 0, 1, 1, 2, 2, 7, 5, 7, 7,
+ 5, 9, 10, 7, 8, 2, 2, 3, 3, 2,
+ 2, 3, 3, 3, 3, 5, 5, 3, 5, 1,
+ 2, 0, 1, 4, 3, 3, 3, 3, 3, 3,
+ 3, 3, 4, 5, 2, 2, 2, 8, 8, 1,
+ 3, 0, 1, 0, 1, 1, 1, 2, 1, 1,
+ 0, 1, 0, 1, 2};
const int JavaScriptGrammar::action_default [] = {
8, 2, 0, 4, 3, 0, 0, 0, 6, 7,
- 5, 31, 231, 0, 35, 0, 33, 34, 232, 9,
- 1, 0, 0, 32, 0, 291, 292, 0, 289, 0,
- 290, 0, 293, 134, 201, 165, 173, 169, 209, 216,
- 113, 185, 215, 223, 211, 161, 0, 212, 294, 0,
- 299, 98, 213, 214, 219, 114, 177, 181, 102, 131,
- 112, 117, 97, 151, 217, 138, 296, 295, 298, 220,
- 0, 0, 0, 0, 44, 45, 0, 41, 0, 300,
- 38, 0, 302, 56, 0, 0, 0, 0, 0, 39,
- 42, 0, 0, 203, 245, 43, 0, 37, 0, 0,
- 40, 0, 0, 0, 0, 0, 221, 222, 127, 210,
- 218, 0, 0, 114, 133, 300, 38, 302, 116, 115,
- 0, 0, 0, 129, 130, 128, 0, 301, 291, 0,
- 0, 293, 0, 288, 0, 303, 0, 63, 64, 65,
- 66, 91, 67, 92, 68, 69, 70, 71, 72, 73,
- 74, 75, 60, 76, 77, 78, 79, 80, 62, 93,
- 81, 61, 82, 83, 84, 85, 86, 87, 88, 89,
- 90, 94, 0, 58, 0, 0, 50, 0, 59, 49,
- 132, 0, 162, 0, 0, 0, 0, 152, 0, 0,
- 0, 0, 0, 0, 142, 0, 0, 0, 136, 137,
- 135, 140, 144, 143, 141, 139, 154, 153, 155, 0,
- 170, 0, 166, 0, 0, 108, 107, 96, 95, 0,
- 0, 106, 202, 109, 0, 110, 0, 111, 105, 246,
- 247, 287, 0, 198, 191, 189, 196, 197, 195, 194,
- 200, 193, 192, 190, 199, 186, 0, 174, 0, 0,
- 178, 0, 0, 182, 0, 0, 108, 100, 0, 99,
- 0, 104, 297, 261, 0, 262, 263, 264, 257, 0,
- 258, 259, 260, 285, 286, 118, 0, 0, 0, 0,
- 0, 250, 251, 207, 205, 167, 175, 171, 187, 163,
- 208, 0, 114, 179, 183, 156, 145, 0, 0, 164,
- 0, 0, 0, 0, 157, 0, 0, 0, 0, 0,
- 149, 147, 150, 148, 146, 159, 158, 160, 0, 172,
- 0, 168, 0, 206, 114, 0, 188, 203, 204, 0,
- 203, 0, 0, 253, 0, 0, 0, 255, 0, 176,
- 0, 0, 180, 0, 0, 184, 243, 0, 235, 244,
- 238, 0, 242, 0, 203, 236, 0, 203, 0, 0,
- 254, 0, 0, 0, 256, 301, 0, 277, 0, 0,
- 0, 249, 0, 248, 225, 228, 0, 64, 91, 67,
- 92, 69, 70, 41, 74, 75, 38, 76, 79, 39,
- 42, 203, 43, 82, 37, 84, 40, 86, 87, 88,
- 89, 90, 94, 226, 224, 102, 103, 108, 0, 101,
- 0, 265, 266, 0, 0, 0, 268, 273, 271, 274,
- 0, 0, 272, 273, 0, 269, 0, 270, 227, 276,
- 0, 227, 275, 0, 278, 279, 0, 227, 280, 281,
- 0, 0, 282, 0, 0, 0, 283, 284, 120, 119,
- 0, 0, 0, 252, 0, 0, 0, 267, 0, 57,
- 0, 54, 56, 47, 0, 53, 48, 55, 52, 46,
- 0, 51, 124, 122, 126, 123, 121, 125, 0, 18,
- 13, 0, 14, 10, 0, 0, 0, 28, 0, 30,
- 27, 0, 29, 0, 0, 26, 38, 56, 21, 0,
- 24, 16, 35, 0, 11, 0, 17, 0, 20, 12,
- 0, 25, 38, 56, 15, 0, 19, 22, 23, 36,
- 240, 233, 0, 241, 237, 0, 239, 229, 0, 230,
- 234, 304};
+ 5, 35, 42, 240, 0, 0, 39, 40, 37, 38,
+ 41, 241, 9, 1, 0, 0, 36, 0, 29, 28,
+ 27, 0, 32, 0, 143, 210, 174, 182, 178, 122,
+ 194, 170, 34, 107, 45, 123, 186, 190, 111, 140,
+ 121, 126, 106, 160, 147, 0, 51, 52, 48, 311,
+ 39, 313, 63, 0, 0, 0, 0, 0, 46, 49,
+ 0, 0, 40, 41, 50, 44, 0, 47, 0, 0,
+ 136, 0, 0, 123, 142, 125, 124, 0, 0, 0,
+ 138, 139, 137, 141, 0, 171, 0, 0, 0, 0,
+ 161, 0, 0, 0, 0, 0, 0, 151, 0, 0,
+ 0, 145, 146, 144, 149, 153, 152, 150, 148, 163,
+ 162, 164, 0, 179, 0, 175, 0, 0, 117, 104,
+ 116, 105, 73, 74, 75, 100, 76, 101, 77, 78,
+ 79, 80, 81, 82, 83, 84, 85, 86, 87, 88,
+ 89, 102, 90, 91, 92, 93, 94, 95, 96, 97,
+ 98, 99, 103, 0, 0, 115, 211, 118, 0, 119,
+ 0, 120, 114, 0, 207, 200, 198, 205, 206, 204,
+ 203, 209, 202, 201, 199, 208, 195, 0, 183, 0,
+ 0, 187, 0, 0, 191, 0, 0, 117, 109, 0,
+ 108, 0, 113, 127, 0, 312, 302, 303, 0, 300,
+ 0, 301, 0, 304, 218, 225, 224, 232, 220, 0,
+ 221, 305, 0, 310, 222, 223, 228, 226, 307, 306,
+ 309, 229, 0, 0, 0, 0, 0, 311, 39, 0,
+ 313, 40, 212, 254, 41, 0, 0, 0, 0, 0,
+ 230, 231, 219, 227, 255, 256, 299, 308, 0, 270,
+ 271, 272, 273, 0, 266, 267, 268, 269, 296, 297,
+ 0, 0, 0, 0, 0, 259, 260, 216, 214, 176,
+ 184, 180, 196, 172, 217, 0, 123, 188, 192, 165,
+ 154, 0, 0, 173, 0, 0, 0, 0, 166, 0,
+ 0, 0, 0, 0, 158, 156, 159, 157, 155, 168,
+ 167, 169, 0, 181, 0, 177, 0, 215, 123, 0,
+ 197, 212, 213, 0, 212, 0, 0, 262, 0, 0,
+ 0, 264, 0, 185, 0, 0, 189, 0, 0, 193,
+ 252, 0, 244, 253, 247, 0, 251, 0, 212, 245,
+ 0, 212, 0, 0, 263, 0, 0, 0, 265, 312,
+ 302, 0, 0, 304, 0, 298, 0, 288, 0, 0,
+ 0, 258, 0, 257, 0, 314, 0, 72, 234, 237,
+ 0, 73, 240, 76, 101, 78, 79, 48, 83, 84,
+ 39, 85, 88, 46, 49, 40, 212, 41, 50, 91,
+ 44, 93, 47, 95, 96, 241, 98, 99, 103, 0,
+ 65, 0, 0, 67, 71, 69, 57, 68, 70, 0,
+ 66, 56, 235, 233, 111, 112, 117, 0, 110, 0,
+ 287, 0, 274, 275, 0, 286, 0, 0, 0, 277,
+ 282, 280, 283, 0, 0, 281, 282, 0, 278, 0,
+ 279, 236, 285, 0, 236, 284, 0, 289, 290, 0,
+ 236, 291, 292, 0, 0, 293, 0, 0, 0, 294,
+ 295, 129, 128, 0, 0, 0, 261, 0, 0, 0,
+ 276, 0, 64, 0, 61, 63, 54, 0, 60, 55,
+ 62, 59, 53, 0, 58, 133, 131, 135, 132, 130,
+ 134, 0, 0, 18, 13, 0, 14, 10, 0, 31,
+ 0, 33, 30, 0, 0, 26, 39, 63, 21, 0,
+ 24, 16, 39, 0, 11, 0, 17, 0, 20, 12,
+ 0, 25, 39, 63, 15, 0, 19, 22, 23, 43,
+ 249, 242, 0, 250, 246, 0, 248, 238, 0, 239,
+ 243, 315};
const int JavaScriptGrammar::goto_default [] = {
- 6, 5, 20, 1, 4, 3, 19, 503, 504, 479,
- 21, 499, 500, 374, 46, 11, 109, 62, 460, 458,
- 136, 135, 34, 459, 134, 137, 216, 58, 51, 224,
- 60, 40, 223, 55, 61, 108, 59, 33, 65, 63,
- 295, 45, 289, 35, 285, 37, 287, 36, 286, 56,
- 293, 57, 294, 41, 288, 284, 325, 410, 290, 291,
- 38, 44, 47, 52, 53, 42, 39, 64, 110, 54,
- 69, 106, 107, 43, 376, 375, 22, 522, 521, 347,
- 348, 524, 350, 523, 349, 416, 420, 423, 419, 418,
- 438, 439, 27, 49, 126, 26, 48, 67, 66, 0};
+ 6, 5, 23, 1, 4, 3, 22, 523, 524, 503,
+ 24, 519, 520, 378, 508, 219, 11, 252, 44, 52,
+ 483, 481, 376, 375, 35, 482, 374, 377, 130, 48,
+ 43, 168, 50, 39, 167, 45, 51, 80, 49, 34,
+ 54, 53, 289, 41, 283, 36, 279, 38, 281, 37,
+ 280, 46, 287, 47, 288, 40, 282, 278, 319, 431,
+ 284, 285, 214, 218, 220, 224, 225, 216, 215, 227,
+ 253, 226, 231, 250, 251, 217, 380, 379, 25, 542,
+ 541, 341, 342, 544, 344, 543, 343, 439, 443, 446,
+ 442, 441, 461, 462, 208, 222, 204, 207, 221, 229,
+ 228, 0};
const int JavaScriptGrammar::action_index [] = {
- 67, -89, 30, -89, 67, 346, 173, 79, -89, -89,
- -89, -89, -89, 32, 33, 90, -89, -89, -89, -89,
- 336, 106, 45, -89, 55, 65, 85, 66, -89, 70,
- -89, 59, 1539, 111, -89, 11, -34, -17, -89, -89,
- 188, -89, -89, -89, -89, 269, 150, -89, -89, -51,
- -89, -89, -89, -89, -89, 549, 41, 146, 247, 158,
- -89, -89, -89, 329, -89, 311, -89, 1539, -89, -89,
- 196, 191, 118, 713, -89, -89, 1454, -89, -23, 16,
- 83, 61, 1709, 78, 713, 713, 713, 452, 713, -89,
- -89, 713, 713, 713, -89, -89, 47, -89, 713, 713,
- -89, 37, 713, 713, 73, 53, -89, -89, -89, -89,
- -89, 713, 713, 76, 193, 46, -89, 1199, -89, -89,
- 713, 713, 713, -89, -89, -89, -25, -89, -13, -52,
- -9, 1539, 60, -89, 77, 80, 17, -89, -89, -89,
- -89, -89, -89, -89, -89, -89, -89, -89, -89, -89,
- -89, -89, -89, -89, -89, -89, -89, -89, -89, -89,
- -89, -89, -89, -89, -89, -89, -89, -89, -89, -89,
- -89, -89, 713, -89, 1284, 21, -89, 713, -89, -89,
- 211, 713, 267, 713, 713, 713, 713, 319, 713, 713,
- 713, 713, 713, 713, 201, 713, 713, 713, 96, 91,
- 110, 189, 242, 246, 238, 234, 359, 339, 349, 713,
- 63, 713, 68, 1114, 713, 713, -89, -89, -89, 104,
- 713, -89, -89, 69, 18, -89, 713, -89, -89, -89,
- -89, -89, 713, -89, -89, -89, -89, -89, -89, -89,
- -89, -89, -89, -89, -89, -89, 713, 48, 713, 713,
- 74, 64, 713, -89, 1114, 713, 713, -89, 116, -89,
- 2, -89, -89, -89, 87, -89, -89, -89, -89, 113,
- -89, -89, -89, -89, -89, -89, 56, 62, 713, 103,
- 130, -89, -89, 791, -89, 84, -38, -67, -89, 260,
- 10, -41, 635, 20, 117, 302, 239, -10, 713, 271,
- 713, 713, 713, 713, 272, 713, 713, 713, 713, 713,
- 208, 222, 205, 213, 217, 287, 377, 377, 713, -73,
- 713, 84, 713, -89, 463, 713, -89, 713, 42, -15,
- 713, -16, 1454, -89, 713, 144, 1454, -89, 713, 6,
- 713, 713, 54, 51, 713, -89, 38, 95, 26, -89,
- -89, 713, -89, -2, 713, -89, -31, 713, -37, 1454,
- -89, 713, 99, 1454, -89, 4, 1454, -89, 713, 97,
- 1454, 22, 1454, -89, -89, 1454, 49, 140, 5, 147,
- 82, 713, 1454, 29, 1, 81, 34, 3, 538, 28,
- 25, 873, 19, -3, 24, 713, 35, 14, 713, 23,
- 713, 15, 27, -89, -89, 163, -89, 713, -7, -89,
- 128, -89, -89, 713, 138, -8, -89, 44, -89, 43,
- 127, 713, -89, 12, -1, -89, -50, -89, 1454, -89,
- 115, 1454, -89, 175, -89, -89, 108, 1454, -18, -89,
- -29, -4, -89, -28, -60, -4, -89, -89, -89, -89,
- 713, 124, 1454, -89, 713, 125, 1454, -89, 112, 13,
- 1029, -89, 7, -89, 951, -89, -89, -89, -89, -89,
- 126, -89, -89, -89, -89, -89, -89, -89, 356, -89,
- -89, 375, -89, -89, 39, 31, 36, 57, 713, 71,
- 75, 713, 72, 1624, 52, -89, 131, 274, -89, 133,
- -89, -89, 40, 137, -89, 101, -89, 148, -89, -89,
- 1369, -89, 94, 262, -89, 98, -89, -89, -89, -89,
- 50, -89, 157, -89, -89, 713, -89, -89, 58, -89,
- -89, -89,
+ 62, -91, -18, -91, -40, 362, 44, 117, -91, -91,
+ -91, -91, -91, -91, -12, 144, 20, 130, -91, -91,
+ 14, -91, -91, 356, 127, 195, -91, 158, -91, -91,
+ -91, 11, 34, 678, 125, -91, 41, -9, -27, 204,
+ -91, 263, 58, -91, -91, 519, 61, 63, 220, 131,
+ -91, -91, -91, 330, 159, 678, -91, -91, -91, 154,
+ -91, 1176, 53, 678, 678, 678, 598, 678, -91, -91,
+ 678, 678, -91, -91, -91, -91, 678, -91, 678, 678,
+ -91, 678, 678, 118, 221, -91, -91, 678, 678, 678,
+ -91, -91, -91, 217, 678, 269, 678, 678, 678, 678,
+ 311, 678, 678, 678, 678, 678, 678, 228, 678, 678,
+ 678, 104, 65, 64, 187, 164, 214, 295, 295, 431,
+ 431, 345, 678, -7, 678, 90, 1089, 678, 678, -91,
+ -91, -91, -91, -91, -91, -91, -91, -91, -91, -91,
+ -91, -91, -91, -91, -91, -91, -91, -91, -91, -91,
+ -91, -91, -91, -91, -91, -91, -91, -91, -91, -91,
+ -91, -91, -91, 113, 678, -91, -91, 42, -8, -91,
+ 678, -91, -91, 678, -91, -91, -91, -91, -91, -91,
+ -91, -91, -91, -91, -91, -91, -91, 678, 22, 678,
+ 678, 29, 5, 678, -91, 1089, 678, 678, -91, 110,
+ -91, 51, -91, -91, 36, -91, 184, 85, 60, -91,
+ 151, -91, 56, 1437, -91, -91, -91, -91, -91, 166,
+ -91, -91, 28, -91, -91, -91, -91, -91, -91, 1437,
+ -91, -91, 290, 244, 102, 1350, 49, 178, 73, 39,
+ 1698, 70, 678, -91, 72, 46, 678, 43, 37, 38,
+ -91, -91, -91, -91, -91, -91, -91, -91, 68, -91,
+ -91, -91, -91, 71, -91, -91, -91, -91, -91, -91,
+ 50, 54, 678, 88, 66, -91, -91, 842, -91, 87,
+ 47, 45, -91, 257, 59, 26, 486, 84, 146, 363,
+ 295, 205, 678, 249, 678, 678, 678, 678, 363, 678,
+ 678, 678, 678, 678, 295, 295, 295, 295, 295, 293,
+ 363, 363, 678, -21, 678, 18, 678, -91, 519, 678,
+ -91, 678, 13, -37, 678, -38, 1350, -91, 678, 98,
+ 1350, -91, 678, -28, 678, 678, 16, 8, 678, -91,
+ 0, 229, -15, -91, -91, 678, -91, 219, 678, -91,
+ -34, 678, -32, 1350, -91, 678, 89, 1350, -91, -6,
+ 197, -24, 1, 1437, -23, -91, 1350, -91, 678, 94,
+ 1350, 17, 1350, -91, 6, 15, -26, -91, -91, 1350,
+ -30, 231, 7, 278, 76, 678, 1350, -5, -36, 260,
+ -3, -29, 598, -4, -1, -91, 762, -91, 3, 19,
+ 4, 678, -2, -25, 678, 2, 678, -35, -10, 678,
+ -91, 1263, 52, -91, -91, -91, -91, -91, -91, 678,
+ -91, -91, -91, -91, 167, -91, 678, 21, -91, 1350,
+ -91, 74, -91, -91, 1350, -91, 678, 91, 25, -91,
+ 105, -91, 105, 97, 678, -91, 105, 55, -91, 23,
+ -91, 1350, -91, 101, 1350, -91, 208, -91, -91, 92,
+ 1350, 40, -91, 33, 35, -91, 180, 24, 31, -91,
+ -91, -91, -91, 678, 86, 1350, -91, 678, 93, 1350,
+ -91, 106, 57, 922, -91, 48, -91, 1002, -91, -91,
+ -91, -91, -91, 132, -91, -91, -91, -91, -91, -91,
+ -91, 10, 424, -91, -91, 421, -91, -91, 9, 30,
+ 678, 27, -91, 1611, 156, -91, 134, 342, -91, 95,
+ -91, -91, 12, 116, -91, 124, -91, 270, -91, -91,
+ 1524, -91, 112, 352, -91, 114, -91, -91, -91, -91,
+ 32, -91, 169, -91, -91, 678, -91, -91, 139, -91,
+ -91, -91,
- -100, -100, -100, -100, 12, 4, -100, -100, -100, -100,
- -100, -100, -100, -100, -100, -100, -100, -100, -100, -100,
- 59, -100, -100, -100, -100, -100, -100, -100, -100, -100,
- -100, -100, 117, -100, -100, -100, -100, -100, -100, -100,
- -100, -100, -100, -100, -100, -100, -100, -100, -100, -100,
- -100, -100, -100, -100, -100, -54, -100, -100, -100, -100,
- -100, -100, -100, -100, -100, -100, -100, 184, -100, -100,
- -100, -100, -100, 116, -100, -100, 47, -100, -100, -100,
- -100, -100, -100, -100, 39, 141, 89, 65, 48, -100,
- -100, 51, 52, 38, -100, -100, -100, -100, 40, 83,
- -100, -16, 61, 66, -100, -100, -100, -100, -100, -100,
- -100, 44, 57, -100, -100, -100, -100, -100, -100, -100,
- 112, 109, 133, -100, -100, -100, -100, -100, -61, -100,
- -100, 193, -100, -100, -100, -100, -100, -100, -100, -100,
- -100, -100, -100, -100, -100, -100, -100, -100, -100, -100,
- -100, -100, -100, -100, -100, -100, -100, -100, -100, -100,
- -100, -100, -100, -100, -100, -100, -100, -100, -100, -100,
- -100, -100, -13, -100, -18, -100, -100, -7, -100, -100,
- -100, 121, -100, 113, 104, 90, 92, -100, 123, 103,
- 101, 102, 95, 137, -100, 145, 132, 126, -100, -100,
- -100, -100, -100, -100, -100, -100, -100, -100, -100, 58,
- -100, 84, -100, 11, 7, 3, -100, -100, -100, -100,
- 6, -100, -100, -100, -100, -100, 10, -100, -100, -100,
- -100, -100, 5, -100, -100, -100, -100, -100, -100, -100,
- -100, -100, -100, -100, -100, -100, 41, -100, 56, -3,
- -100, -100, 0, -100, 147, 64, 138, -100, -100, -100,
- -100, -100, -100, -100, -100, -100, -100, -100, -100, -100,
- -100, -100, -100, -100, -100, -100, -100, -100, 2, -100,
- -100, -100, -100, 115, -100, -100, -100, -100, -100, -100,
- -100, -100, -100, -100, -100, -100, -100, -100, 187, -100,
- 154, 195, 183, 198, -100, 33, 73, 82, 71, 75,
- -100, -100, -100, -100, -100, -100, -100, -100, 165, -100,
- 146, -100, 150, -100, -100, 177, -100, 50, -100, -100,
- 53, -100, 22, -100, 9, -100, 45, -100, 171, -100,
- 189, 169, -100, -100, 163, -100, -100, -100, -100, -100,
- -100, 162, -100, -68, 136, -100, -100, 124, -100, -2,
- -100, -4, -100, -5, -100, -100, 46, -100, 43, -100,
- 35, -100, 34, -100, -100, 42, -100, -100, -100, -100,
- -100, 122, 30, -100, -100, -100, -100, -100, 70, -100,
- -100, 49, -100, -100, -100, 36, -100, -15, 86, -100,
- 79, -100, -100, -100, -100, -100, -100, 142, -100, -100,
- -100, -100, -100, 37, -100, -100, -100, -100, -100, -40,
- -100, 32, -100, -44, -100, -100, -100, -100, -33, -100,
- -100, -12, -100, -100, -100, -100, -100, -100, -35, -100,
- -100, -36, -100, -100, -100, -53, -100, -100, -100, -100,
- -1, -100, 1, -100, -10, -100, -8, -100, -100, -100,
- -19, -100, -17, -100, -22, -100, -100, -100, -100, -100,
- -100, -100, -100, -100, -100, -100, -100, -100, 175, -100,
- -100, 236, -100, -100, -100, -100, -100, -100, 19, -100,
- -100, 15, -100, 21, -100, -100, 28, 29, -100, -100,
- -100, -100, 31, -100, -100, -100, -100, 60, -100, -100,
- 25, -100, 17, 62, -100, -100, -100, -100, -100, -100,
- -100, -100, -100, -100, -100, 8, -100, -100, -60, -100,
- -100, -100};
+ -102, -102, -102, -102, 34, 63, -102, -102, -102, -102,
+ -102, -102, -102, -102, -102, 53, -102, -102, -102, -102,
+ -102, -102, -102, 235, -102, 9, -102, 4, -102, -102,
+ -102, -102, -102, -5, -102, -102, -102, -102, -102, -102,
+ -102, -102, -102, -102, -102, -51, -102, -102, -102, -102,
+ -102, -102, -102, -102, -102, 156, -102, -102, -102, 18,
+ -102, -102, -102, -11, 95, 88, 90, 79, -102, -102,
+ 80, 100, -102, -102, -102, -102, 114, -102, 101, 107,
+ -102, 73, 131, -102, -102, -102, -102, 108, 111, 115,
+ -102, -102, -102, -102, 165, -102, 83, 85, 118, 71,
+ -102, 120, 144, 145, 143, 147, 159, -102, 122, 129,
+ 66, -102, -102, -102, -102, -102, -102, -102, -102, -102,
+ -102, -102, 41, -102, 65, -102, 77, 26, 19, -102,
+ -102, -102, -102, -102, -102, -102, -102, -102, -102, -102,
+ -102, -102, -102, -102, -102, -102, -102, -102, -102, -102,
+ -102, -102, -102, -102, -102, -102, -102, -102, -102, -102,
+ -102, -102, -102, -102, 27, -102, -102, -102, -102, -102,
+ 28, -102, -102, 42, -102, -102, -102, -102, -102, -102,
+ -102, -102, -102, -102, -102, -102, -102, 139, -102, 138,
+ -1, -102, -102, 1, -102, 230, -10, 55, -102, -102,
+ -102, -102, -102, -102, -102, -102, -3, -102, -102, -102,
+ -4, -102, -102, 86, -102, -102, -102, -102, -102, -102,
+ -102, -102, -102, -102, -102, -102, -102, -102, -102, 254,
+ -102, -102, 56, 50, -102, 46, -102, -6, -102, -102,
+ -102, -102, -2, -102, -102, -102, 17, -28, -102, -102,
+ -102, -102, -102, -102, -102, -102, -102, -102, -102, -102,
+ -102, -102, -102, -102, -102, -102, -102, -102, -102, -102,
+ -102, -102, 5, -102, -102, -102, -102, 146, -102, -102,
+ -102, -102, -102, -102, -102, -102, -102, -102, -102, -102,
+ -102, 43, 225, -102, 237, 226, 197, 196, -102, 127,
+ 136, 137, 135, 93, -102, -102, -102, -102, -102, -102,
+ -102, -102, 174, -102, 180, -102, 170, -102, -102, 183,
+ -102, 68, -102, -102, 70, -102, 49, -102, 48, -102,
+ 47, -102, 193, -102, 161, 219, -102, -102, 189, -102,
+ -102, -102, -102, -102, -102, 190, -102, 59, 72, -102,
+ -102, 75, -102, 57, -102, 58, -102, 51, -102, -102,
+ 64, -102, -102, 203, -102, -102, 44, -102, 32, -102,
+ 31, -102, 29, -102, -102, -102, -102, -102, -102, 40,
+ -102, 37, -102, 38, -102, 61, 36, -102, -102, 30,
+ -102, -102, 62, -102, -102, -102, 35, -102, -102, -102,
+ -102, 39, -102, 3, 128, -102, 155, -102, -102, 22,
+ -102, 14, -102, -102, -102, -102, -102, -102, -102, 13,
+ -102, -102, -102, -102, -102, -102, 123, -102, -102, 45,
+ -102, -102, -102, -102, 25, -102, 52, -102, -102, -102,
+ -102, -102, -80, -102, 54, -102, -72, -102, -102, -102,
+ -102, -73, -102, -102, -76, -102, -102, -102, -102, -102,
+ -102, -87, -102, -102, -45, -102, 12, -102, -31, -102,
+ -102, -102, -102, 20, -102, 15, -102, 98, -102, 6,
+ -102, -102, -102, 0, -102, 2, -102, -16, -102, -102,
+ -102, -102, -102, -102, -102, -102, -102, -102, -102, -102,
+ -102, -102, 232, -102, -102, 238, -102, -102, -102, -102,
+ 11, -102, -102, 16, -9, -102, -7, 74, -102, -102,
+ -102, -102, 24, -102, -102, -102, -102, 194, -102, -102,
+ 8, -102, -8, 188, -102, -102, -102, -102, -102, -102,
+ -102, -102, -102, -102, -102, 21, -102, -102, 60, -102,
+ -102, -102};
const int JavaScriptGrammar::action_info [] = {
- 445, 444, 441, 320, 231, 427, 428, 443, 130, 320,
- 318, 128, 181, 283, 209, 461, 28, 421, 322, 346,
- 327, 467, 338, 359, 131, 417, -61, 346, 177, 437,
- 357, -83, -62, 413, -231, -80, -72, 283, 372, 368,
- 25, -60, -85, 246, 332, 365, 330, 437, 421, 421,
- 220, 450, -232, 409, 318, 351, 338, 361, 344, 211,
- 490, 24, 261, 454, 488, 487, 478, 525, 486, 181,
- 437, 252, 179, 478, 520, 127, 246, 226, 228, 220,
- 220, 519, 491, 413, 172, 298, 461, 520, 174, 454,
- 366, 25, 32, 29, 28, 7, 209, 368, 278, 30,
- 484, 366, 0, 353, 404, 220, 507, 220, 510, 450,
- 127, 220, 220, 493, 440, 133, 494, -300, 118, 485,
- 462, 494, 431, 220, 220, 0, 31, 478, 441, 119,
- 277, 111, 220, 220, 220, 0, 111, 424, 366, 211,
- 9, 8, 112, 274, 273, 507, 220, 112, 267, 266,
- 111, 111, 220, 2, 516, 0, 354, 370, 220, 363,
- 221, 112, 112, 280, 478, 528, 0, 340, 463, 264,
- 120, 341, 259, 531, 272, 271, 269, 502, 254, 274,
- 273, 0, 425, 220, 452, 456, 471, 0, 0, 412,
- 411, 282, 281, 508, 518, 517, 248, 255, 415, 407,
- 249, 265, 263, 213, 336, 120, 0, 17, 270, 268,
- 0, 230, 229, 0, 195, 121, 196, 0, 529, 527,
- 269, 122, 214, 120, 215, 264, 195, 197, 196, 0,
- 195, 16, 196, 195, 0, 196, 435, 434, 195, 197,
- 196, 0, 195, 197, 196, 0, 197, 195, 0, 196,
- 121, 197, 270, 268, 0, 197, 122, 265, 263, 195,
- 197, 196, 254, 195, 195, 196, 196, 195, 121, 196,
- 461, 195, 197, 196, 122, 0, 197, 197, 300, 301,
- 197, 255, 461, 256, 197, 183, 184, 183, 184, 300,
- 301, 502, 0, 0, 0, 305, 306, 0, 0, 0,
- 0, 0, 0, 502, 307, 302, 303, 308, 0, 309,
- 305, 306, 185, 186, 185, 186, 302, 303, 0, 307,
- 0, 17, 308, 0, 309, 305, 306, 0, 0, 0,
- 0, 0, 0, 17, 307, 0, 195, 308, 196, 309,
- 0, 0, 188, 189, 0, 16, 0, 0, 0, 197,
- 190, 191, 188, 189, 192, 0, 193, 16, 13, 0,
- 190, 191, 188, 189, 192, 14, 193, 0, 13, 0,
- 190, 191, 188, 189, 192, 14, 193, 0, 13, 0,
- 190, 191, 188, 189, 192, 14, 193, 0, 0, 0,
- 190, 191, 0, 0, 192, 17, 193, 13, 0, 0,
- 305, 306, 0, 0, 14, 17, 0, 0, 18, 307,
- 0, 480, 308, 0, 309, 17, 0, 12, 18, 16,
- 0, 15, 0, 0, 0, 0, 0, 12, 18, 16,
- 482, 15, 0, 0, 17, 0, 0, 12, 0, 16,
- 0, 15, 0, 0, 0, 0, 0, 18, 0, 0,
- 0, 0, 0, 0, 0, 0, 12, 0, 16, 0,
- 15, 0, 0, 0, 74, 75, 233, 0, 0, 0,
- 0, 0, 0, 0, 115, 0, 234, 0, 0, 0,
- 235, 116, 0, 0, 0, 117, 83, 0, 84, 236,
- 0, 237, 0, 0, 0, 87, 0, 0, 0, 90,
- 0, 0, 238, 0, 239, 118, 0, 0, 0, 0,
- 0, 0, 240, 0, 0, 241, 119, 95, 0, 97,
- 0, 242, 0, 0, 0, 0, 0, 243, 0, 0,
- 89, 100, 77, 0, 0, 0, 0, 0, 0, 0,
- 244, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 74, 75, 233, 0, 0, 0, 0, 0, 0, 0,
- 115, 0, 234, 0, 0, 0, 235, 116, 0, 0,
- 0, 117, 83, 0, 84, 236, 0, 237, 0, 0,
- 0, 87, 0, 0, 0, 90, 0, 0, 238, 0,
- 239, 118, 0, 0, 0, 0, 0, 0, 240, 0,
- 0, 241, 119, 95, 0, 97, 0, 242, 0, 0,
- 0, 0, 0, 243, 0, 0, 89, 100, 77, 0,
- 0, 0, 0, 0, 0, 0, 244, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 233, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 234, 0,
- 0, 0, 235, 0, 0, 0, 0, 0, 0, 0,
- 0, 236, 0, 237, 0, 0, 334, 0, 0, 0,
- 0, 0, 0, 0, 238, 0, 239, 118, 0, 0,
- 0, 0, 0, 0, 240, 0, 0, 241, 119, 0,
- 0, 0, 0, 242, 0, 0, 0, 0, 0, 243,
+ 277, 473, -81, -89, -67, -94, -71, 368, 460, -97,
+ -70, -92, 193, 409, -100, 338, 355, 345, 332, 292,
+ 312, 164, 326, 411, 324, 423, 477, 351, 353, 421,
+ 360, 187, 365, 372, 363, 164, 362, 510, 509, 122,
+ 32, 33, 94, 512, 551, 502, 360, 7, 2, 545,
+ 170, 124, 172, 502, 27, 436, 484, 314, 440, 419,
+ 464, 484, 451, 187, 460, 490, 164, 316, 460, 466,
+ 122, 124, 206, 473, 477, 368, 460, 429, 450, 434,
+ 366, 428, 436, 256, 468, 277, 332, 321, 292, 213,
+ 272, 94, 0, 210, 164, 312, 164, 164, 463, 164,
+ 0, 164, 164, 0, 81, 81, 164, 447, 454, 164,
+ 444, 202, 464, 189, 485, 82, 82, 190, 164, 366,
+ 212, 164, 527, 314, 527, 0, 271, 276, 275, 262,
+ 261, 530, 267, 266, 513, 433, 432, 269, 268, 514,
+ 164, 366, 514, 87, 81, 502, 475, 0, 274, 357,
+ 2, 438, 448, 479, 370, 82, 538, 537, 330, 28,
+ 85, 0, 486, 269, 268, 81, 200, 502, 60, 165,
+ 536, 86, 528, 60, 164, 0, 82, 548, 9, 8,
+ 60, 0, 195, 60, 108, 60, 109, 28, 88, 108,
+ 0, 109, 494, 0, 89, 0, 334, 110, 0, 0,
+ 335, 196, 110, 426, 30, 72, 73, 60, 0, 60,
+ 72, 73, 108, 60, 109, 29, 164, 72, 73, 126,
+ 72, 73, 72, 73, 60, 110, 60, 255, 254, 87,
+ 549, 547, 30, 87, 60, 195, 0, 347, 127, 108,
+ 128, 109, 0, 29, 72, 73, 72, 73, 60, 0,
+ 72, 73, 110, 108, 196, 109, 197, 0, 0, 0,
+ 60, 72, 73, 72, 73, 0, 110, 294, 295, 458,
+ 457, 72, 73, 60, 88, 294, 295, 0, 88, 0,
+ 89, 96, 97, 0, 89, 72, 73, 96, 97, 60,
+ 348, 0, 260, 259, 296, 297, -311, 72, 73, 522,
+ 0, 0, 296, 297, 0, 265, 264, 60, 98, 99,
+ 72, 73, 0, 0, 98, 99, 299, 300, 0, 60,
+ 108, 0, 109, 0, 0, 301, 72, 73, 302, 19,
+ 303, 0, 0, 110, 101, 102, 72, 73, 0, 265,
+ 264, 0, 103, 104, 72, 73, 105, 0, 106, 0,
+ 484, 260, 259, 101, 102, 18, 72, 73, 0, 0,
+ 484, 103, 104, 0, 0, 105, 14, 106, 101, 102,
+ 0, 522, 14, 0, 0, 0, 103, 104, 15, 0,
+ 105, 522, 106, 0, 15, 16, 299, 300, 0, 0,
+ 0, 16, 0, 0, 0, 301, 0, 0, 302, 0,
+ 303, 19, 0, 0, 0, 0, 0, 0, 72, 73,
+ 0, 19, 0, 0, 0, 19, 0, 0, 72, 73,
+ 0, 19, 17, 20, 0, 0, 0, 18, 17, 20,
+ 21, 14, 0, 0, 14, 0, 21, 18, 0, 13,
+ 0, 18, 0, 15, 0, 13, 15, 18, 0, 0,
+ 16, 0, 0, 16, 101, 102, 0, 0, 0, 0,
+ 0, 0, 103, 104, 0, 0, 105, 0, 106, 0,
+ 0, 0, 0, 0, 0, 0, 506, 0, 0, 504,
+ 19, 0, 0, 19, 0, 0, 0, 17, 20, 174,
+ 17, 20, 0, 0, 0, 21, 0, 0, 21, 175,
+ 0, 0, 0, 176, 13, 0, 18, 13, 0, 18,
+ 0, 0, 177, 0, 178, 0, 0, 328, 0, 0,
+ 0, 0, 174, 0, 0, 179, 0, 180, 85, 0,
+ 0, 0, 175, 0, 0, 181, 176, 0, 182, 86,
+ 0, 0, 0, 0, 183, 177, 0, 178, 0, 0,
+ 184, 0, 0, 0, 0, 0, 0, 0, 179, 0,
+ 180, 85, 0, 0, 0, 185, 0, 0, 181, 0,
+ 0, 182, 86, 0, 0, 0, 0, 183, 0, 0,
+ 0, 0, 0, 184, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 185, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 244, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 73, 74, 75, 0, 0, 0,
- 0, 0, 0, 0, 0, 115, 0, 0, 0, 0,
- 0, 0, 116, 0, 0, 0, 117, 83, 0, 84,
- 0, 0, 0, 85, 0, 86, 87, 88, 0, 0,
- 90, 0, 0, 0, 91, 0, 92, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 95, 0,
- 97, 0, 99, 0, 102, 0, 103, 0, 0, 0,
- 0, 89, 100, 77, 0, 0, 0, 0, 0, 0,
- 0, 0, 73, 74, 75, 0, 0, 0, 0, 0,
- 0, 0, 0, 115, 0, 0, 0, 0, 0, 0,
- 116, 0, 0, 0, 117, 83, 0, 84, 0, 0,
- 0, 85, 0, 86, 87, 88, 0, 0, 90, 0,
- 0, 0, 91, 0, 92, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 95, 0, 97, 0,
- 99, 0, 102, 297, 103, 0, 0, 0, 0, 89,
- 100, 77, 0, 0, 0, 0, 0, 0, 0, 0,
- -81, 0, 0, 0, 73, 74, 75, 0, 0, 0,
- 0, 0, 0, 0, 0, 115, 0, 0, 0, 0,
- 0, 0, 116, 0, 0, 0, 117, 83, 0, 84,
- 0, 0, 0, 85, 0, 86, 87, 88, 0, 0,
- 90, 0, 0, 0, 91, 0, 92, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 95, 0,
- 97, 0, 99, 0, 102, 0, 103, 0, 0, 0,
- 0, 89, 100, 77, 0, 0, 0, 0, 0, 0,
- 0, 0, 73, 74, 75, 0, 0, 0, 0, 0,
- 0, 0, 0, 115, 0, 0, 0, 0, 0, 0,
- 116, 0, 0, 0, 117, 83, 0, 84, 0, 0,
- 0, 85, 0, 86, 87, 88, 0, 0, 90, 0,
- 0, 0, 91, 0, 92, 0, 0, 466, 0, 0,
- 0, 0, 0, 0, 0, 0, 95, 0, 97, 0,
- 99, 0, 102, 0, 103, 0, 0, 0, 0, 89,
- 100, 77, 0, 0, 0, 0, 0, 0, 0, 0,
- 73, 74, 75, 0, 0, 0, 0, 0, 0, 0,
- 0, 115, 0, 0, 0, 0, 0, 0, 116, 0,
- 0, 0, 117, 83, 0, 84, 0, 0, 0, 85,
- 0, 86, 87, 88, 0, 0, 90, 0, 0, 0,
- 91, 0, 92, 0, 0, 469, 0, 0, 0, 0,
- 0, 0, 0, 0, 95, 0, 97, 0, 99, 0,
- 102, 0, 103, 0, 0, 0, 0, 89, 100, 77,
- 0, 0, 0, 0, 0, 0, 0, 0, 138, 139,
- 140, 0, 0, 142, 144, 145, 0, 0, 146, 0,
- 147, 0, 0, 0, 149, 150, 151, 0, 0, 0,
- 0, 0, 0, 218, 153, 154, 155, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 156, 0, 0,
+ 56, 57, 0, 0, 0, 0, 0, 0, 0, 0,
+ 59, 0, 0, 0, 0, 0, 0, 60, 0, 0,
+ 0, 61, 62, 0, 63, 0, 0, 0, 0, 0,
+ 0, 66, 0, 0, 0, 69, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 160, 0, 0, 0, 0, 0, 0,
- 162, 163, 164, 0, 166, 167, 168, 169, 170, 171,
- 0, 0, 157, 165, 148, 141, 143, 159, 0, 0,
- 0, 0, 0, 138, 139, 140, 0, 0, 142, 144,
- 145, 0, 0, 146, 0, 147, 0, 0, 0, 149,
- 150, 151, 0, 0, 0, 0, 0, 0, 152, 153,
- 154, 155, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 156, 0, 0, 0, 158, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 160, 0,
- 0, 0, 0, 0, 161, 162, 163, 164, 0, 166,
- 167, 168, 169, 170, 171, 0, 0, 157, 165, 148,
- 141, 143, 159, 0, 0, 0, 0, 0, 138, 139,
- 140, 0, 0, 142, 144, 145, 0, 0, 146, 0,
- 147, 0, 0, 0, 149, 150, 151, 0, 0, 0,
- 0, 0, 0, 152, 153, 154, 155, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 156, 0, 0,
- 0, 158, 0, 0, 0, 0, 0, 0, 0, 176,
- 0, 0, 0, 160, 0, 0, 0, 0, 0, 161,
- 162, 163, 164, 0, 166, 167, 168, 169, 170, 171,
- 0, 0, 157, 165, 148, 141, 143, 159, 0, 0,
- 0, 0, 0, 70, 0, 0, 0, 0, 71, 0,
- 73, 74, 75, 76, 0, 0, 0, 0, 0, 0,
- 78, 115, 0, 0, 0, 0, 0, 0, 512, 81,
- 0, 0, 82, 513, 0, 84, 0, 0, 0, 85,
- 0, 86, 87, 88, 0, 0, 90, 0, 0, 0,
- 91, 0, 92, 0, 0, 0, 0, 0, 93, 0,
- 94, 0, 0, 0, 95, 96, 97, 98, 99, 101,
- 102, 18, 103, 104, 105, 0, 0, 89, 100, 77,
- 12, 72, 0, 0, 0, 0, 0, 0, 70, 0,
- 0, 0, 0, 71, 0, 73, 74, 75, 76, 0,
- 0, 0, 0, 0, 0, 78, 115, 0, 0, 0,
- 0, 0, 0, 80, 81, 0, 0, 82, 83, 0,
- 84, 0, 0, 0, 85, 0, 86, 87, 88, 0,
- 0, 90, 0, 0, 0, 91, 0, 92, 0, 0,
- 0, 0, 0, 93, 0, 94, 0, 0, 0, 95,
- 96, 97, 98, 99, 101, 102, 18, 103, 104, 105,
- 0, 0, 89, 100, 77, 12, 72, 0, 0, 0,
- 0, 0, 0, 70, 0, 0, 0, 0, 71, 0,
- 73, 74, 75, 76, 0, 0, 0, 0, 0, 0,
- 78, 79, 0, 0, 0, 0, 0, 0, 80, 81,
- 0, 0, 82, 83, 0, 84, 0, 0, 0, 85,
- 0, 86, 87, 88, 0, 0, 90, 0, 0, 0,
- 91, 0, 92, 0, 0, 0, 0, 0, 93, 0,
- 94, 0, 0, 0, 95, 96, 97, 98, 99, 101,
- 102, 18, 103, 104, 105, 0, 0, 89, 100, 77,
- 12, 72, 0, 0, 0, 0, 0, 0, 70, 0,
- 0, 0, 0, 71, 0, 73, 74, 75, 76, 0,
- 0, 0, 0, 0, 0, 78, 115, 0, 0, 0,
- 0, 0, 0, 496, 81, 0, 0, 82, 497, 0,
- 84, 0, 0, 0, 85, 0, 86, 87, 88, 0,
- 0, 90, 0, 0, 0, 91, 0, 92, 0, 0,
- 0, 0, 0, 93, 0, 94, 0, 0, 0, 95,
- 96, 97, 98, 99, 101, 102, 18, 103, 104, 105,
- 0, 0, 89, 100, 77, 12, 72, 0, 498, 0,
- 0, 0, 0, 377, 139, 140, 0, 0, 379, 144,
- 381, 74, 75, 382, 0, 147, 0, 0, 0, 149,
- 384, 385, 0, 0, 0, 0, 0, 0, 386, 387,
- 154, 155, 82, 83, 0, 84, 0, 0, 0, 85,
- 0, 86, 388, 88, 0, 0, 390, 0, 0, 0,
- 91, 0, 92, 0, -227, 0, 0, 0, 391, 0,
- 94, 0, 0, 0, 392, 393, 394, 395, 99, 397,
- 398, 399, 400, 401, 402, 0, 0, 389, 396, 383,
- 378, 380, 159, 0, 0, 0, 0, 0,
+ 0, 0, 0, 74, 72, 73, 0, 75, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 68, 77,
+ 58, 0, 0, 0, 0, 0, 0, 0, 0, 55,
+ 56, 57, 0, 0, 0, 0, 0, 0, 0, 0,
+ 59, 0, 0, 0, 0, 0, 0, 60, 0, 0,
+ 0, 61, 62, 0, 63, 0, 0, 0, 64, 0,
+ 65, 66, 67, 0, 0, 69, 0, 0, 0, 70,
+ 0, 71, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 74, 72, 73, 0, 75, 0, 76,
+ 0, 78, 0, 79, 0, 0, 0, 0, 68, 77,
+ 58, 0, 0, 0, 0, 0, 0, 0, 0, -90,
+ 0, 0, 0, 55, 56, 57, 0, 0, 0, 0,
+ 0, 0, 0, 0, 59, 0, 0, 0, 0, 0,
+ 0, 60, 0, 0, 0, 61, 62, 0, 63, 0,
+ 0, 0, 64, 0, 65, 66, 67, 0, 0, 69,
+ 0, 0, 0, 70, 0, 71, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 74, 72, 73,
+ 0, 75, 0, 76, 0, 78, 0, 79, 0, 0,
+ 0, 0, 68, 77, 58, 0, 0, 0, 0, 0,
+ 0, 0, 0, 55, 56, 57, 0, 0, 0, 0,
+ 0, 0, 0, 0, 59, 0, 0, 0, 0, 0,
+ 0, 60, 0, 0, 0, 61, 62, 0, 63, 0,
+ 0, 0, 64, 0, 65, 66, 67, 0, 0, 69,
+ 0, 0, 0, 70, 0, 71, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 74, 72, 73,
+ 0, 75, 0, 76, 0, 78, 291, 79, 0, 0,
+ 0, 0, 68, 77, 58, 0, 0, 0, 0, 0,
+ 0, 0, 0, 55, 56, 57, 0, 0, 0, 0,
+ 0, 0, 0, 0, 59, 0, 0, 0, 0, 0,
+ 0, 60, 0, 0, 0, 61, 62, 0, 63, 0,
+ 0, 0, 64, 0, 65, 66, 67, 0, 0, 69,
+ 0, 0, 0, 70, 0, 71, 0, 0, 492, 0,
+ 0, 0, 0, 0, 0, 0, 0, 74, 72, 73,
+ 0, 75, 0, 76, 0, 78, 0, 79, 0, 0,
+ 0, 0, 68, 77, 58, 0, 0, 0, 0, 0,
+ 0, 0, 0, 55, 56, 57, 0, 0, 0, 0,
+ 0, 0, 0, 0, 59, 0, 0, 0, 0, 0,
+ 0, 60, 0, 0, 0, 61, 62, 0, 63, 0,
+ 0, 0, 64, 0, 65, 66, 67, 0, 0, 69,
+ 0, 0, 0, 70, 0, 71, 0, 0, 489, 0,
+ 0, 0, 0, 0, 0, 0, 0, 74, 72, 73,
+ 0, 75, 0, 76, 0, 78, 0, 79, 0, 0,
+ 0, 0, 68, 77, 58, 0, 0, 0, 0, 0,
+ 0, 0, 0, 132, 133, 134, 0, 0, 136, 138,
+ 139, 0, 0, 140, 0, 141, 0, 0, 0, 143,
+ 144, 145, 0, 0, 0, 0, 0, 0, 60, 146,
+ 147, 148, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 149, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 152, 0,
+ 0, 0, 0, 0, 0, 72, 73, 153, 154, 155,
+ 0, 157, 158, 159, 160, 161, 162, 0, 0, 150,
+ 156, 142, 135, 137, 151, 0, 0, 0, 0, 0,
+ 132, 133, 134, 0, 0, 136, 138, 139, 0, 0,
+ 140, 0, 141, 0, 0, 0, 143, 144, 145, 0,
+ 0, 0, 0, 0, 0, 413, 146, 147, 148, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 149,
+ 0, 0, 0, 414, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 152, 0, 0, 0, 0,
+ 0, 418, 415, 417, 153, 154, 155, 0, 157, 158,
+ 159, 160, 161, 162, 0, 0, 150, 156, 142, 135,
+ 137, 151, 0, 0, 0, 0, 0, 132, 133, 134,
+ 0, 0, 136, 138, 139, 0, 0, 140, 0, 141,
+ 0, 0, 0, 143, 144, 145, 0, 0, 0, 0,
+ 0, 0, 413, 146, 147, 148, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 149, 0, 0, 0,
+ 414, 0, 0, 0, 0, 0, 0, 0, 416, 0,
+ 0, 0, 152, 0, 0, 0, 0, 0, 418, 415,
+ 417, 153, 154, 155, 0, 157, 158, 159, 160, 161,
+ 162, 0, 0, 150, 156, 142, 135, 137, 151, 0,
+ 0, 0, 0, 0, 232, 0, 0, 0, 0, 233,
+ 0, 55, 56, 57, 235, 0, 0, 0, 0, 0,
+ 0, 236, 59, 0, 0, 0, 0, 0, 0, 238,
+ 239, 0, 0, 240, 62, 0, 63, 0, 0, 0,
+ 64, 0, 65, 66, 67, 0, 0, 69, 0, 0,
+ 0, 70, 0, 71, 0, 0, 0, 0, 0, 242,
+ 0, 243, 0, 0, 0, 74, 241, 244, 245, 75,
+ 246, 76, 247, 78, 21, 79, 248, 249, 0, 0,
+ 68, 77, 58, 13, 234, 0, 0, 0, 0, 0,
+ 0, 232, 0, 0, 0, 0, 233, 0, 55, 56,
+ 57, 235, 0, 0, 0, 0, 0, 0, 236, 237,
+ 0, 0, 0, 0, 0, 0, 238, 239, 0, 0,
+ 240, 62, 0, 63, 0, 0, 0, 64, 0, 65,
+ 66, 67, 0, 0, 69, 0, 0, 0, 70, 0,
+ 71, 0, 0, 0, 0, 0, 242, 0, 243, 0,
+ 0, 0, 74, 241, 244, 245, 75, 246, 76, 247,
+ 78, 21, 79, 248, 249, 0, 0, 68, 77, 58,
+ 13, 234, 0, 0, 0, 0, 0, 0, 232, 0,
+ 0, 0, 0, 233, 0, 55, 56, 57, 235, 0,
+ 0, 0, 0, 0, 0, 236, 59, 0, 0, 0,
+ 0, 0, 0, 532, 239, 0, 0, 240, 533, 0,
+ 63, 0, 0, 0, 64, 0, 65, 66, 67, 0,
+ 0, 69, 0, 0, 0, 70, 0, 71, 0, 0,
+ 0, 0, 0, 242, 0, 243, 0, 0, 0, 74,
+ 241, 244, 245, 75, 246, 76, 247, 78, 21, 79,
+ 248, 249, 0, 0, 68, 77, 58, 13, 234, 0,
+ 0, 0, 0, 0, 0, 232, 0, 0, 0, 0,
+ 233, 0, 55, 56, 57, 235, 0, 0, 0, 0,
+ 0, 0, 236, 59, 0, 0, 0, 0, 0, 0,
+ 516, 239, 0, 0, 240, 517, 0, 63, 0, 0,
+ 0, 64, 0, 65, 66, 67, 0, 0, 69, 0,
+ 0, 0, 70, 0, 71, 0, 0, 0, 0, 0,
+ 242, 0, 243, 0, 0, 0, 74, 241, 244, 245,
+ 75, 246, 76, 247, 78, 21, 79, 248, 249, 0,
+ 0, 68, 77, 58, 13, 234, 0, 518, 0, 0,
+ 0, 0, 381, 133, 134, 0, 0, 383, 138, 385,
+ 56, 57, 386, 0, 141, 0, 0, 0, 143, 388,
+ 389, 0, 0, 0, 0, 0, 0, 390, 391, 147,
+ 148, 240, 62, 0, 63, 0, 0, 0, 64, 0,
+ 65, 392, 67, 0, 0, 394, 0, 0, 0, 70,
+ 0, 71, 0, -236, 0, 0, 0, 396, 0, 243,
+ 0, 0, 0, 398, 395, 397, 399, 400, 401, 76,
+ 403, 404, 405, 406, 407, 408, 0, 0, 393, 402,
+ 387, 382, 384, 151, 0, 0, 0, 0, 0,
- 465, 464, 232, 468, 455, 457, 175, 446, 364, 173,
- 362, 360, 355, 451, 453, 178, 279, 10, 530, 251,
- 23, 219, 253, 335, 447, 225, 514, 245, 222, 492,
- 526, 129, 227, 489, 495, 333, 217, 501, 511, 505,
- 506, 429, 426, 276, 436, 436, 430, 373, 371, 422,
- 433, 414, 328, 470, 433, 403, 442, 369, 337, 367,
- 276, 0, 432, 328, 328, 483, 113, 328, 509, 515,
- 505, 310, 505, 0, 113, 23, 0, 113, 258, 0,
- 114, 113, 0, 474, 113, 113, 475, 476, 247, 113,
- 113, 113, 405, 180, 113, 406, 448, 405, 0, 113,
- 406, 449, 0, 210, 113, 250, 113, 329, 113, 313,
- 331, 311, 113, 314, 449, 113, 113, 113, 477, 113,
- 312, 448, 113, 113, 473, 113, 0, 212, 113, 207,
- 68, 208, 50, 204, 113, 113, 113, 113, 328, 202,
- 203, 201, 113, 206, 124, 113, 113, 123, 292, 113,
- 328, 275, 187, 296, 113, 113, 113, 275, 0, 113,
- 225, 194, 182, 200, 225, 113, 113, 260, 125, 199,
- 113, 408, 217, 257, 113, 205, 472, 481, 113, 113,
- 0, 358, 198, 324, 296, 0, 0, 113, 296, 0,
- 321, 23, 296, 356, 304, 324, 324, 68, 113, 50,
- 296, 296, 324, 296, 113, 323, 68, 296, 50, 296,
- 324, 319, 0, 0, 0, 296, 113, 352, 345, 339,
- 113, 296, 113, 316, 343, 296, 0, 296, 113, 299,
- 0, 113, 326, 296, 0, 315, 296, 0, 317, 342,
- 0, 0, 483, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 23, 0, 0, 0, 0, 0, 0, 0,
+ 455, 534, 521, 452, 493, 199, 465, 173, 488, 539,
+ 42, 445, 359, 322, 211, 209, 449, 470, 31, 480,
+ 273, 531, 487, 192, 491, 194, 511, 540, 476, 515,
+ 467, 469, 456, 526, 459, 474, 205, 420, 435, 10,
+ 412, 163, 373, 169, 371, 546, 410, 369, 205, 270,
+ 322, 166, 171, 422, 456, 258, 263, 367, 430, 270,
+ 331, 340, 327, 329, 358, 459, 186, 437, 263, 453,
+ 354, 501, 0, 356, 258, 0, 83, 340, 540, 169,
+ 26, 12, 209, 322, 525, 322, 201, 322, 123, 0,
+ 322, 424, 12, 0, 425, 129, 83, 0, 203, 230,
+ 83, 83, 223, 0, 131, 113, 83, 0, 83, 0,
+ 125, 84, 121, 478, 83, 83, 497, 498, 83, 424,
+ 83, 0, 425, 83, 100, 496, 119, 323, 83, 325,
+ 83, 350, 495, 308, 352, 83, 83, 499, 471, 0,
+ 550, 349, 83, 83, 472, 90, 83, 169, 91, 83,
+ 83, 500, 92, 83, 427, 83, 0, 83, 361, 120,
+ 107, 111, 83, 83, 83, 471, 83, 304, 112, 93,
+ 83, 83, 83, 83, 83, 307, 305, 306, 83, 83,
+ 83, 286, 83, 116, 114, 115, 290, 117, 188, 191,
+ 83, 83, 472, 203, 83, 535, 83, 0, 525, 118,
+ 83, 290, 529, 0, 525, 318, 12, 0, 95, 83,
+ 290, 0, 12, 336, 290, 83, 230, 0, 318, 223,
+ 290, 0, 313, 290, 318, 318, 315, 317, 83, 290,
+ 290, 83, 83, 290, 505, 0, 290, 290, 311, 310,
+ 320, 507, 0, 333, 507, 0, 339, 346, 129, 26,
+ 12, 0, 26, 12, 318, 26, 12, 131, 198, 290,
+ 83, 83, 0, 0, 0, 290, 290, 230, 309, 293,
+ 223, 0, 83, 0, 0, 0, 337, 290, 0, 298,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 364, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 262, 0, 0, 0, 132, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0};
+ 0, 0, 0, 0, 257, 0};
const int JavaScriptGrammar::action_check [] = {
- 60, 29, 20, 76, 55, 55, 7, 36, 60, 76,
- 48, 36, 1, 36, 48, 8, 29, 5, 8, 29,
- 61, 8, 2, 60, 33, 33, 7, 29, 7, 33,
- 61, 7, 7, 36, 29, 7, 7, 36, 16, 36,
- 36, 7, 7, 2, 60, 29, 61, 33, 5, 5,
- 8, 36, 29, 60, 48, 17, 2, 31, 7, 76,
- 29, 29, 60, 36, 7, 29, 33, 17, 29, 1,
- 33, 7, 55, 33, 29, 29, 2, 8, 60, 8,
- 8, 29, 7, 36, 7, 1, 8, 29, 8, 36,
- 7, 36, 33, 8, 29, 65, 48, 36, 36, 29,
- 10, 7, -1, 8, 55, 8, 8, 8, 7, 36,
- 29, 8, 8, 7, 6, 55, 15, 36, 42, 29,
- 8, 15, 7, 8, 8, -1, 60, 33, 20, 53,
- 74, 40, 8, 8, 8, -1, 40, 10, 7, 76,
- 61, 62, 51, 61, 62, 8, 8, 51, 61, 62,
- 40, 40, 8, 86, 56, -1, 61, 60, 8, 60,
- 56, 51, 51, 60, 33, 8, -1, 50, 56, 29,
- 12, 54, 56, 0, 61, 62, 29, 29, 15, 61,
- 62, -1, 55, 8, 60, 60, 60, -1, -1, 61,
- 62, 61, 62, 56, 61, 62, 50, 34, 60, 36,
- 54, 61, 62, 15, 60, 12, -1, 59, 61, 62,
- -1, 61, 62, -1, 25, 57, 27, -1, 61, 62,
- 29, 63, 34, 12, 36, 29, 25, 38, 27, -1,
- 25, 83, 27, 25, -1, 27, 61, 62, 25, 38,
- 27, -1, 25, 38, 27, -1, 38, 25, -1, 27,
- 57, 38, 61, 62, -1, 38, 63, 61, 62, 25,
- 38, 27, 15, 25, 25, 27, 27, 25, 57, 27,
- 8, 25, 38, 27, 63, -1, 38, 38, 18, 19,
- 38, 34, 8, 36, 38, 18, 19, 18, 19, 18,
- 19, 29, -1, -1, -1, 23, 24, -1, -1, -1,
- -1, -1, -1, 29, 32, 45, 46, 35, -1, 37,
- 23, 24, 45, 46, 45, 46, 45, 46, -1, 32,
- -1, 59, 35, -1, 37, 23, 24, -1, -1, -1,
- -1, -1, -1, 59, 32, -1, 25, 35, 27, 37,
- -1, -1, 23, 24, -1, 83, -1, -1, -1, 38,
- 31, 32, 23, 24, 35, -1, 37, 83, 22, -1,
- 31, 32, 23, 24, 35, 29, 37, -1, 22, -1,
- 31, 32, 23, 24, 35, 29, 37, -1, 22, -1,
- 31, 32, 23, 24, 35, 29, 37, -1, -1, -1,
- 31, 32, -1, -1, 35, 59, 37, 22, -1, -1,
- 23, 24, -1, -1, 29, 59, -1, -1, 72, 32,
- -1, 55, 35, -1, 37, 59, -1, 81, 72, 83,
- -1, 85, -1, -1, -1, -1, -1, 81, 72, 83,
- 55, 85, -1, -1, 59, -1, -1, 81, -1, 83,
- -1, 85, -1, -1, -1, -1, -1, 72, -1, -1,
- -1, -1, -1, -1, -1, -1, 81, -1, 83, -1,
- 85, -1, -1, -1, 12, 13, 3, -1, -1, -1,
- -1, -1, -1, -1, 22, -1, 13, -1, -1, -1,
- 17, 29, -1, -1, -1, 33, 34, -1, 36, 26,
- -1, 28, -1, -1, -1, 43, -1, -1, -1, 47,
- -1, -1, 39, -1, 41, 42, -1, -1, -1, -1,
- -1, -1, 49, -1, -1, 52, 53, 65, -1, 67,
- -1, 58, -1, -1, -1, -1, -1, 64, -1, -1,
- 78, 79, 80, -1, -1, -1, -1, -1, -1, -1,
- 77, -1, -1, -1, -1, -1, -1, -1, -1, -1,
- 12, 13, 3, -1, -1, -1, -1, -1, -1, -1,
- 22, -1, 13, -1, -1, -1, 17, 29, -1, -1,
- -1, 33, 34, -1, 36, 26, -1, 28, -1, -1,
- -1, 43, -1, -1, -1, 47, -1, -1, 39, -1,
- 41, 42, -1, -1, -1, -1, -1, -1, 49, -1,
- -1, 52, 53, 65, -1, 67, -1, 58, -1, -1,
- -1, -1, -1, 64, -1, -1, 78, 79, 80, -1,
- -1, -1, -1, -1, -1, -1, 77, -1, -1, -1,
- -1, -1, -1, -1, -1, -1, -1, -1, 3, -1,
- -1, -1, -1, -1, -1, -1, -1, -1, 13, -1,
- -1, -1, 17, -1, -1, -1, -1, -1, -1, -1,
- -1, 26, -1, 28, -1, -1, 31, -1, -1, -1,
- -1, -1, -1, -1, 39, -1, 41, 42, -1, -1,
- -1, -1, -1, -1, 49, -1, -1, 52, 53, -1,
- -1, -1, -1, 58, -1, -1, -1, -1, -1, 64,
+ 36, 36, 7, 7, 7, 7, 7, 36, 33, 7,
+ 7, 7, 7, 7, 7, 7, 31, 17, 2, 1,
+ 48, 8, 60, 8, 61, 55, 36, 61, 60, 55,
+ 36, 2, 55, 16, 33, 8, 60, 7, 29, 48,
+ 29, 7, 1, 29, 0, 33, 36, 65, 88, 17,
+ 8, 78, 60, 33, 66, 36, 8, 78, 33, 7,
+ 20, 8, 7, 2, 33, 8, 8, 8, 33, 36,
+ 48, 78, 36, 36, 36, 36, 33, 7, 55, 7,
+ 7, 60, 36, 55, 60, 36, 2, 61, 1, 33,
+ 36, 1, -1, 8, 8, 48, 8, 8, 6, 8,
+ -1, 8, 8, -1, 40, 40, 8, 10, 7, 8,
+ 5, 60, 20, 50, 8, 51, 51, 54, 8, 7,
+ 60, 8, 8, 78, 8, -1, 76, 61, 62, 61,
+ 62, 7, 61, 62, 7, 61, 62, 61, 62, 15,
+ 8, 7, 15, 12, 40, 33, 60, -1, 60, 60,
+ 88, 60, 55, 60, 60, 51, 61, 62, 60, 29,
+ 42, -1, 56, 61, 62, 40, 56, 33, 29, 56,
+ 56, 53, 56, 29, 8, -1, 51, 8, 61, 62,
+ 29, -1, 15, 29, 25, 29, 27, 29, 57, 25,
+ -1, 27, 60, -1, 63, -1, 50, 38, -1, -1,
+ 54, 34, 38, 36, 74, 66, 67, 29, -1, 29,
+ 66, 67, 25, 29, 27, 85, 8, 66, 67, 15,
+ 66, 67, 66, 67, 29, 38, 29, 61, 62, 12,
+ 61, 62, 74, 12, 29, 15, -1, 8, 34, 25,
+ 36, 27, -1, 85, 66, 67, 66, 67, 29, -1,
+ 66, 67, 38, 25, 34, 27, 36, -1, -1, -1,
+ 29, 66, 67, 66, 67, -1, 38, 18, 19, 61,
+ 62, 66, 67, 29, 57, 18, 19, -1, 57, -1,
+ 63, 18, 19, -1, 63, 66, 67, 18, 19, 29,
+ 61, -1, 61, 62, 45, 46, 36, 66, 67, 29,
+ -1, -1, 45, 46, -1, 61, 62, 29, 45, 46,
+ 66, 67, -1, -1, 45, 46, 23, 24, -1, 29,
+ 25, -1, 27, -1, -1, 32, 66, 67, 35, 59,
+ 37, -1, -1, 38, 23, 24, 66, 67, -1, 61,
+ 62, -1, 31, 32, 66, 67, 35, -1, 37, -1,
+ 8, 61, 62, 23, 24, 85, 66, 67, -1, -1,
+ 8, 31, 32, -1, -1, 35, 10, 37, 23, 24,
+ -1, 29, 10, -1, -1, -1, 31, 32, 22, -1,
+ 35, 29, 37, -1, 22, 29, 23, 24, -1, -1,
+ -1, 29, -1, -1, -1, 32, -1, -1, 35, -1,
+ 37, 59, -1, -1, -1, -1, -1, -1, 66, 67,
+ -1, 59, -1, -1, -1, 59, -1, -1, 66, 67,
+ -1, 59, 66, 67, -1, -1, -1, 85, 66, 67,
+ 74, 10, -1, -1, 10, -1, 74, 85, -1, 83,
+ -1, 85, -1, 22, -1, 83, 22, 85, -1, -1,
+ 29, -1, -1, 29, 23, 24, -1, -1, -1, -1,
+ -1, -1, 31, 32, -1, -1, 35, -1, 37, -1,
+ -1, -1, -1, -1, -1, -1, 55, -1, -1, 55,
+ 59, -1, -1, 59, -1, -1, -1, 66, 67, 3,
+ 66, 67, -1, -1, -1, 74, -1, -1, 74, 13,
+ -1, -1, -1, 17, 83, -1, 85, 83, -1, 85,
+ -1, -1, 26, -1, 28, -1, -1, 31, -1, -1,
+ -1, -1, 3, -1, -1, 39, -1, 41, 42, -1,
+ -1, -1, 13, -1, -1, 49, 17, -1, 52, 53,
+ -1, -1, -1, -1, 58, 26, -1, 28, -1, -1,
+ 64, -1, -1, -1, -1, -1, -1, -1, 39, -1,
+ 41, 42, -1, -1, -1, 79, -1, -1, 49, -1,
+ -1, 52, 53, -1, -1, -1, -1, 58, -1, -1,
+ -1, -1, -1, 64, -1, -1, -1, -1, -1, -1,
+ -1, -1, -1, -1, -1, -1, -1, -1, 79, -1,
-1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
- -1, -1, 77, -1, -1, -1, -1, -1, -1, -1,
- -1, -1, -1, -1, 11, 12, 13, -1, -1, -1,
- -1, -1, -1, -1, -1, 22, -1, -1, -1, -1,
- -1, -1, 29, -1, -1, -1, 33, 34, -1, 36,
- -1, -1, -1, 40, -1, 42, 43, 44, -1, -1,
- 47, -1, -1, -1, 51, -1, 53, -1, -1, -1,
- -1, -1, -1, -1, -1, -1, -1, -1, 65, -1,
- 67, -1, 69, -1, 71, -1, 73, -1, -1, -1,
- -1, 78, 79, 80, -1, -1, -1, -1, -1, -1,
- -1, -1, 11, 12, 13, -1, -1, -1, -1, -1,
- -1, -1, -1, 22, -1, -1, -1, -1, -1, -1,
- 29, -1, -1, -1, 33, 34, -1, 36, -1, -1,
- -1, 40, -1, 42, 43, 44, -1, -1, 47, -1,
- -1, -1, 51, -1, 53, -1, -1, -1, -1, -1,
- -1, -1, -1, -1, -1, -1, 65, -1, 67, -1,
- 69, -1, 71, 72, 73, -1, -1, -1, -1, 78,
- 79, 80, -1, -1, -1, -1, -1, -1, -1, -1,
- 7, -1, -1, -1, 11, 12, 13, -1, -1, -1,
- -1, -1, -1, -1, -1, 22, -1, -1, -1, -1,
- -1, -1, 29, -1, -1, -1, 33, 34, -1, 36,
- -1, -1, -1, 40, -1, 42, 43, 44, -1, -1,
- 47, -1, -1, -1, 51, -1, 53, -1, -1, -1,
- -1, -1, -1, -1, -1, -1, -1, -1, 65, -1,
- 67, -1, 69, -1, 71, -1, 73, -1, -1, -1,
- -1, 78, 79, 80, -1, -1, -1, -1, -1, -1,
- -1, -1, 11, 12, 13, -1, -1, -1, -1, -1,
- -1, -1, -1, 22, -1, -1, -1, -1, -1, -1,
- 29, -1, -1, -1, 33, 34, -1, 36, -1, -1,
- -1, 40, -1, 42, 43, 44, -1, -1, 47, -1,
- -1, -1, 51, -1, 53, -1, -1, 56, -1, -1,
- -1, -1, -1, -1, -1, -1, 65, -1, 67, -1,
- 69, -1, 71, -1, 73, -1, -1, -1, -1, 78,
- 79, 80, -1, -1, -1, -1, -1, -1, -1, -1,
- 11, 12, 13, -1, -1, -1, -1, -1, -1, -1,
- -1, 22, -1, -1, -1, -1, -1, -1, 29, -1,
- -1, -1, 33, 34, -1, 36, -1, -1, -1, 40,
- -1, 42, 43, 44, -1, -1, 47, -1, -1, -1,
- 51, -1, 53, -1, -1, 56, -1, -1, -1, -1,
- -1, -1, -1, -1, 65, -1, 67, -1, 69, -1,
- 71, -1, 73, -1, -1, -1, -1, 78, 79, 80,
- -1, -1, -1, -1, -1, -1, -1, -1, 4, 5,
- 6, -1, -1, 9, 10, 11, -1, -1, 14, -1,
- 16, -1, -1, -1, 20, 21, 22, -1, -1, -1,
- -1, -1, -1, 29, 30, 31, 32, -1, -1, -1,
- -1, -1, -1, -1, -1, -1, -1, 43, -1, -1,
+ 12, 13, -1, -1, -1, -1, -1, -1, -1, -1,
+ 22, -1, -1, -1, -1, -1, -1, 29, -1, -1,
+ -1, 33, 34, -1, 36, -1, -1, -1, -1, -1,
+ -1, 43, -1, -1, -1, 47, -1, -1, -1, -1,
-1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
- -1, -1, -1, 59, -1, -1, -1, -1, -1, -1,
- 66, 67, 68, -1, 70, 71, 72, 73, 74, 75,
- -1, -1, 78, 79, 80, 81, 82, 83, -1, -1,
+ -1, -1, -1, 65, 66, 67, -1, 69, -1, -1,
+ -1, -1, -1, -1, -1, -1, -1, -1, 80, 81,
+ 82, -1, -1, -1, -1, -1, -1, -1, -1, 11,
+ 12, 13, -1, -1, -1, -1, -1, -1, -1, -1,
+ 22, -1, -1, -1, -1, -1, -1, 29, -1, -1,
+ -1, 33, 34, -1, 36, -1, -1, -1, 40, -1,
+ 42, 43, 44, -1, -1, 47, -1, -1, -1, 51,
+ -1, 53, -1, -1, -1, -1, -1, -1, -1, -1,
+ -1, -1, -1, 65, 66, 67, -1, 69, -1, 71,
+ -1, 73, -1, 75, -1, -1, -1, -1, 80, 81,
+ 82, -1, -1, -1, -1, -1, -1, -1, -1, 7,
+ -1, -1, -1, 11, 12, 13, -1, -1, -1, -1,
+ -1, -1, -1, -1, 22, -1, -1, -1, -1, -1,
+ -1, 29, -1, -1, -1, 33, 34, -1, 36, -1,
+ -1, -1, 40, -1, 42, 43, 44, -1, -1, 47,
+ -1, -1, -1, 51, -1, 53, -1, -1, -1, -1,
+ -1, -1, -1, -1, -1, -1, -1, 65, 66, 67,
+ -1, 69, -1, 71, -1, 73, -1, 75, -1, -1,
+ -1, -1, 80, 81, 82, -1, -1, -1, -1, -1,
+ -1, -1, -1, 11, 12, 13, -1, -1, -1, -1,
+ -1, -1, -1, -1, 22, -1, -1, -1, -1, -1,
+ -1, 29, -1, -1, -1, 33, 34, -1, 36, -1,
+ -1, -1, 40, -1, 42, 43, 44, -1, -1, 47,
+ -1, -1, -1, 51, -1, 53, -1, -1, -1, -1,
+ -1, -1, -1, -1, -1, -1, -1, 65, 66, 67,
+ -1, 69, -1, 71, -1, 73, 74, 75, -1, -1,
+ -1, -1, 80, 81, 82, -1, -1, -1, -1, -1,
+ -1, -1, -1, 11, 12, 13, -1, -1, -1, -1,
+ -1, -1, -1, -1, 22, -1, -1, -1, -1, -1,
+ -1, 29, -1, -1, -1, 33, 34, -1, 36, -1,
+ -1, -1, 40, -1, 42, 43, 44, -1, -1, 47,
+ -1, -1, -1, 51, -1, 53, -1, -1, 56, -1,
+ -1, -1, -1, -1, -1, -1, -1, 65, 66, 67,
+ -1, 69, -1, 71, -1, 73, -1, 75, -1, -1,
+ -1, -1, 80, 81, 82, -1, -1, -1, -1, -1,
+ -1, -1, -1, 11, 12, 13, -1, -1, -1, -1,
+ -1, -1, -1, -1, 22, -1, -1, -1, -1, -1,
+ -1, 29, -1, -1, -1, 33, 34, -1, 36, -1,
+ -1, -1, 40, -1, 42, 43, 44, -1, -1, 47,
+ -1, -1, -1, 51, -1, 53, -1, -1, 56, -1,
+ -1, -1, -1, -1, -1, -1, -1, 65, 66, 67,
+ -1, 69, -1, 71, -1, 73, -1, 75, -1, -1,
+ -1, -1, 80, 81, 82, -1, -1, -1, -1, -1,
-1, -1, -1, 4, 5, 6, -1, -1, 9, 10,
11, -1, -1, 14, -1, 16, -1, -1, -1, 20,
21, 22, -1, -1, -1, -1, -1, -1, 29, 30,
31, 32, -1, -1, -1, -1, -1, -1, -1, -1,
- -1, -1, 43, -1, -1, -1, 47, -1, -1, -1,
+ -1, -1, 43, -1, -1, -1, -1, -1, -1, -1,
-1, -1, -1, -1, -1, -1, -1, -1, 59, -1,
- -1, -1, -1, -1, 65, 66, 67, 68, -1, 70,
- 71, 72, 73, 74, 75, -1, -1, 78, 79, 80,
- 81, 82, 83, -1, -1, -1, -1, -1, 4, 5,
- 6, -1, -1, 9, 10, 11, -1, -1, 14, -1,
- 16, -1, -1, -1, 20, 21, 22, -1, -1, -1,
- -1, -1, -1, 29, 30, 31, 32, -1, -1, -1,
- -1, -1, -1, -1, -1, -1, -1, 43, -1, -1,
- -1, 47, -1, -1, -1, -1, -1, -1, -1, 55,
- -1, -1, -1, 59, -1, -1, -1, -1, -1, 65,
- 66, 67, 68, -1, 70, 71, 72, 73, 74, 75,
- -1, -1, 78, 79, 80, 81, 82, 83, -1, -1,
- -1, -1, -1, 4, -1, -1, -1, -1, 9, -1,
- 11, 12, 13, 14, -1, -1, -1, -1, -1, -1,
- 21, 22, -1, -1, -1, -1, -1, -1, 29, 30,
- -1, -1, 33, 34, -1, 36, -1, -1, -1, 40,
- -1, 42, 43, 44, -1, -1, 47, -1, -1, -1,
- 51, -1, 53, -1, -1, -1, -1, -1, 59, -1,
- 61, -1, -1, -1, 65, 66, 67, 68, 69, 70,
- 71, 72, 73, 74, 75, -1, -1, 78, 79, 80,
- 81, 82, -1, -1, -1, -1, -1, -1, 4, -1,
- -1, -1, -1, 9, -1, 11, 12, 13, 14, -1,
- -1, -1, -1, -1, -1, 21, 22, -1, -1, -1,
- -1, -1, -1, 29, 30, -1, -1, 33, 34, -1,
- 36, -1, -1, -1, 40, -1, 42, 43, 44, -1,
- -1, 47, -1, -1, -1, 51, -1, 53, -1, -1,
- -1, -1, -1, 59, -1, 61, -1, -1, -1, 65,
- 66, 67, 68, 69, 70, 71, 72, 73, 74, 75,
- -1, -1, 78, 79, 80, 81, 82, -1, -1, -1,
- -1, -1, -1, 4, -1, -1, -1, -1, 9, -1,
- 11, 12, 13, 14, -1, -1, -1, -1, -1, -1,
- 21, 22, -1, -1, -1, -1, -1, -1, 29, 30,
- -1, -1, 33, 34, -1, 36, -1, -1, -1, 40,
- -1, 42, 43, 44, -1, -1, 47, -1, -1, -1,
- 51, -1, 53, -1, -1, -1, -1, -1, 59, -1,
- 61, -1, -1, -1, 65, 66, 67, 68, 69, 70,
- 71, 72, 73, 74, 75, -1, -1, 78, 79, 80,
- 81, 82, -1, -1, -1, -1, -1, -1, 4, -1,
+ -1, -1, -1, -1, -1, 66, 67, 68, 69, 70,
+ -1, 72, 73, 74, 75, 76, 77, -1, -1, 80,
+ 81, 82, 83, 84, 85, -1, -1, -1, -1, -1,
+ 4, 5, 6, -1, -1, 9, 10, 11, -1, -1,
+ 14, -1, 16, -1, -1, -1, 20, 21, 22, -1,
+ -1, -1, -1, -1, -1, 29, 30, 31, 32, -1,
+ -1, -1, -1, -1, -1, -1, -1, -1, -1, 43,
+ -1, -1, -1, 47, -1, -1, -1, -1, -1, -1,
+ -1, -1, -1, -1, -1, 59, -1, -1, -1, -1,
+ -1, 65, 66, 67, 68, 69, 70, -1, 72, 73,
+ 74, 75, 76, 77, -1, -1, 80, 81, 82, 83,
+ 84, 85, -1, -1, -1, -1, -1, 4, 5, 6,
+ -1, -1, 9, 10, 11, -1, -1, 14, -1, 16,
+ -1, -1, -1, 20, 21, 22, -1, -1, -1, -1,
+ -1, -1, 29, 30, 31, 32, -1, -1, -1, -1,
+ -1, -1, -1, -1, -1, -1, 43, -1, -1, -1,
+ 47, -1, -1, -1, -1, -1, -1, -1, 55, -1,
+ -1, -1, 59, -1, -1, -1, -1, -1, 65, 66,
+ 67, 68, 69, 70, -1, 72, 73, 74, 75, 76,
+ 77, -1, -1, 80, 81, 82, 83, 84, 85, -1,
+ -1, -1, -1, -1, 4, -1, -1, -1, -1, 9,
+ -1, 11, 12, 13, 14, -1, -1, -1, -1, -1,
+ -1, 21, 22, -1, -1, -1, -1, -1, -1, 29,
+ 30, -1, -1, 33, 34, -1, 36, -1, -1, -1,
+ 40, -1, 42, 43, 44, -1, -1, 47, -1, -1,
+ -1, 51, -1, 53, -1, -1, -1, -1, -1, 59,
+ -1, 61, -1, -1, -1, 65, 66, 67, 68, 69,
+ 70, 71, 72, 73, 74, 75, 76, 77, -1, -1,
+ 80, 81, 82, 83, 84, -1, -1, -1, -1, -1,
+ -1, 4, -1, -1, -1, -1, 9, -1, 11, 12,
+ 13, 14, -1, -1, -1, -1, -1, -1, 21, 22,
+ -1, -1, -1, -1, -1, -1, 29, 30, -1, -1,
+ 33, 34, -1, 36, -1, -1, -1, 40, -1, 42,
+ 43, 44, -1, -1, 47, -1, -1, -1, 51, -1,
+ 53, -1, -1, -1, -1, -1, 59, -1, 61, -1,
+ -1, -1, 65, 66, 67, 68, 69, 70, 71, 72,
+ 73, 74, 75, 76, 77, -1, -1, 80, 81, 82,
+ 83, 84, -1, -1, -1, -1, -1, -1, 4, -1,
-1, -1, -1, 9, -1, 11, 12, 13, 14, -1,
-1, -1, -1, -1, -1, 21, 22, -1, -1, -1,
-1, -1, -1, 29, 30, -1, -1, 33, 34, -1,
@@ -686,49 +687,60 @@ const int JavaScriptGrammar::action_check [] = {
-1, 47, -1, -1, -1, 51, -1, 53, -1, -1,
-1, -1, -1, 59, -1, 61, -1, -1, -1, 65,
66, 67, 68, 69, 70, 71, 72, 73, 74, 75,
- -1, -1, 78, 79, 80, 81, 82, -1, 84, -1,
- -1, -1, -1, 4, 5, 6, -1, -1, 9, 10,
- 11, 12, 13, 14, -1, 16, -1, -1, -1, 20,
- 21, 22, -1, -1, -1, -1, -1, -1, 29, 30,
- 31, 32, 33, 34, -1, 36, -1, -1, -1, 40,
- -1, 42, 43, 44, -1, -1, 47, -1, -1, -1,
- 51, -1, 53, -1, 55, -1, -1, -1, 59, -1,
- 61, -1, -1, -1, 65, 66, 67, 68, 69, 70,
- 71, 72, 73, 74, 75, -1, -1, 78, 79, 80,
- 81, 82, 83, -1, -1, -1, -1, -1,
+ 76, 77, -1, -1, 80, 81, 82, 83, 84, -1,
+ -1, -1, -1, -1, -1, 4, -1, -1, -1, -1,
+ 9, -1, 11, 12, 13, 14, -1, -1, -1, -1,
+ -1, -1, 21, 22, -1, -1, -1, -1, -1, -1,
+ 29, 30, -1, -1, 33, 34, -1, 36, -1, -1,
+ -1, 40, -1, 42, 43, 44, -1, -1, 47, -1,
+ -1, -1, 51, -1, 53, -1, -1, -1, -1, -1,
+ 59, -1, 61, -1, -1, -1, 65, 66, 67, 68,
+ 69, 70, 71, 72, 73, 74, 75, 76, 77, -1,
+ -1, 80, 81, 82, 83, 84, -1, 86, -1, -1,
+ -1, -1, 4, 5, 6, -1, -1, 9, 10, 11,
+ 12, 13, 14, -1, 16, -1, -1, -1, 20, 21,
+ 22, -1, -1, -1, -1, -1, -1, 29, 30, 31,
+ 32, 33, 34, -1, 36, -1, -1, -1, 40, -1,
+ 42, 43, 44, -1, -1, 47, -1, -1, -1, 51,
+ -1, 53, -1, 55, -1, -1, -1, 59, -1, 61,
+ -1, -1, -1, 65, 66, 67, 68, 69, 70, 71,
+ 72, 73, 74, 75, 76, 77, -1, -1, 80, 81,
+ 82, 83, 84, 85, -1, -1, -1, -1, -1,
- 22, 18, 56, 22, 14, 13, 24, 60, 13, 22,
- 14, 13, 80, 14, 13, 22, 14, 5, 78, 22,
- 16, 14, 22, 14, 60, 22, 9, 22, 22, 14,
- 22, 92, 22, 14, 13, 13, 25, 9, 13, 10,
- 9, 74, 86, 13, 60, 60, 14, 13, 13, 89,
- 14, 14, 14, 14, 14, 13, 91, 14, 13, 13,
- 13, -1, 74, 14, 14, 6, 33, 14, 8, 7,
- 10, 38, 10, -1, 33, 16, -1, 33, 14, -1,
- 36, 33, -1, 35, 33, 33, 35, 35, 47, 33,
- 33, 33, 27, 36, 33, 30, 35, 27, -1, 33,
- 30, 35, -1, 45, 33, 49, 33, 57, 33, 38,
- 57, 38, 33, 38, 35, 33, 33, 33, 35, 33,
- 38, 35, 33, 33, 35, 33, -1, 43, 33, 39,
- 13, 39, 15, 38, 33, 33, 33, 33, 14, 38,
- 38, 38, 33, 39, 35, 33, 33, 35, 33, 33,
- 14, 35, 39, 38, 33, 33, 33, 35, -1, 33,
- 22, 38, 41, 37, 22, 33, 33, 29, 35, 37,
- 33, 29, 25, 26, 33, 38, 35, 2, 33, 33,
- -1, 57, 37, 33, 38, -1, -1, 33, 38, -1,
- 44, 16, 38, 57, 40, 33, 33, 13, 33, 15,
- 38, 38, 33, 38, 33, 55, 13, 38, 15, 38,
- 33, 46, -1, -1, -1, 38, 33, 55, 55, 48,
- 33, 38, 33, 40, 55, 38, -1, 38, 33, 42,
- -1, 33, 55, 38, -1, 40, 38, -1, 40, 50,
- -1, -1, 6, -1, -1, -1, -1, -1, -1, -1,
- -1, -1, 16, -1, -1, -1, -1, -1, -1, -1,
+ 76, 9, 9, 76, 15, 15, 93, 58, 24, 18,
+ 15, 91, 18, 15, 18, 18, 88, 62, 14, 13,
+ 15, 13, 20, 24, 24, 24, 15, 18, 13, 13,
+ 18, 62, 15, 9, 62, 15, 18, 24, 13, 5,
+ 26, 15, 13, 24, 13, 24, 24, 15, 18, 13,
+ 15, 24, 24, 13, 15, 18, 18, 13, 13, 13,
+ 13, 18, 13, 15, 13, 62, 24, 15, 18, 15,
+ 13, 18, -1, 15, 18, -1, 35, 18, 18, 24,
+ 17, 18, 18, 15, 10, 15, 31, 15, 47, -1,
+ 15, 29, 18, -1, 32, 18, 35, -1, 37, 13,
+ 35, 35, 16, -1, 27, 39, 35, -1, 35, -1,
+ 45, 38, 41, 15, 35, 35, 37, 37, 35, 29,
+ 35, -1, 32, 35, 41, 37, 41, 59, 35, 59,
+ 35, 59, 37, 40, 59, 35, 35, 37, 37, -1,
+ 80, 82, 35, 35, 37, 37, 35, 24, 37, 35,
+ 35, 37, 37, 35, 31, 35, -1, 35, 94, 41,
+ 40, 39, 35, 35, 35, 37, 35, 40, 39, 38,
+ 35, 35, 35, 35, 35, 40, 40, 40, 35, 35,
+ 35, 35, 35, 40, 40, 40, 40, 40, 49, 51,
+ 35, 35, 37, 37, 35, 7, 35, -1, 10, 40,
+ 35, 40, 8, -1, 10, 35, 18, -1, 43, 35,
+ 40, -1, 18, 52, 40, 35, 13, -1, 35, 16,
+ 40, -1, 48, 40, 35, 35, 46, 57, 35, 40,
+ 40, 35, 35, 40, 2, -1, 40, 40, 42, 42,
+ 57, 6, -1, 50, 6, -1, 57, 57, 18, 17,
+ 18, -1, 17, 18, 35, 17, 18, 27, 28, 40,
+ 35, 35, -1, -1, -1, 40, 40, 13, 42, 44,
+ 16, -1, 35, -1, -1, -1, 57, 40, -1, 42,
-1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
+ -1, -1, -1, -1, -1, -1, -1, -1, 95, -1,
-1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
- -1, -1, 98, -1, -1, -1, 93, -1, -1, -1,
-1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
-1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
-1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
-1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
- -1, -1, -1, -1, -1, -1};
+ -1, -1, -1, -1, 100, -1};
diff --git a/src/declarative/qml/parser/javascriptgrammar_p.h b/src/declarative/qml/parser/javascriptgrammar_p.h
index 61a2eb0..c01d1cc 100644
--- a/src/declarative/qml/parser/javascriptgrammar_p.h
+++ b/src/declarative/qml/parser/javascriptgrammar_p.h
@@ -59,8 +59,8 @@ class JavaScriptGrammar
public:
enum {
EOF_SYMBOL = 0,
- REDUCE_HERE = 88,
- SHIFT_THERE = 87,
+ REDUCE_HERE = 90,
+ SHIFT_THERE = 89,
T_AND = 1,
T_AND_AND = 2,
T_AND_EQ = 3,
@@ -70,9 +70,9 @@ public:
T_CATCH = 6,
T_COLON = 7,
T_COMMA = 8,
- T_CONST = 81,
+ T_CONST = 83,
T_CONTINUE = 9,
- T_DEBUGGER = 82,
+ T_DEBUGGER = 84,
T_DEFAULT = 10,
T_DELETE = 11,
T_DIVIDE_ = 12,
@@ -83,7 +83,7 @@ public:
T_EQ = 17,
T_EQ_EQ = 18,
T_EQ_EQ_EQ = 19,
- T_FALSE = 80,
+ T_FALSE = 82,
T_FINALLY = 20,
T_FOR = 21,
T_FUNCTION = 22,
@@ -95,7 +95,7 @@ public:
T_GT_GT_GT_EQ = 28,
T_IDENTIFIER = 29,
T_IF = 30,
- T_IMPORT = 86,
+ T_IMPORT = 88,
T_IN = 31,
T_INSTANCEOF = 32,
T_LBRACE = 33,
@@ -108,12 +108,12 @@ public:
T_MINUS = 40,
T_MINUS_EQ = 41,
T_MINUS_MINUS = 42,
- T_MULTILINE_STRING_LITERAL = 84,
+ T_MULTILINE_STRING_LITERAL = 86,
T_NEW = 43,
T_NOT = 44,
T_NOT_EQ = 45,
T_NOT_EQ_EQ = 46,
- T_NULL = 78,
+ T_NULL = 80,
T_NUMERIC_LITERAL = 47,
T_OR = 48,
T_OR_EQ = 49,
@@ -121,42 +121,44 @@ public:
T_PLUS = 51,
T_PLUS_EQ = 52,
T_PLUS_PLUS = 53,
- T_PUBLIC = 85,
+ T_PROPERTY = 66,
+ T_PUBLIC = 87,
T_QUESTION = 54,
T_RBRACE = 55,
T_RBRACKET = 56,
T_REMAINDER = 57,
T_REMAINDER_EQ = 58,
- T_RESERVED_WORD = 83,
+ T_RESERVED_WORD = 85,
T_RETURN = 59,
T_RPAREN = 60,
T_SEMICOLON = 61,
+ T_SIGNAL = 67,
T_STAR = 63,
T_STAR_EQ = 64,
T_STRING_LITERAL = 65,
- T_SWITCH = 66,
- T_THIS = 67,
- T_THROW = 68,
- T_TILDE = 69,
- T_TRUE = 79,
- T_TRY = 70,
- T_TYPEOF = 71,
- T_VAR = 72,
- T_VOID = 73,
- T_WHILE = 74,
- T_WITH = 75,
- T_XOR = 76,
- T_XOR_EQ = 77,
-
- ACCEPT_STATE = 531,
- RULE_COUNT = 304,
- STATE_COUNT = 532,
- TERMINAL_COUNT = 89,
- NON_TERMINAL_COUNT = 100,
-
- GOTO_INDEX_OFFSET = 532,
- GOTO_INFO_OFFSET = 1798,
- GOTO_CHECK_OFFSET = 1798
+ T_SWITCH = 68,
+ T_THIS = 69,
+ T_THROW = 70,
+ T_TILDE = 71,
+ T_TRUE = 81,
+ T_TRY = 72,
+ T_TYPEOF = 73,
+ T_VAR = 74,
+ T_VOID = 75,
+ T_WHILE = 76,
+ T_WITH = 77,
+ T_XOR = 78,
+ T_XOR_EQ = 79,
+
+ ACCEPT_STATE = 551,
+ RULE_COUNT = 315,
+ STATE_COUNT = 552,
+ TERMINAL_COUNT = 91,
+ NON_TERMINAL_COUNT = 102,
+
+ GOTO_INDEX_OFFSET = 552,
+ GOTO_INFO_OFFSET = 1789,
+ GOTO_CHECK_OFFSET = 1789
};
static const char *const spell [];
diff --git a/src/declarative/qml/parser/javascriptlexer.cpp b/src/declarative/qml/parser/javascriptlexer.cpp
index 90f8e44..c0a4b63 100644
--- a/src/declarative/qml/parser/javascriptlexer.cpp
+++ b/src/declarative/qml/parser/javascriptlexer.cpp
@@ -291,6 +291,10 @@ int JavaScript::Lexer::findReservedWord(const QChar *c, int size) const
&& c[2] == QLatin1Char('p') && c[3] == QLatin1Char('o')
&& c[4] == QLatin1Char('r') && c[5] == QLatin1Char('t'))
return JavaScriptGrammar::T_IMPORT;
+ else if (c[0] == QLatin1Char('s') && c[1] == QLatin1Char('i')
+ && c[2] == QLatin1Char('g') && c[3] == QLatin1Char('n')
+ && c[4] == QLatin1Char('a') && c[5] == QLatin1Char('l'))
+ return JavaScriptGrammar::T_SIGNAL;
else if (check_reserved) {
if (c[0] == QLatin1Char('e') && c[1] == QLatin1Char('x')
&& c[2] == QLatin1Char('p') && c[3] == QLatin1Char('o')
@@ -374,6 +378,11 @@ int JavaScript::Lexer::findReservedWord(const QChar *c, int size) const
&& c[4] == QLatin1Char('g') && c[5] == QLatin1Char('g')
&& c[6] == QLatin1Char('e') && c[7] == QLatin1Char('r'))
return JavaScriptGrammar::T_DEBUGGER;
+ else if (c[0] == QLatin1Char('p') && c[1] == QLatin1Char('r')
+ && c[2] == QLatin1Char('o') && c[3] == QLatin1Char('p')
+ && c[4] == QLatin1Char('e') && c[5] == QLatin1Char('r')
+ && c[6] == QLatin1Char('t') && c[7] == QLatin1Char('y'))
+ return JavaScriptGrammar::T_PROPERTY;
else if (check_reserved) {
if (c[0] == QLatin1Char('a') && c[1] == QLatin1Char('b')
&& c[2] == QLatin1Char('s') && c[3] == QLatin1Char('t')
diff --git a/src/declarative/qml/parser/javascriptparser.cpp b/src/declarative/qml/parser/javascriptparser.cpp
index 58b7a5b..185a824 100644
--- a/src/declarative/qml/parser/javascriptparser.cpp
+++ b/src/declarative/qml/parser/javascriptparser.cpp
@@ -271,116 +271,144 @@ case 25: {
sym(1).Node = node;
} break;
-case 26: {
+case 26:
+
+case 27: {
+ sym(1).sval = driver->intern(lexer->characterBuffer(), lexer->characterCount());
+ break;
+}
+
+case 29: {
+ AST::UiPublicMember *node = makeAstNode<AST::UiPublicMember> (driver->nodePool(), (JavaScriptNameIdImpl *)0, sym(2).sval);
+ node->type = AST::UiPublicMember::Signal;
+ node->propertyToken = loc(1);
+ node->typeToken = loc(2);
+ node->identifierToken = loc(3);
+ sym(1).Node = node;
+} break;
+
+case 30: {
AST::UiPublicMember *node = makeAstNode<AST::UiPublicMember> (driver->nodePool(), sym(2).sval, sym(3).sval);
- node->publicToken = loc(1);
- node->attributeTypeToken = loc(2);
+ node->propertyToken = loc(1);
+ node->typeToken = loc(2);
node->identifierToken = loc(3);
sym(1).Node = node;
} break;
-case 27: {
+case 31: {
AST::UiPublicMember *node = makeAstNode<AST::UiPublicMember> (driver->nodePool(), sym(3).sval, sym(4).sval);
node->isDefaultMember = true;
- node->publicToken = loc(1);
- node->attributeTypeToken = loc(3);
+ node->defaultToken = loc(1);
+ node->propertyToken = loc(2);
+ node->typeToken = loc(3);
node->identifierToken = loc(4);
sym(1).Node = node;
} break;
-case 28: {
+case 32: {
AST::UiPublicMember *node = makeAstNode<AST::UiPublicMember> (driver->nodePool(), sym(2).sval, sym(3).sval,
sym(5).Expression);
- node->publicToken = loc(1);
- node->attributeTypeToken = loc(2);
+ node->propertyToken = loc(1);
+ node->typeToken = loc(2);
node->identifierToken = loc(3);
node->colonToken = loc(4);
sym(1).Node = node;
} break;
-case 29: {
+case 33: {
AST::UiPublicMember *node = makeAstNode<AST::UiPublicMember> (driver->nodePool(), sym(3).sval, sym(4).sval,
sym(6).Expression);
node->isDefaultMember = true;
- node->publicToken = loc(1);
- node->attributeTypeToken = loc(3);
+ node->defaultToken = loc(1);
+ node->propertyToken = loc(2);
+ node->typeToken = loc(3);
node->identifierToken = loc(4);
node->colonToken = loc(5);
sym(1).Node = node;
} break;
-case 30: {
+case 34: {
sym(1).Node = makeAstNode<AST::UiSourceElement>(driver->nodePool(), sym(1).Node);
} break;
-case 31: {
+case 35: {
sym(1).Node = makeAstNode<AST::UiSourceElement>(driver->nodePool(), sym(1).Node);
} break;
-
-case 32:
-
-case 33:
+case 36:
+case 37:
{
AST::UiQualifiedId *node = makeAstNode<AST::UiQualifiedId> (driver->nodePool(), driver->intern(lexer->characterBuffer(), lexer->characterCount()));
node->identifierToken = loc(1);
sym(1).Node = node;
} break;
-case 34: {
+case 39: {
+ QString s = QLatin1String(JavaScriptGrammar::spell[T_PROPERTY]);
+ sym(1).sval = driver->intern(s.constData(), s.length());
+ break;
+}
+
+case 40: {
+ QString s = QLatin1String(JavaScriptGrammar::spell[T_SIGNAL]);
+ sym(1).sval = driver->intern(s.constData(), s.length());
+ break;
+}
+
+case 41: {
AST::UiQualifiedId *node = makeAstNode<AST::UiQualifiedId> (driver->nodePool(), sym(1).sval);
node->identifierToken = loc(1);
sym(1).Node = node;
} break;
-case 35: {
+case 42: {
AST::UiQualifiedId *node = makeAstNode<AST::UiQualifiedId> (driver->nodePool(), sym(1).UiQualifiedId, sym(3).sval);
node->identifierToken = loc(3);
sym(1).Node = node;
} break;
-case 36: {
+case 43: {
AST::ThisExpression *node = makeAstNode<AST::ThisExpression> (driver->nodePool());
node->thisToken = loc(1);
sym(1).Node = node;
} break;
-case 37: {
+case 44: {
AST::IdentifierExpression *node = makeAstNode<AST::IdentifierExpression> (driver->nodePool(), sym(1).sval);
node->identifierToken = loc(1);
sym(1).Node = node;
} break;
-case 38: {
+case 45: {
AST::NullExpression *node = makeAstNode<AST::NullExpression> (driver->nodePool());
node->nullToken = loc(1);
sym(1).Node = node;
} break;
-case 39: {
+case 46: {
AST::TrueLiteral *node = makeAstNode<AST::TrueLiteral> (driver->nodePool());
node->trueToken = loc(1);
sym(1).Node = node;
} break;
-case 40: {
+case 47: {
AST::FalseLiteral *node = makeAstNode<AST::FalseLiteral> (driver->nodePool());
node->falseToken = loc(1);
sym(1).Node = node;
} break;
-case 41: {
+case 48: {
AST::NumericLiteral *node = makeAstNode<AST::NumericLiteral> (driver->nodePool(), sym(1).dval);
node->literalToken = loc(1);
sym(1).Node = node;
} break;
-case 42: {
+case 49: {
AST::StringLiteral *node = makeAstNode<AST::StringLiteral> (driver->nodePool(), sym(1).sval);
node->literalToken = loc(1);
sym(1).Node = node;
} break;
-case 43: {
+case 50: {
bool rx = lexer->scanRegExp(Lexer::NoPrefix);
if (!rx) {
diagnostic_messages.append(DiagnosticMessage(DiagnosticMessage::Error, lexer->startLineNo(),
@@ -392,7 +420,7 @@ case 43: {
sym(1).Node = node;
} break;
-case 44: {
+case 51: {
bool rx = lexer->scanRegExp(Lexer::EqualPrefix);
if (!rx) {
diagnostic_messages.append(DiagnosticMessage(DiagnosticMessage::Error, lexer->startLineNo(),
@@ -404,21 +432,21 @@ case 44: {
sym(1).Node = node;
} break;
-case 45: {
+case 52: {
AST::ArrayLiteral *node = makeAstNode<AST::ArrayLiteral> (driver->nodePool(), sym(2).Elision);
node->lbracketToken = loc(1);
node->rbracketToken = loc(3);
sym(1).Node = node;
} break;
-case 46: {
+case 53: {
AST::ArrayLiteral *node = makeAstNode<AST::ArrayLiteral> (driver->nodePool(), sym(2).ElementList->finish ());
node->lbracketToken = loc(1);
node->rbracketToken = loc(3);
sym(1).Node = node;
} break;
-case 47: {
+case 54: {
AST::ArrayLiteral *node = makeAstNode<AST::ArrayLiteral> (driver->nodePool(), sym(2).ElementList->finish (), sym(4).Elision);
node->lbracketToken = loc(1);
node->commaToken = loc(3);
@@ -426,7 +454,7 @@ case 47: {
sym(1).Node = node;
} break;
-case 48: {
+case 55: {
AST::ObjectLiteral *node = 0;
if (sym(2).Node)
node = makeAstNode<AST::ObjectLiteral> (driver->nodePool(),
@@ -438,7 +466,7 @@ case 48: {
sym(1).Node = node;
} break;
-case 49: {
+case 56: {
AST::ObjectLiteral *node = makeAstNode<AST::ObjectLiteral> (driver->nodePool(),
sym(2).PropertyNameAndValueList->finish ());
node->lbraceToken = loc(1);
@@ -446,51 +474,51 @@ case 49: {
sym(1).Node = node;
} break;
-case 50: {
+case 57: {
AST::NestedExpression *node = makeAstNode<AST::NestedExpression>(driver->nodePool(), sym(2).Expression);
node->lparenToken = loc(1);
node->rparenToken = loc(3);
sym(1).Node = node;
} break;
-case 51: {
+case 58: {
sym(1).Node = makeAstNode<AST::ElementList> (driver->nodePool(), sym(1).Elision, sym(2).Expression);
} break;
-case 52: {
+case 59: {
AST::ElementList *node = makeAstNode<AST::ElementList> (driver->nodePool(), sym(1).ElementList, sym(3).Elision, sym(4).Expression);
node->commaToken = loc(2);
sym(1).Node = node;
} break;
-case 53: {
+case 60: {
AST::Elision *node = makeAstNode<AST::Elision> (driver->nodePool());
node->commaToken = loc(1);
sym(1).Node = node;
} break;
-case 54: {
+case 61: {
AST::Elision *node = makeAstNode<AST::Elision> (driver->nodePool(), sym(1).Elision);
node->commaToken = loc(2);
sym(1).Node = node;
} break;
-case 55: {
+case 62: {
sym(1).Node = 0;
} break;
-case 56: {
+case 63: {
sym(1).Elision = sym(1).Elision->finish ();
} break;
-case 57: {
+case 64: {
AST::PropertyNameAndValueList *node = makeAstNode<AST::PropertyNameAndValueList> (driver->nodePool(),
sym(1).PropertyName, sym(3).Expression);
node->colonToken = loc(2);
sym(1).Node = node;
} break;
-case 58: {
+case 65: {
AST::PropertyNameAndValueList *node = makeAstNode<AST::PropertyNameAndValueList> (driver->nodePool(),
sym(1).PropertyNameAndValueList, sym(3).PropertyName, sym(5).Expression);
node->commaToken = loc(2);
@@ -498,48 +526,36 @@ case 58: {
sym(1).Node = node;
} break;
-case 59: {
+case 66: {
AST::IdentifierPropertyName *node = makeAstNode<AST::IdentifierPropertyName> (driver->nodePool(), sym(1).sval);
node->propertyNameToken = loc(1);
sym(1).Node = node;
} break;
+case 67:
+case 68: {
+ AST::IdentifierPropertyName *node = makeAstNode<AST::IdentifierPropertyName> (driver->nodePool(), driver->intern(lexer->characterBuffer(), lexer->characterCount()));
+ node->propertyNameToken = loc(1);
+ sym(1).Node = node;
+} break;
-case 60: {
+case 69: {
AST::StringLiteralPropertyName *node = makeAstNode<AST::StringLiteralPropertyName> (driver->nodePool(), sym(1).sval);
node->propertyNameToken = loc(1);
sym(1).Node = node;
} break;
-case 61: {
+case 70: {
AST::NumericLiteralPropertyName *node = makeAstNode<AST::NumericLiteralPropertyName> (driver->nodePool(), sym(1).dval);
node->propertyNameToken = loc(1);
sym(1).Node = node;
} break;
-case 62: {
+case 71: {
AST::IdentifierPropertyName *node = makeAstNode<AST::IdentifierPropertyName> (driver->nodePool(), sym(1).sval);
node->propertyNameToken = loc(1);
sym(1).Node = node;
} break;
-case 63:
-
-case 64:
-
-case 65:
-
-case 66:
-
-case 67:
-
-case 68:
-
-case 69:
-
-case 70:
-
-case 71:
-
case 72:
case 73:
@@ -583,25 +599,43 @@ case 91:
case 92:
case 93:
+
+case 94:
+
+case 95:
+
+case 96:
+
+case 97:
+
+case 98:
+
+case 99:
+
+case 100:
+
+case 101:
+
+case 102:
{
sym(1).sval = driver->intern(lexer->characterBuffer(), lexer->characterCount());
} break;
-case 98: {
+case 107: {
AST::ArrayMemberExpression *node = makeAstNode<AST::ArrayMemberExpression> (driver->nodePool(), sym(1).Expression, sym(3).Expression);
node->lbracketToken = loc(2);
node->rbracketToken = loc(4);
sym(1).Node = node;
} break;
-case 99: {
+case 108: {
AST::FieldMemberExpression *node = makeAstNode<AST::FieldMemberExpression> (driver->nodePool(), sym(1).Expression, sym(3).sval);
node->dotToken = loc(2);
node->identifierToken = loc(3);
sym(1).Node = node;
} break;
-case 100: {
+case 109: {
AST::NewMemberExpression *node = makeAstNode<AST::NewMemberExpression> (driver->nodePool(), sym(2).Expression, sym(4).ArgumentList);
node->newToken = loc(1);
node->lparenToken = loc(3);
@@ -609,384 +643,384 @@ case 100: {
sym(1).Node = node;
} break;
-case 102: {
+case 111: {
AST::NewExpression *node = makeAstNode<AST::NewExpression> (driver->nodePool(), sym(2).Expression);
node->newToken = loc(1);
sym(1).Node = node;
} break;
-case 103: {
+case 112: {
AST::CallExpression *node = makeAstNode<AST::CallExpression> (driver->nodePool(), sym(1).Expression, sym(3).ArgumentList);
node->lparenToken = loc(2);
node->rparenToken = loc(4);
sym(1).Node = node;
} break;
-case 104: {
+case 113: {
AST::CallExpression *node = makeAstNode<AST::CallExpression> (driver->nodePool(), sym(1).Expression, sym(3).ArgumentList);
node->lparenToken = loc(2);
node->rparenToken = loc(4);
sym(1).Node = node;
} break;
-case 105: {
+case 114: {
AST::ArrayMemberExpression *node = makeAstNode<AST::ArrayMemberExpression> (driver->nodePool(), sym(1).Expression, sym(3).Expression);
node->lbracketToken = loc(2);
node->rbracketToken = loc(4);
sym(1).Node = node;
} break;
-case 106: {
+case 115: {
AST::FieldMemberExpression *node = makeAstNode<AST::FieldMemberExpression> (driver->nodePool(), sym(1).Expression, sym(3).sval);
node->dotToken = loc(2);
node->identifierToken = loc(3);
sym(1).Node = node;
} break;
-case 107: {
+case 116: {
sym(1).Node = 0;
} break;
-case 108: {
+case 117: {
sym(1).Node = sym(1).ArgumentList->finish();
} break;
-case 109: {
+case 118: {
sym(1).Node = makeAstNode<AST::ArgumentList> (driver->nodePool(), sym(1).Expression);
} break;
-case 110: {
+case 119: {
AST::ArgumentList *node = makeAstNode<AST::ArgumentList> (driver->nodePool(), sym(1).ArgumentList, sym(3).Expression);
node->commaToken = loc(2);
sym(1).Node = node;
} break;
-case 114: {
+case 123: {
AST::PostIncrementExpression *node = makeAstNode<AST::PostIncrementExpression> (driver->nodePool(), sym(1).Expression);
node->incrementToken = loc(2);
sym(1).Node = node;
} break;
-case 115: {
+case 124: {
AST::PostDecrementExpression *node = makeAstNode<AST::PostDecrementExpression> (driver->nodePool(), sym(1).Expression);
node->decrementToken = loc(2);
sym(1).Node = node;
} break;
-case 117: {
+case 126: {
AST::DeleteExpression *node = makeAstNode<AST::DeleteExpression> (driver->nodePool(), sym(2).Expression);
node->deleteToken = loc(1);
sym(1).Node = node;
} break;
-case 118: {
+case 127: {
AST::VoidExpression *node = makeAstNode<AST::VoidExpression> (driver->nodePool(), sym(2).Expression);
node->voidToken = loc(1);
sym(1).Node = node;
} break;
-case 119: {
+case 128: {
AST::TypeOfExpression *node = makeAstNode<AST::TypeOfExpression> (driver->nodePool(), sym(2).Expression);
node->typeofToken = loc(1);
sym(1).Node = node;
} break;
-case 120: {
+case 129: {
AST::PreIncrementExpression *node = makeAstNode<AST::PreIncrementExpression> (driver->nodePool(), sym(2).Expression);
node->incrementToken = loc(1);
sym(1).Node = node;
} break;
-case 121: {
+case 130: {
AST::PreDecrementExpression *node = makeAstNode<AST::PreDecrementExpression> (driver->nodePool(), sym(2).Expression);
node->decrementToken = loc(1);
sym(1).Node = node;
} break;
-case 122: {
+case 131: {
AST::UnaryPlusExpression *node = makeAstNode<AST::UnaryPlusExpression> (driver->nodePool(), sym(2).Expression);
node->plusToken = loc(1);
sym(1).Node = node;
} break;
-case 123: {
+case 132: {
AST::UnaryMinusExpression *node = makeAstNode<AST::UnaryMinusExpression> (driver->nodePool(), sym(2).Expression);
node->minusToken = loc(1);
sym(1).Node = node;
} break;
-case 124: {
+case 133: {
AST::TildeExpression *node = makeAstNode<AST::TildeExpression> (driver->nodePool(), sym(2).Expression);
node->tildeToken = loc(1);
sym(1).Node = node;
} break;
-case 125: {
+case 134: {
AST::NotExpression *node = makeAstNode<AST::NotExpression> (driver->nodePool(), sym(2).Expression);
node->notToken = loc(1);
sym(1).Node = node;
} break;
-case 127: {
+case 136: {
AST::BinaryExpression *node = makeAstNode<AST::BinaryExpression> (driver->nodePool(), sym(1).Expression,
QSOperator::Mul, sym(3).Expression);
node->operatorToken = loc(2);
sym(1).Node = node;
} break;
-case 128: {
+case 137: {
AST::BinaryExpression *node = makeAstNode<AST::BinaryExpression> (driver->nodePool(), sym(1).Expression,
QSOperator::Div, sym(3).Expression);
node->operatorToken = loc(2);
sym(1).Node = node;
} break;
-case 129: {
+case 138: {
AST::BinaryExpression *node = makeAstNode<AST::BinaryExpression> (driver->nodePool(), sym(1).Expression,
QSOperator::Mod, sym(3).Expression);
node->operatorToken = loc(2);
sym(1).Node = node;
} break;
-case 131: {
+case 140: {
AST::BinaryExpression *node = makeAstNode<AST::BinaryExpression> (driver->nodePool(), sym(1).Expression,
QSOperator::Add, sym(3).Expression);
node->operatorToken = loc(2);
sym(1).Node = node;
} break;
-case 132: {
+case 141: {
AST::BinaryExpression *node = makeAstNode<AST::BinaryExpression> (driver->nodePool(), sym(1).Expression,
QSOperator::Sub, sym(3).Expression);
node->operatorToken = loc(2);
sym(1).Node = node;
} break;
-case 134: {
+case 143: {
AST::BinaryExpression *node = makeAstNode<AST::BinaryExpression> (driver->nodePool(), sym(1).Expression,
QSOperator::LShift, sym(3).Expression);
node->operatorToken = loc(2);
sym(1).Node = node;
} break;
-case 135: {
+case 144: {
AST::BinaryExpression *node = makeAstNode<AST::BinaryExpression> (driver->nodePool(), sym(1).Expression,
QSOperator::RShift, sym(3).Expression);
node->operatorToken = loc(2);
sym(1).Node = node;
} break;
-case 136: {
+case 145: {
AST::BinaryExpression *node = makeAstNode<AST::BinaryExpression> (driver->nodePool(), sym(1).Expression,
QSOperator::URShift, sym(3).Expression);
node->operatorToken = loc(2);
sym(1).Node = node;
} break;
-case 138: {
+case 147: {
AST::BinaryExpression *node = makeAstNode<AST::BinaryExpression> (driver->nodePool(), sym(1).Expression,
QSOperator::Lt, sym(3).Expression);
node->operatorToken = loc(2);
sym(1).Node = node;
} break;
-case 139: {
+case 148: {
AST::BinaryExpression *node = makeAstNode<AST::BinaryExpression> (driver->nodePool(), sym(1).Expression,
QSOperator::Gt, sym(3).Expression);
node->operatorToken = loc(2);
sym(1).Node = node;
} break;
-case 140: {
+case 149: {
AST::BinaryExpression *node = makeAstNode<AST::BinaryExpression> (driver->nodePool(), sym(1).Expression,
QSOperator::Le, sym(3).Expression);
node->operatorToken = loc(2);
sym(1).Node = node;
} break;
-case 141: {
+case 150: {
AST::BinaryExpression *node = makeAstNode<AST::BinaryExpression> (driver->nodePool(), sym(1).Expression,
QSOperator::Ge, sym(3).Expression);
node->operatorToken = loc(2);
sym(1).Node = node;
} break;
-case 142: {
+case 151: {
AST::BinaryExpression *node = makeAstNode<AST::BinaryExpression> (driver->nodePool(), sym(1).Expression,
QSOperator::InstanceOf, sym(3).Expression);
node->operatorToken = loc(2);
sym(1).Node = node;
} break;
-case 143: {
+case 152: {
AST::BinaryExpression *node = makeAstNode<AST::BinaryExpression> (driver->nodePool(), sym(1).Expression,
QSOperator::In, sym(3).Expression);
node->operatorToken = loc(2);
sym(1).Node = node;
} break;
-case 145: {
+case 154: {
AST::BinaryExpression *node = makeAstNode<AST::BinaryExpression> (driver->nodePool(), sym(1).Expression,
QSOperator::Lt, sym(3).Expression);
node->operatorToken = loc(2);
sym(1).Node = node;
} break;
-case 146: {
+case 155: {
AST::BinaryExpression *node = makeAstNode<AST::BinaryExpression> (driver->nodePool(), sym(1).Expression,
QSOperator::Gt, sym(3).Expression);
node->operatorToken = loc(2);
sym(1).Node = node;
} break;
-case 147: {
+case 156: {
AST::BinaryExpression *node = makeAstNode<AST::BinaryExpression> (driver->nodePool(), sym(1).Expression,
QSOperator::Le, sym(3).Expression);
node->operatorToken = loc(2);
sym(1).Node = node;
} break;
-case 148: {
+case 157: {
AST::BinaryExpression *node = makeAstNode<AST::BinaryExpression> (driver->nodePool(), sym(1).Expression,
QSOperator::Ge, sym(3).Expression);
node->operatorToken = loc(2);
sym(1).Node = node;
} break;
-case 149: {
+case 158: {
AST::BinaryExpression *node = makeAstNode<AST::BinaryExpression> (driver->nodePool(), sym(1).Expression,
QSOperator::InstanceOf, sym(3).Expression);
node->operatorToken = loc(2);
sym(1).Node = node;
} break;
-case 151: {
+case 160: {
AST::BinaryExpression *node = makeAstNode<AST::BinaryExpression> (driver->nodePool(), sym(1).Expression,
QSOperator::Equal, sym(3).Expression);
node->operatorToken = loc(2);
sym(1).Node = node;
} break;
-case 152: {
+case 161: {
AST::BinaryExpression *node = makeAstNode<AST::BinaryExpression> (driver->nodePool(), sym(1).Expression,
QSOperator::NotEqual, sym(3).Expression);
node->operatorToken = loc(2);
sym(1).Node = node;
} break;
-case 153: {
+case 162: {
AST::BinaryExpression *node = makeAstNode<AST::BinaryExpression> (driver->nodePool(), sym(1).Expression,
QSOperator::StrictEqual, sym(3).Expression);
node->operatorToken = loc(2);
sym(1).Node = node;
} break;
-case 154: {
+case 163: {
AST::BinaryExpression *node = makeAstNode<AST::BinaryExpression> (driver->nodePool(), sym(1).Expression,
QSOperator::StrictNotEqual, sym(3).Expression);
node->operatorToken = loc(2);
sym(1).Node = node;
} break;
-case 156: {
+case 165: {
AST::BinaryExpression *node = makeAstNode<AST::BinaryExpression> (driver->nodePool(), sym(1).Expression,
QSOperator::Equal, sym(3).Expression);
node->operatorToken = loc(2);
sym(1).Node = node;
} break;
-case 157: {
+case 166: {
AST::BinaryExpression *node = makeAstNode<AST::BinaryExpression> (driver->nodePool(), sym(1).Expression,
QSOperator::NotEqual, sym(3).Expression);
node->operatorToken = loc(2);
sym(1).Node = node;
} break;
-case 158: {
+case 167: {
AST::BinaryExpression *node = makeAstNode<AST::BinaryExpression> (driver->nodePool(), sym(1).Expression,
QSOperator::StrictEqual, sym(3).Expression);
node->operatorToken = loc(2);
sym(1).Node = node;
} break;
-case 159: {
+case 168: {
AST::BinaryExpression *node = makeAstNode<AST::BinaryExpression> (driver->nodePool(), sym(1).Expression,
QSOperator::StrictNotEqual, sym(3).Expression);
node->operatorToken = loc(2);
sym(1).Node = node;
} break;
-case 161: {
+case 170: {
AST::BinaryExpression *node = makeAstNode<AST::BinaryExpression> (driver->nodePool(), sym(1).Expression,
QSOperator::BitAnd, sym(3).Expression);
node->operatorToken = loc(2);
sym(1).Node = node;
} break;
-case 163: {
+case 172: {
AST::BinaryExpression *node = makeAstNode<AST::BinaryExpression> (driver->nodePool(), sym(1).Expression,
QSOperator::BitAnd, sym(3).Expression);
node->operatorToken = loc(2);
sym(1).Node = node;
} break;
-case 165: {
+case 174: {
AST::BinaryExpression *node = makeAstNode<AST::BinaryExpression> (driver->nodePool(), sym(1).Expression,
QSOperator::BitXor, sym(3).Expression);
node->operatorToken = loc(2);
sym(1).Node = node;
} break;
-case 167: {
+case 176: {
AST::BinaryExpression *node = makeAstNode<AST::BinaryExpression> (driver->nodePool(), sym(1).Expression,
QSOperator::BitXor, sym(3).Expression);
node->operatorToken = loc(2);
sym(1).Node = node;
} break;
-case 169: {
+case 178: {
AST::BinaryExpression *node = makeAstNode<AST::BinaryExpression> (driver->nodePool(), sym(1).Expression,
QSOperator::BitOr, sym(3).Expression);
node->operatorToken = loc(2);
sym(1).Node = node;
} break;
-case 171: {
+case 180: {
AST::BinaryExpression *node = makeAstNode<AST::BinaryExpression> (driver->nodePool(), sym(1).Expression,
QSOperator::BitOr, sym(3).Expression);
node->operatorToken = loc(2);
sym(1).Node = node;
} break;
-case 173: {
+case 182: {
AST::BinaryExpression *node = makeAstNode<AST::BinaryExpression> (driver->nodePool(), sym(1).Expression,
QSOperator::And, sym(3).Expression);
node->operatorToken = loc(2);
sym(1).Node = node;
} break;
-case 175: {
+case 184: {
AST::BinaryExpression *node = makeAstNode<AST::BinaryExpression> (driver->nodePool(), sym(1).Expression,
QSOperator::And, sym(3).Expression);
node->operatorToken = loc(2);
sym(1).Node = node;
} break;
-case 177: {
+case 186: {
AST::BinaryExpression *node = makeAstNode<AST::BinaryExpression> (driver->nodePool(), sym(1).Expression,
QSOperator::Or, sym(3).Expression);
node->operatorToken = loc(2);
sym(1).Node = node;
} break;
-case 179: {
+case 188: {
AST::BinaryExpression *node = makeAstNode<AST::BinaryExpression> (driver->nodePool(), sym(1).Expression,
QSOperator::Or, sym(3).Expression);
node->operatorToken = loc(2);
sym(1).Node = node;
} break;
-case 181: {
+case 190: {
AST::ConditionalExpression *node = makeAstNode<AST::ConditionalExpression> (driver->nodePool(), sym(1).Expression,
sym(3).Expression, sym(5).Expression);
node->questionToken = loc(2);
@@ -994,7 +1028,7 @@ case 181: {
sym(1).Node = node;
} break;
-case 183: {
+case 192: {
AST::ConditionalExpression *node = makeAstNode<AST::ConditionalExpression> (driver->nodePool(), sym(1).Expression,
sym(3).Expression, sym(5).Expression);
node->questionToken = loc(2);
@@ -1002,112 +1036,112 @@ case 183: {
sym(1).Node = node;
} break;
-case 185: {
+case 194: {
AST::BinaryExpression *node = makeAstNode<AST::BinaryExpression> (driver->nodePool(), sym(1).Expression,
sym(2).ival, sym(3).Expression);
node->operatorToken = loc(2);
sym(1).Node = node;
} break;
-case 187: {
+case 196: {
AST::BinaryExpression *node = makeAstNode<AST::BinaryExpression> (driver->nodePool(), sym(1).Expression,
sym(2).ival, sym(3).Expression);
node->operatorToken = loc(2);
sym(1).Node = node;
} break;
-case 188: {
+case 197: {
sym(1).ival = QSOperator::Assign;
} break;
-case 189: {
+case 198: {
sym(1).ival = QSOperator::InplaceMul;
} break;
-case 190: {
+case 199: {
sym(1).ival = QSOperator::InplaceDiv;
} break;
-case 191: {
+case 200: {
sym(1).ival = QSOperator::InplaceMod;
} break;
-case 192: {
+case 201: {
sym(1).ival = QSOperator::InplaceAdd;
} break;
-case 193: {
+case 202: {
sym(1).ival = QSOperator::InplaceSub;
} break;
-case 194: {
+case 203: {
sym(1).ival = QSOperator::InplaceLeftShift;
} break;
-case 195: {
+case 204: {
sym(1).ival = QSOperator::InplaceRightShift;
} break;
-case 196: {
+case 205: {
sym(1).ival = QSOperator::InplaceURightShift;
} break;
-case 197: {
+case 206: {
sym(1).ival = QSOperator::InplaceAnd;
} break;
-case 198: {
+case 207: {
sym(1).ival = QSOperator::InplaceXor;
} break;
-case 199: {
+case 208: {
sym(1).ival = QSOperator::InplaceOr;
} break;
-case 201: {
+case 210: {
AST::Expression *node = makeAstNode<AST::Expression> (driver->nodePool(), sym(1).Expression, sym(3).Expression);
node->commaToken = loc(2);
sym(1).Node = node;
} break;
-case 202: {
+case 211: {
sym(1).Node = 0;
} break;
-case 205: {
+case 214: {
AST::Expression *node = makeAstNode<AST::Expression> (driver->nodePool(), sym(1).Expression, sym(3).Expression);
node->commaToken = loc(2);
sym(1).Node = node;
} break;
-case 206: {
+case 215: {
sym(1).Node = 0;
} break;
-case 223: {
+case 232: {
AST::Block *node = makeAstNode<AST::Block> (driver->nodePool(), sym(2).StatementList);
node->lbraceToken = loc(1);
node->rbraceToken = loc(3);
sym(1).Node = node;
} break;
-case 224: {
+case 233: {
sym(1).Node = makeAstNode<AST::StatementList> (driver->nodePool(), sym(1).Statement);
} break;
-case 225: {
+case 234: {
sym(1).Node = makeAstNode<AST::StatementList> (driver->nodePool(), sym(1).StatementList, sym(2).Statement);
} break;
-case 226: {
+case 235: {
sym(1).Node = 0;
} break;
-case 227: {
+case 236: {
sym(1).Node = sym(1).StatementList->finish ();
} break;
-case 229: {
+case 238: {
AST::VariableStatement *node = makeAstNode<AST::VariableStatement> (driver->nodePool(),
sym(2).VariableDeclarationList->finish (/*readOnly=*/sym(1).ival == T_CONST));
node->declarationKindToken = loc(1);
@@ -1115,76 +1149,76 @@ case 229: {
sym(1).Node = node;
} break;
-case 230: {
+case 239: {
sym(1).ival = T_CONST;
} break;
-case 231: {
+case 240: {
sym(1).ival = T_VAR;
} break;
-case 232: {
+case 241: {
sym(1).Node = makeAstNode<AST::VariableDeclarationList> (driver->nodePool(), sym(1).VariableDeclaration);
} break;
-case 233: {
+case 242: {
AST::VariableDeclarationList *node = makeAstNode<AST::VariableDeclarationList> (driver->nodePool(),
sym(1).VariableDeclarationList, sym(3).VariableDeclaration);
node->commaToken = loc(2);
sym(1).Node = node;
} break;
-case 234: {
+case 243: {
sym(1).Node = makeAstNode<AST::VariableDeclarationList> (driver->nodePool(), sym(1).VariableDeclaration);
} break;
-case 235: {
+case 244: {
sym(1).Node = makeAstNode<AST::VariableDeclarationList> (driver->nodePool(), sym(1).VariableDeclarationList, sym(3).VariableDeclaration);
} break;
-case 236: {
+case 245: {
AST::VariableDeclaration *node = makeAstNode<AST::VariableDeclaration> (driver->nodePool(), sym(1).sval, sym(2).Expression);
node->identifierToken = loc(1);
sym(1).Node = node;
} break;
-case 237: {
+case 246: {
AST::VariableDeclaration *node = makeAstNode<AST::VariableDeclaration> (driver->nodePool(), sym(1).sval, sym(2).Expression);
node->identifierToken = loc(1);
sym(1).Node = node;
} break;
-case 238: {
+case 247: {
// ### TODO: AST for initializer
sym(1) = sym(2);
} break;
-case 239: {
+case 248: {
sym(1).Node = 0;
} break;
-case 241: {
+case 250: {
// ### TODO: AST for initializer
sym(1) = sym(2);
} break;
-case 242: {
+case 251: {
sym(1).Node = 0;
} break;
-case 244: {
+case 253: {
AST::EmptyStatement *node = makeAstNode<AST::EmptyStatement> (driver->nodePool());
node->semicolonToken = loc(1);
sym(1).Node = node;
} break;
-case 246: {
+case 255: {
AST::ExpressionStatement *node = makeAstNode<AST::ExpressionStatement> (driver->nodePool(), sym(1).Expression);
node->semicolonToken = loc(2);
sym(1).Node = node;
} break;
-case 247: {
+case 256: {
AST::IfStatement *node = makeAstNode<AST::IfStatement> (driver->nodePool(), sym(3).Expression, sym(5).Statement, sym(7).Statement);
node->ifToken = loc(1);
node->lparenToken = loc(2);
@@ -1193,7 +1227,7 @@ case 247: {
sym(1).Node = node;
} break;
-case 248: {
+case 257: {
AST::IfStatement *node = makeAstNode<AST::IfStatement> (driver->nodePool(), sym(3).Expression, sym(5).Statement);
node->ifToken = loc(1);
node->lparenToken = loc(2);
@@ -1201,7 +1235,7 @@ case 248: {
sym(1).Node = node;
} break;
-case 250: {
+case 259: {
AST::DoWhileStatement *node = makeAstNode<AST::DoWhileStatement> (driver->nodePool(), sym(2).Statement, sym(5).Expression);
node->doToken = loc(1);
node->whileToken = loc(3);
@@ -1211,7 +1245,7 @@ case 250: {
sym(1).Node = node;
} break;
-case 251: {
+case 260: {
AST::WhileStatement *node = makeAstNode<AST::WhileStatement> (driver->nodePool(), sym(3).Expression, sym(5).Statement);
node->whileToken = loc(1);
node->lparenToken = loc(2);
@@ -1219,7 +1253,7 @@ case 251: {
sym(1).Node = node;
} break;
-case 252: {
+case 261: {
AST::ForStatement *node = makeAstNode<AST::ForStatement> (driver->nodePool(), sym(3).Expression,
sym(5).Expression, sym(7).Expression, sym(9).Statement);
node->forToken = loc(1);
@@ -1230,7 +1264,7 @@ case 252: {
sym(1).Node = node;
} break;
-case 253: {
+case 262: {
AST::LocalForStatement *node = makeAstNode<AST::LocalForStatement> (driver->nodePool(),
sym(4).VariableDeclarationList->finish (/*readOnly=*/false), sym(6).Expression,
sym(8).Expression, sym(10).Statement);
@@ -1243,7 +1277,7 @@ case 253: {
sym(1).Node = node;
} break;
-case 254: {
+case 263: {
AST:: ForEachStatement *node = makeAstNode<AST::ForEachStatement> (driver->nodePool(), sym(3).Expression,
sym(5).Expression, sym(7).Statement);
node->forToken = loc(1);
@@ -1253,7 +1287,7 @@ case 254: {
sym(1).Node = node;
} break;
-case 255: {
+case 264: {
AST::LocalForEachStatement *node = makeAstNode<AST::LocalForEachStatement> (driver->nodePool(),
sym(4).VariableDeclaration, sym(6).Expression, sym(8).Statement);
node->forToken = loc(1);
@@ -1264,14 +1298,14 @@ case 255: {
sym(1).Node = node;
} break;
-case 257: {
+case 266: {
AST::ContinueStatement *node = makeAstNode<AST::ContinueStatement> (driver->nodePool());
node->continueToken = loc(1);
node->semicolonToken = loc(2);
sym(1).Node = node;
} break;
-case 259: {
+case 268: {
AST::ContinueStatement *node = makeAstNode<AST::ContinueStatement> (driver->nodePool(), sym(2).sval);
node->continueToken = loc(1);
node->identifierToken = loc(2);
@@ -1279,14 +1313,14 @@ case 259: {
sym(1).Node = node;
} break;
-case 261: {
+case 270: {
AST::BreakStatement *node = makeAstNode<AST::BreakStatement> (driver->nodePool());
node->breakToken = loc(1);
node->semicolonToken = loc(2);
sym(1).Node = node;
} break;
-case 263: {
+case 272: {
AST::BreakStatement *node = makeAstNode<AST::BreakStatement> (driver->nodePool(), sym(2).sval);
node->breakToken = loc(1);
node->identifierToken = loc(2);
@@ -1294,14 +1328,14 @@ case 263: {
sym(1).Node = node;
} break;
-case 265: {
+case 274: {
AST::ReturnStatement *node = makeAstNode<AST::ReturnStatement> (driver->nodePool(), sym(2).Expression);
node->returnToken = loc(1);
node->semicolonToken = loc(3);
sym(1).Node = node;
} break;
-case 266: {
+case 275: {
AST::WithStatement *node = makeAstNode<AST::WithStatement> (driver->nodePool(), sym(3).Expression, sym(5).Statement);
node->withToken = loc(1);
node->lparenToken = loc(2);
@@ -1309,7 +1343,7 @@ case 266: {
sym(1).Node = node;
} break;
-case 267: {
+case 276: {
AST::SwitchStatement *node = makeAstNode<AST::SwitchStatement> (driver->nodePool(), sym(3).Expression, sym(5).CaseBlock);
node->switchToken = loc(1);
node->lparenToken = loc(2);
@@ -1317,83 +1351,90 @@ case 267: {
sym(1).Node = node;
} break;
-case 268: {
+case 277: {
AST::CaseBlock *node = makeAstNode<AST::CaseBlock> (driver->nodePool(), sym(2).CaseClauses);
node->lbraceToken = loc(1);
node->rbraceToken = loc(3);
sym(1).Node = node;
} break;
-case 269: {
+case 278: {
AST::CaseBlock *node = makeAstNode<AST::CaseBlock> (driver->nodePool(), sym(2).CaseClauses, sym(3).DefaultClause, sym(4).CaseClauses);
node->lbraceToken = loc(1);
node->rbraceToken = loc(5);
sym(1).Node = node;
} break;
-case 270: {
+case 279: {
sym(1).Node = makeAstNode<AST::CaseClauses> (driver->nodePool(), sym(1).CaseClause);
} break;
-case 271: {
+case 280: {
sym(1).Node = makeAstNode<AST::CaseClauses> (driver->nodePool(), sym(1).CaseClauses, sym(2).CaseClause);
} break;
-case 272: {
+case 281: {
sym(1).Node = 0;
} break;
-case 273: {
+case 282: {
sym(1).Node = sym(1).CaseClauses->finish ();
} break;
-case 274: {
+case 283: {
AST::CaseClause *node = makeAstNode<AST::CaseClause> (driver->nodePool(), sym(2).Expression, sym(4).StatementList);
node->caseToken = loc(1);
node->colonToken = loc(3);
sym(1).Node = node;
} break;
-case 275: {
+case 284: {
AST::DefaultClause *node = makeAstNode<AST::DefaultClause> (driver->nodePool(), sym(3).StatementList);
node->defaultToken = loc(1);
node->colonToken = loc(2);
sym(1).Node = node;
} break;
+case 285:
+case 286: {
+ AST::LabelledStatement *node = makeAstNode<AST::LabelledStatement> (driver->nodePool(), driver->intern(lexer->characterBuffer(), lexer->characterCount()), sym(3).Statement);
+ node->identifierToken = loc(1);
+ node->colonToken = loc(2);
+ sym(1).Node = node;
+} break;
-case 276: {
+case 287: {
AST::LabelledStatement *node = makeAstNode<AST::LabelledStatement> (driver->nodePool(), sym(1).sval, sym(3).Statement);
node->identifierToken = loc(1);
node->colonToken = loc(2);
sym(1).Node = node;
} break;
-case 278: {
+case 289: {
AST::ThrowStatement *node = makeAstNode<AST::ThrowStatement> (driver->nodePool(), sym(2).Expression);
node->throwToken = loc(1);
node->semicolonToken = loc(3);
sym(1).Node = node;
} break;
-case 279: {
+case 290: {
AST::TryStatement *node = makeAstNode<AST::TryStatement> (driver->nodePool(), sym(2).Statement, sym(3).Catch);
node->tryToken = loc(1);
sym(1).Node = node;
} break;
-case 280: {
+case 291: {
AST::TryStatement *node = makeAstNode<AST::TryStatement> (driver->nodePool(), sym(2).Statement, sym(3).Finally);
node->tryToken = loc(1);
sym(1).Node = node;
} break;
-case 281: {
+case 292: {
AST::TryStatement *node = makeAstNode<AST::TryStatement> (driver->nodePool(), sym(2).Statement, sym(3).Catch, sym(4).Finally);
node->tryToken = loc(1);
sym(1).Node = node;
} break;
-case 282: {
+case 293: {
AST::Catch *node = makeAstNode<AST::Catch> (driver->nodePool(), sym(3).sval, sym(5).Block);
node->catchToken = loc(1);
node->lparenToken = loc(2);
@@ -1402,20 +1443,20 @@ case 282: {
sym(1).Node = node;
} break;
-case 283: {
+case 294: {
AST::Finally *node = makeAstNode<AST::Finally> (driver->nodePool(), sym(2).Block);
node->finallyToken = loc(1);
sym(1).Node = node;
} break;
-case 285: {
+case 296: {
AST::DebuggerStatement *node = makeAstNode<AST::DebuggerStatement> (driver->nodePool());
node->debuggerToken = loc(1);
node->semicolonToken = loc(2);
sym(1).Node = node;
} break;
-case 286: {
+case 297: {
AST::FunctionDeclaration *node = makeAstNode<AST::FunctionDeclaration> (driver->nodePool(), sym(2).sval, sym(4).FormalParameterList, sym(7).FunctionBody);
node->functionToken = loc(1);
node->identifierToken = loc(2);
@@ -1426,7 +1467,7 @@ case 286: {
sym(1).Node = node;
} break;
-case 287: {
+case 298: {
AST::FunctionExpression *node = makeAstNode<AST::FunctionExpression> (driver->nodePool(), sym(2).sval, sym(4).FormalParameterList, sym(7).FunctionBody);
node->functionToken = loc(1);
if (sym(2).sval)
@@ -1438,56 +1479,56 @@ case 287: {
sym(1).Node = node;
} break;
-case 288: {
+case 299: {
AST::FormalParameterList *node = makeAstNode<AST::FormalParameterList> (driver->nodePool(), sym(1).sval);
node->identifierToken = loc(1);
sym(1).Node = node;
} break;
-case 289: {
+case 300: {
AST::FormalParameterList *node = makeAstNode<AST::FormalParameterList> (driver->nodePool(), sym(1).FormalParameterList, sym(3).sval);
node->commaToken = loc(2);
node->identifierToken = loc(3);
sym(1).Node = node;
} break;
-case 290: {
+case 301: {
sym(1).Node = 0;
} break;
-case 291: {
+case 302: {
sym(1).Node = sym(1).FormalParameterList->finish ();
} break;
-case 292: {
+case 303: {
sym(1).Node = 0;
} break;
-case 294: {
+case 305: {
sym(1).Node = makeAstNode<AST::FunctionBody> (driver->nodePool(), sym(1).SourceElements->finish ());
} break;
-case 295: {
+case 306: {
sym(1).Node = makeAstNode<AST::SourceElements> (driver->nodePool(), sym(1).SourceElement);
} break;
-case 296: {
+case 307: {
sym(1).Node = makeAstNode<AST::SourceElements> (driver->nodePool(), sym(1).SourceElements, sym(2).SourceElement);
} break;
-case 297: {
+case 308: {
sym(1).Node = makeAstNode<AST::StatementSourceElement> (driver->nodePool(), sym(1).Statement);
} break;
-case 298: {
+case 309: {
sym(1).Node = makeAstNode<AST::FunctionSourceElement> (driver->nodePool(), sym(1).FunctionDeclaration);
} break;
-case 299: {
+case 310: {
sym(1).sval = 0;
} break;
-case 301: {
+case 312: {
sym(1).Node = 0;
} break;
diff --git a/src/declarative/qml/parser/javascriptparser_p.h b/src/declarative/qml/parser/javascriptparser_p.h
index 34f41a8..497fae8 100644
--- a/src/declarative/qml/parser/javascriptparser_p.h
+++ b/src/declarative/qml/parser/javascriptparser_p.h
@@ -206,9 +206,9 @@ protected:
};
-#define J_SCRIPT_REGEXPLITERAL_RULE1 43
+#define J_SCRIPT_REGEXPLITERAL_RULE1 50
-#define J_SCRIPT_REGEXPLITERAL_RULE2 44
+#define J_SCRIPT_REGEXPLITERAL_RULE2 51
QT_END_NAMESPACE
diff --git a/src/declarative/qml/qmlcomponent.cpp b/src/declarative/qml/qmlcomponent.cpp
index 2c3ebd6..c316f03 100644
--- a/src/declarative/qml/qmlcomponent.cpp
+++ b/src/declarative/qml/qmlcomponent.cpp
@@ -89,16 +89,20 @@ bool QmlComponentPrivate::isXml(const QByteArray &ba)
file, or for defining a component that logically belongs with the
file containing it.
- \code
- <Item>
- <Component id="RedSquare">
- <Rect color="red" width="10" height="10"/>
- </Component>
-
- <ComponentInstance component="{RedSquare}"/>
- <ComponentInstance component="{RedSquare}" x="20"/>
- </Item>
- \endcode
+ \qml
+Item {
+ Component {
+ id: RedSquare
+ Rect {
+ color: "red"
+ width: 10
+ height: 10
+ }
+ }
+ ComponentInstance { component: RedSquare }
+ ComponentInstance { component: RedSquare; x: 20 }
+}
+ \endqml
*/
QML_DEFINE_TYPE(QmlComponent,Component);
diff --git a/src/declarative/qml/qmlcontext.cpp b/src/declarative/qml/qmlcontext.cpp
index c1acdc7..30857ad 100644
--- a/src/declarative/qml/qmlcontext.cpp
+++ b/src/declarative/qml/qmlcontext.cpp
@@ -261,10 +261,10 @@ QmlContext *QmlContext::parentContext() const
Add a default \a object to this context. The object will be added after
any existing default objects.
*/
-void QmlContext::addDefaultObject(QObject *defaultObject)
+void QmlContext::addDefaultObject(QObject *object)
{
Q_D(QmlContext);
- d->addDefaultObject(defaultObject, QmlContextPrivate::NormalPriority);
+ d->addDefaultObject(object, QmlContextPrivate::NormalPriority);
}
/*!
@@ -340,13 +340,11 @@ QmlContext *QmlContext::activeContext()
/*!
Resolves the URL \a src relative to the URL of the
- containing component.
+ containing component. If \a src is absolute, it is
+ simply returned. If there is no containing component,
+ an empty URL is returned.
- If \a src is absolute, it is simply returned.
-
- If there is no containing component, an empty URL is returned.
-
- \sa componentUrl
+ \sa QmlEngine::componentUrl()
*/
QUrl QmlContext::resolvedUrl(const QUrl &src)
{
@@ -372,10 +370,10 @@ QUrl QmlContext::resolvedUrl(const QUrl &src)
/*!
Resolves the component URI \a src relative to the URL of the
containing component, and according to the
- \link QmlEngine::nameSpacePaths() namespace paths\endlink of the
+ \l {QmlEngine::nameSpacePaths()} {namespace paths} of the
context's engine, returning the resolved URL.
- \sa componentUrl
+ \sa QmlEngine::componentUrl()
*/
QUrl QmlContext::resolvedUri(const QUrl &src)
{
diff --git a/src/declarative/qml/qmldom.cpp b/src/declarative/qml/qmldom.cpp
index 937c244..5380740 100644
--- a/src/declarative/qml/qmldom.cpp
+++ b/src/declarative/qml/qmldom.cpp
@@ -154,12 +154,6 @@ bool QmlDomDocument::load(QmlEngine *engine, const QByteArray &data)
d->error = QString();
- QmlScriptParser parser;
- if (!parser.parse(data)) {
- d->error = parser.errorDescription();
- return false;
- }
-
QmlCompiledComponent component;
QmlCompiler compiler;
@@ -184,8 +178,8 @@ bool QmlDomDocument::load(QmlEngine *engine, const QByteArray &data)
}
if (td->data.tree()) {
- component.dump(0, parser.tree());
- d->root = parser.tree();
+ component.dump(0, td->data.tree());
+ d->root = td->data.tree();
d->root->addref();
}
@@ -220,11 +214,13 @@ QByteArray QmlDomDocument::save() const
document has no root.
In the sample QML below, the root object will be the QFxItem type.
- \code
- <Item>
- <Text text="Hello World" />
- </Item>
- \endcode
+ \qml
+Item {
+ Text {
+ text: "Hello World"
+ }
+}
+ \endqml
*/
QmlDomObject QmlDomDocument::rootObject() const
{
@@ -296,9 +292,13 @@ QmlDomProperty &QmlDomProperty::operator=(const QmlDomProperty &other)
/*!
Return the name of this property.
- \code
- <Text x="10" y="10" font.bold="true" />
- \endcode
+ \qml
+Text {
+ x: 10
+ y: 10
+ font.bold: true
+}
+ \endqml
As illustrated above, a property name can be a simple string, such as "x" or
"y", or a more complex "dot property", such as "font.bold". In both cases
@@ -318,9 +318,13 @@ QByteArray QmlDomProperty::propertyName() const
Return the name of this property, split into multiple parts in the case
of dot properties.
- \code
- <Text x="10" y="10" font.bold="true" />
- \endcode
+ \qml
+Text {
+ x: 10
+ y: 10
+ font.bold: true
+}
+ \endqml
For each of the properties shown above, this method would return ("x"),
("y") and ("font", "bold").
@@ -337,10 +341,10 @@ QList<QByteArray> QmlDomProperty::propertyNameParts() const
Return true if this property is used as a default property in the QML
document.
- \code
- <Text text="hello" />
- <Text>hello</Text>
- \endcode
+ \qml
+<Text text="hello"/>
+<Text>hello</Text>
+ \endqml
The above two examples return the same DOM tree, except that the second has
the default property flag set on the text property. Observe that whether
@@ -456,9 +460,12 @@ QmlDomObjectPrivate::properties(QmlParser::Property *property) const
Each QmlDomProperty represents a QML property assignment on the instantiated
object. For example,
- \code
- <QGraphicsWidget opacity="0.5" size="100x100" />
- \endcode
+ \qml
+QGraphicsWidget {
+ opacity: 0.5
+ size: "100x100"
+}
+ \endqml
describes a single QmlDomObject - "QGraphicsWidget" - with two properties,
"opacity" and "size". Obviously QGraphicsWidget has many more properties than just
@@ -525,9 +532,9 @@ bool QmlDomObject::isValid() const
Returns the type name of this object.
For example, the type of this object would be "QGraphicsWidget".
- \code
- <QGraphicsWidget />
- \endcode
+ \qml
+QGraphicsWidget { }
+ \endqml
*/
QByteArray QmlDomObject::objectType() const
{
@@ -540,9 +547,9 @@ QByteArray QmlDomObject::objectType() const
has been assigned.
For example, the object id of this object would be "MyText".
- \code
- <Text id="MyText" />
- \endcode
+ \qml
+Text { id: MyText }
+ \endqml
*/
QByteArray QmlDomObject::objectId() const
{
@@ -565,9 +572,12 @@ void QmlDomObject::setObjectId(const QByteArray &id)
Returns the list of assigned properties on this object.
In the following example, "text" and "x" properties would be returned.
- \code
- <Text text="Hello world!" x="100" />
- \endcode
+ \qml
+Text {
+ text: "Hello world!"
+ x: 100
+}
+ \endqml
*/
QList<QmlDomProperty> QmlDomObject::properties() const
{
@@ -602,12 +612,12 @@ QList<QmlDomProperty> QmlDomObject::properties() const
Returns the object's \a name property if a value has been assigned to
it, or an invalid QmlDomProperty otherwise.
- In the example below, \c {object.property("src")} would return a valid
+ In the example below, \c {object.property("source")} would return a valid
QmlDomProperty, and \c {object.property("tile")} an invalid QmlDomProperty.
- \code
- <Image src="sample.jpg" />
- \endcode
+ \qml
+Image { source: "sample.jpg" }
+ \endqml
*/
QmlDomProperty QmlDomObject::property(const QByteArray &name) const
{
@@ -730,9 +740,13 @@ QmlDomBasicValuePrivate::~QmlDomBasicValuePrivate()
example below, the "x", "y" and "color" properties are being assigned
literal values.
- \code
- <Rect x="10" y="10" color="red" />
- \endcode
+ \qml
+Rect {
+ x: 10
+ y: 10
+ color: "red"
+}
+ \endqml
*/
/*!
@@ -771,9 +785,9 @@ QmlDomValueLiteral &QmlDomValueLiteral::operator=(const QmlDomValueLiteral &othe
Return the literal value.
In the example below, the literal value will be the string "10".
- \code
- <Rect x="10" />
- \endcode
+ \qml
+Rect { x: 10 }
+ \endqml
*/
QString QmlDomValueLiteral::literal() const
{
@@ -797,15 +811,16 @@ void QmlDomValueLiteral::setLiteral(const QString &value)
A property binding is an ECMAScript expression assigned to a property. In
the example below, the "x" property is being assigned a property binding.
- \code
- <Rect x="{Other.x}" />
- \endcode
+ \qml
+Rect { x: Other.x }
+ \endqml
*/
/*!
Construct an empty QmlDomValueBinding.
*/
-QmlDomValueBinding::QmlDomValueBinding()
+QmlDomValueBinding::QmlDomValueBinding():
+ d(new QmlDomBasicValuePrivate)
{
}
@@ -837,9 +852,9 @@ QmlDomValueBinding &QmlDomValueBinding::operator=(const QmlDomValueBinding &othe
Return the binding expression.
In the example below, the string "Other.x" will be returned.
- \code
- <Rect x="{Other.x}" />
- \endcode
+ \qml
+Rect { x: Other.x }
+ \endqml
*/
QString QmlDomValueBinding::binding() const
{
@@ -867,19 +882,23 @@ void QmlDomValueBinding::setBinding(const QString &expression)
class. In the example below, the "x" property is being assigned the
NumericAnimation value source.
- \code
- <Rect>
- <x>
- <NumericAnimation from="0" to="100" repeat="true" running="true" />
- </x>
- </Rect>
- \endcode
+ \qml
+Rect {
+ x: NumericAnimation {
+ from: 0
+ to: 100
+ repeat: true
+ running: true
+ }
+}
+ \endqml
*/
/*!
Construct an empty QmlDomValueValueSource.
*/
-QmlDomValueValueSource::QmlDomValueValueSource()
+QmlDomValueValueSource::QmlDomValueValueSource():
+ d(new QmlDomBasicValuePrivate)
{
}
@@ -912,13 +931,16 @@ QmlDomValueValueSource &QmlDomValueValueSource::operator=(const QmlDomValueValue
In the example below, an object representing the NumericAnimation will be
returned.
- \code
- <Rect>
- <x>
- <NumericAnimation from="0" to="100" repeat="true" running="true" />
- </x>
- </Rect>
- \endcode
+ \qml
+Rect {
+ x: NumericAnimation {
+ from: 0
+ to: 100
+ repeat: true
+ running: true
+ }
+}
+ \endqml
*/
QmlDomObject QmlDomValueValueSource::object() const
{
@@ -927,7 +949,7 @@ QmlDomObject QmlDomValueValueSource::object() const
rv.d->object = d->value->object;
rv.d->object->addref();
}
- return QmlDomObject();
+ return rv;
}
/*!
@@ -972,9 +994,12 @@ QmlDomValuePrivate::~QmlDomValuePrivate()
For example, in the following example,
- \code
- <Text text="Hello World!" y="{Other.y}" />
- \endcode
+ \qml
+Text {
+ text: "Hello World!"
+ y: Other.y
+}
+ \endqml
The text property is being assigned a literal, and the y property a property
binding. To output the values assigned to the text and y properties in the
@@ -1213,24 +1238,27 @@ QmlDomList QmlDomValue::toList() const
Lists of values can be assigned to properties. For example, the following
example assigns multiple objects to Item's "children" property
- \code
- <Item>
- <children>
- <Text />
- <Rect />
- </children>
- </Item>
- \endcode
+ \qml
+Item {
+ children: [
+ Text { },
+ Rect { }
+ ]
+}
+ \endqml
Lists can also be implicitly created by assigning multiple
\l {QmlDomValueValueSource}{value sources} or constants to a property.
- \code
- <Item x="10">
- <x>
- <NumericAnimation running="false" from="0" to="100" />
- </x>
- </Item>
- \endcode
+ \qml
+Item {
+ x: 10
+ x: NumericAnimation {
+ running: false
+ from: 0
+ to: 100
+ }
+}
+ \endqml
*/
/*!
@@ -1301,13 +1329,16 @@ void QmlDomList::setValues(const QList<QmlDomValue> &values)
following example shows the definition of a sub-component with the id
"ListDelegate".
- \code
- <Item>
- <Component id="ListDelegate">
- <Text text="{modelData.text}" />
- </Component>
- </Item>
- \endcode
+ \qml
+Item {
+ Component {
+ id: ListDelegate
+ Text {
+ text: modelData.text
+ }
+ }
+}
+ \endqml
Like QmlDomDocument's, components contain a single root object.
*/
@@ -1347,13 +1378,16 @@ QmlDomComponent &QmlDomComponent::operator=(const QmlDomComponent &other)
Returns the component's root object.
In the example below, the root object is the "Text" object.
- \code
- <Item>
- <Component id="ListDelegate">
- <Text text="{modelData.text}" />
- </Component>
- </Item>
- \endcode
+ \qml
+Item {
+ Component {
+ id: ListDelegate
+ Text {
+ text: modelData.text
+ }
+ }
+}
+ \endqml
*/
QmlDomObject QmlDomComponent::componentRoot() const
{
diff --git a/src/declarative/qml/qmlscriptparser.cpp b/src/declarative/qml/qmlscriptparser.cpp
index 61cb2ee..8039b5c 100644
--- a/src/declarative/qml/qmlscriptparser.cpp
+++ b/src/declarative/qml/qmlscriptparser.cpp
@@ -334,49 +334,64 @@ bool ProcessAST::visit(AST::UiImport *node)
// UiMemberType: "property" | "signal"
bool ProcessAST::visit(AST::UiPublicMember *node)
{
- const QString memberType = node->memberType->asString();
- const QString name = node->name->asString();
+ if(node->type == AST::UiPublicMember::Signal) {
+ const QString name = node->name->asString();
- if (node->isDefaultMember)
- qWarning() << "default-ness not implemented";
+ Object::DynamicSignal signal;
+ signal.name = name.toUtf8();
- if (memberType == QLatin1String("property")) {
- _stateStack.pushProperty(QLatin1String("properties"), node->publicToken.startLine);
-
- Object *obj = defineObjectBinding(node->identifierToken.startLine,
- 0,
- QLatin1String("Property"));
-
- _stateStack.pushObject(obj);
-
- defineProperty(QLatin1String("name"), node->identifierToken.startLine, name);
- if (node->expression) // default value
- defineProperty(QLatin1String("value"), node->identifierToken.startLine, getPrimitive("value", node->expression));
-
- _stateStack.pop(); // object
- _stateStack.pop(); // properties
-
- } else if (memberType == QLatin1String("signal")) {
- _stateStack.pushProperty(QLatin1String("signals"), node->publicToken.startLine);
-
- Object *obj = defineObjectBinding(node->identifierToken.startLine,
- 0,
- QLatin1String("Signal"));
+ _stateStack.top().object->dynamicSignals << signal;
+ } else {
+ const QString memberType = node->memberType->asString();
+ const QString name = node->name->asString();
+
+ const struct TypeNameToType {
+ const char *name;
+ Object::DynamicProperty::Type type;
+ } propTypeNameToTypes[] = {
+ { "int", Object::DynamicProperty::Int },
+ { "bool", Object::DynamicProperty::Bool },
+ { "double", Object::DynamicProperty::Real },
+ { "real", Object::DynamicProperty::Real },
+ { "string", Object::DynamicProperty::String },
+ { "color", Object::DynamicProperty::Color },
+ { "date", Object::DynamicProperty::Date },
+ { "var", Object::DynamicProperty::Variant },
+ { "variant", Object::DynamicProperty::Variant }
+ };
+ const int propTypeNameToTypesCount = sizeof(propTypeNameToTypes) /
+ sizeof(propTypeNameToTypes[0]);
+
+ bool typeFound = false;
+ Object::DynamicProperty::Type type;
+ for(int ii = 0; !typeFound && ii < propTypeNameToTypesCount; ++ii) {
+ if(QLatin1String(propTypeNameToTypes[ii].name) == memberType) {
+ type = propTypeNameToTypes[ii].type;
+ typeFound = true;
+ }
+ }
+
+ if(!typeFound) {
+ qWarning() << "Unknown property type" << memberType; // ### FIXME
+ return false;
+ }
- _stateStack.pushObject(obj);
+ Object::DynamicProperty property;
+ property.isDefaultProperty = node->isDefaultMember;
+ property.type = type;
+ property.name = name.toUtf8();
- defineProperty(QLatin1String("name"), node->identifierToken.startLine, name);
+ if (node->expression) { // default value
+ property.defaultValue = new Property;
+ Value *value = new Value;
+ value->primitive = getPrimitive("value", node->expression);
+ property.defaultValue->values << value;
+ }
- _stateStack.pop(); // object
- _stateStack.pop(); // signals
- } else {
- qWarning() << "bad public identifier" << memberType; // ### FIXME
+ _stateStack.top().object->dynamicProperties << property;
}
-
- // ### TODO drop initializer (unless some example needs differnet properties than name and type and value.
-
- return false;
+ return true;
}
diff --git a/src/declarative/qml/script/qmlbasicscript.cpp b/src/declarative/qml/script/qmlbasicscript.cpp
index 8b38e08..603e6ba 100644
--- a/src/declarative/qml/script/qmlbasicscript.cpp
+++ b/src/declarative/qml/script/qmlbasicscript.cpp
@@ -252,6 +252,7 @@ struct QmlBasicScriptCompiler
};
/*!
+ \internal
\class QmlBasicScript
\brief The QmlBasicScript class provides a fast implementation of a limited subset of JavaScript bindings.
diff --git a/src/declarative/test/qfxtestview.cpp b/src/declarative/test/qfxtestview.cpp
index 67b6c15..94bcb30 100644
--- a/src/declarative/test/qfxtestview.cpp
+++ b/src/declarative/test/qfxtestview.cpp
@@ -59,8 +59,8 @@ QFxTestView::QFxTestView(const QString &filename, const QString &testdir)
QFile file(filename);
file.open(QFile::ReadOnly);
- QString xml = QString::fromUtf8(file.readAll());
- setXml(xml, filename);
+ QString qml = QString::fromUtf8(file.readAll());
+ setQml(qml, filename);
execute();
}
diff --git a/src/declarative/timeline/qmltimeline.cpp b/src/declarative/timeline/qmltimeline.cpp
index 3fa0161..dcc8745 100644
--- a/src/declarative/timeline/qmltimeline.cpp
+++ b/src/declarative/timeline/qmltimeline.cpp
@@ -51,10 +51,6 @@
QT_BEGIN_NAMESPACE
-//
-// Timeline stuff
-//
-
struct Update {
Update(QmlTimeLineValue *_g, qreal _v)
: g(_g), v(_v) {}
@@ -868,9 +864,10 @@ void QmlTimeLine::remove(QmlTimeLineObject *v)
}
/*!
+ \internal
\class QmlTimeLineValue
\ingroup group_animation
- \brief The QmlTimeLineValue class is modified by QmlTimeLine.
+ \brief The QmlTimeLineValue class provides a value that can be modified by QmlTimeLine.
*/
/*!
diff --git a/src/declarative/util/qfxview.cpp b/src/declarative/util/qfxview.cpp
index aefe3e4..cac73a0 100644
--- a/src/declarative/util/qfxview.cpp
+++ b/src/declarative/util/qfxview.cpp
@@ -97,7 +97,7 @@ public:
QFxItem *root;
QUrl source;
- QString xml;
+ QString qml;
QmlEngine engine;
QmlComponent *component;
@@ -113,20 +113,15 @@ public:
QFxView currently provides a minimal interface for displaying QML
files, and connecting between QML and C++ Qt objects.
- Typcial usage:
+ Typical usage:
\code
...
QFxView *view = new QFxView(this);
vbox->addWidget(view);
- QFile file(fileName);
- file.open(QFile::ReadOnly);
- QString xml = file.readAll();
- view->setXml(xml, fileName);
-
- QFileInfo fi(file);
- view->setPath(fi.path());
-
+ QUrl url(fileName);
+ view->setUrl(url);
+ ...
view->execute();
...
\endcode
@@ -185,31 +180,31 @@ QFxView::~QFxView()
}
/*!
- Sets the source to the \a url. The XML string is set to
+ Sets the source to the \a url. The QML string is set to
empty.
*/
void QFxView::setUrl(const QUrl& url)
{
d->source = url;
- d->xml = QString();
+ d->qml = QString();
}
/*!
Sets the source to the URL from the \a filename, and sets
- the XML string to \a xml.
+ the QML string to \a qml.
*/
-void QFxView::setXml(const QString &xml, const QString &filename)
+void QFxView::setQml(const QString &qml, const QString &filename)
{
d->source = QUrl::fromLocalFile(filename);
- d->xml = xml;
+ d->qml = qml;
}
/*!
- Returns the XML string.
+ Returns the QML string.
*/
-QString QFxView::xml() const
+QString QFxView::qml() const
{
- return d->xml;
+ return d->qml;
}
/*!
@@ -240,10 +235,10 @@ void QFxView::execute()
{
rootContext()->activate();
- if (d->xml.isEmpty()) {
+ if (d->qml.isEmpty()) {
d->component = new QmlComponent(&d->engine, d->source, this);
} else {
- d->component = new QmlComponent(&d->engine, d->xml.toUtf8(), d->source);
+ d->component = new QmlComponent(&d->engine, d->qml.toUtf8(), d->source);
}
if (!d->component->isLoading()) {
@@ -324,17 +319,17 @@ void QFxView::timerEvent(QTimerEvent* e)
}
/*!
- Creates a \l{QmlComponent} {component} from the \a xml
+ Creates a \l{QmlComponent} {component} from the \a qml
string, and returns it as an \l {QFxItem} {item}. If the
\a parent item is provided, it becomes the new item's
parent. \a parent should be in this view's item hierarchy.
*/
-QFxItem* QFxView::addItem(const QString &xml, QFxItem* parent)
+QFxItem* QFxView::addItem(const QString &qml, QFxItem* parent)
{
if (!d->root)
return 0;
- QmlComponent component(&d->engine, xml.toUtf8(), QUrl());
+ QmlComponent component(&d->engine, qml.toUtf8(), QUrl());
QObject *obj = component.create();
if (obj){
QFxItem *item = static_cast<QFxItem *>(obj);
diff --git a/src/declarative/util/qfxview.h b/src/declarative/util/qfxview.h
index c658f07..d2cacf4 100644
--- a/src/declarative/util/qfxview.h
+++ b/src/declarative/util/qfxview.h
@@ -39,8 +39,8 @@
**
****************************************************************************/
-#ifndef _QFXVIEW_H_
-#define _QFXVIEW_H_
+#ifndef QFXVIEW_H
+#define QFXVIEW_H
#include <qfxglobal.h>
#include <QtCore/qdatetime.h>
@@ -48,12 +48,12 @@
#include <QtGui/qwidget.h>
#include <qsimplecanvas.h>
-
QT_BEGIN_HEADER
QT_BEGIN_NAMESPACE
QT_MODULE(Declarative)
+
class QFxItem;
class QmlEngine;
class QmlContext;
@@ -70,14 +70,14 @@ public:
virtual ~QFxView();
void setUrl(const QUrl&);
- void setXml(const QString &xml, const QString &filename=QString());
- QString xml() const;
+ void setQml(const QString &qml, const QString &filename=QString());
+ QString qml() const;
QmlEngine* engine();
QmlContext* rootContext();
virtual void execute();
virtual void reset();
- virtual QFxItem* addItem(const QString &xml, QFxItem* parent=0);
+ virtual QFxItem* addItem(const QString &qml, QFxItem* parent=0);
virtual void clearItems();
virtual QFxItem *root() const;
@@ -102,8 +102,8 @@ private:
QFxViewPrivate *d;
};
-
QT_END_NAMESPACE
QT_END_HEADER
-#endif // _QFXVIEW_H_
+
+#endif // QFXVIEW_H
diff --git a/src/declarative/util/qmlanimation.cpp b/src/declarative/util/qmlanimation.cpp
index d5765c1..4b8ce4e 100644
--- a/src/declarative/util/qmlanimation.cpp
+++ b/src/declarative/util/qmlanimation.cpp
@@ -617,7 +617,7 @@ QAbstractAnimation *QmlPauseAnimation::qtAnimation()
\brief The ColorAnimation allows you to animate color changes.
\code
- ColorAnimation { from: "white" to: "#c0c0c0"; duration: 100 }
+ ColorAnimation { from: "white"; to: "#c0c0c0"; duration: 100 }
\endcode
The default property animated is \c color, but like other animations,
diff --git a/src/declarative/util/qmlconnection.cpp b/src/declarative/util/qmlconnection.cpp
index 5cd4371..8f6c908 100644
--- a/src/declarative/util/qmlconnection.cpp
+++ b/src/declarative/util/qmlconnection.cpp
@@ -62,7 +62,7 @@ public:
/*!
\qmlclass Connection QmlConnection
- \brief The Connection element describes generalized connections to signals.
+ \brief A Connection object describes generalized connections to signals.
JavaScript-in-HTML style signal properties do not allow:
\list
@@ -73,31 +73,40 @@ public:
\i signals in classes with coincidentally-named on<Signal> properties
\endlist
- When any of these is needed, the Connection element can be used instead.
+ When any of these is needed, the Connection object can be used instead.
Where a signal could be connected like this:
- \code
- <MouseRegion onClicked="foo(x+123,y+456)" />
- \endcode
+ \qml
+MouseRegion {
+ onClicked: { foo(x+123,y+456) }
+}
+ \endqml
- An equivalent binding can be made with a Connection element:
+ An equivalent binding can be made with a Connection object:
- \code
- <MouseRegion>
- <Connection signal="clicked(x,y)" script="foo(x+123,y+456)" />
- </MouseRegion>
- \endcode
+ \qml
+MouseRegion {
+ Connection {
+ signal: "clicked(x,y)"
+ script: { foo(x+123,y+456) }
+ }
+}
+ \endqml
- More generally, the Connection element can be a child of some other element than
+ More generally, the Connection object can be a child of some other object than
the sender of the signal, and the script is the default attribute:
- \code
- <MouseRegion id="mr"/>
- ...
- <Connection sender="{mr}" signal="clicked(x,y)">
- foo(x+123,y+456)
- </Connection>
- \endcode
+ \qml
+MouseRegion {
+ id: mr
+}
+...
+Connection {
+ sender: mr
+ signal: "clicked(x,y)"
+ script: { foo(x+123,y+456) }
+}
+ \endqml
*/
/*!
@@ -257,9 +266,12 @@ void QmlConnection::setScript(const QString& script)
The signal must have its formal parameter names given in parentheses:
- \code
- <Connection signal="clicked(x,y)" ... />
- \endcode
+ \qml
+Connection {
+ signal: "clicked(x,y)"
+ script: { ... }
+}
+ \endqml
*/
/*!
diff --git a/tests/auto/declarative/qmldom/tst_qmldom.cpp b/tests/auto/declarative/qmldom/tst_qmldom.cpp
index 7e7e067..36d37f6 100644
--- a/tests/auto/declarative/qmldom/tst_qmldom.cpp
+++ b/tests/auto/declarative/qmldom/tst_qmldom.cpp
@@ -16,6 +16,8 @@ private slots:
void loadProperties();
void loadChildObject();
+ void testValueSource();
+
private:
QmlEngine engine;
};
@@ -63,7 +65,7 @@ void tst_qmldom::loadProperties()
void tst_qmldom::loadChildObject()
{
- QByteArray qml = "Item { Item }";
+ QByteArray qml = "Item { Item {} }";
//QByteArray qml = "<Item> <Item/> </Item>";
QmlDomDocument document;
@@ -85,6 +87,37 @@ void tst_qmldom::loadChildObject()
QVERIFY(childItem.objectType() == "Item");
}
+void tst_qmldom::testValueSource()
+{
+ QByteArray qml = "Rect { height: Follow { spring: 1.4; damping: .15; source: Math.min(Math.max(-130, value*2.2 - 130), 133); }}";
+
+ QmlEngine freshEngine;
+ QmlDomDocument document;
+ QVERIFY(document.load(&freshEngine, qml));
+
+ QmlDomObject rootItem = document.rootObject();
+ QVERIFY(rootItem.isValid());
+ QmlDomProperty heightProperty = rootItem.properties().at(0);
+ QVERIFY(heightProperty.propertyName() == "height");
+ QVERIFY(heightProperty.value().isValueSource());
+
+ const QmlDomValueValueSource valueSource = heightProperty.value().toValueSource();
+ QmlDomObject valueSourceObject = valueSource.object();
+ QVERIFY(valueSourceObject.isValid());
+
+ QVERIFY(valueSourceObject.objectType() == "Follow");
+
+ const QmlDomValue springValue = valueSourceObject.property("spring").value();
+ QVERIFY(!springValue.isInvalid());
+ QVERIFY(springValue.isLiteral());
+ QVERIFY(springValue.toLiteral().literal() == "1.4");
+
+ const QmlDomValue sourceValue = valueSourceObject.property("source").value();
+ QVERIFY(!sourceValue.isInvalid());
+ QVERIFY(sourceValue.isBinding());
+ QVERIFY(sourceValue.toBinding().binding() == "Math.min(Math.max(-130, value*2.2 - 130), 133)");
+}
+
QTEST_MAIN(tst_qmldom)
#include "tst_qmldom.moc"