diff options
author | Thiago Macieira <thiago.macieira@nokia.com> | 2010-04-01 21:10:46 (GMT) |
---|---|---|
committer | Thiago Macieira <thiago.macieira@nokia.com> | 2010-04-01 21:10:46 (GMT) |
commit | 6b3cd57ffd2646aa41f1509e64f949fc390a961f (patch) | |
tree | 85c9aacfb9cf12fa69571c921e716ff692fdd9cc | |
parent | 8603b43cccccf21ca042ab1ceed2f1ddd873d251 (diff) | |
parent | 37e8fd4e09c1221efde3e67e6acd5cfbb35686fd (diff) | |
download | Qt-6b3cd57ffd2646aa41f1509e64f949fc390a961f.zip Qt-6b3cd57ffd2646aa41f1509e64f949fc390a961f.tar.gz Qt-6b3cd57ffd2646aa41f1509e64f949fc390a961f.tar.bz2 |
Merge remote branch 'origin/4.7' into HEAD
Conflicts:
demos/declarative/minehunt/minehunt.pro
84 files changed, 1903 insertions, 1437 deletions
diff --git a/demos/declarative/minehunt/minehunt.pro b/demos/declarative/minehunt/minehunt.pro index 0b0eac6..7b18bfb 100644 --- a/demos/declarative/minehunt/minehunt.pro +++ b/demos/declarative/minehunt/minehunt.pro @@ -9,7 +9,6 @@ DESTDIR = MinehuntCore # Input SOURCES += minehunt.cpp - sources.files = minehunt.qml minehunt.pro sources.path = $$[QT_INSTALL_DEMOS]/declarative/minehunt diff --git a/doc/src/declarative/advtutorial.qdoc b/doc/src/declarative/advtutorial.qdoc index e420e6d..598f47b 100644 --- a/doc/src/declarative/advtutorial.qdoc +++ b/doc/src/declarative/advtutorial.qdoc @@ -45,11 +45,12 @@ \brief A more advanced tutorial, showing how to use QML to create a game. \nextpage QML Advanced Tutorial 1 - Creating the Game Canvas and Blocks -This tutorial goes step-by-step through creating a full application using just QML. -It is assumed that you already know basic QML (such as from doing the simple tutorial) and the focus is on showing -how to turn that knowledge into a complete and functioning application. +This tutorial walks step-by-step through the creation of a full application using QML. -This tutorial involves a significant amount of JavaScript to implement the game logic. An understanding of JavaScript is helpful to understand the JavaScript parts of this tutorial, but if you don't understand JavaScript you can still get a feel for how to integrate QML elements with backend logic which creates and controls them. From the QML perspective, there is little difference between integrating with backend logic written in C++ and backend logic written in JavaScript. +It is assumed that you already know the basics of QML (for example, from reading the \l{QML Tutorial}{simple tutorial}) and this +tutorial focuses on using that knowledge to produce a complete and functioning application. + +The tutorial involves a significant amount of JavaScript to implement the game logic. An understanding of JavaScript is helpful to understand parts of this tutorial, but if you don't understand JavaScript you can still get a feel for how you can integrate backend logic to create and control QML elements. From the QML perspective, there is little difference between integrating QML with backend logic written in C++ and backend logic written in JavaScript. In this tutorial we recreate, step by step, a version of the Same Game demo in $QTDIR/demos/declarative/samegame.qml. The results of the individual steps are in the $QTDIR/examples/declarative/tutorials/samegame directory. @@ -75,45 +76,62 @@ Tutorial chapters: \previouspage QML Advanced Tutorial \nextpage QML Advanced Tutorial 2 - Populating the Game Canvas -The first step is to create the items in your application. In Same Game we have a main game screen and the blocks that populate it. +In this chapter: + +\tableofcontents + +The files referenced on this page can be found in \c $QTDIR\examples\tutorials\samegame\samegame1. + +\section2 Creating the application screen + +The first step is to create the basic QML items in your application. + +To begin with, we create our Same Game application with a main screen like this: \image declarative-adv-tutorial1.png -Here is the QML code for the basic elements. The game window: +This is defined by the main application file, \c samegame.qml, which looks like this: \snippet declarative/tutorials/samegame/samegame1/samegame.qml 0 -This gives you a basic game window, with room for the game canvas. A new game -button and room to display the score. The one thing you may not recognize here -is the \l SystemPalette item. This item provides access to the Qt system palette -and is used to make the button look more like a system button (for exact native -feel you would use a \l QPushButton). Since we want a fully functional button, -we use the QML elements Text and MouseArea inside a Rectangle to assemble a -button. Below is the code which we wrote to do this: +This gives you a basic game window that includes the main canvas for the +blocks, a "New Game" button and a score display. -\snippet declarative/tutorials/samegame/samegame1/Button.qml 0 +One item you may not recognize here +is the \l SystemPalette item. This provides access to the Qt system palette +and is used to give the button a more native look-and-feel. + +\section2 Adding \c Button and \c Block components -Note that this Button component was written to be fairly generic, in case we -want to use a similarly styled button later. +The \c Button item in the code above is defined in a separate file named \c Button.qml. +To create a functional button, we use the QML elements \l Text and \l MouseArea inside a \l Rectangle. +Here is the \c Button.qml code: + +\snippet declarative/tutorials/samegame/samegame1/Button.qml 0 -And here is a simple block: +In Same Game, the screen is filled with small blocks when the game begins. +Each block is just an item that contains an image. The block +code is defined in a separate \c Block.qml file: \snippet declarative/tutorials/samegame/samegame1/Block.qml 0 -Since it doesn't do anything yet it's very simple, just an image. As the -tutorial progresses and the block starts doing things the file will become -more than just an image. Note that we've set the image to be the size of the item. -This will be used later, when we dynamically create and size the block items the image will be scaled automatically -to the correct size. +At the moment, the block doesn't do anything; it is just an image. As the +tutorial progresses we will animate and give behaviors to the blocks. +We have not added any code yet to create the blocks; we will do this +in the next chapter. -Note that because there are several stages to this tutorial they share images. This is done by having a shared resources -folder containing the images, and all stages of the tutorial refer to the same shared folder. This is the reason for the -'../shared/pics' part of the image source. The image source can be any relative or absolute path, and it is relative to the -location of the file the Image element is in, with ../ meaning to go up one level. +We have set the image to be the size of its parent Item using \c {anchors.fill: parent}. +This means that when we dynamically create and resize the block items +later on in the tutorial, the image will be scaled automatically to the +correct size. -You should be familiar with all that goes on in these files so far. This is a -very basic start and doesn't move at all - next we will populate the game canvas -with some blocks. +Notice the relative path for the Image element's \c source property. +This path is relative to the location of the file that contains the \l Image element. +Alternatively, you could set the Image source to an absolute file path or a URL +that contains an image. + +You should be familiar with the code so far. We have just created some basic +elements to get started. Next, we will populate the game canvas with some blocks. */ @@ -124,64 +142,69 @@ with some blocks. \previouspage QML Advanced Tutorial 1 - Creating the Game Canvas and Blocks \nextpage QML Advanced Tutorial 3 - Implementing the Game Logic -Now that we've written some basic elements, let's start writing the game. The -first thing to do is to generate all of the blocks. Now we need to dynamically -generate all of these blocks, because you have a new, random set of blocks -every time. As they are dynamically generated every time the new game button is -clicked, as opposed to on startup, we will be dynamically generating the blocks -in the JavaScript, as opposed to using a \l Repeater. +In this chapter: + +\tableofcontents + +The files referenced on this page can be found in \c $QTDIR\examples\tutorials\samegame\samegame2. + + +\section2 Generating the blocks in JavaScript -This adds enough script to justify a new file, \c{samegame.js}, the intial version -of which is shown below +Now that we've written some basic elements, let's start writing the game. + +The first task is to generate the game blocks. Each time the New Game button +is clicked, the game canvas is populated with a new, random set of +blocks. Since we need to dynamically generate new blocks for each new game, +we cannot use \l Repeater to define the blocks. Instead, we will +create the blocks in JavaScript. + +Here is the JavaScript code for generating the blocks, contained in a new +file, \c samegame.js: \snippet declarative/tutorials/samegame/samegame2/samegame.js 0 -The gist of this code is that we create the blocks dynamically, as many as will fit, and then store them in an array for future reference. -The \c initBoard function will be hooked up to the new game button soon, and should be fairly straight forward. - -The \c createBlock function is a lot bigger, and I'll explain it block by block. -First we ensure that the component has been constructed. QML elements, including composite ones like the \c Block.qml -that we've written, are never created directly in script. While there is a function to parse and create an arbitrary QML string, -in the case where you are repeatedly creating the same item you will want to use the \c createComponent function. \c createComponent is -a built-in function in the declarative JavaScript, and returns a component object. -A component object prepares and stores a QML element (usually a composite element) for easy and efficient use. -When the component is ready, you can create a new instance of the loaded QML with the \c createObject method. -If the component is loaded remotely (over HTTP for example) then you will have to wait for the component to finish loading -before calling \c createObject. Since we don't wait here (the waiting is asyncronous, the component object will send a signal to tell -you when it's done) this code will only work if the block QML is a local file. - -As we aren't waiting for the component, the next block of code creates a game block with \c{component.createObject}. -Since there could be an error in the QML file you are trying to load, success is not guaranteed. -The first bit of error checkign code comes right after \c{createObject()}, to ensure that the object loaded correctly. -If it did not load correctly the function returns false, but we don't have that hooked up to the main UI to indicate -that something has gone wrong. Instead we print out error messages to the console, because an error here means an invalid -QML file and should only happen while you are developing and testing the UI. - -Next we start to set up our dynamically created block. -Because the \c{Block.qml} file is generic it needs to be placed in the main scene, and in the right place. -This is why \c parent, \c x, \c y, \c width and \c height are set. We then store it in the board array for later use. - -Finally, we have some more error handling. You can only call \c{createObject} if the component has loaded. -If it has not loaded, either it is still loading or there was an error loading (such as a missing file). -Since we don't request remote files the problem is likely to be a missing or misplaced file. -Again we print this to the console to aid debugging. - -You now have the code to create a field of blocks dynamically, like below: +The main function here is \c initBoard(). It creates an array to store all the game +blocks, then calls \c createBlock() to create enough blocks to fill the game canvas. -\image declarative-adv-tutorial2.png +The \c createBlock() function creates a block using the \c Block.qml file +and moves the new block to its position on the game canvas. This involves several steps: -To hook this code up to the \e{New Game} button, you alter it as below: +\list +\o \l {createComponent(url file)} is called to generate an element from \c Block.qml. + If the component is ready, we can call \c createObject() to create an instance of the \c Block item. + (If a component is loaded remotely - over HTTP for example - then we would have to wait for the + component to finish loading before calling \c createObject()). +\o If \c createObject() returned null (i.e. if there was an error while + loading the object), print the error information. +\o Place the block in its position on the board and set its width and height. + Also, store in the blocks array for future reference. +\o Finally, print error information to the console if the component could not be + loaded for some reason (for example, if the file is missing). +\endlist -\snippet declarative/tutorials/samegame/samegame2/samegame.qml 1 -We have just replaced the \c{onClicked: console.log("Implement me!")} with \c{onClicked: initBoard()}. -Note that in order to have the function available, you'll need to include the script in the main file, -by adding a script element to it. +\section2 Connecting JavaScript components to QML + +Now we need to call the JavaScript code in \c samegame.js from our QML files. +To do this, we add this line to \c samegame.qml which imports +the JavaScript file as a \l{Modules#QML Modules}{module}: \snippet declarative/tutorials/samegame/samegame2/samegame.qml 2 -With those two changes, and the script file, you are now dynamically creating a field of blocks you can play with. -They don't do anything now though; the next chapter will add the game mechanics. +This allows us to refer to any functions within \c samegame.js using "SameGame" +as a prefix: for example, \c SameGame.initBoard() or \c SameGame.createBlock(). +This means we can now connect the New Game button's \c onClicked handler to the \c initBoard() +function, like this: + +\snippet declarative/tutorials/samegame/samegame2/samegame.qml 1 + +So, when you click the New Game button, \c initBoard() is called and generates a field of blocks, like this: + +\image declarative-adv-tutorial2.png + +Now, we have a screen of blocks, and we can begin to add the game mechanics. + */ /*! @@ -191,11 +214,20 @@ They don't do anything now though; the next chapter will add the game mechanics. \previouspage QML Advanced Tutorial 2 - Populating the Game Canvas \nextpage QML Advanced Tutorial 4 - Finishing Touches -First we add to the \c initBoard function clearing of the board before filling it up again, so that clicking new game won't leave the previous game -lying around in the background. To the \c createComponent function we have added setting the type of the block to a number between -one and three - it's fundamental to the game logic that the blocks be different types if you want a fun game. +In this chapter: + +\tableofcontents + +The files referenced on this page can be found in \c $QTDIR\examples\tutorials\samegame\samegame3. + +\section2 Making a playable game + +Now that we have all the game components, we can add the game logic that +dictates how a player interacts with the blocks and plays the game +until it is won or lost. + +To do this, we have added the following functions to \c samegame.js: -The main change was adding the following game logic functions: \list \o function \c{handleClick(x,y)} \o function \c{floodFill(xIdx,yIdx,type)} @@ -204,59 +236,65 @@ The main change was adding the following game logic functions: \o function \c{floodMoveCheck(xIdx, yIdx, type)} \endlist -As this is a tutorial about QML, not game design, these functions will not be discussed in detail. The game logic here -was written in script, but it could have been written in C++ and had these functions exposed in the same way (except probably faster). -The interfacing of these functions and QML is what we will focus on. Of these functions, only \c handleClick and \c victoryCheck -interface closely with the QML. Those functions are shown below (the rest are still in the code for this tutorial located at -\c{$QTDIR/examples/declarative/tutorials/samegame}). +As this is a tutorial about QML, not game design, we will only discuss \c handleClick() and \c victoryCheck() below since they interface directly with the QML elements. Note that although the game logic here is written in JavaScript, it could have been written in C++ and then exposed to JavaScript. -\snippet declarative/tutorials/samegame/samegame3/samegame.js 1 -\snippet declarative/tutorials/samegame/samegame3/samegame.js 2 +\section3 Enabling mouse click interaction -You'll notice them referring to the \c gameCanvas item. This is an item that has been added to the QML for easier interfacing with the game logic. -It is placed next to the background image and replaces the background as the item to create the blocks in. -Its code is shown below: +To make it easier for the JavaScript code to interface with the QML elements, we have added an Item called \c gameCanvas to \c samegame.qml. It replaces the background as the item which contains the blocks, and accepts mouse input from the user. Here is the item code: \snippet declarative/tutorials/samegame/samegame3/samegame.qml 1 -This item is the exact size of the board, contains a score property, and a mouse region for input. -The blocks are now created as its children, and its size is used to determining the board size, so as to scale to the available screen size. -Since it needs to bind its size to a multiple of \c tileSize, \c tileSize needs to be moved into a QML property and out of the script file. +The \c gameCanvas item is the exact size of the board, and has a \c score property and a \l MouseArea for input. +The blocks are now created as its children, and its dimensions are used to determine the board size so that +the application scales to the available screen size. +Since its size is bound to a multiple of \c tileSize, \c tileSize needs to be moved out of \c samegame.js and into \c samegame.qml as a QML property. Note that it can still be accessed from the script. -The mouse region simply calls \c{handleClick()}, which deals with the input events. -Should those events cause the player to score, \c{gameCanvas.score} is updated. -The score display text item has also been changed to bind its text property to \c{gamecanvas.score}. -Note that if score was a global variable in the \c{samegame.js} file you could not bind to it. You can only bind to QML properties. +The \l MouseArea simply calls \c{handleClick()} in \c samegame.js, which determines whether the player's click should cause any blocks to be removed, and updates \c gameCanvas.score with the current score if necessary. Here is the \c handleClick() function: + +\snippet declarative/tutorials/samegame/samegame3/samegame.js 1 + +Note that if \c score was a global variable in the \c{samegame.js} file you would not be able to bind to it. You can only bind to QML properties. -\c victoryCheck() primarily updates the score variable. But it also pops up a dialog saying \e {Game Over} when the game is over. -In this example we wanted a pure-QML, animated dialog, and since QML doesn't contain one, we wrote our own. -Below is the code for the \c Dialog element, note how it's designed so as to be usable imperatively from within the script file (via the functions and signals): +\section3 Updating the score + +When the player clicks a block and triggers \c handleClick(), \c handleClick() also calls victoryCheck() to update the score and to check whether the player has completed the game. Here is the \c victoryCheck() code: + +\snippet declarative/tutorials/samegame/samegame3/samegame.js 2 + +This updates the \c gameCanvas.score value and displays a "Game Over" dialog if the game is finished. + +The Game Over dialog is created using a \c Dialog element that is defined in \c Dialog.qml. Here is the \c Dialog.qml code. Notice how it is designed to be usable imperatively from the script file, via the functions and signals: \snippet declarative/tutorials/samegame/samegame3/Dialog.qml 0 -And this is how it's used in the main QML file: +And this is how it is used in the main \c samegame.qml file: \snippet declarative/tutorials/samegame/samegame3/samegame.qml 2 -Combined with the line of code in \c victoryCheck, this causes a dialog to appear when the game is over, informing the user of that fact. -We now have a working game! The blocks can be clicked, the player can score, and the game can end (and then you start a new one). -Below is a screenshot of what has been accomplished so far: +\section3 A dash of color -\image declarative-adv-tutorial3.png +It's not much fun to play Same Game if all the blocks are the same color, so we've modified the \c createBlock() function in \c samegame.js to randomly create a different type of block (for either red, green or blue) each time it is called. \c Block.qml has also changed so that each block contains a different image depending on its type: -Here is the QML code as it is now for the main file: +\snippet declarative/tutorials/samegame/samegame3/Block.qml 0 -\snippet declarative/tutorials/samegame/samegame3/samegame.qml 0 -And the code for the block: +\section2 A working game -\snippet declarative/tutorials/samegame/samegame3/Block.qml 0 +Now we now have a working game! The blocks can be clicked, the player can score, and the game can end (and then you can start a new one). +Here is a screenshot of what has been accomplished so far: + +\image declarative-adv-tutorial3.png + +Here is the QML code as it is now in \c samegame.qml: + +\snippet declarative/tutorials/samegame/samegame3/samegame.qml 0 The game works, but it's a little boring right now. Where are the smooth animated transitions? Where are the high scores? -If you were a QML expert you could have written these in for the first iteration, but in this tutorial they've been saved +If you were a QML expert you could have written these in the first iteration, but in this tutorial they've been saved until the next chapter - where your application becomes alive! + */ /*! @@ -265,115 +303,146 @@ until the next chapter - where your application becomes alive! \contentspage QML Advanced Tutorial \previouspage QML Advanced Tutorial 3 - Implementing the Game Logic -Now we're going to do two things to liven the game up. Animate the blocks and add a web-based high score system. +In this chapter: -If you compare the \c samegame3 directory with \c samegame4, you'll noticed that we've cleaned the directory structure up. -We now have a lot of files, and so they've been split up into folders - the most notable one being a content folder -which we've placed all the QML but the main file. +\tableofcontents -\section2 Animated Blocks +The files referenced on this page can be found in \c $QTDIR\examples\tutorials\samegame\samegame4. -The most vital animations are that the blocks move fluidly around the board. QML has many tools for fluid behavior, -and in this case we're going to use the \l SpringFollow element. By having the script set \c targetX and \c targetY, instead of \c x -and \c y directly, we can set the \c x and \c y of the block to a follow. \l SpringFollow is a property value source, which means -that you can set a property to be one of these elements and it will automatically bind the property to the element's value. -The SpringFollow's value follows another value over time, when the value it is tracking changes the SpringFollow's -value will also change, but it will move smoothly there over time with a spring-like movement (based on the spring -parameters specified). This is shown in the below snippet of code from \c Block.qml: +\section2 Adding some flair -\code - property int targetX: 0 - property int targetY: 0 +Now we're going to do two things to liven up the game: animate the blocks and add a High Score system. - x: SpringFollow { source: targetX; spring: 2; damping: 0.2 } - y: SpringFollow { source: targetY; spring: 2; damping: 0.2 } -\endcode +We've also cleaned up the directory structure for our application files. We now have a lot of files, so all the +JavaScript and QML files outside of \c samegame.qml have been moved into a new sub-directory named "content". + +In anticipation of the new block animations, \c Block.qml file is now renamed to \c BoomBlock.qml. + +\section3 Animating block movement -We also have to change the \c{samegame.js} code, so that wherever it was setting the \c x or \c y it now sets \c targetX and \c targetY -(including when creating the block). This simple change is all you need to get spring moving blocks that no longer teleport -around the board. If you try doing just this though, you'll notice that they now never jump from one point to another, even in -the initialization! This gives an odd effect of having them all slide out of the corner (0,0) on start up. We'd rather that they -fall down from the top in rows. To do this, we disable the \c x follow (but not the \c y follow) and only enable it after we've set -the \c x in the \c createBlock function. The above snippet now becomes: +First we will animate the blocks so that they move in a fluid manner. QML has a number of methods for adding fluid +movement, and in this case we're going to use the \l SpringFollow element to add an animation with a spring-like +movement. In \c BoomBlock.qml, we apply a \l SpringFollow +to the \c x and \c y properties so that the block will follow and animate its movement towards the +position specified by the new \c targetX and \c targetY properties (whose values will be set by \c samegame.js). +Here is the code added to \c BoomBlock.qml: \snippet declarative/tutorials/samegame/samegame4/content/BoomBlock.qml 1 -The next-most vital animation is a smooth exit. For this animation, we'll use a \l Behavior element. A Behavior is also a property -value source, and it is much like SpringFollow except that it doesn't model the behavior of a spring. You specify how a Behavior -transitions using the standard animations. As we want the blocks to smoothly fade in and out we'll set a Behavior on the block -image's opacity, like so: +The \c spring and \c damping values can be changed to modify the spring-like effect of the animation. + +The \c {enabled: spawned} setting refers to the \c spawned value that is set from \c createBlock() in \c samegame.js. +This ensures the \l SpringFollow on the \c x is only enabled after \c createBlock() has set the block to +the correct position. Otherwise, the blocks will slide out of the corner (0,0) when a game begins, instead of falling +from the top in rows. (Try commenting out \c {enabled: spawned} and see for yourself.) + +\section3 Animating block opacity changes + +Next, we will add a smooth exit animation. For this, we'll use a \l Behavior element, which allows us to specify +a default animation when a property change occurs. In this case, when the \c opacity of a Block changes, we will +animate the opacity value so that it gradually fades in and out, instead of abruptly changing between fully +visible and invisible. To do this, we'll apply a \l Behavior on the \c opacity property of the \c Image +element in \c BoomBlock.qml: \snippet declarative/tutorials/samegame/samegame4/content/BoomBlock.qml 2 -Note that the \c{opacity: 0} makes it start out transparent. We could set the opacity in the script file when we create and destroy the blocks, -but instead we use states (as this is useful for the next animation we'll implement). The below snippet is set on the root -element of \c{Block.qml}: +Note the \c{opacity: 0} which means the block is transparent when it is first created. We could set the opacity +in \c samegame.js when we create and destroy the blocks, +but instead we'll use \l{QML States}{states}, since this is useful for the next animation we're going to add. +Initially, we add these States to the root element of \c{BoomBlock.qml}: \code property bool dying: false states: [ State{ name: "AliveState"; when: spawned == true && dying == false PropertyChanges { target: img; opacity: 1 } - }, State{ name: "DeathState"; when: dying == true + }, + State{ name: "DeathState"; when: dying == true PropertyChanges { target: img; opacity: 0 } } ] \endcode -Now it will automatically fade in, as we set spawned to true already when implementing the block movement animations. -To fade out, we set 'dying' to true instead of setting opacity to 0 when a block is destroyed (in the \c floodFill function). +Now blocks will automatically fade in, as we already set \c spawned to true when we implemented the block animations. +To fade out, we set \c dying to true instead of setting opacity to 0 when a block is destroyed (in the \c floodFill() function). -The least vital animations are a cool-looking particle effect when they get destroyed. First we create a \l Particles element in -the block, like so: +\section3 Adding particle effects + +Finally, we'll add a cool-looking particle effect to the blocks when they are destroyed. To do this, we first add a \l Particles element in +\c BoomBlock.qml, like so: \snippet declarative/tutorials/samegame/samegame4/content/BoomBlock.qml 3 -To fully understand this you'll want to look at the Particles element documentation, but it's important to note that emissionRate is set -to zero, so that no particles are emitted normally. -We next extend the 'dying' state, which creates a burst of particles by calling the burst method on the particles element. The code for the states now look +To fully understand this you should read the \l Particles documentation, but it's important to note that \c emissionRate is set +to zero so that particles are not emitted normally. +Also, we extend the \c dying State, which creates a burst of particles by calling the \c burst() method on the particles element. The code for the states now look like this: \snippet declarative/tutorials/samegame/samegame4/content/BoomBlock.qml 4 -And now the game should be beautifully animated and smooth, with a subtle (or not-so-subtle) animation added for all of the -player's actions. The end result is shown below, with a different set of images to demonstrate basic themeing: +Now the game is beautifully animated, with subtle (or not-so-subtle) animations added for all of the +player's actions. The end result is shown below, with a different set of images to demonstrate basic theming: \image declarative-adv-tutorial4.gif -The basic theme change there is the result of simply replacing the images. This can be done at run time by setting the source property, so a further advanced feature to try on your own is to add a button which toggles between two different themes. +The theme change here is produced simply by replacing the block images. This can be done at runtime by changing the \l Image \c source property, so for a further challenge, you could add a button that toggles between themes with different images. + +\section2 Keeping a High Scores table + +Another feature we might want to add to the game is a method of storing and retrieving high scores. + +In \c samegame.qml we now pop up a dialog when the game is over and requests the player's name so it can be added to a High Scores table. The dialog is created using \c Dialog.qml: + +\snippet declarative/tutorials/samegame/samegame4/samegame.qml 0 + +When the dialog is closed, we call the new \c saveHighScore() function in \c samegame.js, which stores the high score locally in an SQL database and also send the score to an online database if possible. + -\section2 Offline High Scores -Another extension we might want for the game is some way of storing and retrieving high scores. This tutorial contains both online and offline high score storage. +\section3 Storing high scores offline -For better high score data, we want the name and time of the player. The time is obtained in the script fairly simply, but we -have to ask the player for their name. We thus re-use the dialog QML file to pop up a dialog asking for the player's name (and -if they exit this dialog without entering it they have a way to opt out of posting their high score). When the dialog is closed we store the name and high score, using the code below. +Here is the \c saveHighScore() function in \c samegame.js: \snippet declarative/tutorials/samegame/samegame4/content/samegame.js 2 -For offline storage, we use the HTML 5 offline storage JavaScript API to maintain a persistant SQL database unique to this application. This first line in this function calls the function for the web-based high scores, described later, if it has been setup. Next we create an offline storage database for the high scores using openDatabase and prepare the data and SQL query that we want to use to save it. The offline storage API uses SQL queries for data manipulation and retrival, and in the db.transaction call we use three SQL queries to initialize the database (if necessary), and then add to and retrieve high scores. To use the returned data, we turn it into a string with one line per row returned, and show a dialog containing that string. For a more detailed explanation of the offline storage API in QML, consult the global object documentation. +First we call \c sendHighScore() (explained in the section below) if it is possible to send the high scores to an online database. -This is one way of storing and displaying high scores locally, but not the only way. A more complex alternative would have been to create a high score dialog component, and pass the results to it for processing and display (instead of resusing the Dialog). This would allow a more themable dialog that could present the high scores better. If your QML is the UI for a C++ application, you could also have passed the score to a C++ function to store it locally in a variety of ways, including a simple format without SQL or in another SQL database. +Then, we use the \l{Offline Storage API} to maintain a persistant SQL database unique to this application. We create an offline storage database for the high scores using \c openDatabase() and prepare the data and SQL query that we want to use to save it. The offline storage API uses SQL queries for data manipulation and retrival, and in the \c db.transaction() call we use three SQL queries to initialize the database (if necessary), and then add to and retrieve high scores. To use the returned data, we turn it into a string with one line per row returned, and show a dialog containing that string. -\section2 Web-based High Scores +This is one way of storing and displaying high scores locally, but certainly not the only way. A more complex alternative would be to create a high score dialog component, and pass it the results for processing and display (instead of reusing the \c Dialog). This would allow a more themeable dialog that could beter present the high scores. If your QML is the UI for a C++ application, you could also have passed the score to a C++ function to store it locally in a variety of ways, including a simple format without SQL or in another SQL database. -You've seen how to store high scores locally, but it is also easy to integrate a web enabled high score storage into your QML application. This tutorial also shows you how to communicate the high scores to a web server. The implementation we've done is very -simple - the high score data is posted to a php script running on a server somewhere, and that server then stores it and -displays it to visitors. You could request an XML or QML file from that same server, which contained and displayed the scores, -but that's beyond the scope of this tutorial. The php script we've used is available in the examples directory. +\section3 Storing high scores online -if the player entered their name we can send the data to the web service in the following snippet out of the script file: +You've seen how you can store high scores locally, but it is also easy to integrate a web-enabled high score storage into your QML application. The implementation we've done her is very +simple: the high score data is posted to a php script running on a server somewhere, and that server then stores it and +displays it to visitors. You could also request an XML or QML file from that same server, which contains and displays the scores, +but that's beyond the scope of this tutorial. The php script we use here is available in the \c examples directory. + +If the player entered their name we can send the data to the web service us + +If the player enters a name, we send the data to the service using this code in \c samegame.js: \snippet declarative/tutorials/samegame/samegame4/content/samegame.js 1 -This is the same \c XMLHttpRequest() as you'll find in browser JavaScript, and can be used in the same way to dynamically get XML -or QML from the web service to display the high scores. We don't worry about the response in this case, we just post the high +The \c XMLHttpRequest in this code is the same \c XMLHttpRequest() as you'll find in standard browser JavaScript, and can be used in the same way to dynamically get XML +or QML from the web service to display the high scores. We don't worry about the response in this case - we just post the high score data to the web server. If it had returned a QML file (or a URL to a QML file) you could instantiate it in much the same -way as you did the blocks. +way as you did with the blocks. -An alternate way to access and submit web-based data would be to use QML elements designed for this purpose - XmlListModel +An alternate way to access and submit web-based data would be to use QML elements designed for this purpose. XmlListModel makes it very easy to fetch and display XML based data such as RSS in a QML application (see the Flickr demo for an example). -By following this tutorial you've now ben shown how to write a fully functional application in QML, with the application logic -written in a script file and with both many fluid animations and being web-enabled. Congratulations, you should now be skilled -enough to write entire applications in QML. + +\section2 That's it! + +By following this tutorial you've seen how you can write a fully functional application in QML: + +\list +\o Build your application with \l {{QML Elements}}{QML elements} +\o Add application logic \l{Integrating JavaScript}{with JavaScript code} +\o Add animations with \l {Behavior}{Behaviors} and \l{QML States}{states} +\o Store persistent application data through online and offline methods +\endlist + +There is so much more to learn about QML that we haven't been able to cover in this tutorial. Check out all the +demos and examples and the \l {Declarative UI (QML)}{documentation} to find out all the things you can do with QML! + */ diff --git a/doc/src/declarative/elements.qdoc b/doc/src/declarative/elements.qdoc index fcfc7d6..5eaaf7e 100644 --- a/doc/src/declarative/elements.qdoc +++ b/doc/src/declarative/elements.qdoc @@ -111,8 +111,8 @@ The following table lists the QML elements provided by the Qt Declarative module \header \o \bold {Basic Visual Items} \o \bold {Basic Interaction Items} -\o \bold {Widgets} \o \bold {Utility} +\o \bold {Transforms} \row \o @@ -130,13 +130,8 @@ The following table lists the QML elements provided by the Qt Declarative module \list \o \l MouseArea \o \l FocusScope -\endlist - -\o -\list \o \l Flickable \o \l Flipable -\o \l WebView \endlist \o @@ -148,10 +143,17 @@ The following table lists the QML elements provided by the Qt Declarative module \o \l LayoutItem \endlist +\o +\list +\o \l Scale +\o \l Rotation +\o \l Translate +\endlist + \header \o \bold {Views} \o \bold {Positioners} -\o \bold {Transforms} +\o \bold {Media} \o \bold {Effects} \row @@ -172,6 +174,7 @@ The following table lists the QML elements provided by the Qt Declarative module \o \l PathPercent \endlist \endlist +\o \l WebView \endlist \o @@ -184,16 +187,13 @@ The following table lists the QML elements provided by the Qt Declarative module \o \list -\o \l Scale -\o \l Rotation +\o \l SoundEffect +\o \l Audio +\o \l Video \endlist \o \list -\o \l Blur -\o \l Colorize -\o \l DropShadow -\o \l Opacity \o \l Particles \list \o \l ParticleMotionLinear diff --git a/doc/src/declarative/modules.qdoc b/doc/src/declarative/modules.qdoc index 13658d8..d476d6f 100644 --- a/doc/src/declarative/modules.qdoc +++ b/doc/src/declarative/modules.qdoc @@ -83,7 +83,7 @@ For either type of module, a \c qmldir file in the module directory defines the optional for location modules, but only for local filesystem content or a single remote content with a namespace. The second exception is explained in more detail in the section below on Namespaces. -\seciont2 The Import Path +\section2 The Import Path Installed modules are searched for on the import path. The \c -L option to the \l {Qt Declarative UI Runtime}{qml} runtime adds paths to the import path. @@ -169,8 +169,10 @@ import Ovi 1.0 as Nokia While import statements are needed to make any types available in QML, the directory of the current file is implicitly loaded. This is the exact same as if you had added 'import "."' to -every QML file. The effect of this is that you can automatically use types defined in C++ plugins -or QML files if they reside in the same directory. +the start of every QML file. The effect of this is that you can automatically use types defined in C++ plugins +or QML files if they reside in the same directory. This is the last location searched for types - so if you +happen to have a "Text.qml" file, or "text.qml" on case-insensitive file systems, it will not override +the one from Qt if you import Qt. */ diff --git a/doc/src/declarative/pics/qmldebugger-creator.png b/doc/src/declarative/pics/qmldebugger-creator.png Binary files differdeleted file mode 100644 index da1e22d..0000000 --- a/doc/src/declarative/pics/qmldebugger-creator.png +++ /dev/null diff --git a/doc/src/declarative/qdeclarativedebugging.qdoc b/doc/src/declarative/qdeclarativedebugging.qdoc index e409c3e..4ff7fde 100644 --- a/doc/src/declarative/qdeclarativedebugging.qdoc +++ b/doc/src/declarative/qdeclarativedebugging.qdoc @@ -63,58 +63,23 @@ When a transition doesn't look quite right, it can be helpful to view it in slow motion to see what is happening more clearly. The \l {Qt Declarative UI Runtime}{qml} tool provides a "Slow Down Animations" menu option to facilitate this. +\section1 Debugging with Qt Creator -\section1 The QML Inspector +\l{http://qt.nokia.com/products/developer-tools}{Qt Creator} provides built-in +support for QML debugging. Open a QML project in Creator and enter Debug mode, +or click the "Start Debugging" option from the menu, and Creator will +show QML debugging information and options for your application, including +object inspection, property monitoring and application frame-rate analysis. -The \c qmldebugger tool provides an experimental inspector to aid with debugging. -It can be run as a Qt Creator plugin or as a standalone application. - -\section2 Qt Creator plugin - -The Qt Creator plugin currently builds against Qt Creator 1.3. - -To build the Qt Creator plugin: - -\list -\o Set an environment variable \c CREATOR_SRC_DIR that points to the Qt Creator - source directory -\o Set an environment variable \c CREATOR_BUILD_DIR that points to the Qt Creator - build directory -\o Run \c qmake on \c $QTDIR/tools/qmldebugger/qmldebugger.pro -\endlist - -This builds the plugin into your Qt Creator installation. - -The plugin adds a "QML Inspect" mode into Qt Creator that provides: - -\list -\o An object tree showing all objects and their children -\o The current property values for the object selected in the object tree - (this table is dynamically updated for all properties that have property changed - notifications) -\o An expression evaluator for querying and setting values dynamically -\o A table of watched properties (double-click on a property in the property - table to add it to the watch table) -\o A graph that shows the frame rate of your application -\endlist - - -To start the debugger, open a QML project and click the "QML Inspect" mode, then click the green -"play" button in the toolbar of the bottom-right debugger window. - -\image qmldebugger-creator.png - - -\section2 Standalone qmldebugger tool - -To run the standalone \c qmldebugger tool, set an environment variable \c QML_DEBUG_SERVER_PORT -to an available port number and run the \l {Qt Declarative UI Runtime}{qml} tool. For example: +Creator can be used to debug both local and remote QML applications. To +enable remote debugging, start the \l {Qt Declarative UI Runtime}{qml} tool +on the remote device with a debugging port defined, like this: \code QML_DEBUG_SERVER_PORT=3768 qml myqmlfile.qml \endcode -Then in another process, start the \c qmldebugger tool, enter the port number into the corresponding spinbox -in the top right hand corner, and press the "Connect" button. +In Creator, open the project settings pane and set the server and port +details for the remote device, then start debugging. */ diff --git a/doc/src/declarative/tutorial.qdoc b/doc/src/declarative/tutorial.qdoc index 66de741..1a93d05 100644 --- a/doc/src/declarative/tutorial.qdoc +++ b/doc/src/declarative/tutorial.qdoc @@ -155,13 +155,13 @@ An \l Item is the most basic visual element in QML and is often used as a contai \snippet examples/declarative/tutorials/helloworld/Cell.qml 4 -We declare a \c color property. This property is accessible from \e outside our component, this allows us +We declare a \c cellColor property. This property is accessible from \e outside our component, this allows us to instantiate the cells with different colors. This property is just an alias to an existing property - the color of the rectangle that compose the cell (see \l{intro-properties}{Properties}). \snippet examples/declarative/tutorials/helloworld/Cell.qml 5 -We want our component to also have a signal that we call \e clicked with a \e color parameter. +We want our component to also have a signal that we call \e clicked with a \e cellColor parameter of type \e color. We will use this signal to change the color of the text in the main QML file later. \snippet examples/declarative/tutorials/helloworld/Cell.qml 2 @@ -189,7 +189,7 @@ We create the color picker by putting 6 cells with different colors in a grid. \snippet examples/declarative/tutorials/helloworld/tutorial2.qml 1 -When the \e clicked signal of our cell is triggered, we want to set the color of the text to the color passed as a parameter. +When the \e clicked signal of our cell is triggered, we want to set the color of the text to the \e cellColor passed as a parameter. We can react to any signal of our component through a property of the name \e 'onSignalName' (see \l{Signal Handlers}). */ diff --git a/examples/declarative/declarative.pro b/examples/declarative/declarative.pro index db776b3..98ea6c4 100644 --- a/examples/declarative/declarative.pro +++ b/examples/declarative/declarative.pro @@ -6,7 +6,7 @@ SUBDIRS = \ imageprovider \ objectlistmodel \ plugins \ - widgets + proxywidgets # plugins uses a 'Time' class that conflicts with symbian e32std.h also defining a class of the same name symbian:SUBDIRS -= plugins diff --git a/examples/declarative/imageprovider/imageprovider.pro b/examples/declarative/imageprovider/imageprovider.pro index 86dbcca..945a301 100644 --- a/examples/declarative/imageprovider/imageprovider.pro +++ b/examples/declarative/imageprovider/imageprovider.pro @@ -18,4 +18,8 @@ ImageProviderCore_sources.files = \ ImageProviderCore/qmldir ImageProviderCore_sources.path = $$[QT_INSTALL_EXAMPLES]/declarative/imageprovider/ImageProviderCore +symbian:{ + TARGET.EPOCALLOWDLLDATA=1 +} + INSTALLS = sources ImageProviderCore_sources target diff --git a/examples/declarative/plugins/plugin.cpp b/examples/declarative/plugins/plugin.cpp index 741f68a..fb51b0c 100644 --- a/examples/declarative/plugins/plugin.cpp +++ b/examples/declarative/plugins/plugin.cpp @@ -46,7 +46,7 @@ #include <qbasictimer.h> #include <qapplication.h> -// Implements a "Time" class with hour and minute properties +// Implements a "TimeModel" class with hour and minute properties // that change on-the-minute yet efficiently sleep the rest // of the time. @@ -97,14 +97,14 @@ private: QBasicTimer timer; }; -class Time : public QObject +class TimeModel : public QObject { Q_OBJECT Q_PROPERTY(int hour READ hour NOTIFY timeChanged) Q_PROPERTY(int minute READ minute NOTIFY timeChanged) public: - Time(QObject *parent=0) : QObject(parent) + TimeModel(QObject *parent=0) : QObject(parent) { if (++instances == 1) { if (!timer) @@ -114,7 +114,7 @@ public: } } - ~Time() + ~TimeModel() { if (--instances == 0) { timer->stop(); @@ -133,12 +133,8 @@ private: static int instances; }; -int Time::instances=0; -MinuteTimer *Time::timer=0; - - -QML_DECLARE_TYPE(Time); - +int TimeModel::instances=0; +MinuteTimer *TimeModel::timer=0; class QExampleQmlPlugin : public QDeclarativeExtensionPlugin { @@ -147,7 +143,7 @@ public: void registerTypes(const char *uri) { Q_ASSERT(uri == QLatin1String("com.nokia.TimeExample")); - qmlRegisterType<Time>(uri, 1, 0, "Time"); + qmlRegisterType<TimeModel>(uri, 1, 0, "Time"); } }; diff --git a/examples/declarative/plugins/plugins.pro b/examples/declarative/plugins/plugins.pro index 877a5ce..c409d39 100644 --- a/examples/declarative/plugins/plugins.pro +++ b/examples/declarative/plugins/plugins.pro @@ -8,7 +8,7 @@ VERSION = 1.0.0 SOURCES += plugin.cpp qdeclarativesources.files += \ - com/nokia/TimeExample/qdeclarativedir \ + com/nokia/TimeExample/qmldir \ com/nokia/TimeExample/center.png \ com/nokia/TimeExample/clock.png \ com/nokia/TimeExample/Clock.qml \ @@ -22,6 +22,11 @@ sources.path += $$[QT_INSTALL_EXAMPLES]/declarative/plugins target.path += $$[QT_INSTALL_EXAMPLES]/declarative/plugins/com/nokia/TimeExample +symbian:{ + TARGET.EPOCALLOWDLLDATA=1 +} + + INSTALLS += qdeclarativesources sources target symbian: include($$QT_SOURCE_TREE/examples/symbianpkgrules.pri) diff --git a/examples/declarative/proxywidgets/ProxyWidgets/qmldir b/examples/declarative/proxywidgets/ProxyWidgets/qmldir new file mode 100644 index 0000000..e55267c --- /dev/null +++ b/examples/declarative/proxywidgets/ProxyWidgets/qmldir @@ -0,0 +1 @@ +plugin proxywidgetsplugin diff --git a/examples/declarative/widgets/README b/examples/declarative/proxywidgets/README index f85a1e8..f50fa22 100644 --- a/examples/declarative/widgets/README +++ b/examples/declarative/proxywidgets/README @@ -1,4 +1,4 @@ To run: make install - qml mywidgets.qml + qml proxywidgets.qml diff --git a/examples/declarative/widgets/mywidgets.cpp b/examples/declarative/proxywidgets/proxywidgets.cpp index e17240d..47d0cb9 100644 --- a/examples/declarative/widgets/mywidgets.cpp +++ b/examples/declarative/proxywidgets/proxywidgets.cpp @@ -82,7 +82,7 @@ private: QPushButton *widget; }; -class MyWidgetsPlugin : public QDeclarativeExtensionPlugin +class ProxyWidgetsPlugin : public QDeclarativeExtensionPlugin { Q_OBJECT public: @@ -92,8 +92,8 @@ public: } }; -#include "mywidgets.moc" +#include "proxywidgets.moc" QML_DECLARE_TYPE(MyPushButton) -Q_EXPORT_PLUGIN2(mywidgetsplugin, MyWidgetsPlugin); +Q_EXPORT_PLUGIN2(proxywidgetsplugin, ProxyWidgetsPlugin); diff --git a/examples/declarative/widgets/mywidgets.pro b/examples/declarative/proxywidgets/proxywidgets.pro index 258edb1..eb85191 100644 --- a/examples/declarative/widgets/mywidgets.pro +++ b/examples/declarative/proxywidgets/proxywidgets.pro @@ -1,13 +1,13 @@ TEMPLATE = lib -DESTDIR = MyWidgets -TARGET = mywidgetsplugin +DESTDIR = ProxyWidgets +TARGET = proxywidgetsplugin CONFIG += qt plugin QT += declarative VERSION = 1.0.0 -SOURCES += mywidgets.cpp +SOURCES += proxywidgets.cpp -sources.files += mywidgets.pro mywidgets.cpp mywidgets.qml +sources.files += proxywidgets.pro proxywidgets.cpp proxywidgets.qml sources.path += $$[QT_INSTALL_EXAMPLES]/declarative/plugins @@ -17,3 +17,6 @@ INSTALLS += sources target symbian: include($$QT_SOURCE_TREE/examples/symbianpkgrules.pri) +symbian:{ + TARGET.EPOCALLOWDLLDATA = 1 +}
\ No newline at end of file diff --git a/examples/declarative/widgets/mywidgets.qml b/examples/declarative/proxywidgets/proxywidgets.qml index b1efed4..023de71 100644 --- a/examples/declarative/widgets/mywidgets.qml +++ b/examples/declarative/proxywidgets/proxywidgets.qml @@ -1,5 +1,5 @@ import Qt 4.6 -import "MyWidgets" 1.0 +import "ProxyWidgets" 1.0 Rectangle { id: window diff --git a/examples/declarative/tutorials/helloworld/Cell.qml b/examples/declarative/tutorials/helloworld/Cell.qml index de4f3bb..9249ffe 100644 --- a/examples/declarative/tutorials/helloworld/Cell.qml +++ b/examples/declarative/tutorials/helloworld/Cell.qml @@ -5,10 +5,10 @@ import Qt 4.6 Item { id: container //![4] - property alias color: rectangle.color + property alias cellColor: rectangle.color //![4] //![5] - signal clicked(color color) + signal clicked(color cellColor) //![5] width: 40; height: 25 @@ -25,7 +25,7 @@ Item { //![3] MouseArea { anchors.fill: parent - onClicked: container.clicked(container.color) + onClicked: container.clicked(container.cellColor) } //![3] } diff --git a/examples/declarative/tutorials/helloworld/tutorial2.qml b/examples/declarative/tutorials/helloworld/tutorial2.qml index 99889d7..38447e2 100644 --- a/examples/declarative/tutorials/helloworld/tutorial2.qml +++ b/examples/declarative/tutorials/helloworld/tutorial2.qml @@ -15,17 +15,17 @@ Rectangle { Grid { id: colorPicker - anchors.bottom: page.bottom + x: 4; anchors.bottom: page.bottom; anchors.bottomMargin: 4 rows: 2; columns: 3; spacing: 3 //![1] - Cell { color: "red"; onClicked: helloText.color = color } + Cell { cellColor: "red"; onClicked: helloText.color = cellColor } //![1] - Cell { color: "green"; onClicked: helloText.color = color } - Cell { color: "blue"; onClicked: helloText.color = color } - Cell { color: "yellow"; onClicked: helloText.color = color } - Cell { color: "steelblue"; onClicked: helloText.color = color } - Cell { color: "black"; onClicked: helloText.color = color } + Cell { cellColor: "green"; onClicked: helloText.color = cellColor } + Cell { cellColor: "blue"; onClicked: helloText.color = cellColor } + Cell { cellColor: "yellow"; onClicked: helloText.color = cellColor } + Cell { cellColor: "steelblue"; onClicked: helloText.color = cellColor } + Cell { cellColor: "black"; onClicked: helloText.color = cellColor } } } //![0] diff --git a/examples/declarative/tutorials/helloworld/tutorial3.qml b/examples/declarative/tutorials/helloworld/tutorial3.qml index b8a4f77..d851c49 100644 --- a/examples/declarative/tutorials/helloworld/tutorial3.qml +++ b/examples/declarative/tutorials/helloworld/tutorial3.qml @@ -11,15 +11,14 @@ Rectangle { text: "Hello world!" font.pointSize: 24; font.bold: true y: 30; anchors.horizontalCenter: page.horizontalCenter - transformOrigin: Item.Center //![1] - MouseArea { id: mouseRegion; anchors.fill: parent } + MouseArea { id: mouseArea; anchors.fill: parent } //![1] //![2] states: State { - name: "down"; when: mouseRegion.pressed == true + name: "down"; when: mouseArea.pressed == true PropertyChanges { target: helloText; y: 160; rotation: 180; color: "red" } } //![2] @@ -37,15 +36,15 @@ Rectangle { Grid { id: colorPicker - anchors.bottom: page.bottom + x: 4; anchors.bottom: page.bottom; anchors.bottomMargin: 4 rows: 2; columns: 3; spacing: 3 - Cell { color: "red"; onClicked: helloText.color = color } - Cell { color: "green"; onClicked: helloText.color = color } - Cell { color: "blue"; onClicked: helloText.color = color } - Cell { color: "yellow"; onClicked: helloText.color = color } - Cell { color: "steelblue"; onClicked: helloText.color = color } - Cell { color: "black"; onClicked: helloText.color = color } + Cell { cellColor: "red"; onClicked: helloText.color = cellColor } + Cell { cellColor: "green"; onClicked: helloText.color = cellColor } + Cell { cellColor: "blue"; onClicked: helloText.color = cellColor } + Cell { cellColor: "yellow"; onClicked: helloText.color = cellColor } + Cell { cellColor: "steelblue"; onClicked: helloText.color = cellColor } + Cell { cellColor: "black"; onClicked: helloText.color = cellColor } } } //![0] diff --git a/examples/declarative/tutorials/samegame/samegame1/Button.qml b/examples/declarative/tutorials/samegame/samegame1/Button.qml index 2e31ff8..5e28da7 100644 --- a/examples/declarative/tutorials/samegame/samegame1/Button.qml +++ b/examples/declarative/tutorials/samegame/samegame1/Button.qml @@ -14,11 +14,11 @@ Rectangle { gradient: Gradient { GradientStop { id: topGrad; position: 0.0 - color: if (mr.pressed) { activePalette.dark } else { activePalette.light } } + color: if (mouseArea.pressed) { activePalette.dark } else { activePalette.light } } GradientStop { position: 1.0; color: activePalette.button } } - MouseArea { id: mr; anchors.fill: parent; onClicked: container.clicked() } + MouseArea { id: mouseArea; anchors.fill: parent; onClicked: container.clicked() } Text { id: txtItem; text: container.text; anchors.centerIn: container; color: activePalette.buttonText diff --git a/examples/declarative/tutorials/samegame/samegame1/samegame.qml b/examples/declarative/tutorials/samegame/samegame1/samegame.qml index 5ed30c9..006b926 100644 --- a/examples/declarative/tutorials/samegame/samegame1/samegame.qml +++ b/examples/declarative/tutorials/samegame/samegame1/samegame.qml @@ -24,7 +24,7 @@ Rectangle { anchors.bottom: screen.bottom Button { - id: btnA; text: "New Game"; onClicked: console.log("Implement me!"); + id: btnA; text: "New Game"; onClicked: console.log("Starting a new game..."); anchors.left: parent.left; anchors.leftMargin: 3 anchors.verticalCenter: parent.verticalCenter } diff --git a/examples/declarative/tutorials/samegame/samegame2/Button.qml b/examples/declarative/tutorials/samegame/samegame2/Button.qml index 6629302..a7853d4 100644 --- a/examples/declarative/tutorials/samegame/samegame2/Button.qml +++ b/examples/declarative/tutorials/samegame/samegame2/Button.qml @@ -13,11 +13,11 @@ Rectangle { gradient: Gradient { GradientStop { id: topGrad; position: 0.0 - color: if (mr.pressed) { activePalette.dark } else { activePalette.light } } + color: if (mouseArea.pressed) { activePalette.dark } else { activePalette.light } } GradientStop { position: 1.0; color: activePalette.button } } - MouseArea { id: mr; anchors.fill: parent; onClicked: container.clicked() } + MouseArea { id: mouseArea; anchors.fill: parent; onClicked: container.clicked() } Text { id: txtItem; text: container.text; anchors.centerIn: container; color: activePalette.buttonText diff --git a/examples/declarative/tutorials/samegame/samegame2/samegame.js b/examples/declarative/tutorials/samegame/samegame2/samegame.js index 2c02c61..0ec3a8b 100644 --- a/examples/declarative/tutorials/samegame/samegame2/samegame.js +++ b/examples/declarative/tutorials/samegame/samegame2/samegame.js @@ -15,6 +15,12 @@ function index(xIdx,yIdx) { function initBoard() { + //Delete old blocks + for(var i = 0; i<maxIndex; i++){ + if(board[i] != null) + board[i].destroy(); + } + //Calculate board size maxX = Math.floor(background.width/tileSize); maxY = Math.floor(background.height/tileSize); diff --git a/examples/declarative/tutorials/samegame/samegame2/samegame.qml b/examples/declarative/tutorials/samegame/samegame2/samegame.qml index 7e0bc0c..89d8035 100644 --- a/examples/declarative/tutorials/samegame/samegame2/samegame.qml +++ b/examples/declarative/tutorials/samegame/samegame2/samegame.qml @@ -1,13 +1,13 @@ import Qt 4.6 +//![2] +import "samegame.js" as SameGame +//![2] Rectangle { id: screen width: 490; height: 720 SystemPalette { id: activePalette } -//![2] - Script { source: "samegame.js" } -//![2] Item { width: parent.width; anchors.top: parent.top; anchors.bottom: toolbar.top @@ -27,7 +27,7 @@ Rectangle { //![1] Button { - id: btnA; text: "New Game"; onClicked: initBoard(); + id: btnA; text: "New Game"; onClicked: SameGame.initBoard(); anchors.left: parent.left; anchors.leftMargin: 3 anchors.verticalCenter: parent.verticalCenter } diff --git a/examples/declarative/tutorials/samegame/samegame3/Button.qml b/examples/declarative/tutorials/samegame/samegame3/Button.qml index 6629302..a7853d4 100644 --- a/examples/declarative/tutorials/samegame/samegame3/Button.qml +++ b/examples/declarative/tutorials/samegame/samegame3/Button.qml @@ -13,11 +13,11 @@ Rectangle { gradient: Gradient { GradientStop { id: topGrad; position: 0.0 - color: if (mr.pressed) { activePalette.dark } else { activePalette.light } } + color: if (mouseArea.pressed) { activePalette.dark } else { activePalette.light } } GradientStop { position: 1.0; color: activePalette.button } } - MouseArea { id: mr; anchors.fill: parent; onClicked: container.clicked() } + MouseArea { id: mouseArea; anchors.fill: parent; onClicked: container.clicked() } Text { id: txtItem; text: container.text; anchors.centerIn: container; color: activePalette.buttonText diff --git a/examples/declarative/tutorials/samegame/samegame3/Dialog.qml b/examples/declarative/tutorials/samegame/samegame3/Dialog.qml index 36178ec..966f85a 100644 --- a/examples/declarative/tutorials/samegame/samegame3/Dialog.qml +++ b/examples/declarative/tutorials/samegame/samegame3/Dialog.qml @@ -18,6 +18,6 @@ Rectangle { NumberAnimation { duration: 1000 } } Text { id: myText; anchors.centerIn: parent; text: "Hello World!" } - MouseArea { id: mr; anchors.fill: parent; onClicked: forceClose(); } + MouseArea { id: mouseArea; anchors.fill: parent; onClicked: forceClose(); } } //![0] diff --git a/examples/declarative/tutorials/samegame/samegame3/samegame.js b/examples/declarative/tutorials/samegame/samegame3/samegame.js index 38efb3b..33449fa 100644 --- a/examples/declarative/tutorials/samegame/samegame3/samegame.js +++ b/examples/declarative/tutorials/samegame/samegame3/samegame.js @@ -14,12 +14,6 @@ function index(xIdx,yIdx) { function initBoard() { - for(var i = 0; i<maxIndex; i++){ - //Delete old blocks - if(board[i] != null) - board[i].destroy(); - } - //Calculate board size maxX = Math.floor(gameCanvas.width/gameCanvas.tileSize); maxY = Math.floor(gameCanvas.height/gameCanvas.tileSize); diff --git a/examples/declarative/tutorials/samegame/samegame3/samegame.qml b/examples/declarative/tutorials/samegame/samegame3/samegame.qml index 168bf9b..db25e24 100644 --- a/examples/declarative/tutorials/samegame/samegame3/samegame.qml +++ b/examples/declarative/tutorials/samegame/samegame3/samegame.qml @@ -1,12 +1,12 @@ //![0] import Qt 4.6 +import "samegame.js" as SameGame Rectangle { id: screen width: 490; height: 720 SystemPalette { id: activePalette } - Script { source: "samegame.js" } Item { width: parent.width; anchors.top: parent.top; anchors.bottom: toolbar.top @@ -28,8 +28,7 @@ Rectangle { height: parent.height - (parent.height % tileSize); MouseArea { - id: gameMR - anchors.fill: parent; onClicked: handleClick(mouse.x,mouse.y); + anchors.fill: parent; onClicked: SameGame.handleClick(mouse.x,mouse.y); } } //![1] @@ -46,7 +45,7 @@ Rectangle { anchors.bottom: screen.bottom Button { - id: btnA; text: "New Game"; onClicked: initBoard(); + id: btnA; text: "New Game"; onClicked: SameGame.initBoard(); anchors.left: parent.left; anchors.leftMargin: 3 anchors.verticalCenter: parent.verticalCenter } diff --git a/examples/declarative/tutorials/samegame/samegame4/content/BoomBlock.qml b/examples/declarative/tutorials/samegame/samegame4/content/BoomBlock.qml index a6ef62c..e50aae0 100644 --- a/examples/declarative/tutorials/samegame/samegame4/content/BoomBlock.qml +++ b/examples/declarative/tutorials/samegame/samegame4/content/BoomBlock.qml @@ -9,7 +9,7 @@ Item { id:block property int targetX: 0 property int targetY: 0 - SpringFollow on x { enabled: spawned; source: targetX; spring: 2; damping: 0.2 } + SpringFollow on x { source: targetX; spring: 2; damping: 0.2; enabled: spawned } SpringFollow on y { source: targetY; spring: 2; damping: 0.2 } //![1] diff --git a/examples/declarative/tutorials/samegame/samegame4/content/Button.qml b/examples/declarative/tutorials/samegame/samegame4/content/Button.qml index 6629302..a7853d4 100644 --- a/examples/declarative/tutorials/samegame/samegame4/content/Button.qml +++ b/examples/declarative/tutorials/samegame/samegame4/content/Button.qml @@ -13,11 +13,11 @@ Rectangle { gradient: Gradient { GradientStop { id: topGrad; position: 0.0 - color: if (mr.pressed) { activePalette.dark } else { activePalette.light } } + color: if (mouseArea.pressed) { activePalette.dark } else { activePalette.light } } GradientStop { position: 1.0; color: activePalette.button } } - MouseArea { id: mr; anchors.fill: parent; onClicked: container.clicked() } + MouseArea { id: mouseArea; anchors.fill: parent; onClicked: container.clicked() } Text { id: txtItem; text: container.text; anchors.centerIn: container; color: activePalette.buttonText diff --git a/examples/declarative/tutorials/samegame/samegame4/content/Dialog.qml b/examples/declarative/tutorials/samegame/samegame4/content/Dialog.qml index 831c03b..fc83e39 100644 --- a/examples/declarative/tutorials/samegame/samegame4/content/Dialog.qml +++ b/examples/declarative/tutorials/samegame/samegame4/content/Dialog.qml @@ -17,5 +17,5 @@ Rectangle { NumberAnimation { duration: 1000 } } Text { id: myText; anchors.centerIn: parent; text: "Hello World!" } - MouseArea { id: mr; anchors.fill: parent; onClicked: forceClose(); } + MouseArea { id: mouseArea; anchors.fill: parent; onClicked: forceClose(); } } diff --git a/examples/declarative/tutorials/samegame/samegame4/samegame.qml b/examples/declarative/tutorials/samegame/samegame4/samegame.qml index c2e8018..090496d 100644 --- a/examples/declarative/tutorials/samegame/samegame4/samegame.qml +++ b/examples/declarative/tutorials/samegame/samegame4/samegame.qml @@ -1,5 +1,6 @@ import Qt 4.6 import "content" +import "content/samegame.js" as SameGame Rectangle { id: screen @@ -21,20 +22,19 @@ Rectangle { property int score: 0 property int tileSize: 40 - Script { source: "content/samegame.js" } - z: 20; anchors.centerIn: parent width: parent.width - (parent.width % getTileSize()); height: parent.height - (parent.height % getTileSize()); MouseArea { - id: gameMR - anchors.fill: parent; onClicked: handleClick(mouse.x,mouse.y); + anchors.fill: parent; onClicked: SameGame.handleClick(mouse.x,mouse.y); } } } Dialog { id: dialog; anchors.centerIn: parent; z: 21 } + + //![0] Dialog { id: scoreName; anchors.centerIn: parent; z: 22; Text { @@ -54,6 +54,7 @@ Rectangle { anchors.left: spacer.right } } + //![0] Rectangle { id: toolBar @@ -62,7 +63,7 @@ Rectangle { anchors.bottom: screen.bottom Button { - id: btnA; text: "New Game"; onClicked: {initBoard();} + id: btnA; text: "New Game"; onClicked: {SameGame.initBoard();} anchors.left: parent.left; anchors.leftMargin: 3 anchors.verticalCenter: parent.verticalCenter } diff --git a/examples/declarative/widgets/MyWidgets/qmldir b/examples/declarative/widgets/MyWidgets/qmldir deleted file mode 100644 index dc1d10e..0000000 --- a/examples/declarative/widgets/MyWidgets/qmldir +++ /dev/null @@ -1 +0,0 @@ -plugin mywidgetsplugin diff --git a/src/declarative/graphicsitems/qdeclarativeanchors.cpp b/src/declarative/graphicsitems/qdeclarativeanchors.cpp index dc1f09d..ffcedda 100644 --- a/src/declarative/graphicsitems/qdeclarativeanchors.cpp +++ b/src/declarative/graphicsitems/qdeclarativeanchors.cpp @@ -1059,7 +1059,7 @@ bool QDeclarativeAnchorsPrivate::checkVAnchorValid(QDeclarativeAnchorLine anchor return true; } -#include <moc_qdeclarativeanchors_p.cpp> - QT_END_NAMESPACE +#include <moc_qdeclarativeanchors_p.cpp> + diff --git a/src/declarative/graphicsitems/qdeclarativeflickable.cpp b/src/declarative/graphicsitems/qdeclarativeflickable.cpp index fb22429..8459245 100644 --- a/src/declarative/graphicsitems/qdeclarativeflickable.cpp +++ b/src/declarative/graphicsitems/qdeclarativeflickable.cpp @@ -403,8 +403,10 @@ void QDeclarativeFlickablePrivate::updateBeginningEnd() These properties describe the position and size of the currently viewed area. The size is defined as the percentage of the full view currently visible, - scaled to 0.0 - 1.0. The page position is in the range 0.0 (beginning) to - size ratio (end), i.e. yPosition is in the range 0.0 - heightRatio. + scaled to 0.0 - 1.0. The page position is usually in the range 0.0 (beginning) to + 1.0 minus size ratio (end), i.e. yPosition is in the range 0.0 to 1.0-heightRatio. + However, it is possible for the contents to be dragged outside of the normal + range, resulting in the page positions also being outside the normal range. These properties are typically used to draw a scrollbar, for example: \code diff --git a/src/declarative/graphicsitems/qdeclarativeitem.cpp b/src/declarative/graphicsitems/qdeclarativeitem.cpp index 05e13a7..83c79a0 100644 --- a/src/declarative/graphicsitems/qdeclarativeitem.cpp +++ b/src/declarative/graphicsitems/qdeclarativeitem.cpp @@ -77,13 +77,20 @@ QT_BEGIN_NAMESPACE \since 4.7 \brief The Transform elements provide a way of building advanced transformations on Items. + The Transform element is a base type which cannot be instantiated directly. + The following concrete Transform types are available: + + \list + \o \l Rotation + \o \l Scale + \o \l Translate + \endlist + The Transform elements let you create and control advanced transformations that can be configured independently using specialized properties. You can assign any number of Transform elements to an Item. Each Transform is applied in order, one at a time, to the Item it's assigned to. - - \sa Rotation, Scale, Translate */ /*! @@ -91,7 +98,7 @@ QT_BEGIN_NAMESPACE \since 4.7 \brief The Translate object provides a way to move an Item without changing its x or y properties. - The Translate object independent control over position in addition to the Item's x and y properties. + The Translate object provides independent control over position in addition to the Item's x and y properties. The following example moves the Y axis of the Rectangles while still allowing the Row element to lay the items out as if they had not been transformed: @@ -118,7 +125,7 @@ QT_BEGIN_NAMESPACE */ /*! - \qmlproperty real Translate::yTranslate + \qmlproperty real Translate::y The translation along the Y axis. */ diff --git a/src/declarative/graphicsitems/qdeclarativepositioners.cpp b/src/declarative/graphicsitems/qdeclarativepositioners.cpp index b23b8c9..781e584 100644 --- a/src/declarative/graphicsitems/qdeclarativepositioners.cpp +++ b/src/declarative/graphicsitems/qdeclarativepositioners.cpp @@ -237,21 +237,13 @@ void QDeclarativeBasePositioner::prePositioning() positionedItems.append(*item); } } - doPositioning(); + QSizeF contentSize; + doPositioning(&contentSize); if(d->addTransition || d->moveTransition) finishApplyTransitions(); //Set implicit size to the size of its children - qreal h = 0.0f; - qreal w = 0.0f; - for (int i = 0; i < positionedItems.count(); ++i) { - const PositionedItem &posItem = positionedItems.at(i); - if (posItem.isVisible) { - h = qMax(h, posItem.item->y() + posItem.item->height()); - w = qMax(w, posItem.item->x() + posItem.item->width()); - } - } - setImplicitHeight(h); - setImplicitWidth(w); + setImplicitHeight(contentSize.height()); + setImplicitWidth(contentSize.width()); } void QDeclarativeBasePositioner::positionX(int x, const PositionedItem &target) @@ -423,7 +415,7 @@ static inline bool isInvisible(QDeclarativeItem *child) return child->opacity() == 0.0 || !child->isVisible() || !child->width() || !child->height(); } -void QDeclarativeColumn::doPositioning() +void QDeclarativeColumn::doPositioning(QSizeF *contentSize) { int voffset = 0; @@ -435,9 +427,13 @@ void QDeclarativeColumn::doPositioning() if(child.item->y() != voffset) positionY(voffset, child); + contentSize->setWidth(qMax(contentSize->width(), child.item->width())); + voffset += child.item->height(); voffset += spacing(); } + + contentSize->setHeight(voffset - spacing()); } /*! @@ -534,7 +530,7 @@ QDeclarativeRow::QDeclarativeRow(QDeclarativeItem *parent) { } -void QDeclarativeRow::doPositioning() +void QDeclarativeRow::doPositioning(QSizeF *contentSize) { int hoffset = 0; @@ -546,9 +542,13 @@ void QDeclarativeRow::doPositioning() if(child.item->x() != hoffset) positionX(hoffset, child); + contentSize->setHeight(qMax(contentSize->height(), child.item->height())); + hoffset += child.item->width(); hoffset += spacing(); } + + contentSize->setWidth(hoffset - spacing()); } @@ -698,7 +698,7 @@ void QDeclarativeGrid::setRows(const int rows) emit rowsChanged(); } -void QDeclarativeGrid::doPositioning() +void QDeclarativeGrid::doPositioning(QSizeF *contentSize) { int c=_columns,r=_rows;//Actual number of rows/columns int numVisible = positionedItems.count(); @@ -745,6 +745,10 @@ void QDeclarativeGrid::doPositioning() positionX(xoffset, child); positionY(yoffset, child); } + + contentSize->setWidth(qMax(contentSize->width(), xoffset + child.item->width())); + contentSize->setHeight(yoffset + maxRowHeight[curRow]); + xoffset+=maxColWidth[curCol]+spacing(); curCol++; curCol%=c; @@ -854,7 +858,7 @@ void QDeclarativeFlow::setFlow(Flow flow) } } -void QDeclarativeFlow::doPositioning() +void QDeclarativeFlow::doPositioning(QSizeF *contentSize) { Q_D(QDeclarativeFlow); @@ -886,6 +890,9 @@ void QDeclarativeFlow::doPositioning() positionY(voffset, child); } + contentSize->setWidth(qMax(contentSize->width(), hoffset + child.item->width())); + contentSize->setHeight(qMax(contentSize->height(), voffset + child.item->height())); + if (d->flow == LeftToRight) { hoffset += child.item->width(); hoffset += spacing(); diff --git a/src/declarative/graphicsitems/qdeclarativepositioners_p.h b/src/declarative/graphicsitems/qdeclarativepositioners_p.h index f38847c..c4414d1 100644 --- a/src/declarative/graphicsitems/qdeclarativepositioners_p.h +++ b/src/declarative/graphicsitems/qdeclarativepositioners_p.h @@ -90,10 +90,10 @@ Q_SIGNALS: void addChanged(); protected Q_SLOTS: - virtual void doPositioning()=0; void prePositioning(); protected: + virtual void doPositioning(QSizeF *contentSize)=0; struct PositionedItem { PositionedItem(QDeclarativeItem *i) : item(i), isNew(false), isVisible(true) {} bool operator==(const PositionedItem &other) const { return other.item == item; } @@ -116,8 +116,8 @@ class Q_DECLARATIVE_EXPORT QDeclarativeColumn : public QDeclarativeBasePositione Q_OBJECT public: QDeclarativeColumn(QDeclarativeItem *parent=0); -protected Q_SLOTS: - virtual void doPositioning(); +protected: + virtual void doPositioning(QSizeF *contentSize); private: Q_DISABLE_COPY(QDeclarativeColumn) }; @@ -127,8 +127,8 @@ class Q_DECLARATIVE_EXPORT QDeclarativeRow: public QDeclarativeBasePositioner Q_OBJECT public: QDeclarativeRow(QDeclarativeItem *parent=0); -protected Q_SLOTS: - virtual void doPositioning(); +protected: + virtual void doPositioning(QSizeF *contentSize); private: Q_DISABLE_COPY(QDeclarativeRow) }; @@ -151,8 +151,8 @@ Q_SIGNALS: void rowsChanged(); void columnsChanged(); -protected Q_SLOTS: - virtual void doPositioning(); +protected: + virtual void doPositioning(QSizeF *contentSize); private: int _rows; @@ -176,8 +176,8 @@ public: Q_SIGNALS: void flowChanged(); -protected Q_SLOTS: - virtual void doPositioning(); +protected: + virtual void doPositioning(QSizeF *contentSize); protected: QDeclarativeFlow(QDeclarativeFlowPrivate &dd, QDeclarativeItem *parent); diff --git a/src/declarative/graphicsitems/qdeclarativepositioners_p_p.h b/src/declarative/graphicsitems/qdeclarativepositioners_p_p.h index 3a1edee..7880e3e 100644 --- a/src/declarative/graphicsitems/qdeclarativepositioners_p_p.h +++ b/src/declarative/graphicsitems/qdeclarativepositioners_p_p.h @@ -73,8 +73,8 @@ class QDeclarativeBasePositionerPrivate : public QDeclarativeItemPrivate, public public: QDeclarativeBasePositionerPrivate() - : spacing(0), type(QDeclarativeBasePositioner::None), moveTransition(0), addTransition(0), - queuedPositioning(false) + : spacing(0), type(QDeclarativeBasePositioner::None) + , moveTransition(0), addTransition(0), queuedPositioning(false) { } @@ -84,6 +84,7 @@ public: } int spacing; + QDeclarativeBasePositioner::PositionerType type; QDeclarativeTransition *moveTransition; QDeclarativeTransition *addTransition; diff --git a/src/declarative/graphicsitems/qdeclarativerectangle.cpp b/src/declarative/graphicsitems/qdeclarativerectangle.cpp index b82fb53..8fbaa22 100644 --- a/src/declarative/graphicsitems/qdeclarativerectangle.cpp +++ b/src/declarative/graphicsitems/qdeclarativerectangle.cpp @@ -228,13 +228,12 @@ QDeclarativePen *QDeclarativeRectangle::border() GradientStop { position: 1.0; color: "blue" } } } - Rectangle { rotation: 90; x: 80; y: 200; width: 80; height: 80 + Rectangle { rotation: 90; y: 200; width: 80; height: 80 gradient: Gradient { GradientStop { position: 0.0; color: "lightsteelblue" } GradientStop { position: 1.0; color: "blue" } } } - // The x offset is needed because the rotation is from the top left corner \endqml \endtable diff --git a/src/declarative/qml/parser/qdeclarativejs.g b/src/declarative/qml/parser/qdeclarativejs.g index 6434d10..536989f 100644 --- a/src/declarative/qml/parser/qdeclarativejs.g +++ b/src/declarative/qml/parser/qdeclarativejs.g @@ -971,6 +971,56 @@ case $rule_number: { } break; ./ +UiObjectMember: T_PROPERTY T_IDENTIFIER T_LT UiPropertyType T_GT JsIdentifier T_COLON T_LBRACKET UiArrayMemberList T_RBRACKET ; +/. +case $rule_number: { + AST::UiPublicMember *node = makeAstNode<AST::UiPublicMember> (driver->nodePool(), sym(4).sval, sym(6).sval); + node->typeModifier = sym(2).sval; + node->propertyToken = loc(1); + node->typeModifierToken = loc(2); + node->typeToken = loc(4); + node->identifierToken = loc(6); + node->semicolonToken = loc(7); // insert a fake ';' before ':' + + AST::UiQualifiedId *propertyName = makeAstNode<AST::UiQualifiedId>(driver->nodePool(), sym(6).sval); + propertyName->identifierToken = loc(6); + propertyName->next = 0; + + AST::UiArrayBinding *binding = makeAstNode<AST::UiArrayBinding> (driver->nodePool(), + propertyName, sym(9).UiArrayMemberList->finish()); + binding->colonToken = loc(7); + binding->lbracketToken = loc(8); + binding->rbracketToken = loc(10); + + node->binding = binding; + + sym(1).Node = node; +} break; +./ + +UiObjectMember: T_PROPERTY UiPropertyType JsIdentifier T_COLON UiQualifiedId UiObjectInitializer ; +/. +case $rule_number: { + AST::UiPublicMember *node = makeAstNode<AST::UiPublicMember> (driver->nodePool(), sym(2).sval, sym(3).sval); + node->propertyToken = loc(1); + node->typeToken = loc(2); + node->identifierToken = loc(3); + node->semicolonToken = loc(4); // insert a fake ';' before ':' + + AST::UiQualifiedId *propertyName = makeAstNode<AST::UiQualifiedId>(driver->nodePool(), sym(3).sval); + propertyName->identifierToken = loc(3); + propertyName->next = 0; + + AST::UiObjectBinding *binding = makeAstNode<AST::UiObjectBinding> (driver->nodePool(), + propertyName, sym(5).UiQualifiedId, sym(6).UiObjectInitializer); + binding->colonToken = loc(4); + + node->binding = binding; + + sym(1).Node = node; +} break; +./ + UiObjectMember: FunctionDeclaration ; /. case $rule_number: { diff --git a/src/declarative/qml/parser/qdeclarativejsast.cpp b/src/declarative/qml/parser/qdeclarativejsast.cpp index 3b569a7..e3d3a66 100644 --- a/src/declarative/qml/parser/qdeclarativejsast.cpp +++ b/src/declarative/qml/parser/qdeclarativejsast.cpp @@ -837,6 +837,7 @@ void UiPublicMember::accept0(Visitor *visitor) { if (visitor->visit(this)) { accept(expression, visitor); + accept(binding, visitor); } visitor->endVisit(this); diff --git a/src/declarative/qml/parser/qdeclarativejsast_p.h b/src/declarative/qml/parser/qdeclarativejsast_p.h index c1945ce..b839413 100644 --- a/src/declarative/qml/parser/qdeclarativejsast_p.h +++ b/src/declarative/qml/parser/qdeclarativejsast_p.h @@ -2485,13 +2485,13 @@ public: UiPublicMember(NameId *memberType, NameId *name) - : type(Property), typeModifier(0), memberType(memberType), name(name), expression(0), isDefaultMember(false), isReadonlyMember(false), parameters(0) + : type(Property), typeModifier(0), memberType(memberType), name(name), expression(0), binding(0), isDefaultMember(false), isReadonlyMember(false), parameters(0) { kind = K; } UiPublicMember(NameId *memberType, NameId *name, ExpressionNode *expression) - : type(Property), typeModifier(0), memberType(memberType), name(name), expression(expression), isDefaultMember(false), isReadonlyMember(false), parameters(0) + : type(Property), typeModifier(0), memberType(memberType), name(name), expression(expression), binding(0), isDefaultMember(false), isReadonlyMember(false), parameters(0) { kind = K; } virtual SourceLocation firstSourceLocation() const @@ -2506,6 +2506,9 @@ public: virtual SourceLocation lastSourceLocation() const { + if (binding) + return binding->lastSourceLocation(); + return semicolonToken; } @@ -2516,7 +2519,8 @@ public: NameId *typeModifier; NameId *memberType; NameId *name; - ExpressionNode *expression; + ExpressionNode *expression; // initialized with a JS expression + UiObjectMember *binding; // initialized with a QML object or array. bool isDefaultMember; bool isReadonlyMember; UiParameterList *parameters; diff --git a/src/declarative/qml/parser/qdeclarativejsgrammar.cpp b/src/declarative/qml/parser/qdeclarativejsgrammar.cpp index 89493ff..39a2d3f 100644 --- a/src/declarative/qml/parser/qdeclarativejsgrammar.cpp +++ b/src/declarative/qml/parser/qdeclarativejsgrammar.cpp @@ -64,35 +64,35 @@ const short QDeclarativeJSGrammar::lhs [] = { 106, 106, 106, 106, 106, 106, 106, 106, 126, 126, 126, 127, 127, 128, 128, 106, 106, 106, 106, 106, 106, 106, 106, 106, 106, 106, 106, 106, 106, 106, - 106, 106, 106, 116, 116, 116, 116, 116, 131, 131, + 106, 106, 106, 106, 106, 116, 116, 116, 116, 116, 131, 131, 131, 131, 131, 131, 131, 131, 131, 131, - 131, 131, 131, 131, 131, 131, 121, 133, 133, 133, - 133, 132, 132, 135, 135, 137, 137, 137, 137, 137, - 137, 138, 138, 138, 138, 138, 138, 138, 138, 138, + 131, 131, 131, 131, 131, 131, 131, 131, 121, 133, + 133, 133, 133, 132, 132, 135, 135, 137, 137, 137, + 137, 137, 137, 138, 138, 138, 138, 138, 138, 138, 138, 138, 138, 138, 138, 138, 138, 138, 138, 138, 138, 138, 138, 138, 138, 138, 138, 138, 138, 138, - 138, 138, 139, 139, 114, 114, 114, 114, 114, 142, - 142, 143, 143, 143, 143, 141, 141, 144, 144, 145, - 145, 146, 146, 146, 147, 147, 147, 147, 147, 147, - 147, 147, 147, 147, 148, 148, 148, 148, 149, 149, - 149, 150, 150, 150, 150, 151, 151, 151, 151, 151, - 151, 151, 152, 152, 152, 152, 152, 152, 153, 153, - 153, 153, 153, 154, 154, 154, 154, 154, 155, 155, - 156, 156, 157, 157, 158, 158, 159, 159, 160, 160, - 161, 161, 162, 162, 163, 163, 164, 164, 165, 165, - 166, 166, 136, 136, 167, 167, 168, 168, 168, 168, - 168, 168, 168, 168, 168, 168, 168, 168, 104, 104, - 169, 169, 170, 170, 171, 171, 103, 103, 103, 103, + 138, 138, 138, 138, 139, 139, 114, 114, 114, 114, + 114, 142, 142, 143, 143, 143, 143, 141, 141, 144, + 144, 145, 145, 146, 146, 146, 147, 147, 147, 147, + 147, 147, 147, 147, 147, 147, 148, 148, 148, 148, + 149, 149, 149, 150, 150, 150, 150, 151, 151, 151, + 151, 151, 151, 151, 152, 152, 152, 152, 152, 152, + 153, 153, 153, 153, 153, 154, 154, 154, 154, 154, + 155, 155, 156, 156, 157, 157, 158, 158, 159, 159, + 160, 160, 161, 161, 162, 162, 163, 163, 164, 164, + 165, 165, 166, 166, 136, 136, 167, 167, 168, 168, + 168, 168, 168, 168, 168, 168, 168, 168, 168, 168, + 104, 104, 169, 169, 170, 170, 171, 171, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, - 103, 122, 183, 183, 182, 182, 130, 130, 184, 184, - 185, 185, 187, 187, 186, 188, 191, 189, 189, 192, - 190, 190, 123, 124, 124, 125, 125, 172, 172, 172, - 172, 172, 172, 172, 173, 173, 173, 173, 174, 174, - 174, 174, 175, 175, 176, 178, 193, 193, 196, 196, - 194, 194, 197, 195, 177, 177, 177, 179, 179, 180, - 180, 180, 198, 199, 181, 181, 129, 140, 203, 203, - 200, 200, 201, 201, 204, 107, 205, 205, 105, 105, - 202, 202, 134, 134, 206}; + 103, 103, 103, 122, 183, 183, 182, 182, 130, 130, + 184, 184, 185, 185, 187, 187, 186, 188, 191, 189, + 189, 192, 190, 190, 123, 124, 124, 125, 125, 172, + 172, 172, 172, 172, 172, 172, 173, 173, 173, 173, + 174, 174, 174, 174, 175, 175, 176, 178, 193, 193, + 196, 196, 194, 194, 197, 195, 177, 177, 177, 179, + 179, 180, 180, 180, 198, 199, 181, 181, 129, 140, + 203, 203, 200, 200, 201, 201, 204, 107, 205, 205, + 105, 105, 202, 202, 134, 134, 206}; const short QDeclarativeJSGrammar::rhs [] = { 2, 2, 2, 2, 2, 2, 2, 1, 1, 1, @@ -101,106 +101,107 @@ const short QDeclarativeJSGrammar::rhs [] = { 1, 5, 4, 4, 3, 3, 3, 3, 1, 1, 1, 0, 1, 2, 4, 6, 6, 3, 3, 7, 7, 4, 4, 5, 5, 6, 6, 7, 7, 7, - 7, 1, 1, 1, 1, 1, 1, 1, 1, 1, - 1, 1, 1, 1, 1, 1, 1, 1, 2, 3, - 3, 4, 5, 3, 4, 3, 1, 1, 2, 3, - 4, 1, 2, 3, 5, 1, 1, 1, 1, 1, + 7, 10, 6, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 2, 3, 3, 4, 5, 3, 4, 3, 1, 1, + 2, 3, 4, 1, 2, 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, 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, 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, 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, 3, - 0, 1, 1, 3, 0, 1, 1, 1, 1, 1, + 1, 5, 1, 5, 1, 3, 1, 3, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 3, 0, 1, 1, 3, 0, 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, 3, - 3, 4, 5, 2, 2, 2, 8, 8, 1, 3, - 0, 1, 0, 1, 1, 1, 1, 2, 1, 1, - 0, 1, 0, 1, 2}; + 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, 3, 3, 4, 5, 2, 2, 2, 8, 8, + 1, 3, 0, 1, 0, 1, 1, 1, 1, 2, + 1, 1, 0, 1, 0, 1, 2}; const short QDeclarativeJSGrammar::action_default [] = { - 0, 0, 0, 0, 0, 0, 22, 0, 172, 239, - 203, 211, 207, 151, 223, 199, 3, 136, 70, 152, - 215, 219, 140, 169, 150, 155, 135, 189, 176, 0, - 77, 78, 73, 341, 64, 343, 0, 0, 0, 0, - 75, 0, 0, 71, 74, 68, 0, 0, 65, 67, - 66, 76, 69, 0, 72, 0, 0, 165, 0, 0, - 152, 171, 154, 153, 0, 0, 0, 167, 168, 166, - 170, 0, 200, 0, 0, 0, 0, 190, 0, 0, - 0, 0, 0, 0, 180, 0, 0, 0, 174, 175, - 173, 178, 182, 181, 179, 177, 192, 191, 193, 0, - 208, 0, 204, 0, 0, 146, 133, 145, 134, 102, - 103, 104, 129, 105, 130, 106, 107, 108, 109, 110, - 111, 112, 113, 114, 115, 116, 117, 118, 131, 119, - 120, 121, 122, 123, 124, 125, 126, 127, 128, 132, - 0, 0, 144, 240, 147, 0, 148, 0, 149, 143, - 0, 236, 229, 227, 234, 235, 233, 232, 238, 231, - 230, 228, 237, 224, 0, 212, 0, 0, 216, 0, - 0, 220, 0, 0, 146, 138, 0, 137, 0, 142, - 156, 0, 342, 331, 332, 0, 329, 0, 330, 0, - 333, 247, 254, 253, 261, 249, 0, 250, 334, 0, - 340, 251, 252, 257, 255, 337, 335, 339, 258, 0, - 269, 0, 0, 0, 0, 341, 64, 0, 343, 65, - 241, 283, 66, 0, 0, 0, 270, 0, 0, 259, - 260, 0, 248, 256, 284, 285, 328, 338, 0, 299, - 300, 301, 302, 0, 295, 296, 297, 298, 325, 326, - 0, 0, 0, 0, 0, 288, 289, 245, 243, 205, - 213, 209, 225, 201, 246, 0, 152, 217, 221, 194, - 183, 0, 0, 202, 0, 0, 0, 0, 195, 0, - 0, 0, 0, 0, 187, 185, 188, 186, 184, 197, - 196, 198, 0, 210, 0, 206, 0, 244, 152, 0, - 226, 241, 242, 0, 241, 0, 0, 291, 0, 0, - 0, 293, 0, 214, 0, 0, 218, 0, 0, 222, - 281, 0, 273, 282, 276, 0, 280, 0, 241, 274, - 0, 241, 0, 0, 292, 0, 0, 0, 294, 342, - 331, 0, 0, 333, 0, 327, 0, 317, 0, 0, - 0, 287, 0, 286, 0, 344, 0, 101, 263, 266, - 0, 102, 269, 105, 130, 107, 108, 73, 112, 113, - 64, 114, 117, 71, 74, 65, 241, 66, 76, 120, - 69, 122, 72, 124, 125, 270, 127, 128, 132, 0, - 94, 0, 0, 96, 100, 98, 85, 97, 99, 0, - 95, 84, 264, 262, 140, 141, 146, 0, 139, 0, - 316, 0, 303, 304, 0, 315, 0, 0, 0, 306, - 311, 309, 312, 0, 0, 310, 311, 0, 307, 0, - 308, 265, 314, 0, 265, 313, 0, 318, 319, 0, - 265, 320, 321, 0, 0, 322, 0, 0, 0, 323, - 324, 158, 157, 0, 0, 0, 290, 0, 0, 0, - 305, 278, 271, 0, 279, 275, 0, 277, 267, 0, - 268, 272, 88, 0, 0, 92, 79, 0, 81, 90, - 0, 82, 91, 93, 83, 89, 80, 0, 86, 162, - 160, 164, 161, 159, 163, 6, 336, 4, 2, 62, - 87, 0, 0, 65, 67, 66, 31, 5, 0, 63, + 0, 0, 0, 0, 0, 0, 22, 0, 174, 241, + 205, 213, 209, 153, 225, 201, 3, 138, 72, 154, + 217, 221, 142, 171, 152, 157, 137, 191, 178, 0, + 79, 80, 75, 343, 66, 345, 0, 0, 0, 0, + 77, 0, 0, 73, 76, 70, 0, 0, 67, 69, + 68, 78, 71, 0, 74, 0, 0, 167, 0, 0, + 154, 173, 156, 155, 0, 0, 0, 169, 170, 168, + 172, 0, 202, 0, 0, 0, 0, 192, 0, 0, + 0, 0, 0, 0, 182, 0, 0, 0, 176, 177, + 175, 180, 184, 183, 181, 179, 194, 193, 195, 0, + 210, 0, 206, 0, 0, 148, 135, 147, 136, 104, + 105, 106, 131, 107, 132, 108, 109, 110, 111, 112, + 113, 114, 115, 116, 117, 118, 119, 120, 133, 121, + 122, 123, 124, 125, 126, 127, 128, 129, 130, 134, + 0, 0, 146, 242, 149, 0, 150, 0, 151, 145, + 0, 238, 231, 229, 236, 237, 235, 234, 240, 233, + 232, 230, 239, 226, 0, 214, 0, 0, 218, 0, + 0, 222, 0, 0, 148, 140, 0, 139, 0, 144, + 158, 0, 344, 333, 334, 0, 331, 0, 332, 0, + 335, 249, 256, 255, 263, 251, 0, 252, 336, 0, + 342, 253, 254, 259, 257, 339, 337, 341, 260, 0, + 271, 0, 0, 0, 0, 343, 66, 0, 345, 67, + 243, 285, 68, 0, 0, 0, 272, 0, 0, 261, + 262, 0, 250, 258, 286, 287, 330, 340, 0, 301, + 302, 303, 304, 0, 297, 298, 299, 300, 327, 328, + 0, 0, 0, 0, 0, 290, 291, 247, 245, 207, + 215, 211, 227, 203, 248, 0, 154, 219, 223, 196, + 185, 0, 0, 204, 0, 0, 0, 0, 197, 0, + 0, 0, 0, 0, 189, 187, 190, 188, 186, 199, + 198, 200, 0, 212, 0, 208, 0, 246, 154, 0, + 228, 243, 244, 0, 243, 0, 0, 293, 0, 0, + 0, 295, 0, 216, 0, 0, 220, 0, 0, 224, + 283, 0, 275, 284, 278, 0, 282, 0, 243, 276, + 0, 243, 0, 0, 294, 0, 0, 0, 296, 344, + 333, 0, 0, 335, 0, 329, 0, 319, 0, 0, + 0, 289, 0, 288, 0, 346, 0, 103, 265, 268, + 0, 104, 271, 107, 132, 109, 110, 75, 114, 115, + 66, 116, 119, 73, 76, 67, 243, 68, 78, 122, + 71, 124, 74, 126, 127, 272, 129, 130, 134, 0, + 96, 0, 0, 98, 102, 100, 87, 99, 101, 0, + 97, 86, 266, 264, 142, 143, 148, 0, 141, 0, + 318, 0, 305, 306, 0, 317, 0, 0, 0, 308, + 313, 311, 314, 0, 0, 312, 313, 0, 309, 0, + 310, 267, 316, 0, 267, 315, 0, 320, 321, 0, + 267, 322, 323, 0, 0, 324, 0, 0, 0, 325, + 326, 160, 159, 0, 0, 0, 292, 0, 0, 0, + 307, 280, 273, 0, 281, 277, 0, 279, 269, 0, + 270, 274, 90, 0, 0, 94, 81, 0, 83, 92, + 0, 84, 93, 95, 85, 91, 82, 0, 88, 164, + 162, 166, 163, 161, 165, 6, 338, 4, 2, 64, + 89, 0, 0, 67, 69, 68, 31, 5, 0, 65, 0, 41, 40, 39, 0, 0, 54, 0, 55, 0, 60, 61, 0, 41, 0, 0, 0, 0, 0, 50, - 51, 0, 52, 0, 53, 0, 56, 57, 0, 0, - 0, 0, 0, 58, 59, 0, 48, 42, 49, 43, - 0, 0, 0, 0, 45, 0, 46, 47, 44, 0, - 0, 0, 30, 35, 36, 37, 38, 140, 265, 0, - 0, 102, 269, 105, 130, 107, 108, 73, 112, 113, - 64, 114, 117, 71, 74, 65, 241, 66, 76, 120, - 69, 122, 72, 124, 125, 270, 127, 128, 132, 140, - 0, 26, 0, 0, 32, 27, 33, 28, 24, 0, - 29, 25, 0, 34, 8, 0, 10, 0, 9, 0, - 1, 21, 12, 0, 13, 0, 14, 0, 19, 20, - 0, 15, 16, 0, 17, 18, 11, 23, 7, 345}; + 0, 51, 0, 0, 26, 0, 0, 62, 27, 0, + 30, 28, 24, 0, 29, 25, 0, 52, 0, 53, + 0, 142, 0, 56, 57, 63, 0, 0, 0, 0, + 0, 58, 59, 0, 48, 42, 49, 43, 0, 0, + 0, 0, 45, 0, 46, 47, 44, 0, 0, 35, + 36, 37, 38, 142, 267, 0, 0, 104, 271, 107, + 132, 109, 110, 75, 114, 115, 66, 116, 119, 73, + 76, 67, 243, 68, 78, 122, 71, 124, 74, 126, + 127, 272, 129, 130, 134, 0, 32, 33, 0, 34, + 8, 0, 10, 0, 9, 0, 1, 21, 12, 0, + 13, 0, 14, 0, 19, 20, 0, 15, 16, 0, + 17, 18, 11, 23, 7, 347}; const short QDeclarativeJSGrammar::goto_default [] = { - 7, 620, 207, 196, 205, 507, 495, 619, 638, 614, - 618, 616, 621, 22, 617, 18, 506, 609, 600, 562, - 508, 191, 195, 197, 201, 524, 550, 549, 200, 232, + 7, 626, 207, 196, 205, 507, 495, 625, 644, 620, + 624, 622, 627, 22, 623, 18, 506, 543, 533, 540, + 535, 191, 195, 197, 201, 524, 568, 567, 200, 232, 26, 474, 473, 356, 355, 9, 354, 357, 107, 17, 145, 24, 13, 144, 19, 25, 57, 23, 8, 28, 27, 269, 15, 263, 10, 259, 12, 261, 11, 260, @@ -211,775 +212,771 @@ const short QDeclarativeJSGrammar::goto_default [] = { 199, 181, 184, 198, 206, 0}; const short QDeclarativeJSGrammar::action_index [] = { - 314, 1273, 2404, 2404, 2307, 1001, 58, 98, 78, -101, - 95, 56, 4, 236, -101, 296, 86, -101, -101, 545, - 97, 115, 162, 197, -101, -101, -101, 447, 192, 1273, - -101, -101, -101, 369, -101, 2113, 1919, 1273, 1273, 1273, - -101, 732, 1273, -101, -101, -101, 1273, 1273, -101, -101, - -101, -101, -101, 1273, -101, 1273, 1273, -101, 1273, 1273, - 81, 195, -101, -101, 1273, 1273, 1273, -101, -101, -101, - 185, 1273, 283, 1273, 1273, 1273, 1273, 447, 1273, 1273, - 1273, 1273, 1273, 1273, 297, 1273, 1273, 1273, 107, 85, - 116, 297, 297, 297, 297, 191, 447, 447, 447, 1273, - 74, 1273, 102, 2016, 1273, 1273, -101, -101, -101, -101, + 421, 1288, 2322, 2322, 2419, 1016, -52, 37, 140, -101, + 35, -13, -40, 190, -101, 272, 34, -101, -101, 658, + 42, 103, 194, 201, -101, -101, -101, 439, 256, 1288, + -101, -101, -101, 282, -101, 2128, 1751, 1288, 1288, 1288, + -101, 917, 1288, -101, -101, -101, 1288, 1288, -101, -101, + -101, -101, -101, 1288, -101, 1288, 1288, -101, 1288, 1288, + 109, 245, -101, -101, 1288, 1288, 1288, -101, -101, -101, + 185, 1288, 295, 1288, 1288, 1288, 1288, 461, 1288, 1288, + 1288, 1288, 1288, 1288, 256, 1288, 1288, 1288, 155, 119, + 114, 176, 256, 332, 202, 332, 560, 560, 471, 1288, + -23, 1288, 53, 2031, 1288, 1288, -101, -101, -101, -101, -101, -101, -101, -101, -101, -101, -101, -101, -101, -101, -101, -101, -101, -101, -101, -101, -101, -101, -101, -101, -101, -101, -101, -101, -101, -101, -101, -101, -101, -101, - 112, 1273, -101, -101, 92, 61, -101, 1273, -101, -101, - 1273, -101, -101, -101, -101, -101, -101, -101, -101, -101, - -101, -101, -101, -101, 1273, 36, 1273, 1273, 65, 62, - 1273, -101, 2016, 1273, 1273, -101, 127, -101, 42, -101, - -101, 57, -101, 294, 60, 35, -101, 259, -101, 32, - 2404, -101, -101, -101, -101, -101, 200, -101, -101, 33, - -101, -101, -101, -101, -101, -101, 2404, -101, -101, 436, - -101, 433, 100, 2307, 34, 369, 67, 45, 2598, 71, - 1273, -101, 72, 51, 1273, 59, -101, 54, 55, -101, - -101, 324, -101, -101, -101, -101, -101, -101, 88, -101, - -101, -101, -101, 76, -101, -101, -101, -101, -101, -101, - 5, 49, 1273, 104, 84, -101, -101, 1457, -101, 70, - 41, 1, -101, 287, 68, 46, 643, 73, 77, 364, - 297, 369, 1273, 238, 1273, 1273, 1273, 1273, 341, 1273, - 1273, 1273, 1273, 1273, 297, 175, 167, 161, 176, 348, - 315, 331, 1273, -13, 1273, 63, 1273, -101, 545, 1273, - -101, 1273, 64, 40, 1273, 2, 2307, -101, 1273, 152, - 2307, -101, 1273, 69, 1273, 1273, 75, 79, 1273, -101, - 44, 149, 66, -101, -101, 1273, -101, 369, 1273, -101, - 52, 1273, -54, 2307, -101, 1273, 151, 2307, -101, -29, - 369, -41, -11, 2404, -46, -101, 2307, -101, 1273, 131, - 2307, -5, 2307, -101, 8, 13, -55, -101, -101, 2307, - -51, 360, -2, 352, 119, 1273, 2307, 39, -19, 366, - 3, -24, 910, 6, 7, -101, 1367, -101, 11, -16, - -4, 1273, -6, -31, 1273, 9, 1273, -12, 17, 1273, - -101, 2210, 37, -101, -101, -101, -101, -101, -101, 1273, - -101, -101, -101, -101, 258, -101, 1273, -15, -101, 2307, - -101, 117, -101, -101, 2307, -101, 1273, 106, 16, -101, - 38, -101, 135, 96, 1273, -101, 135, 43, -101, 18, - -101, 2307, -101, 101, 2307, -101, 179, -101, -101, 99, - 2307, 31, -101, -7, -8, -101, 369, -34, -1, -101, - -101, -101, -101, 1273, 124, 2307, -101, 1273, 122, 2307, - -101, 25, -101, 207, -101, -101, 1273, -101, -101, 290, - -101, -101, -101, 114, 1733, -101, -101, 1826, -101, -101, - 1550, -101, -101, -101, -101, -101, -101, 103, -101, -101, - -101, -101, -101, -101, -101, -101, 2404, -101, -101, -101, - 221, -43, 704, 164, -26, 12, -101, -101, 188, -101, - 196, -101, -101, -101, 369, 183, -101, 1273, -101, 165, - -101, -101, 170, 0, 369, 160, 10, 369, 113, -101, - -101, 215, -101, 1273, -101, 225, -101, -101, 203, 369, - 28, 1273, 229, -101, -101, 202, -101, 218, -101, 30, - -21, 369, 199, 278, -101, 110, -101, -101, -101, 1640, - 1092, 583, -101, -101, -101, -101, -101, 284, 2501, 1919, - 14, 388, 29, 424, 93, 1273, 2307, 39, -9, 338, - 21, -3, 821, 24, 23, -101, 1367, -101, 48, 20, - 47, 1273, 50, 26, 1273, 53, 1273, 27, 22, 264, - 120, -101, 15, 813, -101, -101, -101, -101, -101, 1183, - -101, -101, 19, -101, -101, 498, -101, 249, -82, 902, - -101, -101, 118, 369, -101, 204, -101, 80, -101, -101, - 369, -101, -101, 82, -101, -101, -101, -101, -101, -101, + 100, 1288, -101, -101, 70, 59, -101, 1288, -101, -101, + 1288, -101, -101, -101, -101, -101, -101, -101, -101, -101, + -101, -101, -101, -101, 1288, 41, 1288, 1288, 98, 91, + 1288, -101, 2031, 1288, 1288, -101, 121, -101, 73, -101, + -101, 39, -101, 385, 180, 78, -101, 391, -101, 64, + 2322, -101, -101, -101, -101, -101, 208, -101, -101, 82, + -101, -101, -101, -101, -101, -101, 2322, -101, -101, 538, + -101, 495, 128, 2419, 54, 358, 62, 44, 2613, 67, + 1288, -101, 76, 63, 1288, 58, -101, 60, 46, -101, + -101, 309, -101, -101, -101, -101, -101, -101, 86, -101, + -101, -101, -101, 107, -101, -101, -101, -101, -101, -101, + 28, 52, 1288, 101, 102, -101, -101, 1472, -101, 83, + 75, 79, -101, 287, 84, 80, 585, 69, 89, 321, + 177, 482, 1288, 297, 1288, 1288, 1288, 1288, 331, 1288, + 1288, 1288, 1288, 1288, 332, 222, 332, 332, 332, 410, + 410, 410, 1288, 57, 1288, 72, 1288, -101, 658, 1288, + -101, 1288, 71, 45, 1288, 61, 2419, -101, 1288, 132, + 2419, -101, 1288, 47, 1288, 1288, 66, 65, 1288, -101, + 68, 112, 81, -101, -101, 1288, -101, 369, 1288, -101, + 85, 1288, 74, 2419, -101, 1288, 122, 2419, -101, 77, + 294, 16, -29, 2322, -53, -101, 2419, -101, 1288, 127, + 2419, -15, 2419, -101, 10, 11, -34, -101, -101, 2419, + -48, 504, 4, 476, 113, 1288, 2419, 2, -28, 420, + 6, -21, 719, 7, 87, -101, 1382, -101, -4, -16, + 5, 1288, 3, -27, 1288, 9, 1288, -18, -31, 1288, + -101, 2225, -7, -101, -101, -101, -101, -101, -101, 1288, + -101, -101, -101, -101, 246, -101, 1288, -38, -101, 2419, + -101, 88, -101, -101, 2419, -101, 1288, 106, 26, -101, + 55, -101, 50, 105, 1288, -101, 48, 38, -101, -8, + -101, 2419, -101, 94, 2419, -101, 238, -101, -101, 104, + 2419, 31, -101, 21, 19, -101, 305, 1, 30, -101, + -101, -101, -101, 1288, 136, 2419, -101, 1288, 134, 2419, + -101, 49, -101, 173, -101, -101, 1288, -101, -101, 363, + -101, -101, -101, 137, 1565, -101, -101, 1658, -101, -101, + 1844, -101, -101, -101, -101, -101, -101, 95, -101, -101, + -101, -101, -101, -101, -101, -101, 2322, -101, -101, -101, + 92, 15, 925, 169, 27, -6, -101, -101, 212, -101, + 191, -101, -101, -101, 323, 211, -101, 1288, -101, 214, + -101, -101, 216, 40, 317, 210, 43, 259, 236, -101, + 36, -101, 747, 96, -101, 29, 747, -101, -101, 1198, + -101, -101, -101, 1107, -101, -101, 231, -101, 1288, -101, + 217, 286, 32, -101, -101, -101, 188, 340, 51, 1288, + 175, -101, -101, 171, -101, 179, -101, 56, -11, 351, + 181, 336, -101, 110, -101, -101, -101, 1934, 647, -101, + -101, -101, -101, 253, 2516, 1751, -5, 460, 22, 468, + 138, 1288, 2419, 24, -2, 412, 23, -3, 836, 20, + 87, -101, 1382, -101, 17, -10, 18, 1288, 25, 8, + 1288, 33, 1288, 12, 14, 120, -101, -101, 13, -101, + -101, 747, -101, 248, -47, 828, -101, -101, 152, 482, + -101, 150, -101, 123, -101, -101, 398, -101, -101, 117, + -101, -101, -101, -101, -101, -101, - -106, 17, -83, 19, 24, 228, -106, -106, -106, -106, - -106, -106, -106, -106, -106, -106, -106, -106, -106, -49, - -106, -106, -106, -106, -106, -106, -106, -106, -106, 101, - -106, -106, -106, 2, -106, -106, -2, 29, 107, 166, - -106, 204, 183, -106, -106, -106, 174, 169, -106, -106, - -106, -106, -106, 145, -106, 141, 137, -106, 152, 161, - -106, -106, -106, -106, 163, 158, 157, -106, -106, -106, - -106, 132, -106, 142, 138, 187, 178, -106, 167, 181, - 81, 82, 85, 83, -106, 93, 114, 96, -106, -106, - -106, -106, -106, -106, -106, -106, -106, -106, -106, 170, - -106, 74, -106, 109, 80, 51, -106, -106, -106, -106, + -106, 6, -92, 10, 5, 278, -106, -106, -106, -106, + -106, -106, -106, -106, -106, -106, -106, -106, -106, -42, + -106, -106, -106, -106, -106, -106, -106, -106, -106, 109, + -106, -106, -106, -10, -106, -106, -35, 24, 73, 90, + -106, 219, 181, -106, -106, -106, 171, 120, -106, -106, + -106, -106, -106, 174, -106, 170, 167, -106, 175, 163, + -106, -106, -106, -106, 184, 177, 180, -106, -106, -106, + -106, 125, -106, 132, 134, 162, 130, -106, 121, 124, + 123, 141, 142, 152, -106, 154, 161, 160, -106, -106, + -106, -106, -106, -106, -106, -106, -106, -106, -106, 139, + -106, 143, -106, 156, 91, 55, -106, -106, -106, -106, -106, -106, -106, -106, -106, -106, -106, -106, -106, -106, -106, -106, -106, -106, -106, -106, -106, -106, -106, -106, -106, -106, -106, -106, -106, -106, -106, -106, -106, -106, - -106, 25, -106, -106, -106, -106, -106, 41, -106, -106, - 50, -106, -106, -106, -106, -106, -106, -106, -106, -106, - -106, -106, -106, -106, 98, -106, 104, 43, -106, -106, - 42, -106, 221, 64, 117, -106, -106, -106, -106, -106, - -106, -106, -106, 54, -106, -106, -106, 55, -106, -106, + -106, 32, -106, -106, -106, -106, -106, 33, -106, -106, + 26, -106, -106, -106, -106, -106, -106, -106, -106, -106, + -106, -106, -106, -106, 96, -106, 119, 52, -106, -106, + 66, -106, 220, 69, 71, -106, -106, -106, -106, -106, + -106, -106, -106, 25, -106, -106, -106, 64, -106, -106, -106, -106, -106, -106, -106, -106, -106, -106, -106, -106, - -106, -106, -106, -106, -106, -106, 47, -106, -106, 38, - -106, 33, -106, 92, -106, 73, -106, -106, 88, -106, - 86, -106, -106, -106, 94, 23, -106, -106, -106, -106, - -106, -11, -106, -106, -106, -106, -106, -106, -106, -106, + -106, -106, -106, -106, -106, -106, 70, -106, -106, 61, + -106, 41, -106, 39, -106, 37, -106, -106, 42, -106, + 79, -106, -106, -106, 81, 72, -106, -106, -106, -106, + -106, -5, -106, -106, -106, -106, -106, -106, -106, -106, -106, -106, -106, -106, -106, -106, -106, -106, -106, -106, - -106, -106, 22, -106, -106, -106, -106, 105, -106, -106, + -106, -106, 21, -106, -106, -106, -106, 112, -106, -106, -106, -106, -106, -106, -106, -106, -106, -106, -106, -106, - -106, 7, 235, -106, 249, 219, 216, 222, -106, 124, - 125, 123, 122, 116, -106, -106, -106, -106, -106, -106, - -106, -106, 191, -106, 232, -106, 225, -106, -106, 231, - -106, 156, -106, -106, 130, -106, 91, -106, 5, -106, - 8, -106, 233, -106, 200, 189, -106, -106, 198, -106, - -106, -106, -106, -106, -106, 245, -106, 108, 95, -106, - -106, 298, -106, 195, -106, 89, -106, 71, -106, -106, - 120, -106, -106, -5, -106, -106, 52, -106, 53, -106, - 56, -106, 60, -106, -106, -106, -106, -106, -106, 39, - -106, 37, -106, 49, -106, 133, 69, -106, -106, 59, - -106, -106, 102, -106, -106, -106, 79, -106, -106, -106, - -106, 62, -106, 45, 67, -106, 75, -106, -106, 44, - -106, 1, -106, -106, -106, -106, -106, -106, -106, 46, - -106, -106, -106, -106, -106, -106, 115, -106, -106, 66, - -106, -106, -106, -106, 70, -106, 77, -106, -106, -106, - -106, -106, -9, -106, 72, -106, -38, -106, -106, -106, - -106, 97, -106, -106, 99, -106, -106, -106, -106, -106, - 40, -51, -106, -106, 36, -106, 34, -106, 63, -106, - -106, -106, -106, 35, -106, 48, -106, 58, -106, 57, - -106, -106, -106, -106, -106, -106, 28, -106, -106, 90, - -106, -106, -106, -106, 65, -106, -106, 159, -106, -106, - 61, -106, -106, -106, -106, -106, -106, -106, -106, -106, - -106, -106, -106, -106, -106, -106, 87, -106, -106, -106, - -106, -106, -13, -106, -106, -106, -106, -106, -106, -106, - -18, -106, -106, -106, -10, -106, -106, 0, -106, -106, - -106, -106, -106, -106, -4, -12, -106, -6, -106, -106, - -106, -106, -106, 3, -106, -106, -106, -106, -23, -14, - -106, 11, -106, -106, -106, -106, -106, 15, -106, -106, - -106, 16, 18, 14, -106, -106, -106, -106, -106, 292, - 399, 180, -106, -106, -106, -106, -106, -106, 26, 286, - 20, 21, -106, 30, -106, 177, 10, -106, -106, 31, - -106, -106, 193, -106, -106, -106, 32, -106, -106, -106, - -106, 27, -106, 13, 76, -106, 68, -106, -106, -106, - -106, -106, -106, 230, -106, -106, -106, -106, -106, 290, - -106, -106, -3, -106, -106, 6, -106, -106, 4, 270, - -106, -106, -106, 9, -106, -106, -106, -106, -106, -106, - 12, -106, -106, -106, -106, -106, -106, -106, -106, -106}; + -106, 17, 237, -106, 192, 236, 224, 225, -106, 97, + 98, 101, 99, 113, -106, -106, -106, -106, -106, -106, + -106, -106, 204, -106, 223, -106, 235, -106, -106, 239, + -106, 197, -106, -106, 228, -106, 27, -106, 13, -106, + 2, -106, 233, -106, 190, 198, -106, -106, 196, -106, + -106, -106, -106, -106, -106, 200, -106, 107, 135, -106, + -106, 186, -106, 84, -106, 80, -106, 76, -106, -106, + 89, -106, -106, -49, -106, -106, 47, -106, 40, -106, + 44, -106, 68, -106, -106, -106, -106, -106, -106, 53, + -106, 35, -106, 49, -106, 87, 63, -106, -106, 30, + -106, -106, 103, -106, -106, -106, 51, -106, -106, -106, + -106, 86, -106, 67, 114, -106, 74, -106, -106, 65, + -106, 56, -106, -106, -106, -106, -106, -106, -106, 62, + -106, -106, -106, -106, -106, -106, 95, -106, -106, 78, + -106, -106, -106, -106, 75, -106, 88, -106, -106, -106, + -106, -106, -54, -106, 45, -106, -40, -106, -106, -106, + -106, 94, -106, -106, 100, -106, -106, -106, -106, -106, + 150, -41, -106, -106, 54, -106, 43, -106, 48, -106, + -106, -106, -106, 59, -106, 57, -106, 60, -106, 58, + -106, -106, -106, -106, -106, -106, 38, -106, -106, 144, + -106, -106, -106, -106, 31, -106, -106, 202, -106, -106, + 50, -106, -106, -106, -106, -106, -106, -106, -106, -106, + -106, -106, -106, -106, -106, -106, 77, -106, -106, -106, + -106, -106, 82, -106, -106, -106, -106, -106, -106, -106, + -17, -106, -106, -106, -4, -106, -106, 12, -106, -106, + -106, -106, -106, -106, -14, 46, -106, -13, -106, -106, + -106, -106, 108, -106, -106, -106, 243, -106, -106, 295, + -106, -106, -106, 290, -106, -106, -106, -106, 346, -106, + -106, -106, 16, -106, -106, -106, 22, 23, -106, 34, + -106, -106, -106, -106, -106, 11, -106, -106, -106, 7, + 1, 8, -106, -106, -106, -106, -106, 307, 179, -106, + -106, -106, -106, -106, 18, 281, 9, 15, -106, 4, + -106, 83, 29, -106, -106, -2, -106, -106, 85, -106, + -106, -106, 3, -106, -106, -106, -106, 14, -106, 0, + 105, -106, 93, -106, -106, -106, -106, -106, -1, -106, + -106, 20, -106, -106, 28, 92, -106, -106, -106, 19, + -106, -106, -106, -106, -106, -106, -12, -106, -106, -106, + -106, -106, -106, -106, -106, -106}; const short QDeclarativeJSGrammar::action_info [] = { - 401, -123, 440, -121, 403, -129, 333, 340, 615, 345, - -96, 352, 348, -118, -100, 389, -126, 257, -99, 342, - 416, 391, 343, 510, 453, 440, 448, 257, -96, 446, - -100, -118, 440, 348, 527, 541, -129, 525, 552, 555, - 538, 545, 466, 424, 399, 408, -110, 560, 560, 420, - 431, 444, 560, 457, -121, -99, 416, -123, 457, 440, - -126, 325, 306, 453, 272, 190, 294, 164, 187, 170, - 257, 272, 141, 430, 346, 312, 296, 312, 409, 414, - 294, 348, 251, 101, 99, 252, 318, 416, 236, 292, - 453, 457, 440, 183, 141, 189, 71, 335, 639, 164, - 147, 304, 179, 71, 99, 443, 427, 301, 434, 141, - 0, 141, 141, 331, 141, 0, 0, 292, 58, 444, - 141, 149, 477, 62, 0, 58, 0, 314, 603, 59, - 141, 315, 141, 172, 63, 141, 59, 247, 246, 141, - 424, 629, 628, 635, 634, 256, 255, 58, 615, 242, - 241, 428, 173, 101, 249, 248, 58, 327, 59, 141, - 141, 249, 248, 488, 254, 166, 418, 59, 142, 167, - 478, 557, 556, 141, 530, 529, 604, 172, 413, 412, - 249, 248, 459, 177, 455, 172, 85, 141, 86, 511, - 517, 350, 85, 523, 86, 559, 173, 64, 174, 87, - 85, 85, 86, 86, 173, 87, 406, 64, 141, 64, - 328, 337, 310, 87, 87, 469, 85, 85, 86, 86, - 0, 560, 533, 0, 0, 511, 521, 520, 511, 87, - 87, 0, 511, 141, 0, 513, 172, 141, 547, 513, - 438, 437, 65, 0, 518, 516, 512, 511, 66, 0, - 512, 103, 65, 0, 65, 173, 274, 275, 66, 0, - 66, 235, 234, 548, 546, 632, 631, 0, 470, 468, - 104, 513, 105, 172, 513, 0, 534, 532, 513, 172, - 561, 0, 512, 276, 277, 512, 537, 536, 34, 512, - 544, 543, 173, 513, 406, 630, 625, -87, 173, 172, - 174, 73, 74, 0, 512, 274, 275, 34, 0, 0, - 626, 624, 0, 0, 73, 74, 0, -87, 173, 34, - 174, 0, 85, 34, 86, 48, 50, 49, 75, 76, - 0, 0, 276, 277, 0, 87, 0, 0, 279, 280, - 623, 75, 76, 0, 48, 50, 49, 281, 0, 0, - 282, 45, 283, 34, 279, 280, 48, 50, 49, 0, - 48, 50, 49, 281, 279, 280, 282, 34, 283, 0, - 45, 279, 280, 281, -341, 0, 282, 0, 283, 0, - 281, 34, 45, 282, 0, 283, 45, 279, 280, 34, - 48, 50, 49, 0, 0, 34, 281, 0, 34, 282, - 0, 283, -341, 0, 48, 50, 49, 6, 5, 4, - 1, 3, 2, 245, 244, 0, 45, 34, 48, 50, - 49, 240, 239, 0, 0, 0, 48, 50, 49, 0, - 45, 0, 48, 50, 49, 48, 50, 49, 0, 0, - 0, 0, 0, 0, 45, 0, 0, 0, 0, 240, - 239, 0, 45, 34, 48, 50, 49, 0, 45, 0, - 0, 45, 34, 0, 0, 34, 0, 0, 0, 0, - 78, 79, 0, 0, 0, 0, 0, 0, 80, 81, - 45, 0, 82, 0, 83, 245, 244, 0, 0, 0, - 48, 50, 49, 0, 245, 244, 0, 240, 239, 48, - 50, 49, 48, 50, 49, 0, 0, 0, 0, 0, - 30, 31, 0, 0, 0, 0, 45, 0, 0, 0, - 33, 0, 0, 0, 0, 45, 0, 34, 45, 0, + 399, 352, 345, -101, 343, 457, 440, 403, 257, -112, + -125, -131, -123, -98, -120, 348, -128, 389, 453, 391, + 416, 401, 408, 563, -101, -123, 416, -120, 539, -131, + -98, -112, -125, 348, 257, 99, 71, 645, 621, 101, + -128, 440, 141, 621, 164, 431, 539, 430, 453, 573, + 457, 444, 440, 424, 71, 424, 101, 446, 559, 420, + 424, 448, 539, 440, 570, 539, 466, 527, 312, 346, + 532, 312, 318, 272, 409, 183, 342, 525, 147, 141, + 348, 510, 457, 414, 272, 325, 0, 0, 252, 99, + 257, 440, 296, 556, -102, 292, 453, 190, 170, 416, + 164, 434, 141, 141, 536, 251, 304, 172, 141, 141, + 443, 0, 335, 340, 141, 427, 0, 0, 0, 149, + 327, 306, 0, 292, 444, 0, 173, 0, 536, 141, + 141, 0, 0, 179, 333, 141, 294, 236, 189, 314, + 141, 301, 141, 315, 141, 477, 331, 242, 241, 413, + 412, 62, 537, 166, 58, 488, 142, 167, 294, 58, + 428, 254, 63, 256, 255, 59, 418, 172, 247, 246, + 59, 575, 574, 328, 249, 248, 616, 177, 641, 640, + 58, 469, 337, 141, 635, 634, 173, 350, 187, 249, + 248, 59, 310, 478, 459, 58, 455, 64, 523, 249, + 248, 85, 85, 86, 86, 103, 59, 565, 511, 172, + 511, 638, 637, 64, 87, 87, 141, 511, 517, 577, + 511, 0, 141, 0, 104, 141, 105, 85, 173, 86, + 174, 172, 566, 564, 470, 468, 562, 561, 548, 511, + 87, 636, 65, 530, 513, 539, 141, 85, 66, 86, + 173, 0, 406, 0, 513, 512, 513, 64, 65, 0, + 87, 172, 0, 513, 66, 512, 513, 512, 172, 235, + 234, 0, 518, 516, 512, 521, 520, 512, 554, 553, + 173, 85, 406, 86, 0, 513, -89, 173, 34, 174, + 73, 74, 549, 547, 87, 631, 512, 531, 529, 438, + 437, 172, 65, 0, 578, 274, 275, 0, 66, 632, + 630, 34, 0, 73, 74, 274, 275, 75, 76, -89, + 173, 0, 174, 34, 0, 48, 50, 49, 0, 0, + 0, 0, 276, 277, 34, 0, 0, 0, 34, 629, + 75, 76, 276, 277, 279, 280, 34, 0, 48, 50, + 49, 45, 34, 281, 279, 280, 282, 85, 283, 86, + 48, 50, 49, 281, 0, 34, 282, 0, 283, 34, + 87, 48, 50, 49, 45, 48, 50, 49, 0, 0, + 34, 0, 0, 48, 50, 49, 45, 34, 0, 48, + 50, 49, 34, 0, 0, 0, 0, 45, 34, 0, + 0, 45, 48, 50, 49, 0, 48, 50, 49, 45, + 0, 0, 0, 0, 34, 45, 0, 48, 50, 49, + 34, 0, 0, 0, 48, 50, 49, 34, 45, 48, + 50, 49, 45, 279, 280, 48, 50, 49, 0, 0, + 0, 34, 281, 45, 0, 282, 0, 283, -343, 34, + 45, 48, 50, 49, 0, 45, -343, 48, 50, 49, + 0, 45, 78, 79, 48, 50, 49, 0, 0, 0, + 80, 81, 0, 0, 82, 0, 83, 45, 48, 50, + 49, 0, 0, 45, 78, 79, 48, 50, 49, 34, + 45, 0, 80, 81, 78, 79, 82, 34, 83, 0, + 0, 0, 80, 81, 45, 34, 82, 0, 83, 0, + 0, 34, 45, 0, 6, 5, 4, 1, 3, 2, + 0, 240, 239, 0, 34, 0, 48, 50, 49, 245, + 244, 0, 0, 34, 48, 50, 49, 245, 244, 0, + 0, 0, 48, 50, 49, 0, 0, 0, 48, 50, + 49, 0, 45, 0, 0, 0, 245, 244, 0, 0, + 45, 48, 50, 49, 0, 240, 239, 34, 45, 0, + 48, 50, 49, 0, 45, 0, 0, 0, 0, 0, + 0, 0, 0, 78, 79, 0, 0, 45, 151, 0, + 0, 80, 81, 0, 0, 82, 45, 83, 152, 240, + 239, 0, 153, 0, 48, 50, 49, 0, 0, 0, + 0, 154, 0, 155, 0, 0, 308, 0, 0, 0, + 0, 0, 0, 0, 156, 0, 157, 62, 0, 0, + 45, 0, 0, 0, 158, 0, 0, 159, 63, 0, + 0, 0, 0, 160, 0, 0, 0, 0, 0, 161, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 30, + 31, 151, 0, 0, 0, 162, 0, 0, 0, 33, + 0, 152, 0, 0, 0, 153, 34, 0, 0, 0, + 35, 36, 0, 37, 154, 0, 155, 0, 0, 0, + 502, 0, 0, 0, 44, 0, 0, 156, 0, 157, + 62, 0, 0, 0, 0, 0, 0, 158, 0, 0, + 159, 63, 51, 48, 50, 49, 160, 52, 0, 0, + 0, 0, 161, 0, 0, 0, 0, 0, 43, 54, + 32, 30, 31, 0, 40, 0, 0, 0, 162, 45, + 0, 33, 0, 0, 0, 0, 0, 0, 34, 0, + 0, 0, 35, 36, 0, 37, 0, 0, 0, 30, + 31, 0, 41, 0, 0, 0, 44, 0, 0, 33, + 0, 0, 0, 0, 0, 0, 34, 0, 0, 0, + 35, 36, 0, 37, 51, 48, 50, 49, 0, 52, + 502, 0, 0, 0, 44, 0, 0, 0, 0, 0, + 43, 54, 32, 0, 0, 0, 40, 0, 0, 0, + 0, 45, 51, 48, 50, 49, 0, 52, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 43, 54, + 32, 0, 0, 0, 40, 0, 0, 0, 0, 45, + 30, 31, 0, 0, 0, 0, 0, 0, 30, 31, + 33, 0, 0, 0, 0, 0, 0, 34, 33, 0, + 0, 35, 36, 0, 37, 34, 0, 0, 0, 35, + 36, 502, 37, 0, 0, 44, 0, 0, 0, 41, + 0, 0, 0, 44, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 51, 48, 50, 49, 0, 52, 0, + 0, 51, 48, 50, 49, 0, 52, 0, 0, 43, + 54, 32, 0, 0, 0, 40, 0, 43, 54, 32, + 45, 0, 0, 40, 0, 0, 0, 0, 45, 30, + 31, 0, 0, 0, 0, 0, 0, 30, 31, 33, + 0, 0, 0, 0, 0, 0, 34, 33, 0, 0, + 35, 36, 0, 37, 34, 0, 0, 0, 35, 36, + 41, 37, 0, 0, 44, 0, 0, 0, 502, 0, + 0, 0, 44, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 51, 48, 50, 49, 0, 52, 0, 0, + 51, 48, 50, 49, 0, 52, 0, 0, 43, 54, + 32, 0, 0, 0, 40, 0, 43, 54, 32, 45, + 0, 0, 40, 0, 0, 0, 0, 45, 0, 0, + 0, 0, 0, 0, 0, 0, 501, 0, 30, 31, + 0, 0, 0, 0, 0, 0, 0, 0, 215, 0, + 0, 0, 0, 0, 0, 34, 0, 0, 0, 35, + 36, 0, 37, 0, 0, 0, 0, 0, 0, 502, + 0, 0, 0, 44, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 51, 503, 505, 504, 0, 52, 0, 0, 0, + 0, 226, 0, 0, 0, 0, 0, 43, 54, 32, + 210, 0, 0, 40, 0, 0, 0, 0, 45, 0, + 0, 0, 0, 0, 0, 0, 0, 501, 0, 30, + 31, 0, 0, 0, 0, 0, 0, 0, 0, 215, + 0, 0, 0, 0, 0, 0, 34, 0, 0, 0, + 35, 36, 0, 37, 0, 0, 0, 0, 0, 0, + 502, 0, 0, 0, 44, 0, 0, 0, 0, 0, + 0, 0, 544, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 51, 503, 505, 504, 0, 52, 0, 0, + 0, 0, 226, 0, 0, 0, 0, 0, 43, 54, + 32, 210, 0, 0, 40, 0, 0, 0, 0, 45, + 0, 0, 0, 0, 0, 0, 0, 0, 501, 0, + 30, 31, 0, 0, 0, 0, 0, 0, 0, 0, + 215, 0, 0, 0, 0, 0, 0, 34, 0, 0, 0, 35, 36, 0, 37, 0, 0, 0, 0, 0, - 0, 502, 0, 0, 0, 44, 0, 0, 151, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 152, 0, - 0, 0, 153, 51, 48, 50, 49, 0, 52, 0, - 0, 154, 0, 155, 0, 0, 0, 0, 0, 43, - 54, 32, 0, 0, 156, 40, 157, 62, 0, 0, - 45, 0, 0, 0, 158, 30, 31, 159, 63, 0, - 0, 0, 0, 160, 0, 33, 0, 0, 0, 161, - 0, 0, 34, 0, 0, 0, 35, 36, 0, 37, - 0, 0, 0, 0, 0, 162, 502, 0, 0, 0, - 44, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 151, 0, 51, 48, - 50, 49, 0, 52, 0, 0, 152, 0, 0, 0, - 153, 0, 0, 0, 43, 54, 32, 0, 0, 154, - 40, 155, 0, 0, 308, 45, 0, 0, 0, 0, - 0, 0, 156, 0, 157, 62, 0, 0, 0, 0, - 0, 0, 158, 0, 0, 159, 63, 0, 0, 0, - 0, 160, 0, 0, 0, 0, 0, 161, 0, 0, - 0, 0, 0, 0, 0, 0, 30, 31, 0, 0, - 0, 0, 0, 162, 0, 0, 33, 0, 0, 0, - 0, 0, 0, 34, 0, 0, 0, 35, 36, 0, - 37, 0, 0, 0, 30, 31, 0, 502, 0, 0, - 0, 44, 0, 0, 33, 0, 0, 0, 0, 0, - 0, 34, 0, 0, 0, 35, 36, 0, 37, 51, - 48, 50, 49, 0, 52, 41, 0, 0, 0, 44, - 0, 0, 0, 0, 0, 43, 54, 32, 0, 0, - 0, 40, 0, 0, 0, 0, 45, 51, 48, 50, - 49, 0, 52, 0, 0, 0, 0, 0, 0, 0, + 0, 502, 0, 0, 0, 44, 0, 0, 0, 0, + 0, 0, 0, 541, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 51, 503, 505, 504, 0, 52, 0, + 0, 0, 0, 226, 0, 0, 0, 0, 0, 43, + 54, 32, 210, 0, 0, 40, 0, 0, 0, 0, + 45, 0, 0, 0, 0, 0, 0, 0, 0, 29, + 30, 31, 0, 0, 0, 0, 0, 0, 0, 0, + 33, 0, 0, 0, 0, 0, 0, 34, 0, 0, + 0, 35, 36, 0, 37, 0, 0, 0, 38, 0, + 39, 41, 42, 0, 0, 44, 0, 0, 0, 46, + 0, 47, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 51, 48, 50, 49, 0, 52, 0, + 53, 0, 55, 0, 56, 0, 0, 0, 0, 43, + 54, 32, 0, 0, 0, 40, 0, 0, 0, 0, + 45, 0, 0, 0, 0, 0, 0, 0, 0, -121, + 0, 0, 0, 29, 30, 31, 0, 0, 0, 0, + 0, 0, 0, 0, 33, 0, 0, 0, 0, 0, + 0, 34, 0, 0, 0, 35, 36, 0, 37, 0, + 0, 0, 38, 0, 39, 41, 42, 0, 0, 44, + 0, 0, 0, 46, 0, 47, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 51, 48, 50, + 49, 0, 52, 0, 53, 0, 55, 0, 56, 0, 0, 0, 0, 43, 54, 32, 0, 0, 0, 40, - 0, 0, 0, 0, 45, 30, 31, 0, 0, 0, - 0, 0, 0, 30, 31, 33, 0, 0, 0, 0, - 0, 0, 34, 33, 0, 0, 35, 36, 0, 37, - 34, 0, 0, 0, 35, 36, 502, 37, 0, 0, - 44, 0, 0, 0, 41, 0, 0, 0, 44, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 51, 48, - 50, 49, 0, 52, 0, 0, 51, 48, 50, 49, - 0, 52, 0, 0, 43, 54, 32, 0, 0, 0, - 40, 0, 43, 54, 32, 45, 0, 0, 40, 0, - 0, 0, 0, 45, 30, 31, 0, 0, 0, 0, - 0, 0, 30, 31, 33, 0, 0, 0, 0, 0, - 0, 34, 33, 0, 0, 35, 36, 0, 37, 34, - 0, 0, 0, 35, 36, 502, 37, 0, 0, 44, - 0, 0, 0, 41, 0, 0, 0, 44, 0, 0, + 0, 0, 0, 0, 45, 0, 0, 0, 0, 0, + 0, 0, 0, 29, 30, 31, 0, 0, 0, 0, + 0, 0, 0, 0, 33, 0, 0, 0, 0, 0, + 0, 34, 0, 0, 0, 35, 36, 0, 37, 0, + 0, 0, 38, 0, 39, 41, 42, 0, 0, 44, + 0, 0, 0, 46, 0, 47, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 51, 48, 50, - 49, 0, 52, 0, 0, 51, 48, 50, 49, 0, - 52, 0, 0, 43, 54, 32, 0, 0, 0, 40, - 0, 43, 54, 32, 45, 0, 0, 40, 0, 0, - 0, 0, 45, 0, 0, 0, 0, 0, 0, 0, - 0, 501, 0, 30, 31, 0, 0, 0, 0, 0, - 0, 0, 0, 215, 0, 0, 0, 0, 0, 0, + 49, 0, 52, 0, 53, 0, 55, 271, 56, 0, + 0, 0, 0, 43, 54, 32, 0, 0, 0, 40, + 0, 0, 0, 0, 45, 0, 0, 0, 0, 0, + 0, 0, 0, 483, 0, 0, 29, 30, 31, 0, + 0, 0, 0, 0, 0, 0, 0, 33, 0, 0, + 0, 0, 0, 0, 34, 0, 0, 0, 35, 36, + 0, 37, 0, 0, 0, 38, 0, 39, 41, 42, + 0, 0, 44, 0, 0, 0, 46, 0, 47, 0, + 0, 486, 0, 0, 0, 0, 0, 0, 0, 0, + 51, 48, 50, 49, 0, 52, 0, 53, 0, 55, + 0, 56, 0, 0, 0, 0, 43, 54, 32, 0, + 0, 0, 40, 0, 0, 0, 0, 45, 0, 0, + 0, 0, 0, 0, 0, 0, 475, 0, 0, 29, + 30, 31, 0, 0, 0, 0, 0, 0, 0, 0, + 33, 0, 0, 0, 0, 0, 0, 34, 0, 0, + 0, 35, 36, 0, 37, 0, 0, 0, 38, 0, + 39, 41, 42, 0, 0, 44, 0, 0, 0, 46, + 0, 47, 0, 0, 481, 0, 0, 0, 0, 0, + 0, 0, 0, 51, 48, 50, 49, 0, 52, 0, + 53, 0, 55, 0, 56, 0, 0, 0, 0, 43, + 54, 32, 0, 0, 0, 40, 0, 0, 0, 0, + 45, 0, 0, 0, 0, 0, 0, 0, 0, 475, + 0, 0, 29, 30, 31, 0, 0, 0, 0, 0, + 0, 0, 0, 33, 0, 0, 0, 0, 0, 0, 34, 0, 0, 0, 35, 36, 0, 37, 0, 0, - 0, 0, 0, 0, 502, 0, 0, 0, 44, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 51, 503, 505, 504, - 0, 52, 0, 0, 0, 0, 226, 0, 0, 0, - 0, 0, 43, 54, 32, 210, 0, 0, 40, 0, + 0, 38, 0, 39, 41, 42, 0, 0, 44, 0, + 0, 0, 46, 0, 47, 0, 0, 476, 0, 0, + 0, 0, 0, 0, 0, 0, 51, 48, 50, 49, + 0, 52, 0, 53, 0, 55, 0, 56, 0, 0, + 0, 0, 43, 54, 32, 0, 0, 0, 40, 0, 0, 0, 0, 45, 0, 0, 0, 0, 0, 0, - 0, 0, 501, 0, 30, 31, 0, 0, 0, 0, - 0, 0, 0, 0, 215, 0, 0, 0, 0, 0, - 0, 34, 0, 0, 0, 35, 36, 0, 37, 0, - 0, 0, 0, 0, 0, 502, 0, 0, 0, 44, - 0, 0, 0, 0, 0, 0, 0, 607, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 51, 503, 505, - 504, 0, 52, 0, 0, 0, 0, 226, 0, 0, - 0, 0, 0, 43, 54, 32, 210, 0, 0, 40, - 0, 0, 0, 0, 45, 0, 0, 0, 0, 0, - 0, 0, 0, 501, 0, 30, 31, 0, 0, 0, - 0, 0, 0, 0, 0, 215, 0, 0, 0, 0, - 0, 0, 34, 0, 0, 0, 35, 36, 0, 37, - 0, 0, 0, 0, 0, 0, 502, 0, 0, 0, - 44, 0, 0, 0, 0, 0, 0, 0, 610, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 51, 503, - 505, 504, 0, 52, 0, 0, 0, 0, 226, 0, - 0, 0, 0, 0, 43, 54, 32, 210, 0, 0, - 40, 0, 0, 0, 0, 45, 0, 0, 0, 0, - 0, 0, 0, 0, 29, 30, 31, 0, 0, 0, - 0, 0, 0, 0, 0, 33, 0, 0, 0, 0, - 0, 0, 34, 0, 0, 0, 35, 36, 0, 37, - 0, 0, 0, 38, 0, 39, 41, 42, 0, 0, - 44, 0, 0, 0, 46, 0, 47, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 51, 48, - 50, 49, 0, 52, 0, 53, 0, 55, 0, 56, - 0, 0, 0, 0, 43, 54, 32, 0, 0, 0, - 40, 0, 0, 0, 0, 45, 0, 0, 0, 0, - 0, 0, 0, 0, -119, 0, 0, 0, 29, 30, - 31, 0, 0, 0, 0, 0, 0, 0, 0, 33, - 0, 0, 0, 0, 0, 0, 34, 0, 0, 0, - 35, 36, 0, 37, 0, 0, 0, 38, 0, 39, - 41, 42, 0, 0, 44, 0, 0, 0, 46, 0, - 47, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 51, 48, 50, 49, 0, 52, 0, 53, - 0, 55, 0, 56, 0, 0, 0, 0, 43, 54, - 32, 0, 0, 0, 40, 0, 0, 0, 0, 45, - 0, 0, 0, 0, 0, 0, 0, 0, 29, 30, - 31, 0, 0, 0, 0, 0, 0, 0, 0, 33, - 0, 0, 0, 0, 0, 0, 34, 0, 0, 0, - 35, 36, 0, 37, 0, 0, 0, 38, 0, 39, - 41, 42, 0, 0, 44, 0, 0, 0, 46, 0, - 47, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 51, 48, 50, 49, 0, 52, 0, 53, - 0, 55, 271, 56, 0, 0, 0, 0, 43, 54, - 32, 0, 0, 0, 40, 0, 0, 0, 0, 45, - 0, 0, 0, 0, 0, 0, 0, 0, 483, 0, - 0, 29, 30, 31, 0, 0, 0, 0, 0, 0, - 0, 0, 33, 0, 0, 0, 0, 0, 0, 34, - 0, 0, 0, 35, 36, 0, 37, 0, 0, 0, - 38, 0, 39, 41, 42, 0, 0, 44, 0, 0, - 0, 46, 0, 47, 0, 0, 484, 0, 0, 0, - 0, 0, 0, 0, 0, 51, 48, 50, 49, 0, - 52, 0, 53, 0, 55, 0, 56, 0, 0, 0, - 0, 43, 54, 32, 0, 0, 0, 40, 0, 0, - 0, 0, 45, 0, 0, 0, 0, 0, 0, 0, - 0, 29, 30, 31, 0, 0, 0, 0, 0, 0, - 0, 0, 33, 0, 0, 0, 0, 0, 0, 34, - 217, 0, 0, 568, 569, 0, 37, 0, 0, 0, - 38, 0, 39, 41, 42, 0, 0, 44, 0, 0, - 0, 46, 0, 47, 0, 0, 0, 0, 0, 0, - 0, 221, 0, 0, 0, 51, 48, 50, 49, 0, - 52, 0, 53, 0, 55, 0, 56, 0, 0, 0, - 0, 43, 54, 32, 0, 0, 0, 40, 0, 0, - 0, 0, 45, 0, 0, 0, 0, 0, 0, 0, - 0, 483, 0, 0, 29, 30, 31, 0, 0, 0, - 0, 0, 0, 0, 0, 33, 0, 0, 0, 0, - 0, 0, 34, 0, 0, 0, 35, 36, 0, 37, - 0, 0, 0, 38, 0, 39, 41, 42, 0, 0, - 44, 0, 0, 0, 46, 0, 47, 0, 0, 486, - 0, 0, 0, 0, 0, 0, 0, 0, 51, 48, - 50, 49, 0, 52, 0, 53, 0, 55, 0, 56, - 0, 0, 0, 0, 43, 54, 32, 0, 0, 0, - 40, 0, 0, 0, 0, 45, 0, 0, 0, 0, - 0, 0, 0, 0, 475, 0, 0, 29, 30, 31, - 0, 0, 0, 0, 0, 0, 0, 0, 33, 0, - 0, 0, 0, 0, 0, 34, 0, 0, 0, 35, - 36, 0, 37, 0, 0, 0, 38, 0, 39, 41, - 42, 0, 0, 44, 0, 0, 0, 46, 0, 47, - 0, 0, 481, 0, 0, 0, 0, 0, 0, 0, - 0, 51, 48, 50, 49, 0, 52, 0, 53, 0, - 55, 0, 56, 0, 0, 0, 0, 43, 54, 32, - 0, 0, 0, 40, 0, 0, 0, 0, 45, 0, - 0, 0, 0, 0, 0, 0, 0, 475, 0, 0, - 29, 30, 31, 0, 0, 0, 0, 0, 0, 0, - 0, 33, 0, 0, 0, 0, 0, 0, 34, 0, - 0, 0, 35, 36, 0, 37, 0, 0, 0, 38, - 0, 39, 41, 42, 0, 0, 44, 0, 0, 0, - 46, 0, 47, 0, 0, 476, 0, 0, 0, 0, - 0, 0, 0, 0, 51, 48, 50, 49, 0, 52, - 0, 53, 0, 55, 0, 56, 0, 0, 0, 0, - 43, 54, 32, 0, 0, 0, 40, 0, 0, 0, - 0, 45, 0, 0, 0, 0, 0, 0, 0, 0, - 109, 110, 111, 0, 0, 113, 115, 116, 0, 0, - 117, 0, 118, 0, 0, 0, 120, 121, 122, 0, - 0, 0, 0, 0, 0, 34, 123, 124, 125, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 126, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 129, 0, 0, 0, 0, - 0, 0, 48, 50, 49, 130, 131, 132, 0, 134, - 135, 136, 137, 138, 139, 0, 0, 127, 133, 119, - 112, 114, 128, 0, 0, 0, 0, 0, 45, 0, - 0, 0, 0, 0, 0, 0, 0, 109, 110, 111, - 0, 0, 113, 115, 116, 0, 0, 117, 0, 118, - 0, 0, 0, 120, 121, 122, 0, 0, 0, 0, - 0, 0, 393, 123, 124, 125, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 126, 0, 0, 0, - 394, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 129, 0, 0, 0, 0, 0, 398, 395, - 397, 0, 130, 131, 132, 0, 134, 135, 136, 137, - 138, 139, 0, 0, 127, 133, 119, 112, 114, 128, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 109, 110, 111, 0, 0, 113, - 115, 116, 0, 0, 117, 0, 118, 0, 0, 0, - 120, 121, 122, 0, 0, 0, 0, 0, 0, 393, - 123, 124, 125, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 126, 0, 0, 0, 394, 0, 0, - 0, 0, 0, 0, 0, 396, 0, 0, 0, 129, - 0, 0, 0, 0, 0, 398, 395, 397, 0, 130, - 131, 132, 0, 134, 135, 136, 137, 138, 139, 0, - 0, 127, 133, 119, 112, 114, 128, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 209, 0, 0, 0, 0, 211, 0, 29, 30, - 31, 213, 0, 0, 0, 0, 0, 0, 214, 33, - 0, 0, 0, 0, 0, 0, 216, 217, 0, 0, - 218, 36, 0, 37, 0, 0, 0, 38, 0, 39, - 41, 42, 0, 0, 44, 0, 0, 0, 46, 0, - 47, 0, 0, 0, 0, 0, 220, 0, 221, 0, - 0, 0, 51, 219, 222, 49, 223, 52, 224, 53, - 225, 55, 226, 56, 227, 228, 0, 0, 43, 54, - 32, 210, 212, 0, 40, 0, 0, 0, 0, 45, - 0, 0, 0, 0, 0, 0, 0, 0, 209, 0, - 0, 0, 0, 211, 0, 29, 30, 31, 213, 0, - 0, 0, 0, 0, 0, 214, 215, 0, 0, 0, - 0, 0, 0, 216, 217, 0, 0, 218, 36, 0, + 0, 0, 483, 0, 0, 29, 30, 31, 0, 0, + 0, 0, 0, 0, 0, 0, 33, 0, 0, 0, + 0, 0, 0, 34, 0, 0, 0, 35, 36, 0, + 37, 0, 0, 0, 38, 0, 39, 41, 42, 0, + 0, 44, 0, 0, 0, 46, 0, 47, 0, 0, + 484, 0, 0, 0, 0, 0, 0, 0, 0, 51, + 48, 50, 49, 0, 52, 0, 53, 0, 55, 0, + 56, 0, 0, 0, 0, 43, 54, 32, 0, 0, + 0, 40, 0, 0, 0, 0, 45, 0, 0, 0, + 0, 0, 0, 0, 0, 29, 30, 31, 0, 0, + 0, 0, 0, 0, 0, 0, 33, 0, 0, 0, + 0, 0, 0, 34, 217, 0, 0, 584, 585, 0, 37, 0, 0, 0, 38, 0, 39, 41, 42, 0, 0, 44, 0, 0, 0, 46, 0, 47, 0, 0, - 0, 0, 0, 220, 0, 221, 0, 0, 0, 51, - 219, 222, 49, 223, 52, 224, 53, 225, 55, 226, - 56, 227, 228, 0, 0, 43, 54, 32, 210, 212, + 0, 0, 0, 0, 0, 221, 0, 0, 0, 51, + 48, 50, 49, 0, 52, 0, 53, 0, 55, 0, + 56, 0, 0, 0, 0, 43, 54, 32, 0, 0, 0, 40, 0, 0, 0, 0, 45, 0, 0, 0, - 0, 0, 0, 0, 0, 571, 110, 111, 0, 0, - 573, 115, 575, 30, 31, 576, 0, 118, 0, 0, - 0, 120, 578, 579, 0, 0, 0, 0, 0, 0, - 580, 581, 124, 125, 218, 36, 0, 37, 0, 0, - 0, 38, 0, 39, 582, 42, 0, 0, 584, 0, - 0, 0, 46, 0, 47, 0, 0, 0, 0, 0, - 586, 0, 221, 0, 0, 0, 588, 585, 587, 49, - 589, 590, 591, 53, 593, 594, 595, 596, 597, 598, - 0, 0, 583, 592, 577, 572, 574, 128, 40, 0, + 0, 0, 0, 0, 0, 109, 110, 111, 0, 0, + 113, 115, 116, 0, 0, 117, 0, 118, 0, 0, + 0, 120, 121, 122, 0, 0, 0, 0, 0, 0, + 34, 123, 124, 125, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 126, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 129, 0, 0, 0, 0, 0, 0, 48, 50, 49, + 130, 131, 132, 0, 134, 135, 136, 137, 138, 139, + 0, 0, 127, 133, 119, 112, 114, 128, 0, 0, 0, 0, 0, 45, 0, 0, 0, 0, 0, 0, - 0, 0, 361, 110, 111, 0, 0, 363, 115, 365, - 30, 31, 366, 0, 118, 0, 0, 0, 120, 368, - 369, 0, 0, 0, 0, 0, 0, 370, 371, 124, - 125, 218, 36, 0, 37, 0, 0, 0, 38, 0, - 39, 372, 42, 0, 0, 374, 0, 0, 0, 46, - 0, 47, 0, -265, 0, 0, 0, 376, 0, 221, - 0, 0, 0, 378, 375, 377, 49, 379, 380, 381, - 53, 383, 384, 385, 386, 387, 388, 0, 0, 373, - 382, 367, 362, 364, 128, 40, 0, 0, 0, 0, - 45, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 109, 110, 111, 0, 0, 113, 115, 116, + 0, 0, 117, 0, 118, 0, 0, 0, 120, 121, + 122, 0, 0, 0, 0, 0, 0, 393, 123, 124, + 125, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 126, 0, 0, 0, 394, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 129, 0, 0, + 0, 0, 0, 398, 395, 397, 0, 130, 131, 132, + 0, 134, 135, 136, 137, 138, 139, 0, 0, 127, + 133, 119, 112, 114, 128, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 109, + 110, 111, 0, 0, 113, 115, 116, 0, 0, 117, + 0, 118, 0, 0, 0, 120, 121, 122, 0, 0, + 0, 0, 0, 0, 393, 123, 124, 125, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 126, 0, + 0, 0, 394, 0, 0, 0, 0, 0, 0, 0, + 396, 0, 0, 0, 129, 0, 0, 0, 0, 0, + 398, 395, 397, 0, 130, 131, 132, 0, 134, 135, + 136, 137, 138, 139, 0, 0, 127, 133, 119, 112, + 114, 128, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 209, 0, 0, 0, + 0, 211, 0, 29, 30, 31, 213, 0, 0, 0, + 0, 0, 0, 214, 215, 0, 0, 0, 0, 0, + 0, 216, 217, 0, 0, 218, 36, 0, 37, 0, + 0, 0, 38, 0, 39, 41, 42, 0, 0, 44, + 0, 0, 0, 46, 0, 47, 0, 0, 0, 0, + 0, 220, 0, 221, 0, 0, 0, 51, 219, 222, + 49, 223, 52, 224, 53, 225, 55, 226, 56, 227, + 228, 0, 0, 43, 54, 32, 210, 212, 0, 40, + 0, 0, 0, 0, 45, 0, 0, 0, 0, 0, + 0, 0, 0, 209, 0, 0, 0, 0, 211, 0, + 29, 30, 31, 213, 0, 0, 0, 0, 0, 0, + 214, 33, 0, 0, 0, 0, 0, 0, 216, 217, + 0, 0, 218, 36, 0, 37, 0, 0, 0, 38, + 0, 39, 41, 42, 0, 0, 44, 0, 0, 0, + 46, 0, 47, 0, 0, 0, 0, 0, 220, 0, + 221, 0, 0, 0, 51, 219, 222, 49, 223, 52, + 224, 53, 225, 55, 226, 56, 227, 228, 0, 0, + 43, 54, 32, 210, 212, 0, 40, 0, 0, 0, + 0, 45, 0, 0, 0, 0, 0, 0, 0, 0, + 587, 110, 111, 0, 0, 589, 115, 591, 30, 31, + 592, 0, 118, 0, 0, 0, 120, 594, 595, 0, + 0, 0, 0, 0, 0, 596, 597, 124, 125, 218, + 36, 0, 37, 0, 0, 0, 38, 0, 39, 598, + 42, 0, 0, 600, 0, 0, 0, 46, 0, 47, + 0, 0, 0, 0, 0, 602, 0, 221, 0, 0, + 0, 604, 601, 603, 49, 605, 606, 607, 53, 609, + 610, 611, 612, 613, 614, 0, 0, 599, 608, 593, + 588, 590, 128, 40, 0, 0, 0, 0, 45, 0, + 0, 0, 0, 0, 0, 0, 0, 361, 110, 111, + 0, 0, 363, 115, 365, 30, 31, 366, 0, 118, + 0, 0, 0, 120, 368, 369, 0, 0, 0, 0, + 0, 0, 370, 371, 124, 125, 218, 36, 0, 37, + 0, 0, 0, 38, 0, 39, 372, 42, 0, 0, + 374, 0, 0, 0, 46, 0, 47, 0, -267, 0, + 0, 0, 376, 0, 221, 0, 0, 0, 378, 375, + 377, 49, 379, 380, 381, 53, 383, 384, 385, 386, + 387, 388, 0, 0, 373, 382, 367, 362, 364, 128, + 40, 0, 0, 0, 0, 45, 0, 0, 0, 0, + 0, 0, 0, 0, - 522, 540, 539, 519, 461, 515, 535, 514, 309, 528, - 311, 531, 250, 526, 542, 636, 613, 182, 150, 622, - 16, 496, 320, 497, 627, 253, 498, 633, 358, 554, - 436, 558, 487, 472, 439, 302, 238, 392, 454, 606, - 551, 402, 358, 553, 439, 243, 182, 445, 243, 447, - 456, 237, 238, 238, 347, 429, 349, 450, 351, 460, - 143, 458, 353, 467, 243, 436, 439, 176, 410, 186, - 188, 250, 415, 338, 182, 433, 148, 171, 169, 390, - 417, 400, 302, 140, 449, 163, 146, 425, 339, 302, - 358, 237, 336, 307, 250, 344, 482, 436, 302, 358, - 485, 358, 0, 0, 0, 461, 0, 0, 0, 0, - 0, 60, 60, 451, 452, 404, 0, 0, 60, 60, - 60, 452, 451, 320, 106, 60, 60, 60, 102, 60, - 92, 93, 95, 302, 94, 186, 0, 60, 0, 0, - 60, 88, 60, 405, 90, 60, 108, 180, 60, 266, - 146, 60, 146, 489, 270, 407, 165, 178, 60, 302, - 60, 0, 89, 330, 168, 288, 60, 60, 60, 60, - 0, 287, 286, 284, 285, 471, 60, 60, 432, 180, - 435, 60, 60, 452, 72, 60, 60, 451, 96, 60, - 480, 494, 77, 500, 479, 329, 60, 334, 305, 61, - 612, 60, 60, 69, 68, 60, 404, 60, 70, 67, - 60, 60, 490, 60, 60, 493, 84, 404, 60, 341, - 492, 60, 60, 180, 303, 60, 100, 60, 98, 491, - 91, 60, 0, 298, 405, 60, 106, 97, 270, 0, - 270, 500, 298, 500, 60, 405, 605, 270, 293, 270, - 602, 0, 0, 0, 0, 317, 499, 509, 108, 175, - 60, 316, 0, 60, 319, 270, 60, 290, 270, 298, - 289, 270, 0, 291, 270, 298, 60, 60, 0, 60, - 270, 270, 270, 500, 270, 0, 637, 295, 273, 298, - 602, 297, 313, 60, 270, 611, 0, 300, 270, 599, - 278, 302, 601, 500, 0, 567, 602, 0, 0, 0, - 0, 326, 570, 563, 564, 565, 566, 0, 499, 509, - 0, 472, 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, 332, 0, 0, 0, + 472, 546, 528, 639, 311, 182, 302, 498, 514, 16, + 461, 515, 496, 182, 497, 519, 309, 436, 619, 243, + 358, 439, 576, 572, 253, 150, 571, 487, 617, 307, + 238, 250, 320, 628, 633, 555, 569, 560, 558, 642, + 186, 250, 425, 349, 358, 182, 351, 557, 433, 347, + 238, 344, 339, 429, 302, 402, 243, 445, 447, 456, + 460, 163, 454, 458, 243, 250, 485, 143, 148, 449, + 353, 526, 176, 467, 237, 450, 238, 415, 338, 188, + 410, 237, 302, 336, 436, 482, 334, 169, 439, 436, + 146, 417, 392, 439, 140, 522, 358, 400, 404, 0, + 390, 171, 358, 0, 186, 500, 146, 0, 643, 0, + 0, 178, 0, 0, 0, 0, 404, 60, 60, 489, + 452, 500, 320, 0, 534, 0, 405, 60, 0, 180, + 146, 60, 0, 180, 60, 407, 490, 60, 302, 452, + 60, 60, 60, 60, 405, 60, 284, 285, 287, 60, + 286, 451, 358, 60, 165, 180, 266, 60, 60, 461, + 451, 270, 288, 60, 60, 60, 493, 60, 60, 60, + 84, 106, 92, 91, 60, 432, 60, 72, 60, 168, + 98, 435, 77, 60, 96, 60, 60, 60, 341, 302, + 93, 94, 500, 108, 329, 100, 60, 102, 60, 618, + 302, 95, 88, 330, 60, 60, 60, 60, 90, 89, + 70, 60, 97, 452, 60, 60, 451, 492, 60, 60, + 494, 60, 61, 68, 60, 60, 69, 491, 60, 471, + 67, 302, 404, 480, 60, 106, 60, 479, 0, 270, + 298, 270, 298, 278, 298, 270, 0, 270, 60, 270, + 0, 316, 0, 270, 332, 0, 500, 108, 175, 538, + 405, 293, 319, 0, 317, 303, 326, 60, 60, 60, + 0, 0, 270, 270, 270, 290, 291, 60, 295, 298, + 60, 60, 270, 298, 270, 270, 270, 289, 270, 0, + 273, 500, 313, 0, 551, 545, 305, 534, 508, 615, + 542, 297, 0, 500, 0, 300, 499, 509, 500, 0, + 508, 0, 0, 0, 0, 508, 472, 0, 499, 509, + 583, 0, 0, 499, 509, 0, 0, 586, 579, 580, + 581, 582, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 550, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 551, + 0, 0, 0, 0, 0, 0, 552, 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, 608, 0, 0, 0, 0, 0, - 0, 0, 500, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 499, 509, 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, 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}; const short QDeclarativeJSGrammar::action_check [] = { - 55, 7, 33, 7, 55, 7, 60, 36, 90, 55, - 7, 16, 36, 7, 7, 7, 7, 36, 7, 60, - 36, 8, 33, 66, 36, 33, 60, 36, 7, 36, - 7, 7, 33, 36, 24, 7, 7, 37, 8, 60, - 66, 29, 17, 5, 7, 60, 7, 33, 33, 33, - 7, 20, 33, 36, 7, 7, 36, 7, 36, 33, - 7, 17, 60, 36, 1, 33, 79, 2, 8, 7, - 36, 1, 8, 55, 7, 2, 8, 2, 7, 7, - 79, 36, 77, 79, 48, 36, 7, 36, 55, 48, - 36, 36, 33, 36, 8, 60, 1, 31, 0, 2, - 8, 61, 60, 1, 48, 6, 10, 61, 7, 8, - -1, 8, 8, 61, 8, -1, -1, 48, 40, 20, - 8, 60, 8, 42, -1, 40, -1, 50, 8, 51, - 8, 54, 8, 15, 53, 8, 51, 61, 62, 8, - 5, 61, 62, 61, 62, 61, 62, 40, 90, 61, - 62, 55, 34, 79, 61, 62, 40, 8, 51, 8, - 8, 61, 62, 60, 60, 50, 60, 51, 56, 54, - 56, 61, 62, 8, 61, 62, 56, 15, 61, 62, - 61, 62, 60, 56, 60, 15, 25, 8, 27, 29, - 7, 60, 25, 29, 27, 7, 34, 12, 36, 38, - 25, 25, 27, 27, 34, 38, 36, 12, 8, 12, - 61, 60, 60, 38, 38, 8, 25, 25, 27, 27, - -1, 33, 7, -1, -1, 29, 61, 62, 29, 38, - 38, -1, 29, 8, -1, 75, 15, 8, 36, 75, - 61, 62, 57, -1, 61, 62, 86, 29, 63, -1, - 86, 15, 57, -1, 57, 34, 18, 19, 63, -1, - 63, 61, 62, 61, 62, 61, 62, -1, 61, 62, - 34, 75, 36, 15, 75, -1, 61, 62, 75, 15, - 92, -1, 86, 45, 46, 86, 61, 62, 29, 86, - 61, 62, 34, 75, 36, 91, 47, 33, 34, 15, - 36, 18, 19, -1, 86, 18, 19, 29, -1, -1, - 61, 62, -1, -1, 18, 19, -1, 33, 34, 29, - 36, -1, 25, 29, 27, 66, 67, 68, 45, 46, - -1, -1, 45, 46, -1, 38, -1, -1, 23, 24, - 91, 45, 46, -1, 66, 67, 68, 32, -1, -1, - 35, 92, 37, 29, 23, 24, 66, 67, 68, -1, - 66, 67, 68, 32, 23, 24, 35, 29, 37, -1, - 92, 23, 24, 32, 36, -1, 35, -1, 37, -1, - 32, 29, 92, 35, -1, 37, 92, 23, 24, 29, - 66, 67, 68, -1, -1, 29, 32, -1, 29, 35, - -1, 37, 36, -1, 66, 67, 68, 93, 94, 95, - 96, 97, 98, 61, 62, -1, 92, 29, 66, 67, - 68, 61, 62, -1, -1, -1, 66, 67, 68, -1, - 92, -1, 66, 67, 68, 66, 67, 68, -1, -1, - -1, -1, -1, -1, 92, -1, -1, -1, -1, 61, - 62, -1, 92, 29, 66, 67, 68, -1, 92, -1, - -1, 92, 29, -1, -1, 29, -1, -1, -1, -1, - 23, 24, -1, -1, -1, -1, -1, -1, 31, 32, - 92, -1, 35, -1, 37, 61, 62, -1, -1, -1, - 66, 67, 68, -1, 61, 62, -1, 61, 62, 66, - 67, 68, 66, 67, 68, -1, -1, -1, -1, -1, - 12, 13, -1, -1, -1, -1, 92, -1, -1, -1, - 22, -1, -1, -1, -1, 92, -1, 29, 92, -1, + 7, 16, 55, 7, 33, 36, 33, 55, 36, 7, + 7, 7, 7, 7, 7, 36, 7, 7, 36, 8, + 36, 55, 60, 29, 7, 7, 36, 7, 33, 7, + 7, 7, 7, 36, 36, 48, 1, 0, 90, 79, + 7, 33, 8, 90, 2, 7, 33, 55, 36, 60, + 36, 20, 33, 5, 1, 5, 79, 36, 7, 33, + 5, 60, 33, 33, 8, 33, 17, 24, 2, 7, + 34, 2, 7, 1, 7, 36, 60, 37, 8, 8, + 36, 66, 36, 7, 1, 17, -1, -1, 36, 48, + 36, 33, 8, 66, 7, 48, 36, 33, 7, 36, + 2, 7, 8, 8, 8, 77, 61, 15, 8, 8, + 6, -1, 31, 36, 8, 10, -1, -1, -1, 60, + 8, 60, -1, 48, 20, -1, 34, -1, 8, 8, + 8, -1, -1, 60, 60, 8, 79, 55, 60, 50, + 8, 61, 8, 54, 8, 8, 61, 61, 62, 61, + 62, 42, 56, 50, 40, 60, 56, 54, 79, 40, + 55, 60, 53, 61, 62, 51, 60, 15, 61, 62, + 51, 61, 62, 61, 61, 62, 56, 56, 61, 62, + 40, 8, 60, 8, 61, 62, 34, 60, 8, 61, + 62, 51, 60, 56, 60, 40, 60, 12, 29, 61, + 62, 25, 25, 27, 27, 15, 51, 36, 29, 15, + 29, 61, 62, 12, 38, 38, 8, 29, 7, 7, + 29, -1, 8, -1, 34, 8, 36, 25, 34, 27, + 36, 15, 61, 62, 61, 62, 61, 62, 7, 29, + 38, 91, 57, 7, 75, 33, 8, 25, 63, 27, + 34, -1, 36, -1, 75, 86, 75, 12, 57, -1, + 38, 15, -1, 75, 63, 86, 75, 86, 15, 61, + 62, -1, 61, 62, 86, 61, 62, 86, 61, 62, + 34, 25, 36, 27, -1, 75, 33, 34, 29, 36, + 18, 19, 61, 62, 38, 47, 86, 61, 62, 61, + 62, 15, 57, -1, 92, 18, 19, -1, 63, 61, + 62, 29, -1, 18, 19, 18, 19, 45, 46, 33, + 34, -1, 36, 29, -1, 66, 67, 68, -1, -1, + -1, -1, 45, 46, 29, -1, -1, -1, 29, 91, + 45, 46, 45, 46, 23, 24, 29, -1, 66, 67, + 68, 92, 29, 32, 23, 24, 35, 25, 37, 27, + 66, 67, 68, 32, -1, 29, 35, -1, 37, 29, + 38, 66, 67, 68, 92, 66, 67, 68, -1, -1, + 29, -1, -1, 66, 67, 68, 92, 29, -1, 66, + 67, 68, 29, -1, -1, -1, -1, 92, 29, -1, + -1, 92, 66, 67, 68, -1, 66, 67, 68, 92, + -1, -1, -1, -1, 29, 92, -1, 66, 67, 68, + 29, -1, -1, -1, 66, 67, 68, 29, 92, 66, + 67, 68, 92, 23, 24, 66, 67, 68, -1, -1, + -1, 29, 32, 92, -1, 35, -1, 37, 36, 29, + 92, 66, 67, 68, -1, 92, 36, 66, 67, 68, + -1, 92, 23, 24, 66, 67, 68, -1, -1, -1, + 31, 32, -1, -1, 35, -1, 37, 92, 66, 67, + 68, -1, -1, 92, 23, 24, 66, 67, 68, 29, + 92, -1, 31, 32, 23, 24, 35, 29, 37, -1, + -1, -1, 31, 32, 92, 29, 35, -1, 37, -1, + -1, 29, 92, -1, 93, 94, 95, 96, 97, 98, + -1, 61, 62, -1, 29, -1, 66, 67, 68, 61, + 62, -1, -1, 29, 66, 67, 68, 61, 62, -1, + -1, -1, 66, 67, 68, -1, -1, -1, 66, 67, + 68, -1, 92, -1, -1, -1, 61, 62, -1, -1, + 92, 66, 67, 68, -1, 61, 62, 29, 92, -1, + 66, 67, 68, -1, 92, -1, -1, -1, -1, -1, + -1, -1, -1, 23, 24, -1, -1, 92, 3, -1, + -1, 31, 32, -1, -1, 35, 92, 37, 13, 61, + 62, -1, 17, -1, 66, 67, 68, -1, -1, -1, + -1, 26, -1, 28, -1, -1, 31, -1, -1, -1, + -1, -1, -1, -1, 39, -1, 41, 42, -1, -1, + 92, -1, -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, 12, + 13, 3, -1, -1, -1, 80, -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, 66, 67, 68, 58, 70, -1, -1, + -1, -1, 64, -1, -1, -1, -1, -1, 81, 82, + 83, 12, 13, -1, 87, -1, -1, -1, 80, 92, + -1, 22, -1, -1, -1, -1, -1, -1, 29, -1, + -1, -1, 33, 34, -1, 36, -1, -1, -1, 12, + 13, -1, 43, -1, -1, -1, 47, -1, -1, 22, + -1, -1, -1, -1, -1, -1, 29, -1, -1, -1, + 33, 34, -1, 36, 65, 66, 67, 68, -1, 70, + 43, -1, -1, -1, 47, -1, -1, -1, -1, -1, + 81, 82, 83, -1, -1, -1, 87, -1, -1, -1, + -1, 92, 65, 66, 67, 68, -1, 70, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, 81, 82, + 83, -1, -1, -1, 87, -1, -1, -1, -1, 92, + 12, 13, -1, -1, -1, -1, -1, -1, 12, 13, + 22, -1, -1, -1, -1, -1, -1, 29, 22, -1, + -1, 33, 34, -1, 36, 29, -1, -1, -1, 33, + 34, 43, 36, -1, -1, 47, -1, -1, -1, 43, + -1, -1, -1, 47, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 65, 66, 67, 68, -1, 70, -1, + -1, 65, 66, 67, 68, -1, 70, -1, -1, 81, + 82, 83, -1, -1, -1, 87, -1, 81, 82, 83, + 92, -1, -1, 87, -1, -1, -1, -1, 92, 12, + 13, -1, -1, -1, -1, -1, -1, 12, 13, 22, + -1, -1, -1, -1, -1, -1, 29, 22, -1, -1, + 33, 34, -1, 36, 29, -1, -1, -1, 33, 34, + 43, 36, -1, -1, 47, -1, -1, -1, 43, -1, + -1, -1, 47, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 65, 66, 67, 68, -1, 70, -1, -1, + 65, 66, 67, 68, -1, 70, -1, -1, 81, 82, + 83, -1, -1, -1, 87, -1, 81, 82, 83, 92, + -1, -1, 87, -1, -1, -1, -1, 92, -1, -1, + -1, -1, -1, -1, -1, -1, 10, -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, 65, 66, 67, 68, -1, 70, -1, -1, -1, + -1, 75, -1, -1, -1, -1, -1, 81, 82, 83, + 84, -1, -1, 87, -1, -1, -1, -1, 92, -1, + -1, -1, -1, -1, -1, -1, -1, 10, -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, 55, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 65, 66, 67, 68, -1, 70, -1, -1, + -1, -1, 75, -1, -1, -1, -1, -1, 81, 82, + 83, 84, -1, -1, 87, -1, -1, -1, -1, 92, + -1, -1, -1, -1, -1, -1, -1, -1, 10, -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, 3, -1, - -1, -1, -1, -1, -1, -1, -1, -1, 13, -1, - -1, -1, 17, 65, 66, 67, 68, -1, 70, -1, - -1, 26, -1, 28, -1, -1, -1, -1, -1, 81, - 82, 83, -1, -1, 39, 87, 41, 42, -1, -1, - 92, -1, -1, -1, 49, 12, 13, 52, 53, -1, - -1, -1, -1, 58, -1, 22, -1, -1, -1, 64, - -1, -1, 29, -1, -1, -1, 33, 34, -1, 36, - -1, -1, -1, -1, -1, 80, 43, -1, -1, -1, - 47, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, 3, -1, 65, 66, - 67, 68, -1, 70, -1, -1, 13, -1, -1, -1, - 17, -1, -1, -1, 81, 82, 83, -1, -1, 26, - 87, 28, -1, -1, 31, 92, -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, -1, -1, - -1, -1, -1, -1, -1, -1, 12, 13, -1, -1, - -1, -1, -1, 80, -1, -1, 22, -1, -1, -1, - -1, -1, -1, 29, -1, -1, -1, 33, 34, -1, - 36, -1, -1, -1, 12, 13, -1, 43, -1, -1, - -1, 47, -1, -1, 22, -1, -1, -1, -1, -1, - -1, 29, -1, -1, -1, 33, 34, -1, 36, 65, - 66, 67, 68, -1, 70, 43, -1, -1, -1, 47, - -1, -1, -1, -1, -1, 81, 82, 83, -1, -1, - -1, 87, -1, -1, -1, -1, 92, 65, 66, 67, - 68, -1, 70, -1, -1, -1, -1, -1, -1, -1, + -1, 43, -1, -1, -1, 47, -1, -1, -1, -1, + -1, -1, -1, 55, -1, -1, -1, -1, -1, -1, + -1, -1, -1, 65, 66, 67, 68, -1, 70, -1, + -1, -1, -1, 75, -1, -1, -1, -1, -1, 81, + 82, 83, 84, -1, -1, 87, -1, -1, -1, -1, + 92, -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, 68, -1, 70, -1, + 72, -1, 74, -1, 76, -1, -1, -1, -1, 81, + 82, 83, -1, -1, -1, 87, -1, -1, -1, -1, + 92, -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, + 68, -1, 70, -1, 72, -1, 74, -1, 76, -1, -1, -1, -1, 81, 82, 83, -1, -1, -1, 87, - -1, -1, -1, -1, 92, 12, 13, -1, -1, -1, - -1, -1, -1, 12, 13, 22, -1, -1, -1, -1, - -1, -1, 29, 22, -1, -1, 33, 34, -1, 36, - 29, -1, -1, -1, 33, 34, 43, 36, -1, -1, - 47, -1, -1, -1, 43, -1, -1, -1, 47, -1, - -1, -1, -1, -1, -1, -1, -1, -1, 65, 66, - 67, 68, -1, 70, -1, -1, 65, 66, 67, 68, - -1, 70, -1, -1, 81, 82, 83, -1, -1, -1, - 87, -1, 81, 82, 83, 92, -1, -1, 87, -1, - -1, -1, -1, 92, 12, 13, -1, -1, -1, -1, - -1, -1, 12, 13, 22, -1, -1, -1, -1, -1, - -1, 29, 22, -1, -1, 33, 34, -1, 36, 29, - -1, -1, -1, 33, 34, 43, 36, -1, -1, 47, - -1, -1, -1, 43, -1, -1, -1, 47, -1, -1, + -1, -1, -1, -1, 92, -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, - 68, -1, 70, -1, -1, 65, 66, 67, 68, -1, - 70, -1, -1, 81, 82, 83, -1, -1, -1, 87, - -1, 81, 82, 83, 92, -1, -1, 87, -1, -1, - -1, -1, 92, -1, -1, -1, -1, -1, -1, -1, - -1, 10, -1, 12, 13, -1, -1, -1, -1, -1, + 68, -1, 70, -1, 72, -1, 74, 75, 76, -1, + -1, -1, -1, 81, 82, 83, -1, -1, -1, 87, + -1, -1, -1, -1, 92, -1, -1, -1, -1, -1, + -1, -1, -1, 8, -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, 68, -1, 70, -1, 72, -1, 74, + -1, 76, -1, -1, -1, -1, 81, 82, 83, -1, + -1, -1, 87, -1, -1, -1, -1, 92, -1, -1, + -1, -1, -1, -1, -1, -1, 8, -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, 68, -1, 70, -1, + 72, -1, 74, -1, 76, -1, -1, -1, -1, 81, + 82, 83, -1, -1, -1, 87, -1, -1, -1, -1, + 92, -1, -1, -1, -1, -1, -1, -1, -1, 8, + -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, -1, -1, -1, 43, -1, -1, -1, 47, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -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, 68, - -1, 70, -1, -1, -1, -1, 75, -1, -1, -1, - -1, -1, 81, 82, 83, 84, -1, -1, 87, -1, + -1, 70, -1, 72, -1, 74, -1, 76, -1, -1, + -1, -1, 81, 82, 83, -1, -1, -1, 87, -1, -1, -1, -1, 92, -1, -1, -1, -1, -1, -1, - -1, -1, 10, -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, 55, -1, -1, - -1, -1, -1, -1, -1, -1, -1, 65, 66, 67, - 68, -1, 70, -1, -1, -1, -1, 75, -1, -1, - -1, -1, -1, 81, 82, 83, 84, -1, -1, 87, - -1, -1, -1, -1, 92, -1, -1, -1, -1, -1, - -1, -1, -1, 10, -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, 55, -1, - -1, -1, -1, -1, -1, -1, -1, -1, 65, 66, - 67, 68, -1, 70, -1, -1, -1, -1, 75, -1, - -1, -1, -1, -1, 81, 82, 83, 84, -1, -1, - 87, -1, -1, -1, -1, 92, -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, 68, -1, 70, -1, 72, -1, 74, -1, 76, - -1, -1, -1, -1, 81, 82, 83, -1, -1, -1, - 87, -1, -1, -1, -1, 92, -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, 68, -1, 70, -1, 72, - -1, 74, -1, 76, -1, -1, -1, -1, 81, 82, - 83, -1, -1, -1, 87, -1, -1, -1, -1, 92, - -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, 68, -1, 70, -1, 72, - -1, 74, 75, 76, -1, -1, -1, -1, 81, 82, - 83, -1, -1, -1, 87, -1, -1, -1, -1, 92, - -1, -1, -1, -1, -1, -1, -1, -1, 8, -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, 68, -1, - 70, -1, 72, -1, 74, -1, 76, -1, -1, -1, - -1, 81, 82, 83, -1, -1, -1, 87, -1, -1, - -1, -1, 92, -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, - 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, -1, - -1, 61, -1, -1, -1, 65, 66, 67, 68, -1, - 70, -1, 72, -1, 74, -1, 76, -1, -1, -1, - -1, 81, 82, 83, -1, -1, -1, 87, -1, -1, - -1, -1, 92, -1, -1, -1, -1, -1, -1, -1, - -1, 8, -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, 68, -1, 70, -1, 72, -1, 74, -1, 76, - -1, -1, -1, -1, 81, 82, 83, -1, -1, -1, - 87, -1, -1, -1, -1, 92, -1, -1, -1, -1, - -1, -1, -1, -1, 8, -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, 68, -1, 70, -1, 72, -1, - 74, -1, 76, -1, -1, -1, -1, 81, 82, 83, - -1, -1, -1, 87, -1, -1, -1, -1, 92, -1, - -1, -1, -1, -1, -1, -1, -1, 8, -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, 68, -1, 70, - -1, 72, -1, 74, -1, 76, -1, -1, -1, -1, - 81, 82, 83, -1, -1, -1, 87, -1, -1, -1, - -1, 92, -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, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, 59, -1, -1, -1, -1, - -1, -1, 66, 67, 68, 69, 70, 71, -1, 73, - 74, 75, 76, 77, 78, -1, -1, 81, 82, 83, - 84, 85, 86, -1, -1, -1, -1, -1, 92, -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, -1, -1, -1, -1, - -1, -1, 59, -1, -1, -1, -1, -1, 65, 66, - 67, -1, 69, 70, 71, -1, 73, 74, 75, 76, - 77, 78, -1, -1, 81, 82, 83, 84, 85, 86, - -1, -1, -1, -1, -1, -1, -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, -1, -1, 55, -1, -1, -1, 59, - -1, -1, -1, -1, -1, 65, 66, 67, -1, 69, - 70, 71, -1, 73, 74, 75, 76, 77, 78, -1, - -1, 81, 82, 83, 84, 85, 86, -1, -1, -1, - -1, -1, -1, -1, -1, -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, 78, -1, -1, 81, 82, - 83, 84, 85, -1, 87, -1, -1, -1, -1, 92, - -1, -1, -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, 8, -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, 68, -1, 70, -1, 72, -1, 74, -1, + 76, -1, -1, -1, -1, 81, 82, 83, -1, -1, + -1, 87, -1, -1, -1, -1, 92, -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, 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, 78, -1, -1, 81, 82, 83, 84, 85, + -1, -1, -1, -1, -1, 61, -1, -1, -1, 65, + 66, 67, 68, -1, 70, -1, 72, -1, 74, -1, + 76, -1, -1, -1, -1, 81, 82, 83, -1, -1, -1, 87, -1, -1, -1, -1, 92, -1, -1, -1, -1, -1, -1, -1, -1, 4, 5, 6, -1, -1, - 9, 10, 11, 12, 13, 14, -1, 16, -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, 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, 78, - -1, -1, 81, 82, 83, 84, 85, 86, 87, -1, + 29, 30, 31, 32, -1, -1, -1, -1, -1, -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, -1, 66, 67, 68, + 69, 70, 71, -1, 73, 74, 75, 76, 77, 78, + -1, -1, 81, 82, 83, 84, 85, 86, -1, -1, -1, -1, -1, 92, -1, -1, -1, -1, -1, -1, -1, -1, 4, 5, 6, -1, -1, 9, 10, 11, - 12, 13, 14, -1, 16, -1, -1, -1, 20, 21, + -1, -1, 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, 78, -1, -1, 81, - 82, 83, 84, 85, 86, 87, -1, -1, -1, -1, - 92, -1, -1, -1, -1, -1, -1, -1, -1, + 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, -1, 69, 70, 71, + -1, 73, 74, 75, 76, 77, 78, -1, -1, 81, + 82, 83, 84, 85, 86, -1, -1, -1, -1, -1, + -1, -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, -1, -1, + 55, -1, -1, -1, 59, -1, -1, -1, -1, -1, + 65, 66, 67, -1, 69, 70, 71, -1, 73, 74, + 75, 76, 77, 78, -1, -1, 81, 82, 83, 84, + 85, 86, -1, -1, -1, -1, -1, -1, -1, -1, + -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, + 78, -1, -1, 81, 82, 83, 84, 85, -1, 87, + -1, -1, -1, -1, 92, -1, -1, -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, 78, -1, -1, + 81, 82, 83, 84, 85, -1, 87, -1, -1, -1, + -1, 92, -1, -1, -1, -1, -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, -1, -1, -1, -1, 59, -1, 61, -1, -1, + -1, 65, 66, 67, 68, 69, 70, 71, 72, 73, + 74, 75, 76, 77, 78, -1, -1, 81, 82, 83, + 84, 85, 86, 87, -1, -1, -1, -1, 92, -1, + -1, -1, -1, -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, 78, -1, -1, 81, 82, 83, 84, 85, 86, + 87, -1, -1, -1, -1, 92, -1, -1, -1, -1, + -1, -1, -1, -1, - 13, 15, 25, 3, 15, 15, 3, 25, 3, 15, - 2, 15, 2, 25, 3, 11, 19, 15, 67, 13, - 3, 104, 15, 4, 15, 3, 2, 15, 2, 15, - 3, 15, 3, 35, 21, 3, 15, 36, 3, 19, - 25, 2, 2, 25, 21, 15, 15, 98, 15, 15, - 2, 4, 15, 15, 2, 93, 3, 21, 2, 2, - 35, 3, 2, 35, 15, 3, 21, 3, 2, 15, - 15, 2, 2, 2, 15, 3, 35, 35, 35, 35, - 3, 35, 3, 3, 21, 35, 35, 96, 15, 3, - 2, 4, 3, 2, 2, 100, 35, 3, 3, 2, - 35, 2, -1, -1, -1, 15, -1, -1, -1, -1, - -1, 44, 44, 46, 46, 13, -1, -1, 44, 44, - 44, 46, 46, 15, 15, 44, 44, 44, 54, 44, - 49, 49, 49, 3, 49, 15, -1, 44, -1, -1, - 44, 48, 44, 41, 48, 44, 37, 46, 44, 44, - 35, 44, 35, 46, 49, 40, 58, 40, 44, 3, - 44, -1, 48, 68, 60, 49, 44, 44, 44, 44, - -1, 49, 49, 49, 49, 85, 44, 44, 81, 46, - 81, 44, 44, 46, 52, 44, 44, 46, 50, 44, - 31, 46, 50, 13, 35, 87, 44, 2, 68, 47, - 20, 44, 44, 46, 46, 44, 13, 44, 47, 46, - 44, 44, 46, 44, 44, 46, 49, 13, 44, 99, - 46, 44, 44, 46, 68, 44, 56, 44, 50, 46, - 49, 44, -1, 44, 41, 44, 15, 50, 49, -1, - 49, 13, 44, 13, 44, 41, 16, 49, 57, 49, - 20, -1, -1, -1, -1, 66, 28, 29, 37, 38, - 44, 61, -1, 44, 66, 49, 44, 51, 49, 44, - 51, 49, -1, 51, 49, 44, 44, 44, -1, 44, - 49, 49, 49, 13, 49, -1, 16, 55, 53, 44, - 20, 66, 59, 44, 49, 5, -1, 66, 49, 13, - 51, 3, 16, 13, -1, 13, 20, -1, -1, -1, - -1, 66, 20, 21, 22, 23, 24, -1, 28, 29, - -1, 35, -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, 68, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 35, 15, 15, 15, 2, 15, 3, 2, 25, 3, + 15, 15, 104, 15, 4, 3, 3, 3, 19, 15, + 2, 21, 15, 15, 3, 67, 25, 3, 19, 2, + 15, 2, 15, 13, 15, 19, 25, 3, 15, 11, + 15, 2, 96, 3, 2, 15, 2, 25, 3, 2, + 15, 100, 15, 93, 3, 2, 15, 98, 15, 2, + 2, 35, 3, 3, 15, 2, 35, 35, 35, 21, + 2, 25, 3, 35, 4, 21, 15, 2, 2, 15, + 2, 4, 3, 3, 3, 35, 2, 35, 21, 3, + 35, 3, 36, 21, 3, 13, 2, 35, 13, -1, + 35, 35, 2, -1, 15, 13, 35, -1, 16, -1, + -1, 40, -1, -1, -1, -1, 13, 44, 44, 46, + 46, 13, 15, -1, 16, -1, 41, 44, -1, 46, + 35, 44, -1, 46, 44, 40, 46, 44, 3, 46, + 44, 44, 44, 44, 41, 44, 49, 49, 49, 44, + 49, 46, 2, 44, 58, 46, 44, 44, 44, 15, + 46, 49, 49, 44, 44, 44, 46, 44, 44, 44, + 49, 15, 49, 49, 44, 81, 44, 52, 44, 60, + 50, 81, 50, 44, 50, 44, 44, 44, 99, 3, + 49, 49, 13, 37, 87, 56, 44, 54, 44, 20, + 3, 49, 48, 68, 44, 44, 44, 44, 48, 48, + 47, 44, 50, 46, 44, 44, 46, 46, 44, 44, + 46, 44, 47, 46, 44, 44, 46, 46, 44, 85, + 46, 3, 13, 31, 44, 15, 44, 35, -1, 49, + 44, 49, 44, 51, 44, 49, -1, 49, 44, 49, + -1, 61, -1, 49, 68, -1, 13, 37, 38, 16, + 41, 57, 66, -1, 66, 68, 66, 44, 44, 44, + -1, -1, 49, 49, 49, 51, 51, 44, 55, 44, + 44, 44, 49, 44, 49, 49, 49, 51, 49, -1, + 53, 13, 59, -1, 13, 5, 68, 16, 20, 18, + 5, 66, -1, 13, -1, 66, 28, 29, 13, -1, + 20, -1, -1, -1, -1, 20, 35, -1, 28, 29, + 13, -1, -1, 28, 29, -1, -1, 20, 21, 22, + 23, 24, -1, -1, -1, -1, -1, -1, -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, -1, -1, -1, 20, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, 5, -1, -1, -1, -1, -1, - -1, -1, 13, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, 28, 29, -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, @@ -987,6 +984,6 @@ const short QDeclarativeJSGrammar::action_check [] = { -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}; QT_END_NAMESPACE diff --git a/src/declarative/qml/parser/qdeclarativejsgrammar_p.h b/src/declarative/qml/parser/qdeclarativejsgrammar_p.h index 32bb12b..064c67a 100644 --- a/src/declarative/qml/parser/qdeclarativejsgrammar_p.h +++ b/src/declarative/qml/parser/qdeclarativejsgrammar_p.h @@ -164,15 +164,15 @@ public: T_XOR = 79, T_XOR_EQ = 80, - ACCEPT_STATE = 639, - RULE_COUNT = 345, - STATE_COUNT = 640, + ACCEPT_STATE = 645, + RULE_COUNT = 347, + STATE_COUNT = 646, TERMINAL_COUNT = 101, NON_TERMINAL_COUNT = 106, - GOTO_INDEX_OFFSET = 640, - GOTO_INFO_OFFSET = 2699, - GOTO_CHECK_OFFSET = 2699 + GOTO_INDEX_OFFSET = 646, + GOTO_INFO_OFFSET = 2714, + GOTO_CHECK_OFFSET = 2714 }; static const char *const spell []; diff --git a/src/declarative/qml/parser/qdeclarativejsparser.cpp b/src/declarative/qml/parser/qdeclarativejsparser.cpp index 3cf73b1..170c7fa 100644 --- a/src/declarative/qml/parser/qdeclarativejsparser.cpp +++ b/src/declarative/qml/parser/qdeclarativejsparser.cpp @@ -487,80 +487,124 @@ case 60: { } break; case 61: { - sym(1).Node = makeAstNode<AST::UiSourceElement>(driver->nodePool(), sym(1).Node); + AST::UiPublicMember *node = makeAstNode<AST::UiPublicMember> (driver->nodePool(), sym(4).sval, sym(6).sval); + node->typeModifier = sym(2).sval; + node->propertyToken = loc(1); + node->typeModifierToken = loc(2); + node->typeToken = loc(4); + node->identifierToken = loc(6); + node->semicolonToken = loc(7); // insert a fake ';' before ':' + + AST::UiQualifiedId *propertyName = makeAstNode<AST::UiQualifiedId>(driver->nodePool(), sym(6).sval); + propertyName->identifierToken = loc(6); + propertyName->next = 0; + + AST::UiArrayBinding *binding = makeAstNode<AST::UiArrayBinding> (driver->nodePool(), + propertyName, sym(9).UiArrayMemberList->finish()); + binding->colonToken = loc(7); + binding->lbracketToken = loc(8); + binding->rbracketToken = loc(10); + + node->binding = binding; + + sym(1).Node = node; } break; case 62: { + AST::UiPublicMember *node = makeAstNode<AST::UiPublicMember> (driver->nodePool(), sym(2).sval, sym(3).sval); + node->propertyToken = loc(1); + node->typeToken = loc(2); + node->identifierToken = loc(3); + node->semicolonToken = loc(4); // insert a fake ';' before ':' + + AST::UiQualifiedId *propertyName = makeAstNode<AST::UiQualifiedId>(driver->nodePool(), sym(3).sval); + propertyName->identifierToken = loc(3); + propertyName->next = 0; + + AST::UiObjectBinding *binding = makeAstNode<AST::UiObjectBinding> (driver->nodePool(), + propertyName, sym(5).UiQualifiedId, sym(6).UiObjectInitializer); + binding->colonToken = loc(4); + + node->binding = binding; + + sym(1).Node = node; +} break; + +case 63: { sym(1).Node = makeAstNode<AST::UiSourceElement>(driver->nodePool(), sym(1).Node); } break; case 64: { + sym(1).Node = makeAstNode<AST::UiSourceElement>(driver->nodePool(), sym(1).Node); +} break; + +case 66: { QString s = QLatin1String(QDeclarativeJSGrammar::spell[T_PROPERTY]); sym(1).sval = driver->intern(s.constData(), s.length()); break; } -case 65: { +case 67: { QString s = QLatin1String(QDeclarativeJSGrammar::spell[T_SIGNAL]); sym(1).sval = driver->intern(s.constData(), s.length()); break; } -case 66: { +case 68: { QString s = QLatin1String(QDeclarativeJSGrammar::spell[T_READONLY]); sym(1).sval = driver->intern(s.constData(), s.length()); break; } -case 67: { +case 69: { QString s = QLatin1String(QDeclarativeJSGrammar::spell[T_ON]); sym(1).sval = driver->intern(s.constData(), s.length()); break; } -case 68: { +case 70: { AST::ThisExpression *node = makeAstNode<AST::ThisExpression> (driver->nodePool()); node->thisToken = loc(1); sym(1).Node = node; } break; -case 69: { +case 71: { AST::IdentifierExpression *node = makeAstNode<AST::IdentifierExpression> (driver->nodePool(), sym(1).sval); node->identifierToken = loc(1); sym(1).Node = node; } break; -case 70: { +case 72: { AST::NullExpression *node = makeAstNode<AST::NullExpression> (driver->nodePool()); node->nullToken = loc(1); sym(1).Node = node; } break; -case 71: { +case 73: { AST::TrueLiteral *node = makeAstNode<AST::TrueLiteral> (driver->nodePool()); node->trueToken = loc(1); sym(1).Node = node; } break; -case 72: { +case 74: { AST::FalseLiteral *node = makeAstNode<AST::FalseLiteral> (driver->nodePool()); node->falseToken = loc(1); sym(1).Node = node; } break; -case 73: { +case 75: { AST::NumericLiteral *node = makeAstNode<AST::NumericLiteral> (driver->nodePool(), sym(1).dval); node->literalToken = loc(1); sym(1).Node = node; } break; -case 74: -case 75: { +case 76: +case 77: { AST::StringLiteral *node = makeAstNode<AST::StringLiteral> (driver->nodePool(), sym(1).sval); node->literalToken = loc(1); sym(1).Node = node; } break; -case 76: { +case 78: { bool rx = lexer->scanRegExp(Lexer::NoPrefix); if (!rx) { diagnostic_messages.append(DiagnosticMessage(DiagnosticMessage::Error, location(lexer), lexer->errorMessage())); @@ -574,7 +618,7 @@ case 76: { sym(1).Node = node; } break; -case 77: { +case 79: { bool rx = lexer->scanRegExp(Lexer::EqualPrefix); if (!rx) { diagnostic_messages.append(DiagnosticMessage(DiagnosticMessage::Error, location(lexer), lexer->errorMessage())); @@ -588,28 +632,28 @@ case 77: { sym(1).Node = node; } break; -case 78: { +case 80: { AST::ArrayLiteral *node = makeAstNode<AST::ArrayLiteral> (driver->nodePool(), (AST::Elision *) 0); node->lbracketToken = loc(1); node->rbracketToken = loc(2); sym(1).Node = node; } break; -case 79: { +case 81: { AST::ArrayLiteral *node = makeAstNode<AST::ArrayLiteral> (driver->nodePool(), sym(2).Elision->finish()); node->lbracketToken = loc(1); node->rbracketToken = loc(3); sym(1).Node = node; } break; -case 80: { +case 82: { 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 81: { +case 83: { AST::ArrayLiteral *node = makeAstNode<AST::ArrayLiteral> (driver->nodePool(), sym(2).ElementList->finish (), (AST::Elision *) 0); node->lbracketToken = loc(1); @@ -618,7 +662,7 @@ case 81: { sym(1).Node = node; } break; -case 82: { +case 84: { AST::ArrayLiteral *node = makeAstNode<AST::ArrayLiteral> (driver->nodePool(), sym(2).ElementList->finish (), sym(4).Elision->finish()); node->lbracketToken = loc(1); @@ -627,7 +671,7 @@ case 82: { sym(1).Node = node; } break; -case 83: { +case 85: { AST::ObjectLiteral *node = 0; if (sym(2).Node) node = makeAstNode<AST::ObjectLiteral> (driver->nodePool(), @@ -639,7 +683,7 @@ case 83: { sym(1).Node = node; } break; -case 84: { +case 86: { AST::ObjectLiteral *node = makeAstNode<AST::ObjectLiteral> (driver->nodePool(), sym(2).PropertyNameAndValueList->finish ()); node->lbraceToken = loc(1); @@ -647,14 +691,14 @@ case 84: { sym(1).Node = node; } break; -case 85: { +case 87: { 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 86: { +case 88: { if (AST::ArrayMemberExpression *mem = AST::cast<AST::ArrayMemberExpression *>(sym(1).Expression)) { diagnostic_messages.append(DiagnosticMessage(DiagnosticMessage::Warning, mem->lbracketToken, QLatin1String("Ignored annotation"))); @@ -674,48 +718,48 @@ case 86: { } } break; -case 87: { +case 89: { sym(1).Node = makeAstNode<AST::ElementList> (driver->nodePool(), (AST::Elision *) 0, sym(1).Expression); } break; -case 88: { +case 90: { sym(1).Node = makeAstNode<AST::ElementList> (driver->nodePool(), sym(1).Elision->finish(), sym(2).Expression); } break; -case 89: { +case 91: { AST::ElementList *node = makeAstNode<AST::ElementList> (driver->nodePool(), sym(1).ElementList, (AST::Elision *) 0, sym(3).Expression); node->commaToken = loc(2); sym(1).Node = node; } break; -case 90: { +case 92: { AST::ElementList *node = makeAstNode<AST::ElementList> (driver->nodePool(), sym(1).ElementList, sym(3).Elision->finish(), sym(4).Expression); node->commaToken = loc(2); sym(1).Node = node; } break; -case 91: { +case 93: { AST::Elision *node = makeAstNode<AST::Elision> (driver->nodePool()); node->commaToken = loc(1); sym(1).Node = node; } break; -case 92: { +case 94: { AST::Elision *node = makeAstNode<AST::Elision> (driver->nodePool(), sym(1).Elision); node->commaToken = loc(2); sym(1).Node = node; } break; -case 93: { +case 95: { AST::PropertyNameAndValueList *node = makeAstNode<AST::PropertyNameAndValueList> (driver->nodePool(), sym(1).PropertyName, sym(3).Expression); node->colonToken = loc(2); sym(1).Node = node; } break; -case 94: { +case 96: { AST::PropertyNameAndValueList *node = makeAstNode<AST::PropertyNameAndValueList> (driver->nodePool(), sym(1).PropertyNameAndValueList, sym(3).PropertyName, sym(5).Expression); node->commaToken = loc(2); @@ -723,40 +767,36 @@ case 94: { sym(1).Node = node; } break; -case 95: { +case 97: { AST::IdentifierPropertyName *node = makeAstNode<AST::IdentifierPropertyName> (driver->nodePool(), sym(1).sval); node->propertyNameToken = loc(1); sym(1).Node = node; } break; -case 96: -case 97: { +case 98: +case 99: { AST::IdentifierPropertyName *node = makeAstNode<AST::IdentifierPropertyName> (driver->nodePool(), driver->intern(lexer->characterBuffer(), lexer->characterCount())); node->propertyNameToken = loc(1); sym(1).Node = node; } break; -case 98: { +case 100: { AST::StringLiteralPropertyName *node = makeAstNode<AST::StringLiteralPropertyName> (driver->nodePool(), sym(1).sval); node->propertyNameToken = loc(1); sym(1).Node = node; } break; -case 99: { +case 101: { AST::NumericLiteralPropertyName *node = makeAstNode<AST::NumericLiteralPropertyName> (driver->nodePool(), sym(1).dval); node->propertyNameToken = loc(1); sym(1).Node = node; } break; -case 100: { +case 102: { AST::IdentifierPropertyName *node = makeAstNode<AST::IdentifierPropertyName> (driver->nodePool(), sym(1).sval); node->propertyNameToken = loc(1); sym(1).Node = node; } break; -case 101: - -case 102: - case 103: case 104: @@ -814,25 +854,29 @@ case 129: case 130: case 131: + +case 132: + +case 133: { sym(1).sval = driver->intern(lexer->characterBuffer(), lexer->characterCount()); } break; -case 136: { +case 138: { 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 137: { +case 139: { 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 138: { +case 140: { AST::NewMemberExpression *node = makeAstNode<AST::NewMemberExpression> (driver->nodePool(), sym(2).Expression, sym(4).ArgumentList); node->newToken = loc(1); node->lparenToken = loc(3); @@ -840,316 +884,309 @@ case 138: { sym(1).Node = node; } break; -case 140: { +case 142: { AST::NewExpression *node = makeAstNode<AST::NewExpression> (driver->nodePool(), sym(2).Expression); node->newToken = loc(1); sym(1).Node = node; } break; -case 141: { +case 143: { 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 142: { +case 144: { 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 143: { +case 145: { 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 144: { +case 146: { 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 145: { +case 147: { sym(1).Node = 0; } break; -case 146: { +case 148: { sym(1).Node = sym(1).ArgumentList->finish(); } break; -case 147: { +case 149: { sym(1).Node = makeAstNode<AST::ArgumentList> (driver->nodePool(), sym(1).Expression); } break; -case 148: { +case 150: { AST::ArgumentList *node = makeAstNode<AST::ArgumentList> (driver->nodePool(), sym(1).ArgumentList, sym(3).Expression); node->commaToken = loc(2); sym(1).Node = node; } break; -case 152: { +case 154: { AST::PostIncrementExpression *node = makeAstNode<AST::PostIncrementExpression> (driver->nodePool(), sym(1).Expression); node->incrementToken = loc(2); sym(1).Node = node; } break; -case 153: { +case 155: { AST::PostDecrementExpression *node = makeAstNode<AST::PostDecrementExpression> (driver->nodePool(), sym(1).Expression); node->decrementToken = loc(2); sym(1).Node = node; } break; -case 155: { +case 157: { AST::DeleteExpression *node = makeAstNode<AST::DeleteExpression> (driver->nodePool(), sym(2).Expression); node->deleteToken = loc(1); sym(1).Node = node; } break; -case 156: { +case 158: { AST::VoidExpression *node = makeAstNode<AST::VoidExpression> (driver->nodePool(), sym(2).Expression); node->voidToken = loc(1); sym(1).Node = node; } break; -case 157: { +case 159: { AST::TypeOfExpression *node = makeAstNode<AST::TypeOfExpression> (driver->nodePool(), sym(2).Expression); node->typeofToken = loc(1); sym(1).Node = node; } break; -case 158: { +case 160: { AST::PreIncrementExpression *node = makeAstNode<AST::PreIncrementExpression> (driver->nodePool(), sym(2).Expression); node->incrementToken = loc(1); sym(1).Node = node; } break; -case 159: { +case 161: { AST::PreDecrementExpression *node = makeAstNode<AST::PreDecrementExpression> (driver->nodePool(), sym(2).Expression); node->decrementToken = loc(1); sym(1).Node = node; } break; -case 160: { +case 162: { AST::UnaryPlusExpression *node = makeAstNode<AST::UnaryPlusExpression> (driver->nodePool(), sym(2).Expression); node->plusToken = loc(1); sym(1).Node = node; } break; -case 161: { +case 163: { AST::UnaryMinusExpression *node = makeAstNode<AST::UnaryMinusExpression> (driver->nodePool(), sym(2).Expression); node->minusToken = loc(1); sym(1).Node = node; } break; -case 162: { +case 164: { AST::TildeExpression *node = makeAstNode<AST::TildeExpression> (driver->nodePool(), sym(2).Expression); node->tildeToken = loc(1); sym(1).Node = node; } break; -case 163: { +case 165: { AST::NotExpression *node = makeAstNode<AST::NotExpression> (driver->nodePool(), sym(2).Expression); node->notToken = loc(1); sym(1).Node = node; } break; -case 165: { +case 167: { 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 166: { +case 168: { 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 167: { +case 169: { 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 169: { +case 171: { 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 170: { +case 172: { 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 172: { +case 174: { 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 173: { +case 175: { 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 174: { +case 176: { 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 176: { +case 178: { 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 177: { +case 179: { 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 178: { +case 180: { 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 179: { +case 181: { 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 180: { +case 182: { 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 181: { +case 183: { 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 183: { +case 185: { 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 184: { +case 186: { 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 185: { +case 187: { 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 186: { +case 188: { 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 187: { +case 189: { 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 189: { +case 191: { 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 190: { +case 192: { 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 191: { +case 193: { 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 192: { +case 194: { 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 194: { +case 196: { 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 195: { +case 197: { 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 196: { +case 198: { 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 197: { - 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 199: { AST::BinaryExpression *node = makeAstNode<AST::BinaryExpression> (driver->nodePool(), sym(1).Expression, - QSOperator::BitAnd, sym(3).Expression); + QSOperator::StrictNotEqual, sym(3).Expression); node->operatorToken = loc(2); sym(1).Node = node; } break; @@ -1163,7 +1200,7 @@ case 201: { case 203: { AST::BinaryExpression *node = makeAstNode<AST::BinaryExpression> (driver->nodePool(), sym(1).Expression, - QSOperator::BitXor, sym(3).Expression); + QSOperator::BitAnd, sym(3).Expression); node->operatorToken = loc(2); sym(1).Node = node; } break; @@ -1177,7 +1214,7 @@ case 205: { case 207: { AST::BinaryExpression *node = makeAstNode<AST::BinaryExpression> (driver->nodePool(), sym(1).Expression, - QSOperator::BitOr, sym(3).Expression); + QSOperator::BitXor, sym(3).Expression); node->operatorToken = loc(2); sym(1).Node = node; } break; @@ -1191,7 +1228,7 @@ case 209: { case 211: { AST::BinaryExpression *node = makeAstNode<AST::BinaryExpression> (driver->nodePool(), sym(1).Expression, - QSOperator::And, sym(3).Expression); + QSOperator::BitOr, sym(3).Expression); node->operatorToken = loc(2); sym(1).Node = node; } break; @@ -1205,7 +1242,7 @@ case 213: { case 215: { AST::BinaryExpression *node = makeAstNode<AST::BinaryExpression> (driver->nodePool(), sym(1).Expression, - QSOperator::Or, sym(3).Expression); + QSOperator::And, sym(3).Expression); node->operatorToken = loc(2); sym(1).Node = node; } break; @@ -1218,6 +1255,13 @@ case 217: { } break; case 219: { + 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 221: { AST::ConditionalExpression *node = makeAstNode<AST::ConditionalExpression> (driver->nodePool(), sym(1).Expression, sym(3).Expression, sym(5).Expression); node->questionToken = loc(2); @@ -1225,7 +1269,7 @@ case 219: { sym(1).Node = node; } break; -case 221: { +case 223: { AST::ConditionalExpression *node = makeAstNode<AST::ConditionalExpression> (driver->nodePool(), sym(1).Expression, sym(3).Expression, sym(5).Expression); node->questionToken = loc(2); @@ -1233,112 +1277,112 @@ case 221: { sym(1).Node = node; } break; -case 223: { +case 225: { 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 225: { +case 227: { 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 226: { +case 228: { sym(1).ival = QSOperator::Assign; } break; -case 227: { +case 229: { sym(1).ival = QSOperator::InplaceMul; } break; -case 228: { +case 230: { sym(1).ival = QSOperator::InplaceDiv; } break; -case 229: { +case 231: { sym(1).ival = QSOperator::InplaceMod; } break; -case 230: { +case 232: { sym(1).ival = QSOperator::InplaceAdd; } break; -case 231: { +case 233: { sym(1).ival = QSOperator::InplaceSub; } break; -case 232: { +case 234: { sym(1).ival = QSOperator::InplaceLeftShift; } break; -case 233: { +case 235: { sym(1).ival = QSOperator::InplaceRightShift; } break; -case 234: { +case 236: { sym(1).ival = QSOperator::InplaceURightShift; } break; -case 235: { +case 237: { sym(1).ival = QSOperator::InplaceAnd; } break; -case 236: { +case 238: { sym(1).ival = QSOperator::InplaceXor; } break; -case 237: { +case 239: { sym(1).ival = QSOperator::InplaceOr; } break; -case 239: { +case 241: { AST::Expression *node = makeAstNode<AST::Expression> (driver->nodePool(), sym(1).Expression, sym(3).Expression); node->commaToken = loc(2); sym(1).Node = node; } break; -case 240: { +case 242: { sym(1).Node = 0; } break; -case 243: { +case 245: { AST::Expression *node = makeAstNode<AST::Expression> (driver->nodePool(), sym(1).Expression, sym(3).Expression); node->commaToken = loc(2); sym(1).Node = node; } break; -case 244: { +case 246: { sym(1).Node = 0; } break; -case 261: { +case 263: { 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 262: { +case 264: { sym(1).Node = makeAstNode<AST::StatementList> (driver->nodePool(), sym(1).Statement); } break; -case 263: { +case 265: { sym(1).Node = makeAstNode<AST::StatementList> (driver->nodePool(), sym(1).StatementList, sym(2).Statement); } break; -case 264: { +case 266: { sym(1).Node = 0; } break; -case 265: { +case 267: { sym(1).Node = sym(1).StatementList->finish (); } break; -case 267: { +case 269: { AST::VariableStatement *node = makeAstNode<AST::VariableStatement> (driver->nodePool(), sym(2).VariableDeclarationList->finish (/*readOnly=*/sym(1).ival == T_CONST)); node->declarationKindToken = loc(1); @@ -1346,76 +1390,76 @@ case 267: { sym(1).Node = node; } break; -case 268: { +case 270: { sym(1).ival = T_CONST; } break; -case 269: { +case 271: { sym(1).ival = T_VAR; } break; -case 270: { +case 272: { sym(1).Node = makeAstNode<AST::VariableDeclarationList> (driver->nodePool(), sym(1).VariableDeclaration); } break; -case 271: { +case 273: { AST::VariableDeclarationList *node = makeAstNode<AST::VariableDeclarationList> (driver->nodePool(), sym(1).VariableDeclarationList, sym(3).VariableDeclaration); node->commaToken = loc(2); sym(1).Node = node; } break; -case 272: { +case 274: { sym(1).Node = makeAstNode<AST::VariableDeclarationList> (driver->nodePool(), sym(1).VariableDeclaration); } break; -case 273: { +case 275: { sym(1).Node = makeAstNode<AST::VariableDeclarationList> (driver->nodePool(), sym(1).VariableDeclarationList, sym(3).VariableDeclaration); } break; -case 274: { +case 276: { AST::VariableDeclaration *node = makeAstNode<AST::VariableDeclaration> (driver->nodePool(), sym(1).sval, sym(2).Expression); node->identifierToken = loc(1); sym(1).Node = node; } break; -case 275: { +case 277: { AST::VariableDeclaration *node = makeAstNode<AST::VariableDeclaration> (driver->nodePool(), sym(1).sval, sym(2).Expression); node->identifierToken = loc(1); sym(1).Node = node; } break; -case 276: { +case 278: { // ### TODO: AST for initializer sym(1) = sym(2); } break; -case 277: { +case 279: { sym(1).Node = 0; } break; -case 279: { +case 281: { // ### TODO: AST for initializer sym(1) = sym(2); } break; -case 280: { +case 282: { sym(1).Node = 0; } break; -case 282: { +case 284: { AST::EmptyStatement *node = makeAstNode<AST::EmptyStatement> (driver->nodePool()); node->semicolonToken = loc(1); sym(1).Node = node; } break; -case 284: { +case 286: { AST::ExpressionStatement *node = makeAstNode<AST::ExpressionStatement> (driver->nodePool(), sym(1).Expression); node->semicolonToken = loc(2); sym(1).Node = node; } break; -case 285: { +case 287: { 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); @@ -1424,7 +1468,7 @@ case 285: { sym(1).Node = node; } break; -case 286: { +case 288: { AST::IfStatement *node = makeAstNode<AST::IfStatement> (driver->nodePool(), sym(3).Expression, sym(5).Statement); node->ifToken = loc(1); node->lparenToken = loc(2); @@ -1432,7 +1476,7 @@ case 286: { sym(1).Node = node; } break; -case 288: { +case 290: { AST::DoWhileStatement *node = makeAstNode<AST::DoWhileStatement> (driver->nodePool(), sym(2).Statement, sym(5).Expression); node->doToken = loc(1); node->whileToken = loc(3); @@ -1442,7 +1486,7 @@ case 288: { sym(1).Node = node; } break; -case 289: { +case 291: { AST::WhileStatement *node = makeAstNode<AST::WhileStatement> (driver->nodePool(), sym(3).Expression, sym(5).Statement); node->whileToken = loc(1); node->lparenToken = loc(2); @@ -1450,7 +1494,7 @@ case 289: { sym(1).Node = node; } break; -case 290: { +case 292: { AST::ForStatement *node = makeAstNode<AST::ForStatement> (driver->nodePool(), sym(3).Expression, sym(5).Expression, sym(7).Expression, sym(9).Statement); node->forToken = loc(1); @@ -1461,7 +1505,7 @@ case 290: { sym(1).Node = node; } break; -case 291: { +case 293: { AST::LocalForStatement *node = makeAstNode<AST::LocalForStatement> (driver->nodePool(), sym(4).VariableDeclarationList->finish (/*readOnly=*/false), sym(6).Expression, sym(8).Expression, sym(10).Statement); @@ -1474,7 +1518,7 @@ case 291: { sym(1).Node = node; } break; -case 292: { +case 294: { AST:: ForEachStatement *node = makeAstNode<AST::ForEachStatement> (driver->nodePool(), sym(3).Expression, sym(5).Expression, sym(7).Statement); node->forToken = loc(1); @@ -1484,7 +1528,7 @@ case 292: { sym(1).Node = node; } break; -case 293: { +case 295: { AST::LocalForEachStatement *node = makeAstNode<AST::LocalForEachStatement> (driver->nodePool(), sym(4).VariableDeclaration, sym(6).Expression, sym(8).Statement); node->forToken = loc(1); @@ -1495,14 +1539,14 @@ case 293: { sym(1).Node = node; } break; -case 295: { +case 297: { AST::ContinueStatement *node = makeAstNode<AST::ContinueStatement> (driver->nodePool()); node->continueToken = loc(1); node->semicolonToken = loc(2); sym(1).Node = node; } break; -case 297: { +case 299: { AST::ContinueStatement *node = makeAstNode<AST::ContinueStatement> (driver->nodePool(), sym(2).sval); node->continueToken = loc(1); node->identifierToken = loc(2); @@ -1510,14 +1554,14 @@ case 297: { sym(1).Node = node; } break; -case 299: { +case 301: { AST::BreakStatement *node = makeAstNode<AST::BreakStatement> (driver->nodePool()); node->breakToken = loc(1); node->semicolonToken = loc(2); sym(1).Node = node; } break; -case 301: { +case 303: { AST::BreakStatement *node = makeAstNode<AST::BreakStatement> (driver->nodePool(), sym(2).sval); node->breakToken = loc(1); node->identifierToken = loc(2); @@ -1525,14 +1569,14 @@ case 301: { sym(1).Node = node; } break; -case 303: { +case 305: { 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 304: { +case 306: { AST::WithStatement *node = makeAstNode<AST::WithStatement> (driver->nodePool(), sym(3).Expression, sym(5).Statement); node->withToken = loc(1); node->lparenToken = loc(2); @@ -1540,7 +1584,7 @@ case 304: { sym(1).Node = node; } break; -case 305: { +case 307: { AST::SwitchStatement *node = makeAstNode<AST::SwitchStatement> (driver->nodePool(), sym(3).Expression, sym(5).CaseBlock); node->switchToken = loc(1); node->lparenToken = loc(2); @@ -1548,90 +1592,90 @@ case 305: { sym(1).Node = node; } break; -case 306: { +case 308: { 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 307: { +case 309: { 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 308: { +case 310: { sym(1).Node = makeAstNode<AST::CaseClauses> (driver->nodePool(), sym(1).CaseClause); } break; -case 309: { +case 311: { sym(1).Node = makeAstNode<AST::CaseClauses> (driver->nodePool(), sym(1).CaseClauses, sym(2).CaseClause); } break; -case 310: { +case 312: { sym(1).Node = 0; } break; -case 311: { +case 313: { sym(1).Node = sym(1).CaseClauses->finish (); } break; -case 312: { +case 314: { 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 313: { +case 315: { 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 314: -case 315: { +case 316: +case 317: { 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 316: { +case 318: { 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 318: { +case 320: { 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 319: { +case 321: { AST::TryStatement *node = makeAstNode<AST::TryStatement> (driver->nodePool(), sym(2).Statement, sym(3).Catch); node->tryToken = loc(1); sym(1).Node = node; } break; -case 320: { +case 322: { AST::TryStatement *node = makeAstNode<AST::TryStatement> (driver->nodePool(), sym(2).Statement, sym(3).Finally); node->tryToken = loc(1); sym(1).Node = node; } break; -case 321: { +case 323: { 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 322: { +case 324: { AST::Catch *node = makeAstNode<AST::Catch> (driver->nodePool(), sym(3).sval, sym(5).Block); node->catchToken = loc(1); node->lparenToken = loc(2); @@ -1640,20 +1684,20 @@ case 322: { sym(1).Node = node; } break; -case 323: { +case 325: { AST::Finally *node = makeAstNode<AST::Finally> (driver->nodePool(), sym(2).Block); node->finallyToken = loc(1); sym(1).Node = node; } break; -case 325: { +case 327: { AST::DebuggerStatement *node = makeAstNode<AST::DebuggerStatement> (driver->nodePool()); node->debuggerToken = loc(1); node->semicolonToken = loc(2); sym(1).Node = node; } break; -case 326: { +case 328: { 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); @@ -1664,7 +1708,7 @@ case 326: { sym(1).Node = node; } break; -case 327: { +case 329: { 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) @@ -1676,60 +1720,60 @@ case 327: { sym(1).Node = node; } break; -case 328: { +case 330: { AST::FormalParameterList *node = makeAstNode<AST::FormalParameterList> (driver->nodePool(), sym(1).sval); node->identifierToken = loc(1); sym(1).Node = node; } break; -case 329: { +case 331: { 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 330: { +case 332: { sym(1).Node = 0; } break; -case 331: { +case 333: { sym(1).Node = sym(1).FormalParameterList->finish (); } break; -case 332: { +case 334: { sym(1).Node = 0; } break; -case 334: { +case 336: { sym(1).Node = makeAstNode<AST::FunctionBody> (driver->nodePool(), sym(1).SourceElements->finish ()); } break; -case 335: { +case 337: { sym(1).Node = makeAstNode<AST::Program> (driver->nodePool(), sym(1).SourceElements->finish ()); } break; -case 336: { +case 338: { sym(1).Node = makeAstNode<AST::SourceElements> (driver->nodePool(), sym(1).SourceElement); } break; -case 337: { +case 339: { sym(1).Node = makeAstNode<AST::SourceElements> (driver->nodePool(), sym(1).SourceElements, sym(2).SourceElement); } break; -case 338: { +case 340: { sym(1).Node = makeAstNode<AST::StatementSourceElement> (driver->nodePool(), sym(1).Statement); } break; -case 339: { +case 341: { sym(1).Node = makeAstNode<AST::FunctionSourceElement> (driver->nodePool(), sym(1).FunctionDeclaration); } break; -case 340: { +case 342: { sym(1).sval = 0; } break; -case 342: { +case 344: { sym(1).Node = 0; } break; diff --git a/src/declarative/qml/parser/qdeclarativejsparser_p.h b/src/declarative/qml/parser/qdeclarativejsparser_p.h index 3864398..8838fbe 100644 --- a/src/declarative/qml/parser/qdeclarativejsparser_p.h +++ b/src/declarative/qml/parser/qdeclarativejsparser_p.h @@ -235,9 +235,9 @@ protected: -#define J_SCRIPT_REGEXPLITERAL_RULE1 76 +#define J_SCRIPT_REGEXPLITERAL_RULE1 78 -#define J_SCRIPT_REGEXPLITERAL_RULE2 77 +#define J_SCRIPT_REGEXPLITERAL_RULE2 79 QT_QML_END_NAMESPACE diff --git a/src/declarative/qml/qdeclarativecompositetypemanager.cpp b/src/declarative/qml/qdeclarativecompositetypemanager.cpp index c59e5e2..eb8c9eb 100644 --- a/src/declarative/qml/qdeclarativecompositetypemanager.cpp +++ b/src/declarative/qml/qdeclarativecompositetypemanager.cpp @@ -537,6 +537,31 @@ int QDeclarativeCompositeTypeManager::resolveTypes(QDeclarativeCompositeTypeData int waiting = 0; + /* + For local urls, add an implicit import "." as first (most overridden) lookup. This will also trigger + the loading of the qmldir and the import of any native types from available plugins. + */ + { + + QDeclarativeDirComponents qmldircomponentsnetwork; + if (QDeclarativeCompositeTypeResource *resource + = resources.value(unit->imports.baseUrl().resolved(QUrl(QLatin1String("./qmldir"))))) { + QDeclarativeDirParser parser; + parser.setSource(QString::fromUtf8(resource->data)); + parser.parse(); + qmldircomponentsnetwork = parser.components(); + } + + QDeclarativeEnginePrivate::get(engine)-> + addToImport(&unit->imports, + qmldircomponentsnetwork, + QLatin1String("."), + QString(), + -1, -1, + QDeclarativeScriptParser::Import::File, + 0); // error ignored (just means no fallback) + } + foreach (QDeclarativeScriptParser::Import imp, unit->data.imports()) { QDeclarativeDirComponents qmldircomponentsnetwork; @@ -587,31 +612,6 @@ int QDeclarativeCompositeTypeManager::resolveTypes(QDeclarativeCompositeTypeData } } - /* - For local urls, add an implicit import "." as first lookup. This will also trigger - the loading of the qmldir and the import of any native types from available plugins. - */ - { - - QDeclarativeDirComponents qmldircomponentsnetwork; - if (QDeclarativeCompositeTypeResource *resource - = resources.value(unit->imports.baseUrl().resolved(QUrl(QLatin1String("./qmldir"))))) { - QDeclarativeDirParser parser; - parser.setSource(QString::fromUtf8(resource->data)); - parser.parse(); - qmldircomponentsnetwork = parser.components(); - } - - QDeclarativeEnginePrivate::get(engine)-> - addToImport(&unit->imports, - qmldircomponentsnetwork, - QLatin1String("."), - QString(), - -1, -1, - QDeclarativeScriptParser::Import::File, - 0); // error ignored (just means no fallback) - } - QList<QDeclarativeScriptParser::TypeReference*> types = unit->data.referencedTypes(); diff --git a/src/declarative/qml/qdeclarativeengine.cpp b/src/declarative/qml/qdeclarativeengine.cpp index 3e570e5..9442705 100644 --- a/src/declarative/qml/qdeclarativeengine.cpp +++ b/src/declarative/qml/qdeclarativeengine.cpp @@ -1980,8 +1980,11 @@ QString QDeclarativeEnginePrivate::resolvePlugin(const QDir &dir, const QString QStringList() # ifdef QT_DEBUG << QLatin1String("_debug.dylib") // try a qmake-style debug build first -# endif << QLatin1String(".dylib") +# else + << QLatin1String(".dylib") + << QLatin1String("_debug.dylib") // try a qmake-style debug build after +# endif << QLatin1String(".so") << QLatin1String(".bundle"), QLatin1String("lib")); diff --git a/src/declarative/qml/qdeclarativescriptparser.cpp b/src/declarative/qml/qdeclarativescriptparser.cpp index 9fff294..2b9cd4b 100644 --- a/src/declarative/qml/qdeclarativescriptparser.cpp +++ b/src/declarative/qml/qdeclarativescriptparser.cpp @@ -397,7 +397,7 @@ Object *ProcessAST::defineObjectBinding(AST::UiQualifiedId *qualifiedId, bool on if (string.isStringList()) { QStringList urls = string.asStringList(); // We need to add this as a resource - for (int ii = 0; ii < urls.count(); ++ii) + for (int ii = 0; ii < urls.count(); ++ii) _parser->_refUrls << QUrl(urls.at(ii)); } } @@ -503,7 +503,7 @@ bool ProcessAST::visit(AST::UiImport *node) error.setColumn(node->importIdToken.startColumn); _parser->_errors << error; return false; - } + } import.location = location(startLoc, endLoc); @@ -637,7 +637,7 @@ bool ProcessAST::visit(AST::UiPublicMember *node) property.isDefaultProperty = node->isDefaultMember; property.type = type; if (type >= Object::DynamicProperty::Custom) { - QDeclarativeScriptParser::TypeReference *typeRef = + QDeclarativeScriptParser::TypeReference *typeRef = _parser->findOrCreateType(memberType); typeRef->refObjects.append(_stateStack.top().object); } @@ -660,9 +660,12 @@ bool ProcessAST::visit(AST::UiPublicMember *node) } _stateStack.top().object->dynamicProperties << property; + + // process QML-like initializers (e.g. property Object o: Object {}) + accept(node->binding); } - return true; + return false; } @@ -996,7 +999,7 @@ QDeclarativeParser::Object::ScriptBlock::Pragmas QDeclarativeScriptParser::extra for (int ii = 0; ii < length; ++ii) { const QChar &c = data[ii]; - if (c.isSpace()) + if (c.isSpace()) continue; if (c == forwardSlash) { diff --git a/src/declarative/util/qdeclarativelistmodel.cpp b/src/declarative/util/qdeclarativelistmodel.cpp index 1a28176..13662c5 100644 --- a/src/declarative/util/qdeclarativelistmodel.cpp +++ b/src/declarative/util/qdeclarativelistmodel.cpp @@ -532,7 +532,7 @@ QScriptValue QDeclarativeListModel::get(int index) const \qmlmethod ListModel::set(int index, jsobject dict) Changes the item at \a index in the list model with the - values in \a dict. Properties not appearing in \a valuemap + values in \a dict. Properties not appearing in \a dict are left unchanged. \code @@ -1273,6 +1273,8 @@ void ModelNode::setObjectValue(const QScriptValue& valuemap) { value->setListValue(v); } else { value->values << v.toVariant(); + if (objectCache) + objectCache->setValue(it.name().toUtf8(), value->values.last()); } if (properties.contains(it.name())) delete properties[it.name()]; diff --git a/src/imports/multimedia/qdeclarativeaudio.cpp b/src/imports/multimedia/qdeclarativeaudio.cpp index 077ed9a..8d2dc61 100644 --- a/src/imports/multimedia/qdeclarativeaudio.cpp +++ b/src/imports/multimedia/qdeclarativeaudio.cpp @@ -51,7 +51,12 @@ QT_BEGIN_NAMESPACE \since 4.7 \brief The Audio element allows you to add audio playback to a scene. + This element is part of the \bold{Qt.multimedia 4.7} module. + \qml + import Qt 4.6 + import Qt.multimedia 4.7 + Audio { source: "audio/song.mp3" } \endqml diff --git a/src/imports/multimedia/qdeclarativevideo.cpp b/src/imports/multimedia/qdeclarativevideo.cpp index c878fe1..bf112be 100644 --- a/src/imports/multimedia/qdeclarativevideo.cpp +++ b/src/imports/multimedia/qdeclarativevideo.cpp @@ -73,7 +73,12 @@ void QDeclarativeVideo::_q_error(int errorCode, const QString &errorString) \brief The Video element allows you to add videos to a scene. \inherits Item + This element is part of the \bold{Qt.multimedia 4.7} module. + \qml + import Qt 4.6 + import Qt.multimedia 4.7 + Video { source: "video/movie.mpg" } \endqml diff --git a/src/imports/particles/qdeclarativeparticles.cpp b/src/imports/particles/qdeclarativeparticles.cpp index e69c235..e98a801 100644 --- a/src/imports/particles/qdeclarativeparticles.cpp +++ b/src/imports/particles/qdeclarativeparticles.cpp @@ -623,7 +623,7 @@ void QDeclarativeParticlesPrivate::updateOpacity(QDeclarativeParticle &p, int ag \brief The Particles object generates and moves particles. \inherits Item - Particles are available in the Qt.labs.particles 1.0 module. + Particles are available in the \bold{Qt.labs.particles 1.0} module. This element provides preliminary support for particles in QML, and may be heavily changed or removed in later versions. diff --git a/src/imports/webkit/qdeclarativewebview.cpp b/src/imports/webkit/qdeclarativewebview.cpp index 1ff1078..5db812c 100644 --- a/src/imports/webkit/qdeclarativewebview.cpp +++ b/src/imports/webkit/qdeclarativewebview.cpp @@ -123,7 +123,7 @@ public: This type is made available by importing the \c org.webkit module: - \b{import org.webkit 1.0} + \bold{import org.webkit 1.0} If the width and height of the item is not set, they will dynamically adjust to a size appropriate for the content. diff --git a/src/multimedia/effects/qsoundeffect.cpp b/src/multimedia/effects/qsoundeffect.cpp index ed9ab3f..8a38103 100644 --- a/src/multimedia/effects/qsoundeffect.cpp +++ b/src/multimedia/effects/qsoundeffect.cpp @@ -56,18 +56,25 @@ QT_BEGIN_NAMESPACE \since 4.7 \brief The SoundEffect element provides a way to play sound effects in qml. + This element is part of the \bold{Qt.multimedia 4.7} module. + The following example plays a wav file on mouse click. \qml - SoundEffect { - id: playSound - source: "test.wav" - } - MouseArea { - id: playArea - anchors.fill: parent - onPressed: { - playSound.play() + import Qt 4.6 + import Qt.multimedia 4.7 + + Item { + SoundEffect { + id: playSound + source: "test.wav" + } + MouseArea { + id: playArea + anchors.fill: parent + onPressed: { + playSound.play() + } } } \endqml diff --git a/tests/auto/declarative/qdeclarativeanchors/tst_qdeclarativeanchors.cpp b/tests/auto/declarative/qdeclarativeanchors/tst_qdeclarativeanchors.cpp index 6b7d57f..16ae7fc 100644 --- a/tests/auto/declarative/qdeclarativeanchors/tst_qdeclarativeanchors.cpp +++ b/tests/auto/declarative/qdeclarativeanchors/tst_qdeclarativeanchors.cpp @@ -390,7 +390,7 @@ void tst_qdeclarativeanchors::fill() QCOMPARE(rect->y(), 0.0 + 30.0); QCOMPARE(rect->width(), 200.0 - 10.0 - 20.0); QCOMPARE(rect->height(), 200.0 - 30.0 - 40.0); - //Alter Offsets (QTBUG-6631) + //Alter Offsets (tests QTBUG-6631) rect->anchors()->setLeftMargin(20.0); rect->anchors()->setRightMargin(0.0); rect->anchors()->setBottomMargin(0.0); @@ -411,7 +411,7 @@ void tst_qdeclarativeanchors::centerIn() QDeclarativeRectangle* rect = findItem<QDeclarativeRectangle>(view->rootObject(), QLatin1String("centered")); QCOMPARE(rect->x(), 75.0 + 10); QCOMPARE(rect->y(), 75.0 + 30); - //Alter Offsets (QTBUG-6631) + //Alter Offsets (tests QTBUG-6631) rect->anchors()->setHorizontalCenterOffset(-20.0); rect->anchors()->setVerticalCenterOffset(-10.0); QCOMPARE(rect->x(), 75.0 - 20.0); diff --git a/tests/auto/declarative/qdeclarativelanguage/data/LocalLast.qml b/tests/auto/declarative/qdeclarativelanguage/data/LocalLast.qml new file mode 100644 index 0000000..a0706ad --- /dev/null +++ b/tests/auto/declarative/qdeclarativelanguage/data/LocalLast.qml @@ -0,0 +1,2 @@ +import Qt 4.6 +Text {} diff --git a/tests/auto/declarative/qdeclarativelanguage/data/lib/com/nokia/installedtest/LocalLast.qml b/tests/auto/declarative/qdeclarativelanguage/data/lib/com/nokia/installedtest/LocalLast.qml new file mode 100644 index 0000000..d8a22a8 --- /dev/null +++ b/tests/auto/declarative/qdeclarativelanguage/data/lib/com/nokia/installedtest/LocalLast.qml @@ -0,0 +1,2 @@ +import Qt 4.6 +Rectangle {} diff --git a/tests/auto/declarative/qdeclarativelanguage/data/lib/com/nokia/installedtest/qmldir b/tests/auto/declarative/qdeclarativelanguage/data/lib/com/nokia/installedtest/qmldir index eeb9a05..0adb0f6 100644 --- a/tests/auto/declarative/qdeclarativelanguage/data/lib/com/nokia/installedtest/qmldir +++ b/tests/auto/declarative/qdeclarativelanguage/data/lib/com/nokia/installedtest/qmldir @@ -1,4 +1,5 @@ Rectangle 1.5 InstalledTest2.qml +LocalLast 1.0 LocalLast.qml InstalledTest 1.4 InstalledTest2.qml InstalledTest 1.0 InstalledTest.qml InstalledTestTP 0.0 InstalledTest.qml diff --git a/tests/auto/declarative/qdeclarativelanguage/tst_qdeclarativelanguage.cpp b/tests/auto/declarative/qdeclarativelanguage/tst_qdeclarativelanguage.cpp index e2cf5ca..722e161 100644 --- a/tests/auto/declarative/qdeclarativelanguage/tst_qdeclarativelanguage.cpp +++ b/tests/auto/declarative/qdeclarativelanguage/tst_qdeclarativelanguage.cpp @@ -1065,7 +1065,6 @@ void tst_qdeclarativelanguage::defaultPropertyListOrder() void tst_qdeclarativelanguage::declaredPropertyValues() { QDeclarativeComponent component(&engine, TEST_FILE("declaredPropertyValues.qml")); - QEXPECT_FAIL("", "QTBUG-7860", Abort); VERIFY_ERRORS(0); } @@ -1358,6 +1357,13 @@ void tst_qdeclarativelanguage::importsOrder_data() "import com.nokia.installedtest 1.5\n" "Rectangle.Image {}" << "QDeclarativeImage"; + QTest::newRow("local last 1") << + "LocalLast {}" + << "QDeclarativeText"; + QTest::newRow("local last 2") << + "import com.nokia.installedtest 1.0\n" + "LocalLast {}" + << "QDeclarativeRectangle"; // i.e. from com.nokia.installedtest, not data/LocalLast.qml } void tst_qdeclarativelanguage::importsOrder() diff --git a/tests/auto/declarative/qdeclarativelistmodel/tst_qdeclarativelistmodel.cpp b/tests/auto/declarative/qdeclarativelistmodel/tst_qdeclarativelistmodel.cpp index 12000d0..d02f54f 100644 --- a/tests/auto/declarative/qdeclarativelistmodel/tst_qdeclarativelistmodel.cpp +++ b/tests/auto/declarative/qdeclarativelistmodel/tst_qdeclarativelistmodel.cpp @@ -41,6 +41,7 @@ #include <qtest.h> #include <QtDeclarative/private/qdeclarativeitem_p.h> #include <QtDeclarative/private/qdeclarativetext_p.h> +#include <QtDeclarative/private/qdeclarativeengine_p.h> #include <QtDeclarative/private/qdeclarativelistmodel_p.h> #include <QtDeclarative/private/qdeclarativeexpression_p.h> #include <QDeclarativeComponent> @@ -77,6 +78,7 @@ private slots: void convertNestedToFlat_ok_data(); void error_data(); void error(); + void set(); }; QScriptValue tst_QDeclarativeListModel::nestedListValue(QScriptEngine *eng) const @@ -550,6 +552,30 @@ void tst_QDeclarativeListModel::error() } } +void tst_QDeclarativeListModel::set() +{ + QDeclarativeEngine engine; + QDeclarativeListModel model; + QDeclarativeEngine::setContextForObject(&model,engine.rootContext()); + engine.rootContext()->setContextObject(&model); + QScriptEngine *seng = QDeclarativeEnginePrivate::getScriptEngine(&engine); + + QScriptValue sv = seng->newObject(); + sv.setProperty("test", QScriptValue(false)); + model.append(sv); + + sv.setProperty("test", QScriptValue(true)); + model.set(0, sv); + QCOMPARE(model.get(0).property("test").toBool(), true); // triggers creation of model cache + QCOMPARE(model.data(0, model.roles()[0]), qVariantFromValue(true)); + + sv.setProperty("test", QScriptValue(false)); + model.set(0, sv); + QCOMPARE(model.get(0).property("test").toBool(), false); // tests model cache is updated + QCOMPARE(model.data(0, model.roles()[0]), qVariantFromValue(false)); +} + + QTEST_MAIN(tst_QDeclarativeListModel) #include "tst_qdeclarativelistmodel.moc" diff --git a/tests/auto/declarative/qdeclarativepositioners/data/flowtest.qml b/tests/auto/declarative/qdeclarativepositioners/data/flowtest.qml index bd13bac..6c1c823 100644 --- a/tests/auto/declarative/qdeclarativepositioners/data/flowtest.qml +++ b/tests/auto/declarative/qdeclarativepositioners/data/flowtest.qml @@ -4,7 +4,8 @@ Item { width: 90 height: 480 Flow { - anchors.fill: parent + objectName: "flow" + width: parent.width Rectangle { objectName: "one" color: "red" diff --git a/tests/auto/declarative/qdeclarativepositioners/data/grid-animated.qml b/tests/auto/declarative/qdeclarativepositioners/data/grid-animated.qml index f6376a1..9741ba9 100644 --- a/tests/auto/declarative/qdeclarativepositioners/data/grid-animated.qml +++ b/tests/auto/declarative/qdeclarativepositioners/data/grid-animated.qml @@ -4,6 +4,7 @@ Item { width: 640 height: 480 Grid { + objectName: "grid" columns: 3 add: Transition { NumberAnimation { diff --git a/tests/auto/declarative/qdeclarativepositioners/data/grid-spacing.qml b/tests/auto/declarative/qdeclarativepositioners/data/grid-spacing.qml index 5b4a30d..e335932 100644 --- a/tests/auto/declarative/qdeclarativepositioners/data/grid-spacing.qml +++ b/tests/auto/declarative/qdeclarativepositioners/data/grid-spacing.qml @@ -4,6 +4,7 @@ Item { width: 640 height: 480 Grid { + objectName: "grid" columns: 3 spacing: 4 Rectangle { diff --git a/tests/auto/declarative/qdeclarativepositioners/data/gridtest.qml b/tests/auto/declarative/qdeclarativepositioners/data/gridtest.qml index 830df6a..1d6f44e 100644 --- a/tests/auto/declarative/qdeclarativepositioners/data/gridtest.qml +++ b/tests/auto/declarative/qdeclarativepositioners/data/gridtest.qml @@ -4,6 +4,7 @@ Item { width: 640 height: 480 Grid { + objectName: "grid" columns: 3 Rectangle { objectName: "one" diff --git a/tests/auto/declarative/qdeclarativepositioners/data/horizontal-animated.qml b/tests/auto/declarative/qdeclarativepositioners/data/horizontal-animated.qml index c113a36..a1c05a8 100644 --- a/tests/auto/declarative/qdeclarativepositioners/data/horizontal-animated.qml +++ b/tests/auto/declarative/qdeclarativepositioners/data/horizontal-animated.qml @@ -4,6 +4,7 @@ Item { width: 640 height: 480 Row { + objectName: "row" add: Transition { NumberAnimation { properties: "x"; diff --git a/tests/auto/declarative/qdeclarativepositioners/data/horizontal-spacing.qml b/tests/auto/declarative/qdeclarativepositioners/data/horizontal-spacing.qml index 32bf775..fb9fdd1 100644 --- a/tests/auto/declarative/qdeclarativepositioners/data/horizontal-spacing.qml +++ b/tests/auto/declarative/qdeclarativepositioners/data/horizontal-spacing.qml @@ -4,6 +4,7 @@ Item { width: 640 height: 480 Row { + objectName: "row" spacing: 10 Rectangle { objectName: "one" diff --git a/tests/auto/declarative/qdeclarativepositioners/data/horizontal.qml b/tests/auto/declarative/qdeclarativepositioners/data/horizontal.qml index 06ae151..3a7a3b1 100644 --- a/tests/auto/declarative/qdeclarativepositioners/data/horizontal.qml +++ b/tests/auto/declarative/qdeclarativepositioners/data/horizontal.qml @@ -4,6 +4,7 @@ Item { width: 640 height: 480 Row { + objectName: "row" Rectangle { objectName: "one" color: "red" diff --git a/tests/auto/declarative/qdeclarativepositioners/data/vertical-animated.qml b/tests/auto/declarative/qdeclarativepositioners/data/vertical-animated.qml index 10f6cbb..31faa54 100644 --- a/tests/auto/declarative/qdeclarativepositioners/data/vertical-animated.qml +++ b/tests/auto/declarative/qdeclarativepositioners/data/vertical-animated.qml @@ -4,6 +4,7 @@ Item { width: 640 height: 480 Column { + objectName: "column" add: Transition { NumberAnimation { properties: "y"; diff --git a/tests/auto/declarative/qdeclarativepositioners/data/vertical-spacing.qml b/tests/auto/declarative/qdeclarativepositioners/data/vertical-spacing.qml index 69a8256..1c5696b 100644 --- a/tests/auto/declarative/qdeclarativepositioners/data/vertical-spacing.qml +++ b/tests/auto/declarative/qdeclarativepositioners/data/vertical-spacing.qml @@ -4,6 +4,7 @@ Item { width: 640 height: 480 Column { + objectName: "column" spacing: 10 Rectangle { objectName: "one" diff --git a/tests/auto/declarative/qdeclarativepositioners/data/vertical.qml b/tests/auto/declarative/qdeclarativepositioners/data/vertical.qml index 856c180..cd777e2 100644 --- a/tests/auto/declarative/qdeclarativepositioners/data/vertical.qml +++ b/tests/auto/declarative/qdeclarativepositioners/data/vertical.qml @@ -4,6 +4,7 @@ Item { width: 640 height: 480 Column { + objectName: "column" Rectangle { objectName: "one" color: "red" diff --git a/tests/auto/declarative/qdeclarativepositioners/tst_qdeclarativepositioners.cpp b/tests/auto/declarative/qdeclarativepositioners/tst_qdeclarativepositioners.cpp index 9026566..08eac0a 100644 --- a/tests/auto/declarative/qdeclarativepositioners/tst_qdeclarativepositioners.cpp +++ b/tests/auto/declarative/qdeclarativepositioners/tst_qdeclarativepositioners.cpp @@ -94,6 +94,10 @@ void tst_QDeclarativePositioners::test_horizontal() QCOMPARE(two->y(), 0.0); QCOMPARE(three->x(), 70.0); QCOMPARE(three->y(), 0.0); + + QDeclarativeItem *row = canvas->rootObject()->findChild<QDeclarativeItem*>("row"); + QCOMPARE(row->width(), 110.0); + QCOMPARE(row->height(), 50.0); } void tst_QDeclarativePositioners::test_horizontal_spacing() @@ -115,6 +119,10 @@ void tst_QDeclarativePositioners::test_horizontal_spacing() QCOMPARE(two->y(), 0.0); QCOMPARE(three->x(), 90.0); QCOMPARE(three->y(), 0.0); + + QDeclarativeItem *row = canvas->rootObject()->findChild<QDeclarativeItem*>("row"); + QCOMPARE(row->width(), 130.0); + QCOMPARE(row->height(), 50.0); } void tst_QDeclarativePositioners::test_horizontal_animated() @@ -135,6 +143,11 @@ void tst_QDeclarativePositioners::test_horizontal_animated() QCOMPARE(two->x(), -100.0); QCOMPARE(three->x(), -100.0); + QDeclarativeItem *row = canvas->rootObject()->findChild<QDeclarativeItem*>("row"); + QVERIFY(row); + QCOMPARE(row->width(), 100.0); + QCOMPARE(row->height(), 50.0); + //QTRY_COMPARE used instead of waiting for the expected time of animation completion //Note that this means the duration of the animation is NOT tested @@ -149,6 +162,11 @@ void tst_QDeclarativePositioners::test_horizontal_animated() //Add 'two' two->setOpacity(1.0); QCOMPARE(two->opacity(), 1.0); + + // New size should be immediate + QCOMPARE(row->width(), 150.0); + QCOMPARE(row->height(), 50.0); + QTest::qWait(0);//Let the animation start QCOMPARE(two->x(), -100.0); QCOMPARE(three->x(), 50.0); @@ -176,6 +194,11 @@ void tst_QDeclarativePositioners::test_vertical() QCOMPARE(two->y(), 50.0); QCOMPARE(three->x(), 0.0); QCOMPARE(three->y(), 60.0); + + QDeclarativeItem *column = canvas->rootObject()->findChild<QDeclarativeItem*>("column"); + QVERIFY(column); + QCOMPARE(column->height(), 80.0); + QCOMPARE(column->width(), 50.0); } void tst_QDeclarativePositioners::test_vertical_spacing() @@ -197,6 +220,10 @@ void tst_QDeclarativePositioners::test_vertical_spacing() QCOMPARE(two->y(), 60.0); QCOMPARE(three->x(), 0.0); QCOMPARE(three->y(), 80.0); + + QDeclarativeItem *column = canvas->rootObject()->findChild<QDeclarativeItem*>("column"); + QCOMPARE(column->height(), 100.0); + QCOMPARE(column->width(), 50.0); } void tst_QDeclarativePositioners::test_vertical_animated() @@ -216,6 +243,11 @@ void tst_QDeclarativePositioners::test_vertical_animated() QVERIFY(three != 0); QCOMPARE(three->y(), -100.0); + QDeclarativeItem *column = canvas->rootObject()->findChild<QDeclarativeItem*>("column"); + QVERIFY(column); + QCOMPARE(column->height(), 100.0); + QCOMPARE(column->width(), 50.0); + //QTRY_COMPARE used instead of waiting for the expected time of animation completion //Note that this means the duration of the animation is NOT tested @@ -230,6 +262,8 @@ void tst_QDeclarativePositioners::test_vertical_animated() //Add 'two' two->setOpacity(1.0); QTRY_COMPARE(two->opacity(), 1.0); + QCOMPARE(column->height(), 150.0); + QCOMPARE(column->width(), 50.0); QTest::qWait(0);//Let the animation start QCOMPARE(two->y(), -100.0); QCOMPARE(three->y(), 50.0); @@ -264,6 +298,10 @@ void tst_QDeclarativePositioners::test_grid() QCOMPARE(four->y(), 50.0); QCOMPARE(five->x(), 50.0); QCOMPARE(five->y(), 50.0); + + QDeclarativeItem *grid = canvas->rootObject()->findChild<QDeclarativeItem*>("grid"); + QCOMPARE(grid->width(), 120.0); + QCOMPARE(grid->height(), 100.0); } void tst_QDeclarativePositioners::test_grid_spacing() @@ -291,6 +329,10 @@ void tst_QDeclarativePositioners::test_grid_spacing() QCOMPARE(four->y(), 54.0); QCOMPARE(five->x(), 54.0); QCOMPARE(five->y(), 54.0); + + QDeclarativeItem *grid = canvas->rootObject()->findChild<QDeclarativeItem*>("grid"); + QCOMPARE(grid->width(), 128.0); + QCOMPARE(grid->height(), 104.0); } void tst_QDeclarativePositioners::test_grid_animated() @@ -323,6 +365,11 @@ void tst_QDeclarativePositioners::test_grid_animated() QCOMPARE(five->x(), -100.0); QCOMPARE(five->y(), -100.0); + QDeclarativeItem *grid = canvas->rootObject()->findChild<QDeclarativeItem*>("grid"); + QVERIFY(grid); + QCOMPARE(grid->width(), 150.0); + QCOMPARE(grid->height(), 100.0); + //QTRY_COMPARE used instead of waiting for the expected time of animation completion //Note that this means the duration of the animation is NOT tested @@ -341,6 +388,8 @@ void tst_QDeclarativePositioners::test_grid_animated() //Add 'two' two->setOpacity(1.0); QCOMPARE(two->opacity(), 1.0); + QCOMPARE(grid->width(), 150.0); + QCOMPARE(grid->height(), 100.0); QTest::qWait(0);//Let the animation start QCOMPARE(two->x(), -100.0); QCOMPARE(two->y(), -100.0); @@ -468,6 +517,11 @@ void tst_QDeclarativePositioners::test_flow() QCOMPARE(four->y(), 70.0); QCOMPARE(five->x(), 50.0); QCOMPARE(five->y(), 70.0); + + QDeclarativeItem *flow = canvas->rootObject()->findChild<QDeclarativeItem*>("flow"); + QVERIFY(flow); + QCOMPARE(flow->width(), 90.0); + QCOMPARE(flow->height(), 120.0); } void tst_QDeclarativePositioners::test_flow_resize() diff --git a/tests/auto/declarative/qdeclarativerepeater/data/itemlist.qml b/tests/auto/declarative/qdeclarativerepeater/data/itemlist.qml index fc6b34c..d74b2dc 100644 --- a/tests/auto/declarative/qdeclarativerepeater/data/itemlist.qml +++ b/tests/auto/declarative/qdeclarativerepeater/data/itemlist.qml @@ -21,17 +21,17 @@ Rectangle { objectName: "itemModel" Rectangle { objectName: "item1" - height: view.height; width: view.width; color: "#FFFEF0" + height: 50; width: 100; color: "#FFFEF0" Text { objectName: "text1"; text: "index: " + parent.VisualItemModel.index; font.bold: true; anchors.centerIn: parent } } Rectangle { objectName: "item2" - height: view.height; width: view.width; color: "#F0FFF7" + height: 50; width: 100; color: "#F0FFF7" Text { objectName: "text2"; text: "index: " + parent.VisualItemModel.index; font.bold: true; anchors.centerIn: parent } } Rectangle { objectName: "item3" - height: view.height; width: view.width; color: "#F4F0FF" + height: 50; width: 100; color: "#F4F0FF" Text { objectName: "text3"; text: "index: " + parent.VisualItemModel.index; font.bold: true; anchors.centerIn: parent } } } @@ -41,8 +41,6 @@ Rectangle { Repeater { id: view objectName: "repeater" - anchors.fill: parent - anchors.bottomMargin: 30 model: testObject.useModel ? itemModel : 0 } } diff --git a/tests/auto/declarative/qdeclarativetextinput/tst_qdeclarativetextinput.cpp b/tests/auto/declarative/qdeclarativetextinput/tst_qdeclarativetextinput.cpp index 84e7182..b6f55dd 100644 --- a/tests/auto/declarative/qdeclarativetextinput/tst_qdeclarativetextinput.cpp +++ b/tests/auto/declarative/qdeclarativetextinput/tst_qdeclarativetextinput.cpp @@ -523,7 +523,7 @@ void tst_qdeclarativetextinput::navigation() QVERIFY(input->hasFocus() == false); simulateKey(canvas, Qt::Key_Right); QVERIFY(input->hasFocus() == true); - //QT-2944: If text is selected, then we should deselect first. + //QT-2944: If text is selected, ensure we deselect upon cursor motion input->setCursorPosition(input->text().length()); input->setSelectionStart(0); input->setSelectionEnd(input->text().length()); diff --git a/tests/auto/declarative/qdeclarativevaluetypes/tst_qdeclarativevaluetypes.cpp b/tests/auto/declarative/qdeclarativevaluetypes/tst_qdeclarativevaluetypes.cpp index a5cb16f..4e254eb 100644 --- a/tests/auto/declarative/qdeclarativevaluetypes/tst_qdeclarativevaluetypes.cpp +++ b/tests/auto/declarative/qdeclarativevaluetypes/tst_qdeclarativevaluetypes.cpp @@ -432,7 +432,6 @@ void tst_qdeclarativevaluetypes::autoBindingRemoval() object->setProperty("value", QVariant(92)); - //QEXPECT_FAIL("", "QT-2920", Continue); QCOMPARE(object->rect().x(), 42); delete object; diff --git a/tests/benchmarks/declarative/typeimports/data/QmlTestType1.qml b/tests/benchmarks/declarative/typeimports/data/QmlTestType1.qml new file mode 100644 index 0000000..f359b85 --- /dev/null +++ b/tests/benchmarks/declarative/typeimports/data/QmlTestType1.qml @@ -0,0 +1,2 @@ +import Qt.test 2.0 +TestType1 { } diff --git a/tests/benchmarks/declarative/typeimports/data/QmlTestType2.qml b/tests/benchmarks/declarative/typeimports/data/QmlTestType2.qml new file mode 100644 index 0000000..b6fabe6 --- /dev/null +++ b/tests/benchmarks/declarative/typeimports/data/QmlTestType2.qml @@ -0,0 +1,2 @@ +import Qt.test 2.0 +TestType2 { } diff --git a/tests/benchmarks/declarative/typeimports/data/QmlTestType3.qml b/tests/benchmarks/declarative/typeimports/data/QmlTestType3.qml new file mode 100644 index 0000000..6a30887 --- /dev/null +++ b/tests/benchmarks/declarative/typeimports/data/QmlTestType3.qml @@ -0,0 +1,2 @@ +import Qt.test 2.0 +TestType3 { } diff --git a/tests/benchmarks/declarative/typeimports/data/QmlTestType4.qml b/tests/benchmarks/declarative/typeimports/data/QmlTestType4.qml new file mode 100644 index 0000000..5cc8a6b --- /dev/null +++ b/tests/benchmarks/declarative/typeimports/data/QmlTestType4.qml @@ -0,0 +1,2 @@ +import Qt.test 2.0 +TestType4 { } diff --git a/tests/benchmarks/declarative/typeimports/data/cpp.qml b/tests/benchmarks/declarative/typeimports/data/cpp.qml new file mode 100644 index 0000000..11ee4e6 --- /dev/null +++ b/tests/benchmarks/declarative/typeimports/data/cpp.qml @@ -0,0 +1,15 @@ +import Qt.test 2.0 + +TestType1 { + TestType1 { } TestType2 { } TestType3 { } TestType4 { } + TestType1 { } TestType2 { } TestType3 { } TestType4 { } + TestType1 { } TestType2 { } TestType3 { } TestType4 { } + TestType1 { } TestType2 { } TestType3 { } TestType4 { } + TestType1 { } TestType2 { } TestType3 { } TestType4 { } + + TestType1 { } TestType2 { } TestType3 { } TestType4 { } + TestType1 { } TestType2 { } TestType3 { } TestType4 { } + TestType1 { } TestType2 { } TestType3 { } TestType4 { } + TestType1 { } TestType2 { } TestType3 { } TestType4 { } + TestType1 { } TestType2 { } TestType3 { } TestType4 { } +} diff --git a/tests/benchmarks/declarative/typeimports/data/qml.qml b/tests/benchmarks/declarative/typeimports/data/qml.qml new file mode 100644 index 0000000..d776bcf --- /dev/null +++ b/tests/benchmarks/declarative/typeimports/data/qml.qml @@ -0,0 +1,13 @@ +QmlTestType1 { + QmlTestType1 { } QmlTestType2 { } QmlTestType3 { } QmlTestType4 { } + QmlTestType1 { } QmlTestType2 { } QmlTestType3 { } QmlTestType4 { } + QmlTestType1 { } QmlTestType2 { } QmlTestType3 { } QmlTestType4 { } + QmlTestType1 { } QmlTestType2 { } QmlTestType3 { } QmlTestType4 { } + QmlTestType1 { } QmlTestType2 { } QmlTestType3 { } QmlTestType4 { } + + QmlTestType1 { } QmlTestType2 { } QmlTestType3 { } QmlTestType4 { } + QmlTestType1 { } QmlTestType2 { } QmlTestType3 { } QmlTestType4 { } + QmlTestType1 { } QmlTestType2 { } QmlTestType3 { } QmlTestType4 { } + QmlTestType1 { } QmlTestType2 { } QmlTestType3 { } QmlTestType4 { } + QmlTestType1 { } QmlTestType2 { } QmlTestType3 { } QmlTestType4 { } +} diff --git a/tests/benchmarks/declarative/typeimports/tst_typeimports.cpp b/tests/benchmarks/declarative/typeimports/tst_typeimports.cpp new file mode 100644 index 0000000..b92ab46 --- /dev/null +++ b/tests/benchmarks/declarative/typeimports/tst_typeimports.cpp @@ -0,0 +1,138 @@ +/**************************************************************************** +** +** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies). +** All rights reserved. +** Contact: Nokia Corporation (qt-info@nokia.com) +** +** This file is part of the test suite 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 Technology Preview License Agreement accompanying +** this package. +** +** 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.1, included in the file LGPL_EXCEPTION.txt in this package. +** +** If you have questions regarding the use of this file, please contact +** Nokia at qt-info@nokia.com. +** +** +** +** +** +** +** +** +** $QT_END_LICENSE$ +** +****************************************************************************/ + +#include <qtest.h> +#include <QDeclarativeEngine> +#include <QDeclarativeComponent> +#include <QDebug> + +#ifdef Q_OS_SYMBIAN +// In Symbian OS test data is located in applications private dir +// Application private dir is default serach path for files, so SRCDIR can be set to empty +#define SRCDIR "" +#endif + +class tst_typeimports : public QObject +{ + Q_OBJECT +public: + tst_typeimports(); + +private slots: + void cpp(); + void qml(); + +private: + QDeclarativeEngine engine; +}; + +class TestType1 : public QObject +{ + Q_OBJECT + Q_PROPERTY(QDeclarativeListProperty<QObject> resources READ resources); + Q_CLASSINFO("DefaultProperty", "resources"); +public: + TestType1(QObject *parent = 0) : QObject(parent) {} + + QDeclarativeListProperty<QObject> resources() { + return QDeclarativeListProperty<QObject>(this, 0, resources_append); + } + + static void resources_append(QDeclarativeListProperty<QObject> *p, QObject *o) { + o->setParent(p->object); + } +}; + +class TestType2 : public TestType1 +{ + Q_OBJECT +public: + TestType2(QObject *parent = 0) : TestType1(parent) {} +}; + + +class TestType3 : public TestType1 +{ + Q_OBJECT +public: + TestType3(QObject *parent = 0) : TestType1(parent) {} +}; + +class TestType4 : public TestType1 +{ + Q_OBJECT +public: + TestType4(QObject *parent = 0) : TestType1(parent) {} +}; + + +tst_typeimports::tst_typeimports() +{ + qmlRegisterType<TestType1>("Qt.test", 1, 0, "TestType1"); + qmlRegisterType<TestType2>("Qt.test", 1, 0, "TestType2"); + qmlRegisterType<TestType3>("Qt.test", 2, 0, "TestType3"); + qmlRegisterType<TestType4>("Qt.test", 2, 0, "TestType4"); +} + +inline QUrl TEST_FILE(const QString &filename) +{ + return QUrl::fromLocalFile(QLatin1String(SRCDIR) + QLatin1String("/data/") + filename); +} + +void tst_typeimports::cpp() +{ + QBENCHMARK { + QDeclarativeComponent component(&engine, TEST_FILE("cpp.qml")); + QVERIFY(component.isReady()); + } +} + +void tst_typeimports::qml() +{ + QBENCHMARK { + QDeclarativeComponent component(&engine, TEST_FILE("qml.qml")); + QVERIFY(component.isReady()); + } +} + +QTEST_MAIN(tst_typeimports) + +#include "tst_typeimports.moc" diff --git a/tests/benchmarks/declarative/typeimports/typeimports.pro b/tests/benchmarks/declarative/typeimports/typeimports.pro new file mode 100644 index 0000000..8a74e0d --- /dev/null +++ b/tests/benchmarks/declarative/typeimports/typeimports.pro @@ -0,0 +1,15 @@ +load(qttest_p4) +TEMPLATE = app +TARGET = tst_typeimports +QT += declarative +macx:CONFIG -= app_bundle + +SOURCES += tst_typeimports.cpp + +symbian* { + data.sources = data/* + data.path = data + DEPLOYMENT += addFiles +} else { + DEFINES += SRCDIR=\\\"$$PWD\\\" +}
\ No newline at end of file |