diff options
135 files changed, 5210 insertions, 740 deletions
diff --git a/demos/declarative/samegame/SamegameCore/samegame.js b/demos/declarative/samegame/SamegameCore/samegame.js index aafbfdf..bf99ca3 100755 --- a/demos/declarative/samegame/SamegameCore/samegame.js +++ b/demos/declarative/samegame/SamegameCore/samegame.js @@ -5,7 +5,6 @@ var maxRow = 15; var maxIndex = maxColumn*maxRow; var board = new Array(maxIndex); var blockSrc = "SamegameCore/BoomBlock.qml"; -var scoresURL = "http://qtfx-nokia.trolltech.com.au/samegame/scores.php"; var scoresURL = ""; var gameDuration; var component = Qt.createComponent(blockSrc); @@ -179,8 +178,8 @@ function createBlock(column,row){ if(component.isReady){ var dynamicObject = component.createObject(); if(dynamicObject == null){ - print("error creating block"); - print(component.errorsString()); + console.log("error creating block"); + console.log(component.errorsString()); return false; } dynamicObject.type = Math.floor(Math.random() * 3); @@ -193,8 +192,8 @@ function createBlock(column,row){ dynamicObject.spawned = true; board[index(column,row)] = dynamicObject; }else{ - print("error loading block component"); - print(component.errorsString()); + console.log("error loading block component"); + console.log(component.errorsString()); return false; } return true; diff --git a/demos/declarative/snake/content/snake.js b/demos/declarative/snake/content/snake.js index 2457fbd..02f9757 100644 --- a/demos/declarative/snake/content/snake.js +++ b/demos/declarative/snake/content/snake.js @@ -54,9 +54,9 @@ function startNewGame() } else { if(linkComponent.isReady == false){ if(linkComponent.isError == true) - print(linkComponent.errorsString()); + console.log(linkComponent.errorsString()); else - print("Still loading linkComponent"); + console.log("Still loading linkComponent"); continue;//TODO: Better error handling? } var link = linkComponent.createObject(); @@ -295,9 +295,9 @@ function createCookie(value) { if(cookieComponent.isReady == false){ if(cookieComponent.isError == true) - print(cookieComponent.errorsString()); + console.log(cookieComponent.errorsString()); else - print("Still loading cookieComponent"); + console.log("Still loading cookieComponent"); return;//TODO: Better error handling? } cookie = cookieComponent.createObject(); diff --git a/dist/changes-4.7.0 b/dist/changes-4.7.0 index d5b4672..4fd7fdb 100644 --- a/dist/changes-4.7.0 +++ b/dist/changes-4.7.0 @@ -56,6 +56,10 @@ QtGui functions, and replaced them with setCopyCount(), copyCount() and supportsMultipleCopies(). + - QCommonStyle + * Fixed a bug that led to missing text pixels in QTabBar when using + small font sizes. (QTBUG-7137) + **************************************************************************** * Database Drivers * **************************************************************************** @@ -72,6 +76,13 @@ Qt for Linux/X11 Qt for Windows -------------- + - QLocalSocket + * Pipe handle leak fixed, when closing a QLocalSocket that still has + unwritten data. (QTBUG-7815) + * Fixed closing state for local sockets with unwritten data. (QTBUG-9681) + * Detection of Windows mobile 6.5 fixed. (QTBUG-8418) + * Improved performance of writing to QLocalSocket. + Qt for Mac OS X --------------- @@ -84,6 +95,17 @@ Qt for Embedded Linux Qt for Windows CE ----------------- + - Core changes + * Fixed menu handling on Windows mobile. (QTBUG-8754) + * Fixed a crash when receiving a certain type of WM_SETTINGSCHANGE + message. (QTBUG-7943) + + - QWindowsMobileStyle + * Huge performance penalty for QTabWidget fixed for + Windows mobile 6.5. (QTBUG-8419) + * QTabBar scroll button size has been fixed. (QTBUG-8757) + + **************************************************************************** * Compiler Specific Changes * @@ -96,6 +118,9 @@ Qt for Windows CE - Build System + - "configure -fast" on Windows now also works for other make tools than + nmake. (QTBUG-8562) + - Assistant diff --git a/doc/src/declarative/advtutorial.qdoc b/doc/src/declarative/advtutorial.qdoc index c465da4..2d05850 100644 --- a/doc/src/declarative/advtutorial.qdoc +++ b/doc/src/declarative/advtutorial.qdoc @@ -66,13 +66,13 @@ control QML elements. Tutorial chapters: \list 1 -\o \l {QML Advanced Tutorial 1 - Creating the Game Canvas and Blocks}{Creating the Game Canvas and Blocks} -\o \l {QML Advanced Tutorial 2 - Populating the Game Canvas}{Populating the Game Canvas} -\o \l {QML Advanced Tutorial 3 - Implementing the Game Logic}{Implementing the Game Logic} -\o \l {QML Advanced Tutorial 4 - Finishing Touches}{Finishing Touches} +\o \l {declarative/tutorials/samegame/samegame1}{Creating the Game Canvas and Blocks} +\o \l {declarative/tutorials/samegame/samegame2}{Populating the Game Canvas} +\o \l {declarative/tutorials/samegame/samegame3}{Implementing the Game Logic} +\o \l {declarative/tutorials/samegame/samegame4}{Finishing Touches} \endlist -All the code in this tutorial can be found in the $QTDIR/examples/declarative/tutorials/samegame +All the code in this tutorial can be found in Qt's \c examples/declarative/tutorials/samegame directory. */ @@ -83,7 +83,7 @@ directory. \previouspage QML Advanced Tutorial \nextpage QML Advanced Tutorial 2 - Populating the Game Canvas -The files referenced on this page can be found in \c $QTDIR\examples\tutorials\samegame\samegame1. +\example declarative/tutorials/samegame/samegame1 \section2 Creating the application screen @@ -148,8 +148,7 @@ elements to get started. Next, we will populate the game canvas with some blocks \previouspage QML Advanced Tutorial 1 - Creating the Game Canvas and Blocks \nextpage QML Advanced Tutorial 3 - Implementing the Game Logic -The files referenced on this page can be found in \c $QTDIR\examples\tutorials\samegame\samegame2. - +\example declarative/tutorials/samegame/samegame2 \section2 Generating the blocks in JavaScript @@ -216,7 +215,7 @@ Now, we have a screen of blocks, and we can begin to add the game mechanics. \previouspage QML Advanced Tutorial 2 - Populating the Game Canvas \nextpage QML Advanced Tutorial 4 - Finishing Touches -The files referenced on this page can be found in \c $QTDIR\examples\tutorials\samegame\samegame3. +\example declarative/tutorials/samegame/samegame3 \section2 Making a playable game @@ -301,7 +300,7 @@ until the next chapter - where your application becomes alive! \contentspage QML Advanced Tutorial \previouspage QML Advanced Tutorial 3 - Implementing the Game Logic -The files referenced on this page can be found in \c $QTDIR\examples\tutorials\samegame\samegame4. +\example declarative/tutorials/samegame/samegame4 \section2 Adding some flair diff --git a/doc/src/declarative/anchor-layout.qdoc b/doc/src/declarative/anchor-layout.qdoc index ff47694..5340de6 100644 --- a/doc/src/declarative/anchor-layout.qdoc +++ b/doc/src/declarative/anchor-layout.qdoc @@ -44,10 +44,16 @@ \target anchor-layout \title Anchor-based Layout in QML -In addition to the more traditional \l Grid, \l Row, and \l Column, QML also provides a way to layout items using the concept of \e anchors. Each item can be thought of as having a set of 6 invisible "anchor lines": \e left, \e horizontalCenter, \e right, \e top, \e verticalCenter, and \e bottom. +In addition to the more traditional \l Grid, \l Row, and \l Column, +QML also provides a way to layout items using the concept of \e anchors. +Each item can be thought of as having a set of 7 invisible "anchor lines": +\e left, \e horizontalCenter, \e right, \e top, \e verticalCenter, \e baseline, and \e bottom. \image edges_qml.png +The baseline (not pictured above) corresponds to the imaginary line on which +text would sit. For items with no text it is the same as \e top. + The QML anchoring system allows you to define relationships between the anchor lines of different items. For example, you can write: \code diff --git a/doc/src/declarative/animation.qdoc b/doc/src/declarative/animation.qdoc index 9969e8f..88aca1b 100644 --- a/doc/src/declarative/animation.qdoc +++ b/doc/src/declarative/animation.qdoc @@ -94,7 +94,7 @@ Rectangle { Rectangle { color: "red" width: 50; height: 50 - NumberAnimation on x { to: 50; } + NumberAnimation on x { to: 50 } } } \endqml diff --git a/doc/src/declarative/declarativeui.qdoc b/doc/src/declarative/declarativeui.qdoc index 55945e6..d79c4d2 100644 --- a/doc/src/declarative/declarativeui.qdoc +++ b/doc/src/declarative/declarativeui.qdoc @@ -40,19 +40,28 @@ ****************************************************************************/ /*! -\title Declarative UI (QML) +\title Declarative UI Using QML \page declarativeui.html \brief The Qt Declarative module provides a declarative framework for building highly dynamic, custom user interfaces. +\section1 \l{QML Elements}{Fast QML Elements Reference Page} + +\raw HTML +<br> +\endraw + +\section1 Preamble + Qt Declarative UI provides a declarative framework for building highly dynamic, custom user interfaces. Declarative UI helps programmers and designers collaborate to build the animation rich, fluid user interfaces that are becoming common in portable consumer devices, such as mobile phones, media players, set-top boxes and netbooks. -The Qt Declarative module provides an engine for interpreting the declarative QML -language, and a rich set of \l {QML Elements}{QML elements} that can be used -from QML. + +The Qt Declarative module provides an engine for interpreting the declarative +QML language, and a rich set of \bold { \l {QML Elements}{QML elements} } +that can be used from QML. QML is an extension to \l {http://www.ecma-international.org/publications/standards/Ecma-262.htm} {JavaScript}, that provides a mechanism to declaratively build an object tree @@ -76,7 +85,6 @@ completely new applications. QML is fully \l {Extending QML in C++}{extensible \o \l {QML Tutorial}{Tutorial: 'Hello World'} \o \l {QML Advanced Tutorial}{Tutorial: 'Same Game'} \o \l {QML Examples and Demos} -\o \l {Using QML in C++ Applications} \o \l {QML for Qt programmers} \endlist @@ -98,12 +106,18 @@ completely new applications. QML is fully \l {Extending QML in C++}{extensible \o \l {qmlruntime.html}{The Qt Declarative Runtime} \endlist +\section1 Using QML with C++: +\list +\o \l {Tutorial: Writing QML extensions with C++} +\o \l {Extending QML in C++} +\o \l {Using QML in C++ Applications} +\o \l {Integrating QML with existing Qt UI code} +\endlist + \section1 Reference: \list \o \l {QML Elements} \o \l {QML Global Object} -\o \l {Extending QML in C++} -\o \l {Integrating QML with existing Qt UI code} \o \l {QML Internationalization} \o \l {QML Security} \o \l {QtDeclarative Module} diff --git a/doc/src/declarative/elements.qdoc b/doc/src/declarative/elements.qdoc index 355c0f4..79fe909 100644 --- a/doc/src/declarative/elements.qdoc +++ b/doc/src/declarative/elements.qdoc @@ -44,7 +44,7 @@ \target elements \title QML Elements -The following table lists the QML elements provided by the Qt Declarative module. +The following table lists the QML elements provided by the \l {QtDeclarative}{Qt Declarative} module. \table 80% \header @@ -122,6 +122,7 @@ The following table lists the QML elements provided by the Qt Declarative module \o \l Rectangle \o \l Image \o \l BorderImage +\o \l AnimatedImage \o \l Text \o \l TextInput \o \l TextEdit diff --git a/doc/src/declarative/examples.qdoc b/doc/src/declarative/examples.qdoc index dc6b76c..e01459f 100644 --- a/doc/src/declarative/examples.qdoc +++ b/doc/src/declarative/examples.qdoc @@ -71,7 +71,47 @@ For example, from your build directory, run: \section1 Examples \list +\o \l{declarative/animations}{Animations} +\o \l{declarative/aspectratio}{Aspect Ratio} +\o \l{declarative/behaviors}{Behaviors} +\o \l{declarative/border-image}{Border Image} +\o \l{declarative/clocks}{Clocks} +\o \l{declarative/connections}{Connections} +\o \l{declarative/dial}{Dial} +\o \l{declarative/dynamic}{Dynamic} +\o \l{declarative/extending}{Extending} +\o \l{declarative/fillmode}{Fillmode} +\o \l{declarative/flipable}{Flipable} \o \l{declarative/focus}{Focus} +\o \l{declarative/fonts}{Fonts} +\o \l{declarative/gridview}{GridView} +\o \l{declarative/imageprovider}{Image Provider} +\o \l{declarative/images}{Images} +\o \l{declarative/layouts}{Layouts} +\o \l{declarative/listmodel-threaded}{ListModel Threaded} +\o \l{declarative/listview}{ListView} +\o \l{declarative/mousearea}{Mouse Area} +\o \l{declarative/objectlistmodel}{Object ListModel} +\o \l{declarative/package}{Package} +\o \l{declarative/parallax}{Parallax} +\o \l{declarative/plugins}{Plugins} +\o \l{declarative/progressbar}{Progress Bars} +\o \l{declarative/proxywidgets}{Proxy Widgets} +\o \l{declarative/scrollbar}{Scrollbar} +\o \l{declarative/searchbox}{Search Box} +\o \l{declarative/slideswitch}{Slide Switch} +\o \l{declarative/sql}{SQL} +\o \l{declarative/states}{States} +\o \l{declarative/stringlistmodel}{String ListModel} +\o \l{declarative/tabwidget}{Tab Widget} +\o \l{declarative/tic-tac-toe}{Tic-Tac-Toe} +\o \l{declarative/tvtennis}{TV Tennis} +\o \l{declarative/velocity}{Velocity} +\o \l{declarative/webview}{WebView} +\o \l{declarative/workerscript}{WorkerScript} +\o \l{declarative/xmldata}{XML Data} +\o \l{declarative/xmlhttprequest}{XMLHttpRequest} + \endlist \section1 Demos diff --git a/doc/src/declarative/extending-tutorial.qdoc b/doc/src/declarative/extending-tutorial.qdoc new file mode 100644 index 0000000..f00b858 --- /dev/null +++ b/doc/src/declarative/extending-tutorial.qdoc @@ -0,0 +1,420 @@ +/**************************************************************************** +** +** 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 documentation of the Qt Toolkit. +** +** $QT_BEGIN_LICENSE:LGPL$ +** No Commercial Usage +** This file contains pre-release code and may not be distributed. +** You may use this file in accordance with the terms and conditions +** contained in the 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$ +** +****************************************************************************/ + +/*! + +\page qml-extending-tutorial-index.html +\title Tutorial: Writing QML extensions with C++ + +The QtDeclarative module provides a set of APIs for extending QML through +C++ extensions. You can write extensions to add your own QML types, extend existing +Qt types, or call C/C++ functions that are not accessible from ordinary QML code. + +This tutorial shows how to write a QML extension using C++ that includes +core QML features, including properties, signals and bindings. It also shows how +extensions can be deployed through plugins. + +You can find the source code for this tutorial in \c Qt's +examples/declarative/tutorials/extending directory. + +Tutorial chapters: + +\list 1 +\o \l{declarative/tutorials/extending/chapter1-basics}{Creating a New Type} +\o \l{declarative/tutorials/extending/chapter2-methods}{Connecting to C++ Methods and Signals} +\o \l{declarative/tutorials/extending/chapter3-bindings}{Adding Property Bindings} +\o \l{declarative/tutorials/extending/chapter4-customPropertyTypes}{Using Custom Property Types} +\o \l{declarative/tutorials/extending/chapter5-plugins}{Writing an Extension Plugin} +\o \l{qml-extending-tutorial6.html}{In Summary} +\endlist + +*/ + +/*! +\title Chapter 1: Creating a New Type + +\example declarative/tutorials/extending/chapter1-basics + +Let's create a new QML type called "Musician" that has two properties: a name +and an instrument. We will make it available in a \l {Modules}{module} called "Music", with +a module version of 1.0. +We want this \c Musician type to be usable from QML like this: + +\code + import Music 1.0 + + Musician { + name: "Reddy the Rocker" + instrument: "Guitar" + } +\endcode + +To do this, we need a C++ class that encapsulates this \c Musician type and its two +properties. Since QML relies heavily on Qt's \l{Meta-Object System}{meta object system}, +this new class must: + +\list +\o inherit from QObject +\o declare its properties using the Q_PROPERTY() macro +\endlist + +Here is our \c Musician class, defined in \c musician.h: + +\snippet declarative/tutorials/extending/chapter1-basics/musician.h 0 + +It defines the two properties, \c name and \c instrument, with the Q_PROPERTY() macro. +The class implementation in \c musician.cpp simply sets and returns the \c m_name and +\c m_instrument values as appropriate. + +Our QML file, \c app.qml, creates a \c Musician item and display the musician's details +using a standard QML \l Text item: + +\quotefile declarative/tutorials/extending/chapter1-basics/app.qml + +We'll also create a C++ application that uses a QDeclarativeView to run and +display \c app.qml. The application must register the \c Musician type +using the qmlRegisterType() function, to allow it to be used from QML. If +you don't register the type, \c app.qml won't be able to create a \c Musician. + +Here is the application \c main.cpp: + +\snippet declarative/tutorials/extending/chapter1-basics/main.cpp 0 + +This call to qmlRegisterType() registers the \c Musician type as a type called "Musician", in a module named "Music", +with a module version of 1.0. + +Lastly, we write a \c .pro project file that includes the files and the \c declarative library: + +\quotefile declarative/tutorials/extending/chapter1-basics/chapter1-basics.pro + +Now we can build and run the application. Try it yourself with the code in Qt's \c examples/tutorials/extending/chapter1-basics directory. + +\example declarative/tutorials/extending/chapter1-basics + +At the moment, the \c app.qml is run from within a C++ application. +This may seem odd if you're used to running QML files with the standard \c qml tool. +Later on, we'll show how to create a plugin so that you can run \c app.qml using the +\c qml tool instead. + +*/ + + +/*! +\title Chapter 2: Connecting to C++ Methods and Signals + +\example declarative/tutorials/extending/chapter2-methods + +Suppose we want \c Musician to have a "perform" method that prints a message +to the console and then emits a "performanceEnded" signal. +Other elements would be able to call \c perform() and receive +\c performanceEnded() signals like this: + +\quotefile declarative/tutorials/extending/chapter2-methods/app.qml + +To do this, we add a \c perform() method and a \c performanceEnded() signal +to our C++ class: + +\snippet declarative/tutorials/extending/chapter2-methods/musician.h 0 +\dots +\snippet declarative/tutorials/extending/chapter2-methods/musician.h 1 +\dots +\snippet declarative/tutorials/extending/chapter2-methods/musician.h 2 +\dots +\snippet declarative/tutorials/extending/chapter2-methods/musician.h 3 + +The use of Q_INVOKABLE makes the \c perform() method available to the +Qt Meta-Object system, and in turn, to QML. Note that it could have +been declared as as a Qt slot instead of using Q_INVOKABLE, as +slots are also callable from QML. Both of these approaches are valid. + +The \c perform() method simply prints a message to the console and +then emits \c performanceEnded(): + +\snippet declarative/tutorials/extending/chapter2-methods/musician.cpp 0 + +Now when we run the application and click the window, the application outputs: + +\code + "Reddy the Rocker" is playing the "Guitar" + The performance has now ended +\endcode + +Try out the example yourself with the updated code in Qt's \c examples/tutorials/extending/chapter2-methods directory. + +*/ + +/*! +\title Chapter 3: Adding Property Bindings + +\example declarative/tutorials/extending/chapter3-bindings + +Property bindings is a powerful feature of QML that allows values of different +elements to be synchronized automatically. It uses signals to notify and update +other elements' values when property values change. + +Let's enable property bindings for the \c instrument property. That means +if we have code like this: + +\quotefile declarative/tutorials/extending/chapter3-bindings/app.qml + +The "instrument: reddy.instrument" statement binds the \c instrument value of +\c craig to the \c instrument of \c reddy. +Whenever \c reddy's \c instrument value changes, \c craig's \c instrument value +updates to the same value. When the window is clicked, the application outputs: + +\code + "Reddy the Rocker" is playing the "Guitar" + "Craig the Copycat" is playing the "Guitar" + "Reddy the Rocker" is playing the "Drums" + "Craig the Copycat" is playing the "Drums" +\endcode + +It's easy to enable property binding for the \c instrument property. +We add a \l{Qt's Property System}{NOTIFY} feature to its Q_PROPERTY() declaration to indicate that a "instrumentChanged" signal +is emitted whenever the value changes. + +\snippet declarative/tutorials/extending/chapter3-bindings/musician.h 0 +\dots +\snippet declarative/tutorials/extending/chapter3-bindings/musician.h 1 +\dots +\snippet declarative/tutorials/extending/chapter3-bindings/musician.h 2 +\dots +\snippet declarative/tutorials/extending/chapter3-bindings/musician.h 3 + +Then, we emit this signal in \c setInstrument(): + +\snippet declarative/tutorials/extending/chapter3-bindings/musician.cpp 0 + +It's important for \c setInstrument() to check that the instrument value has actually changed +before emitting \c instrumentChanged(). This ensures the signal is not emitted unnecessarily and +also prevents loops when other elements respond to the value change. + +*/ + +/*! +\title Chapter 4: Using Custom Property Types + +\example declarative/tutorials/extending/chapter4-customPropertyTypes + +The \c Musician type currently has two properties that are both strings. +It could have all sorts of other properties. For example, we could add an +integer-type property to store the age of each musician: + +\code + class Musician : public QObject + { + ... + Q_PROPERTY(int age READ age WRITE setAge) + public: + ... + int age() const; + void setAge(int age); + ... + }; +\endcode + +We can also use various other property types. QML has built-in support for the following +types: + +\list +\o bool +\o unsigned int, int +\o float, double, qreal +\o QString +\o QUrl +\o QColor +\o QDate, QTime, QDateTime +\o QPoint, QPointF +\o QSize, QSizeF +\o QRect, QRectF +\o QVariant +\endlist + +If we want to create a property whose type is not supported by QML by default, +we need to register the type with QML. + +For example, let's change the type of the \c instrument property from a string to a +new type called "Instrument". Instead of assigning a string value to \c instrument, +we assign an \c Instrument value: + +\quotefile declarative/tutorials/extending/chapter4-customPropertyTypes/app.qml + +Like \c Musician, this new \c Instrument type has to inherit from QObject and declare +its properties with Q_PROPERTY(): + +\snippet declarative/tutorials/extending/chapter4-customPropertyTypes/instrument.h 0 + +To use it from \c Musician, we modify the \c instrument property declaration +and associated method signatures: + +\snippet declarative/tutorials/extending/chapter4-customPropertyTypes/musician.h 0 +\dots +\snippet declarative/tutorials/extending/chapter4-customPropertyTypes/musician.h 1 +\dots +\snippet declarative/tutorials/extending/chapter4-customPropertyTypes/musician.h 2 +\dots +\snippet declarative/tutorials/extending/chapter4-customPropertyTypes/musician.h 3 + +Like the \c Musician type, the \c Instrument type has to be registered +using qmlRegisterType() to be used from QML. As with \c Musician, we'll add the +type to the "Music" module, version 1.0: + +\snippet declarative/tutorials/extending/chapter4-customPropertyTypes/main.cpp 0 +\dots +\snippet declarative/tutorials/extending/chapter4-customPropertyTypes/main.cpp 1 +\dots +\snippet declarative/tutorials/extending/chapter4-customPropertyTypes/main.cpp 2 + +Try it out with the code in Qt's \c examples/tutorials/extending/chapter4-customPropertyTypes directory. + +*/ + +/*! +\title Chapter 5: Writing an Extension Plugin + +\example declarative/tutorials/extending/chapter5-plugins + +Currently the \c Musician and \c Instrument types are used by \c app.qml, +which is displayed using a QDeclarativeView in a C++ application. An alternative +way to use our QML extension is to create a plugin library to make it available +to the QML engine. This means we could load \c app.qml using the standard \c qml tool +(or some other QML runtime application) instead of writing a \c main.cpp file and +loading our own C++ application. + +To create a plugin library, we need: + +\list +\o A plugin class that registers our QML types +\o A project file that describes the plugin +\o A "qmldir" file that tells the QML engine to load the plugin +\endlist + +First, we create a plugin class named \c MusicPlugin. It subclasses QDeclarativeExtensionPlugin +and registers our QML types in the inherited \l{QDeclarativeExtensionPlugin::}{registerTypes()} method. It also calls +Q_EXPORT_PLUGIN2 for Qt's \l{How to Create Qt Plugins}{plugin system}. + +Here is the \c MusicPlugin definition in \c musicplugin.h: + +\snippet declarative/tutorials/extending/chapter5-plugins/musicplugin.h 0 + +And its implementation in \c musicplugin.cpp: + +\snippet declarative/tutorials/extending/chapter5-plugins/musicplugin.cpp 0 + +Then, we write a \c .pro project file that defines the project as a plugin library +and specifies with DESTDIR that library files should be built into a "lib" subdirectory: + +\quotefile declarative/tutorials/extending/chapter5-plugins/chapter5-plugins.pro + +Finally, we add a \c qmldir file that is automatically parsed by the QML engine. +Here, we specify that a plugin named "chapter5-plugin" (the name +of the example project) can be found in the "lib" subdirectory: + +\quotefile declarative/tutorials/extending/chapter5-plugins/qmldir + +Now we have a plugin, and instead of having a main.cpp and an executable, we can build +the project and then run the QML file directly using the \c qml tool: + +\code + qml app.qml +\endcode + +Notice the "import Music 1.0" statement has disappeared from \c app.qml. This is +because the \c qmldir file is in the same directory as \c app.qml: this is equivalent to +having Musician.qml and Instrument.qml files inside the project directory, which could both +be used by \c app.qml without import statements. +*/ + +/*! +\page qml-extending-tutorial6.html +\title Chapter 6: In Summary + +In this tutorial, we've shown the basic steps for creating a QML extension: + +\list +\o Define new QML types by subclassing QObject and registering them with qmlRegisterType() +\o Add callable methods using Q_INVOKABLE or Qt slots, and connect to Qt signals with an \c onSignal syntax +\o Add property bindings by defining \l{Qt's Property System}{NOTIFY} signals +\o Define custom property types if the built-in types are not sufficient +\o Create a plugin library by defining a Qt plugin and writing a \c qmldir file +\endlist + + +The \l {Extending QML in C++} reference documentation shows other useful features that can be added to +QML extensions. For example, we could use \l{Object and List Property Types}{list properties} to allow multiple instruments for a \c Musician: + +\code + Musician { + instruments: [ + Instrument { type: "Guitar" } + Instrument { type: "Drums" } + Instrument { type: "Keyboard" } + ] + } +\endcode + +Or use \l{Default Property}{default properties} and avoid an +\c instruments property altogether: + +\code + Musician { + Instrument { type: "Guitar" } + Instrument { type: "Drums" } + Instrument { type: "Keyboard" } + } +\endcode + +Or even change the \c instrument of a \c Musician from time to time using \l{Property Value Sources}{property value sources}: + +\code + Musician { + InstrumentRandomizer on instrument {} + } +\endcode + + +See the \l{Extending QML in C++}{reference documentation} for more information. + +Additionally, \l {Integrating QML with existing Qt UI code} shows how to create +and integrate with QML extensions that have drawing and graphical capabilities (through QGraphicsWidget). + +*/ + diff --git a/doc/src/declarative/extending.qdoc b/doc/src/declarative/extending.qdoc index c27d091..1c159e4 100644 --- a/doc/src/declarative/extending.qdoc +++ b/doc/src/declarative/extending.qdoc @@ -43,7 +43,7 @@ \page qml-extending.html \title Extending QML in C++ -The QML syntax declaratively describes how to construct an in memory object +The QML syntax declaratively describes how to construct an in-memory object tree. In Qt, QML is mainly used to describe a visual scene graph, but it is not conceptually limited to this: the QML format is an abstract description of any object tree. All the QML element types included in Qt are implemented using @@ -65,7 +65,7 @@ QML relies heavily on Qt's meta object system and can only instantiate classes that derive from QObject. The QML engine has no intrinsic knowledge of any class types. Instead the -programmer must define the C++ types, and their corresponding QML name. +programmer must register the C++ types with their corresponding QML names. Custom C++ types are registered using a template function: @@ -152,7 +152,7 @@ template<typename T> int qmlRegisterInterface(const char *typeName) \endcode -Registers the C++ interface \a T with the QML system as \a typeName. +This registers the C++ interface \a T with the QML system as \a typeName. Following registration, QML can coerce objects that implement this interface for assignment to appropriately typed properties. @@ -196,7 +196,7 @@ registered, the following function can be used: int qmlRegisterType() \endcode -Registers the C++ type \a T with the QML system. The parameterless call to the template +This registers the C++ type \a T with the QML system. The parameterless call to the template function qmlRegisterType() does not define a mapping between the C++ class and a QML element name, so the type is not instantiable from QML, but it is available for type coercion. @@ -222,7 +222,7 @@ The QML snippet shown above assigns a collection of objects to the The \e {default property} is a syntactic convenience that allows a type designer to specify a single property as the type's default. The default property is assigned to whenever no explicit property is specified. As a convenience, it is -behaviorally identical to assigning the default property explicitly by name. +behaviorally identical to assigning to the default property explicitly by name. From C++, type designers mark the default property using a Q_CLASSINFO() annotation: @@ -232,7 +232,7 @@ annotation: Q_CLASSINFO("DefaultProperty", "property") \endcode -Mark \a property as the class's default property. \a property must be either +This marks \a property as the class's default property. \a property must be either an object property, or a list property. A default property is optional. A derived class inherits its base class's @@ -248,7 +248,7 @@ specify a default property. \snippet examples/declarative/extending/grouped/example.qml 1 -The QML snippet shown above assigns a number properties to the \c Boy object, +The QML snippet shown above assigns a number of properties to the \c Boy object, including four properties using the grouped property syntax. Grouped properties collect similar properties together into a single named @@ -273,13 +273,13 @@ implement the \c shoe property grouping. \snippet examples/declarative/extending/attached/example.qml 1 -The QML snippet shown above assigns the \c rsvp property using the attached +The QML snippet shown above assigns a date to the \c rsvp property using the attached property syntax. Attached properties allow unrelated types to annotate other types with some additional properties, generally for their own use. Attached properties are identified through the use of the attacher type name, in the case shown -\c BirthdayParty, as a suffix to the property name. +\c BirthdayParty, as a prefix to the property name. In the example shown, \c BirthdayParty is called the attaching type, and the \c Boy instance the attachee object instance. @@ -306,7 +306,7 @@ public: QML_DECLARE_TYPEINFO(MyType, QML_HAS_ATTACHED_PROPERTIES) \endcode -Return an attachment object, of type \a AttachedPropertiesType, for the +This returns an attachment object, of type \a AttachedPropertiesType, for the attachee \a object instance. It is customary, though not strictly required, for the attachment object to be parented to \a object to prevent memory leaks. @@ -349,7 +349,7 @@ an instance can be accessed using the following method: template<typename T> QObject *qmlAttachedPropertiesObject<T>(QObject *attachee, bool create = true); \endcode -Returns the attachment object attached to \a attachee by the attaching type +This returns the attachment object attached to \a attachee by the attaching type \a T. If type \a T is not a valid attaching type, this method always returns 0. If \a create is true, a valid attachment object will always be returned, @@ -366,7 +366,7 @@ It is an element's responsibility to ensure that it does not access or return pointers to invalid objects. QML makes the following guarentees: \list -\o An object assigned to an QObject (or QObject-derived) pointer property will be +\o An object assigned to a QObject (or QObject-derived) pointer property will be valid at the time of assignment. Following assignment, it is the responsibility of the class to subsequently guard @@ -562,19 +562,22 @@ extension type - when registering the target class whose properties are transparently merged with the original target class when used from within QML. An extension class is a regular QObject, with a constructor that takes a QObject -pointer. When needed (extension classes are delay created until the first extended +pointer. When needed (extension class creation is delayed until the first extended property is accessed) the extension class is created and the target object is passed in as the parent. When an extended property on the original is accessed, the appropriate property on the extension object is used instead. When an extended type is installed, one of the \code - #define QML_REGISTER_EXTENDED_TYPE(URI, VMAJ, VFROM, VTO, QDeclarativeName,T, ExtendedT) - #define QML_REGISTER_EXTENDED_NOCREATE_TYPE(T, ExtendedT) +template<typename T, typename ExtendedT> +int qmlRegisterType(const char *uri, int versionMajor, int versionMinor, const char *qmlName) + +template<typename T, typename ExtendedT> +int qmlRegisterType() \endcode -macros should be used instead of the regular \c QML_REGISTER_TYPE or -\c QML_REGISTER_NOCREATE_TYPE. The arguments are identical to the corresponding -non-extension object macro, except for the ExtendedT parameter which is the type +functions should be used instead of the regular \c qmlRegisterType() variations. +The arguments are identical to the corresponding non-extension registration functions, +except for the ExtendedT parameter which is the type of the extension object. \section1 Optimization diff --git a/doc/src/declarative/globalobject.qdoc b/doc/src/declarative/globalobject.qdoc index 6709ab4..57eaae7 100644 --- a/doc/src/declarative/globalobject.qdoc +++ b/doc/src/declarative/globalobject.qdoc @@ -223,7 +223,7 @@ of their use. function finishCreation(){ if(component.isReady()){ sprite = component.createObject(); - if(sprite == 0){ + if(sprite == null){ // Error Handling }else{ sprite.parent = page; @@ -248,7 +248,7 @@ of their use. \code component = createComponent("Sprite.qml"); sprite = component.createObject(); - if(sprite == 0){ + if(sprite == null){ // Error Handling console.log(component.errorsString()); }else{ diff --git a/doc/src/declarative/integrating.qdoc b/doc/src/declarative/integrating.qdoc index 65413ec..0051f09 100644 --- a/doc/src/declarative/integrating.qdoc +++ b/doc/src/declarative/integrating.qdoc @@ -152,8 +152,8 @@ Here is a screenshot of the result: \image declarative-integrating-graphicswidgets.png -Note this approach of creating your graphics widgets from QML does not work -with QGraphicsItem objects that are not QGraphicsWidget-based, since they are not QObjects. +Note this approach of creating your graphics objects from QML does not work +with QGraphicsItems that are not QGraphicsObject-based, since they are not QObjects. See \l{Extending QML in C++} for further information on using C++ types. diff --git a/doc/src/declarative/javascriptblocks.qdoc b/doc/src/declarative/javascriptblocks.qdoc index 7c0570e..2db7e8e 100644 --- a/doc/src/declarative/javascriptblocks.qdoc +++ b/doc/src/declarative/javascriptblocks.qdoc @@ -75,7 +75,7 @@ Item { MouseArea { anchors.fill: parent - onClicked: print(factorial(10)) + onClicked: console.log(factorial(10)) } } \endcode @@ -99,7 +99,7 @@ import "factorial.js" as MathFunctions Item { MouseArea { anchors.fill: parent - onClicked: print(MathFunctions.factorial(10)) + onClicked: console.log(MathFunctions.factorial(10)) } } \endcode @@ -184,6 +184,9 @@ Any element in a QML file - including nested elements and nested QML component instances - can use this attached property. If there is more than one \c onCompleted() handler to execute at startup, they are run sequentially in an undefined order. +Likewise, the \l {Component::onDestruction} attached property is triggered on +component destruction. + \section1 QML JavaScript Restrictions QML executes standard JavaScript code, with the following restrictions: @@ -204,16 +207,18 @@ is illegal in QML. \code // Illegal modification of undeclared variable a = 1; -for (var ii = 1; ii < 10; ++ii) a = a * ii; - console.log("Result: " + a); +for (var ii = 1; ii < 10; ++ii) + a = a * ii; +console.log("Result: " + a); \endcode It can be trivially modified to this legal code. \code var a = 1; -for (var ii = 1; ii < 10; ++ii) a = a * ii; - console.log("Result: " + a); +for (var ii = 1; ii < 10; ++ii) + a = a * ii; +console.log("Result: " + a); \endcode Any attempt to modify the global object - either implicitly or explicitly - will diff --git a/doc/src/declarative/measuring-performance.qdoc b/doc/src/declarative/measuring-performance.qdoc deleted file mode 100644 index cb608bf..0000000 --- a/doc/src/declarative/measuring-performance.qdoc +++ /dev/null @@ -1,122 +0,0 @@ -/**************************************************************************** -** -** 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 documentation of the Qt Toolkit. -** -** $QT_BEGIN_LICENSE:LGPL$ -** No Commercial Usage -** This file contains pre-release code and may not be distributed. -** You may use this file in accordance with the terms and conditions -** contained in the 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$ -** -****************************************************************************/ - -/*! -\page optimizing-performance.html -\target optimizing-performance -\title Optimizing Performance in QML - -The Qt Declarative module includes several tools to help measure performance. - -\section1 Performance Logging - -The declarative module uses the functionality provided by QPerformanceLog to log performance information. To see this information you can add the following to src.pro: - -\code -DEFINES += Q_ENABLE_PERFORMANCE_LOG -\endcode - -The performance information will be printed to screen on a QML application startup, or when running the viewer can be forced at anytime by pressing 'F3' on the keyboard. - -Additional logging can be enabled by adding the relevant categories to qfxperf.h and qfxperf.cpp. - -For example, to measure the cost of calculating the size of a text item, you would first define a TextSize category by adding the following: - -\code -//in qfxperf.h -Q_DECLARE_PERFORMANCE_METRIC(TextSize); - -//in qfxperf.cpp -Q_DEFINE_PERFORMANCE_METRIC(TextSize, "Text Size Calculation"); -\endcode - -You could then use this category in the code: - -\code -void QDeclarativeText::updateSize() -{ - QDeclarativePerfTimer<QDeclarativePerf::TextSize> perf; - ... -} -\endcode - -Because there is no cost for a QDeclarativePerfTimer when Q_ENABLE_PERFORMANCE_LOG is not defined, this line can persist in the code and be used to help detect performance bottlenecks and regressions. See the QPerformanceLog documentation for more information on this performance framework. - -\section1 FPS Measurements - -When running the viewer, pressing 'F2' on the keyboard while a QML program is running will cause information on cost-per-frame and frames-per-second (FPS) to be printed to the console. - -The information printed includes: -\list -\o \e repaint(): the total time spent painting. -\o \e paint(): the time spent by Qt painting. -\o \e timeBetweenFrames: the total time spent per frame. This number minus repaint() gives a good idea of how much time is spent on things besides painting. A high number here with a low number for repaint() indicates expensive calculations happening each frame. -\endlist - -\section1 Improving Performance - -The following tips can help decrease startup time for QML-based appications. - -\section2 Images - -\list -\o Use jpg instead of png for photo-like images. On the N810, this can save 150ms for a large (320x480) image. - -\o If you are configuring Qt, configure out any image plugins you don't plan to support (mng and svg are the most expensive). On the N810, this can save 75-100ms startup time. For example: - -\code -configure -no-libmng -no-svg -no-libtiff -\endcode - -\o In some cases running pngcrush, optipng, gifsicle or other similar tools can give some improvement. - -We are also investigating support for the loading of uncompressed images. This will provide opportunites to decrease startup time at the cost of increased storage space. -\endlist - -\section2 Fonts - -\list -\o Use qpf instead of ttf. When using multiple font sizes and weights on the N810, this can save 125ms startup time compared to a ttf 'clean' run, and 40-50ms on subsequent runs (ttfs are shared by open applications). -\endlist - -*/ - -*/ diff --git a/doc/src/declarative/network.qdoc b/doc/src/declarative/network.qdoc index d268a13..68768c6 100644 --- a/doc/src/declarative/network.qdoc +++ b/doc/src/declarative/network.qdoc @@ -130,11 +130,12 @@ See the \tt demos/declarative/flickr for a real demonstration of this. \section1 Configuring the Network Access Manager All network access from QML is managed by a QNetworkAccessManager set on the QDeclarativeEngine which executes the QML. -By default, this is an unmodified Qt QNetworkAccessManager. You may set a different manager using -QDeclarativeEngine::setNetworkAccessManager() as appropriate for the policies of your application. -For example, the \l {Qt Declarative UI Runtime}{qml} tool sets a new QNetworkAccessManager which -trusts HTTP Expiry headers to avoid network cache checks, allows HTTP Pipelining, adds a persistent HTTP CookieJar, -a simple disk cache, and supports proxy settings. +By default, this is an unmodified Qt QNetworkAccessManager. You may set a different manager by +providing a QDeclarativeNetworkAccessManagerFactory and setting it via +QDeclarativeEngine::setNetworkAccessManagerFactory(). +For example, the \l {Qt Declarative UI Runtime}{qml} tool sets a QDeclarativeNetworkAccessManagerFactory which +creates QNetworkAccessManager that trusts HTTP Expiry headers to avoid network cache checks, +allows HTTP Pipelining, adds a persistent HTTP CookieJar, a simple disk cache, and supports proxy settings. \section1 QRC Resources diff --git a/doc/src/declarative/qdeclarativedocument.qdoc b/doc/src/declarative/qdeclarativedocument.qdoc index cf3aae2..bc099ce 100644 --- a/doc/src/declarative/qdeclarativedocument.qdoc +++ b/doc/src/declarative/qdeclarativedocument.qdoc @@ -93,7 +93,7 @@ behaviour. As it is a template, a single QML component can be "run" multiple ti produce several objects, each of which are said to be \e instances of the component. Once created, instances are not dependent on the component that created them, so they can -operate on independent data. Here is an example of a simple "button" component that is +operate on independent data. Here is an example of a simple "Button" component that is instantiated four times, each with a different value for its \c text property. \table diff --git a/doc/src/declarative/qdeclarativei18n.qdoc b/doc/src/declarative/qdeclarativei18n.qdoc index 0a48dd9..c7dbd4d 100644 --- a/doc/src/declarative/qdeclarativei18n.qdoc +++ b/doc/src/declarative/qdeclarativei18n.qdoc @@ -86,7 +86,7 @@ lupdate hello.qml -ts hello.ts \endcode Then we open \c hello.ts in \l{Qt Linguist Manual} {Linguist}, provide -a translation and create the release file \c hello.qml. +a translation and create the release file \c hello.qm. Finally, we can test the translation: \code diff --git a/doc/src/declarative/qdeclarativeintro.qdoc b/doc/src/declarative/qdeclarativeintro.qdoc index 4d05a8c..a98c9e1 100644 --- a/doc/src/declarative/qdeclarativeintro.qdoc +++ b/doc/src/declarative/qdeclarativeintro.qdoc @@ -142,8 +142,8 @@ Commenting in QML is similar to JavaScript. \quotefile doc/src/snippets/declarative/comments.qml -Comments are ignored by the engine. The are useful for explaining what you -are doing: for referring back to at a later date, or for others reading +Comments are ignored by the engine. They are useful for explaining what you +are doing; for referring back to at a later date, or for others reading your QML files. Comments can also be used to prevent the execution of code, which is diff --git a/doc/src/declarative/qdeclarativestates.qdoc b/doc/src/declarative/qdeclarativestates.qdoc index 0fea6f8..fd0c677 100644 --- a/doc/src/declarative/qdeclarativestates.qdoc +++ b/doc/src/declarative/qdeclarativestates.qdoc @@ -70,7 +70,7 @@ In QML: \o A state can affect the properties of other objects, not just the object owning the state (and not just that object's children). \endlist -Here is an example of using states. In the default state \c myRect is positioned at 0,0. In the 'moved' state it is positioned at 50,50. Clicking within the mouse region changes the state from the default state to the 'moved' state, thus moving the rectangle. +Here is an example of using states. In the default state \c myRect is positioned at 0,0. In the 'moved' state it is positioned at 50,50. Clicking within the mouse area changes the state from the default state to the 'moved' state, thus moving the rectangle. \qml Item { diff --git a/doc/src/declarative/qmlruntime.qdoc b/doc/src/declarative/qmlruntime.qdoc index 9f7183a..a724c7d 100644 --- a/doc/src/declarative/qmlruntime.qdoc +++ b/doc/src/declarative/qmlruntime.qdoc @@ -52,7 +52,7 @@ QML is a runtime, as you can run plain qml files which pull in their required modules. To run apps with the QML runtime, you can either start the runtime - from your on application (using a QDeclarativeView) or with the simple \c qml application. + from your own application (using a QDeclarativeView) or with the simple \c qml application. The \c qml application can be installed in a production environment, assuming that it is not already present in the system. It is generally packaged alongside Qt. @@ -137,8 +137,8 @@ \section2 Runtime Object All applications using the qmlruntime will have access to the 'runtime' - property on the root context. This property contains several information - about the runtime environment of the application. + property on the root context. This property contains several pieces of + information about the runtime environment of the application. \section3 Screen Orientation @@ -150,11 +150,11 @@ which can be either Orientation.Landscape or Orientation.Portrait and which can be bound to in your application. An example is below: -\code + \code Item { state: (runtime.orientation == Orientation.Landscape) ? 'landscape' : '' } -\endcode + \endcode This allows your application to respond to the orientation of the screen changing. The runtime will automatically update this on some platforms (currently the N900 only) to match the physical @@ -163,12 +163,12 @@ \section3 Window Active The runtime.isActiveWindow property tells whether the main window of the qml runtime is currently active - or not. This is specially useful for embedded devices when you want to pause parts of your application, + or not. This is especially useful for embedded devices when you want to pause parts of your application, including animations, when your application loses focus or goes to the background. The example below, stops the animation when the application's window is deactivated and resumes on activation: -\code + \code Item { width: 300; height: 200 Rectangle { @@ -182,6 +182,6 @@ } } } -\endcode + \endcode */ diff --git a/doc/src/declarative/qtprogrammers.qdoc b/doc/src/declarative/qtprogrammers.qdoc index 05ffeb0..0b40840 100644 --- a/doc/src/declarative/qtprogrammers.qdoc +++ b/doc/src/declarative/qtprogrammers.qdoc @@ -62,7 +62,7 @@ QML provides direct access to the following concepts from Qt: \o QObject signals and slots - available as functions to call in JavaScript \o QObject properties - available as variables in JavaScript \o QWidget - QDeclarativeView is a QML-displaying widget - \o Qt models - used directly in data binding (QAbstractItemModel and next generation QListModelInterface) + \o Qt models - used directly in data binding (QAbstractItemModel) \endlist Qt knowledge is \e required for \l {Extending QML in C++}, and also for \l{Integrating QML with existing Qt UI code}. @@ -104,7 +104,7 @@ and exactly how it respond to mouse, key, or touch input, should all be left for in QML. It is illustrative to note that QDeclarativeTextEdit is built upon QTextControl, -QDeclarativeWebView is built upon QWebPage, and ListView uses QListModelInterface, +QDeclarativeWebView is built upon QWebPage, and ListView uses QAbstractItemModel, just as QTextEdit, QWebView, and QListView are built upon those same UI-agnostic components. diff --git a/doc/src/declarative/snippets/qtbinding/contextproperties/main.cpp b/doc/src/declarative/snippets/qtbinding/contextproperties/main.cpp index 15e3d4c..4073a6c 100644 --- a/doc/src/declarative/snippets/qtbinding/contextproperties/main.cpp +++ b/doc/src/declarative/snippets/qtbinding/contextproperties/main.cpp @@ -56,7 +56,7 @@ int main(int argc, char *argv[]) context->setContextProperty("backgroundColor", QColor(Qt::yellow)); - view.setSource(QUrl("main.qml")); + view.setSource(QUrl::fromLocalFile("main.qml")); view.show(); return app.exec(); diff --git a/doc/src/declarative/snippets/qtbinding/custompalette/main.cpp b/doc/src/declarative/snippets/qtbinding/custompalette/main.cpp index c723688..dc651f6 100644 --- a/doc/src/declarative/snippets/qtbinding/custompalette/main.cpp +++ b/doc/src/declarative/snippets/qtbinding/custompalette/main.cpp @@ -53,7 +53,7 @@ int main(int argc, char *argv[]) QDeclarativeView view; view.rootContext()->setContextProperty("palette", new CustomPalette); - view.setSource(QUrl("main.qml")); + view.setSource(QUrl::fromLocalFile("main.qml")); view.show(); return app.exec(); diff --git a/doc/src/declarative/snippets/qtbinding/stopwatch/main.cpp b/doc/src/declarative/snippets/qtbinding/stopwatch/main.cpp index 13e3b9f..537a288 100644 --- a/doc/src/declarative/snippets/qtbinding/stopwatch/main.cpp +++ b/doc/src/declarative/snippets/qtbinding/stopwatch/main.cpp @@ -54,7 +54,7 @@ int main(int argc, char *argv[]) view.rootContext()->setContextProperty("stopwatch", new Stopwatch); - view.setSource(QUrl("main.qml")); + view.setSource(QUrl::fromLocalFile("main.qml")); view.show(); return app.exec(); diff --git a/doc/src/examples/qml-examples.qdoc b/doc/src/examples/qml-examples.qdoc new file mode 100644 index 0000000..93e4a46 --- /dev/null +++ b/doc/src/examples/qml-examples.qdoc @@ -0,0 +1,260 @@ +/**************************************************************************** +** +** 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 documentation of the Qt Toolkit. +** +** $QT_BEGIN_LICENSE:LGPL$ +** No Commercial Usage +** This file contains pre-release code and may not be distributed. +** You may use this file in accordance with the terms and conditions +** contained in the 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$ +** +****************************************************************************/ + +/*! + \title Animations + \example declarative/animations + + This example shows how to use animations in QML. +*/ + +/*! + \title AspectRatio + \example declarative/aspectratio + + This example shows how to implement different aspect ratios in QML. +*/ + +/*! + \example declarative/behaviors + \title Behaviors +*/ + +/*! + \title Border Image + \example declarative/border-image + + This example shows how to use a BorderImage in QML. +*/ + +/*! + \title Clocks + \example declarative/clocks + + This example shows how to create a Clock component and reuse it in a grid. +*/ + +/*! + \title Connections + \example declarative/connections + + This example shows how to use a Connection element in QML. +*/ + +/*! + \title Dial + \example declarative/dial + + This example shows how to implement a dial in QML. +*/ + +/*! + \title Dynamic + \example declarative/dynamic + + This example shows how to create dynamic objects QML. +*/ + +/*! + \example declarative/extending + \title Extending +*/ + +/*! + \example declarative/fillmode + \title Fillmode +*/ + +/*! + \title Flipable + \example declarative/flipable + + This example shows how to use a Flipable element in QML. +*/ + +/*! + \title Focus + \example declarative/focus + + This example shows how to handle keys and focus in QML. + + \image qml-focus-example.png +*/ + +/*! + \example declarative/fonts + \title Fonts +*/ + +/*! + \example declarative/gridview + \title GridView +*/ + +/*! + \example declarative/imageprovider + \title Image Provider +*/ + +/*! + \example declarative/images + \title Images +*/ + +/*! + \example declarative/layouts + \title Layouts +*/ + +/*! + \example declarative/listmodel-threaded + \title ListModel Threaded +*/ + +/*! + \example declarative/listview + \title ListView +*/ + +/*! + \example declarative/mousearea + \title Mouse Area +*/ + +/*! + \example declarative/objectlistmodel + \title Object ListModel +*/ + +/*! + \example declarative/package + \title Package +*/ + +/*! + \example declarative/parallax + \title Parallax +*/ + +/*! + \example declarative/plugins + \title Plugins +*/ + +/*! + \example declarative/progressbar + \title Progress Bars +*/ + +/*! + \example declarative/proxywidgets + \title Proxy Widgets +*/ + +/*! + \example declarative/scrollbar + \title Scrollbar +*/ + +/*! + \example declarative/searchbox + \title Search Box +*/ + +/*! + \example declarative/slideswitch + \title Slide Switch +*/ + +/*! + \example declarative/sql + \title SQL +*/ + +/*! + \example declarative/states + \title States +*/ + +/*! + \example declarative/stringlistmodel + \title String ListModel +*/ + +/*! + \example declarative/tabwidget + \title Tab Widget +*/ + +/*! + \example declarative/tic-tac-toe + \title Tic-Tac-Toe +*/ + +/*! + \example declarative/tvtennis + \title TV Tennis +*/ + +/*! + \example declarative/velocity + \title Velocity +*/ + +/*! + \example declarative/webview + \title WebView +*/ + +/*! + \example declarative/workerscript + \title WorkerScript +*/ + +/*! + \example declarative/xmldata + \title XML Data +*/ + +/*! + \example declarative/xmlhttprequest + \title XMLHttpRequest +*/ diff --git a/examples/declarative/animations/easing.qml b/examples/declarative/animations/easing.qml index bed4b5f9..b0f9669 100644 --- a/examples/declarative/animations/easing.qml +++ b/examples/declarative/animations/easing.qml @@ -79,10 +79,10 @@ Rectangle { } transitions: Transition { - ParallelAnimation { + // ParallelAnimation { NumberAnimation { properties: "x"; easing.type: type; duration: 1000 } ColorAnimation { properties: "color"; easing.type: type; duration: 1000 } - } + // } } } } diff --git a/examples/declarative/dynamic/qml/itemCreation.js b/examples/declarative/dynamic/qml/itemCreation.js index 4fa0d9f..98d48a8 100644 --- a/examples/declarative/dynamic/qml/itemCreation.js +++ b/examples/declarative/dynamic/qml/itemCreation.js @@ -32,7 +32,7 @@ function loadComponent() { createItem(); itemComponent = Qt.createComponent(itemButton.file); - //print(itemButton.file) + //console.log(itemButton.file) if(itemComponent.isLoading){ component.statusChanged.connect(finishCreation); }else{//Depending on the content, it can be ready or error immediately @@ -51,8 +51,8 @@ function createItem() { draggedItem.z = 4;//On top } else if (itemComponent.isError) { draggedItem = null; - print("error creating component"); - print(component.errorsString()); + console.log("error creating component"); + console.log(component.errorsString()); } } diff --git a/examples/declarative/tutorials/extending/chapter1-basics/app.qml b/examples/declarative/tutorials/extending/chapter1-basics/app.qml new file mode 100644 index 0000000..15dcd2d --- /dev/null +++ b/examples/declarative/tutorials/extending/chapter1-basics/app.qml @@ -0,0 +1,17 @@ +import Music 1.0 +import Qt 4.7 + +Rectangle { + width: 300; height: 200 + + Musician { + id: aMusician + name: "Reddy the Rocker" + instrument: "Guitar" + } + + Text { + anchors.fill: parent + text: aMusician.name + " plays the " + aMusician.instrument + } +} diff --git a/examples/declarative/tutorials/extending/chapter1-basics/chapter1-basics.pro b/examples/declarative/tutorials/extending/chapter1-basics/chapter1-basics.pro new file mode 100644 index 0000000..bd05ebe --- /dev/null +++ b/examples/declarative/tutorials/extending/chapter1-basics/chapter1-basics.pro @@ -0,0 +1,5 @@ +QT += declarative + +HEADERS += musician.h +SOURCES += musician.cpp \ + main.cpp diff --git a/examples/declarative/tutorials/extending/chapter1-basics/main.cpp b/examples/declarative/tutorials/extending/chapter1-basics/main.cpp new file mode 100644 index 0000000..0e71bb0 --- /dev/null +++ b/examples/declarative/tutorials/extending/chapter1-basics/main.cpp @@ -0,0 +1,58 @@ +/**************************************************************************** +** +** 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 documentation of the Qt Toolkit. +** +** $QT_BEGIN_LICENSE:LGPL$ +** No Commercial Usage +** This file contains pre-release code and may not be distributed. +** You may use this file in accordance with the terms and conditions +** contained in the 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$ +** +****************************************************************************/ +//![0] +#include "musician.h" +#include <qdeclarative.h> +#include <QDeclarativeView> +#include <QApplication> + +int main(int argc, char *argv[]) +{ + QApplication app(argc, argv); + + qmlRegisterType<Musician>("Music", 1, 0, "Musician"); + + QDeclarativeView view; + view.setSource(QUrl::fromLocalFile("app.qml")); + view.show(); + return app.exec(); +} +//![0] diff --git a/examples/declarative/tutorials/extending/chapter1-basics/musician.cpp b/examples/declarative/tutorials/extending/chapter1-basics/musician.cpp new file mode 100644 index 0000000..b545f84 --- /dev/null +++ b/examples/declarative/tutorials/extending/chapter1-basics/musician.cpp @@ -0,0 +1,67 @@ +/**************************************************************************** +** +** 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 documentation of the Qt Toolkit. +** +** $QT_BEGIN_LICENSE:LGPL$ +** No Commercial Usage +** This file contains pre-release code and may not be distributed. +** You may use this file in accordance with the terms and conditions +** contained in the 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 "musician.h" + +Musician::Musician(QObject *parent) + : QObject(parent) +{ +} + +QString Musician::name() const +{ + return m_name; +} + +void Musician::setName(const QString &name) +{ + m_name = name; +} + +QString Musician::instrument() const +{ + return m_instrument; +} + +void Musician::setInstrument(const QString &instrument) +{ + m_instrument = instrument; +} + diff --git a/examples/declarative/tutorials/extending/chapter1-basics/musician.h b/examples/declarative/tutorials/extending/chapter1-basics/musician.h new file mode 100644 index 0000000..70ade82 --- /dev/null +++ b/examples/declarative/tutorials/extending/chapter1-basics/musician.h @@ -0,0 +1,69 @@ +/**************************************************************************** +** +** 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 documentation of the Qt Toolkit. +** +** $QT_BEGIN_LICENSE:LGPL$ +** No Commercial Usage +** This file contains pre-release code and may not be distributed. +** You may use this file in accordance with the terms and conditions +** contained in the 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$ +** +****************************************************************************/ +#ifndef MUSICIAN_H +#define MUSICIAN_H + +//![0] +#include <QObject> + +class Musician : public QObject +{ + Q_OBJECT + Q_PROPERTY(QString name READ name WRITE setName) + Q_PROPERTY(QString instrument READ instrument WRITE setInstrument) + +public: + Musician(QObject *parent = 0); + + QString name() const; + void setName(const QString &name); + + QString instrument() const; + void setInstrument(const QString &instrument); + +private: + QString m_name; + QString m_instrument; +}; +//![0] + +#endif + diff --git a/examples/declarative/tutorials/extending/chapter2-methods/app.qml b/examples/declarative/tutorials/extending/chapter2-methods/app.qml new file mode 100644 index 0000000..35e083e --- /dev/null +++ b/examples/declarative/tutorials/extending/chapter2-methods/app.qml @@ -0,0 +1,19 @@ +import Music 1.0 +import Qt 4.7 + +Rectangle { + width: 200; height: 200 + + Musician { + id: aMusician + name: "Reddy the Rocker" + instrument: "Guitar" + + onPerformanceEnded: console.log("The performance has now ended") + } + + MouseArea { + anchors.fill: parent + onClicked: aMusician.perform() + } +} diff --git a/examples/declarative/tutorials/extending/chapter2-methods/chapter2-methods.pro b/examples/declarative/tutorials/extending/chapter2-methods/chapter2-methods.pro new file mode 100644 index 0000000..bd05ebe --- /dev/null +++ b/examples/declarative/tutorials/extending/chapter2-methods/chapter2-methods.pro @@ -0,0 +1,5 @@ +QT += declarative + +HEADERS += musician.h +SOURCES += musician.cpp \ + main.cpp diff --git a/examples/declarative/tutorials/extending/chapter2-methods/main.cpp b/examples/declarative/tutorials/extending/chapter2-methods/main.cpp new file mode 100644 index 0000000..0e71bb0 --- /dev/null +++ b/examples/declarative/tutorials/extending/chapter2-methods/main.cpp @@ -0,0 +1,58 @@ +/**************************************************************************** +** +** 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 documentation of the Qt Toolkit. +** +** $QT_BEGIN_LICENSE:LGPL$ +** No Commercial Usage +** This file contains pre-release code and may not be distributed. +** You may use this file in accordance with the terms and conditions +** contained in the 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$ +** +****************************************************************************/ +//![0] +#include "musician.h" +#include <qdeclarative.h> +#include <QDeclarativeView> +#include <QApplication> + +int main(int argc, char *argv[]) +{ + QApplication app(argc, argv); + + qmlRegisterType<Musician>("Music", 1, 0, "Musician"); + + QDeclarativeView view; + view.setSource(QUrl::fromLocalFile("app.qml")); + view.show(); + return app.exec(); +} +//![0] diff --git a/examples/declarative/tutorials/extending/chapter2-methods/musician.cpp b/examples/declarative/tutorials/extending/chapter2-methods/musician.cpp new file mode 100644 index 0000000..3df19e3 --- /dev/null +++ b/examples/declarative/tutorials/extending/chapter2-methods/musician.cpp @@ -0,0 +1,75 @@ +/**************************************************************************** +** +** 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 documentation of the Qt Toolkit. +** +** $QT_BEGIN_LICENSE:LGPL$ +** No Commercial Usage +** This file contains pre-release code and may not be distributed. +** You may use this file in accordance with the terms and conditions +** contained in the 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 "musician.h" +#include <QDebug> + +Musician::Musician(QObject *parent) + : QObject(parent) +{ +} + +QString Musician::name() const +{ + return m_name; +} + +void Musician::setName(const QString &name) +{ + m_name = name; +} + +QString Musician::instrument() const +{ + return m_instrument; +} + +void Musician::setInstrument(const QString &instrument) +{ + m_instrument = instrument; +} + +//![0] +void Musician::perform() +{ + qWarning() << m_name << "is playing the" << m_instrument; + emit performanceEnded(); +} +//![0] diff --git a/examples/declarative/tutorials/extending/chapter2-methods/musician.h b/examples/declarative/tutorials/extending/chapter2-methods/musician.h new file mode 100644 index 0000000..dc48759 --- /dev/null +++ b/examples/declarative/tutorials/extending/chapter2-methods/musician.h @@ -0,0 +1,82 @@ +/**************************************************************************** +** +** 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 documentation of the Qt Toolkit. +** +** $QT_BEGIN_LICENSE:LGPL$ +** No Commercial Usage +** This file contains pre-release code and may not be distributed. +** You may use this file in accordance with the terms and conditions +** contained in the 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$ +** +****************************************************************************/ +#ifndef MUSICIAN_H +#define MUSICIAN_H + +#include <QObject> + +//![0] +class Musician : public QObject +{ +//![0] + Q_OBJECT + Q_PROPERTY(QString name READ name WRITE setName) + Q_PROPERTY(QString instrument READ instrument WRITE setInstrument) + +//![1] +public: +//![1] + + Musician(QObject *parent = 0); + + QString name() const; + void setName(const QString &name); + + QString instrument() const; + void setInstrument(const QString &instrument); + +//![2] + Q_INVOKABLE void perform(); + +signals: + void performanceEnded(); +//![2] + +private: + QString m_name; + QString m_instrument; + +//![3] +}; +//![3] + +#endif + diff --git a/examples/declarative/tutorials/extending/chapter3-bindings/app.qml b/examples/declarative/tutorials/extending/chapter3-bindings/app.qml new file mode 100644 index 0000000..0460b0b --- /dev/null +++ b/examples/declarative/tutorials/extending/chapter3-bindings/app.qml @@ -0,0 +1,31 @@ +import Music 1.0 +import Qt 4.7 + +Rectangle { + width: 200; height: 200 + + Musician { + id: reddy + name: "Reddy the Rocker" + instrument: "Guitar" + } + + Musician { + id: craig + name: "Craig the Copycat" + instrument: reddy.instrument + } + + MouseArea { + anchors.fill: parent + onClicked: { + reddy.perform() + craig.perform() + + reddy.instrument = "Drums" + + reddy.perform() + craig.perform() + } + } +} diff --git a/examples/declarative/tutorials/extending/chapter3-bindings/chapter3-bindings.pro b/examples/declarative/tutorials/extending/chapter3-bindings/chapter3-bindings.pro new file mode 100644 index 0000000..bd05ebe --- /dev/null +++ b/examples/declarative/tutorials/extending/chapter3-bindings/chapter3-bindings.pro @@ -0,0 +1,5 @@ +QT += declarative + +HEADERS += musician.h +SOURCES += musician.cpp \ + main.cpp diff --git a/examples/declarative/tutorials/extending/chapter3-bindings/main.cpp b/examples/declarative/tutorials/extending/chapter3-bindings/main.cpp new file mode 100644 index 0000000..0e71bb0 --- /dev/null +++ b/examples/declarative/tutorials/extending/chapter3-bindings/main.cpp @@ -0,0 +1,58 @@ +/**************************************************************************** +** +** 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 documentation of the Qt Toolkit. +** +** $QT_BEGIN_LICENSE:LGPL$ +** No Commercial Usage +** This file contains pre-release code and may not be distributed. +** You may use this file in accordance with the terms and conditions +** contained in the 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$ +** +****************************************************************************/ +//![0] +#include "musician.h" +#include <qdeclarative.h> +#include <QDeclarativeView> +#include <QApplication> + +int main(int argc, char *argv[]) +{ + QApplication app(argc, argv); + + qmlRegisterType<Musician>("Music", 1, 0, "Musician"); + + QDeclarativeView view; + view.setSource(QUrl::fromLocalFile("app.qml")); + view.show(); + return app.exec(); +} +//![0] diff --git a/examples/declarative/tutorials/extending/chapter3-bindings/musician.cpp b/examples/declarative/tutorials/extending/chapter3-bindings/musician.cpp new file mode 100644 index 0000000..eb615f6 --- /dev/null +++ b/examples/declarative/tutorials/extending/chapter3-bindings/musician.cpp @@ -0,0 +1,77 @@ +/**************************************************************************** +** +** 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 documentation of the Qt Toolkit. +** +** $QT_BEGIN_LICENSE:LGPL$ +** No Commercial Usage +** This file contains pre-release code and may not be distributed. +** You may use this file in accordance with the terms and conditions +** contained in the 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 "musician.h" +#include <QDebug> + +Musician::Musician(QObject *parent) + : QObject(parent) +{ +} + +QString Musician::name() const +{ + return m_name; +} + +void Musician::setName(const QString &name) +{ + m_name = name; +} + +QString Musician::instrument() const +{ + return m_instrument; +} + +//![0] +void Musician::setInstrument(const QString &instrument) +{ + if (instrument != m_instrument) { + m_instrument = instrument; + emit instrumentChanged(); + } +} +//![0] + +void Musician::perform() +{ + qWarning() << m_name << "is playing the" << m_instrument; +} diff --git a/examples/declarative/tutorials/extending/chapter3-bindings/musician.h b/examples/declarative/tutorials/extending/chapter3-bindings/musician.h new file mode 100644 index 0000000..39887be --- /dev/null +++ b/examples/declarative/tutorials/extending/chapter3-bindings/musician.h @@ -0,0 +1,83 @@ +/**************************************************************************** +** +** 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 documentation of the Qt Toolkit. +** +** $QT_BEGIN_LICENSE:LGPL$ +** No Commercial Usage +** This file contains pre-release code and may not be distributed. +** You may use this file in accordance with the terms and conditions +** contained in the 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$ +** +****************************************************************************/ +#ifndef MUSICIAN_H +#define MUSICIAN_H + +#include <QObject> + +//![0] +class Musician : public QObject +{ +//![0] + Q_OBJECT + Q_PROPERTY(QString name READ name WRITE setName) + Q_PROPERTY(QString instrument READ instrument WRITE setInstrument) + +//![1] + Q_PROPERTY(QString instrument READ instrument WRITE setInstrument NOTIFY instrumentChanged) +public: +//![1] + + Musician(QObject *parent = 0); + + QString name() const; + void setName(const QString &name); + + QString instrument() const; + void setInstrument(const QString &instrument); + + Q_INVOKABLE void perform(); + +//![2] +signals: + void instrumentChanged(); +//![2] + +private: + QString m_name; + QString m_instrument; + +//![3] +}; +//![3] + +#endif + diff --git a/examples/declarative/tutorials/extending/chapter4-customPropertyTypes/app.qml b/examples/declarative/tutorials/extending/chapter4-customPropertyTypes/app.qml new file mode 100644 index 0000000..ae9272e --- /dev/null +++ b/examples/declarative/tutorials/extending/chapter4-customPropertyTypes/app.qml @@ -0,0 +1,13 @@ +import Music 1.0 +import Qt 4.7 + +Item { + + Musician { + id: reddy + name: "Reddy the Rocker" + instrument: Instrument { type: "Guitar" } + } + + Component.onCompleted: console.log("Reddy plays the " + reddy.instrument.type) +} diff --git a/examples/declarative/tutorials/extending/chapter4-customPropertyTypes/chapter4-customPropertyTypes.pro b/examples/declarative/tutorials/extending/chapter4-customPropertyTypes/chapter4-customPropertyTypes.pro new file mode 100644 index 0000000..aea07a0 --- /dev/null +++ b/examples/declarative/tutorials/extending/chapter4-customPropertyTypes/chapter4-customPropertyTypes.pro @@ -0,0 +1,7 @@ +QT += declarative + +HEADERS += musician.h \ + instrument.h +SOURCES += musician.cpp \ + instrument.cpp \ + main.cpp diff --git a/doc/src/examples/qml-focus.qdoc b/examples/declarative/tutorials/extending/chapter4-customPropertyTypes/instrument.cpp index 92d93b2..13cd2fe 100644 --- a/doc/src/examples/qml-focus.qdoc +++ b/examples/declarative/tutorials/extending/chapter4-customPropertyTypes/instrument.cpp @@ -38,12 +38,20 @@ ** $QT_END_LICENSE$ ** ****************************************************************************/ +#include "instrument.h" -/*! - \title Focus - \example declarative/focus +Instrument::Instrument(QObject *parent) + : QObject(parent) +{ +} - This example shows how to handle keys and focus in QML. +QString Instrument::type() const +{ + return m_type; +} + +void Instrument::setType(const QString &type) +{ + m_type = type; +} - \image qml-focus-example.png -*/ diff --git a/examples/declarative/tutorials/extending/chapter4-customPropertyTypes/instrument.h b/examples/declarative/tutorials/extending/chapter4-customPropertyTypes/instrument.h new file mode 100644 index 0000000..e2f09be --- /dev/null +++ b/examples/declarative/tutorials/extending/chapter4-customPropertyTypes/instrument.h @@ -0,0 +1,64 @@ +/**************************************************************************** +** +** 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 documentation of the Qt Toolkit. +** +** $QT_BEGIN_LICENSE:LGPL$ +** No Commercial Usage +** This file contains pre-release code and may not be distributed. +** You may use this file in accordance with the terms and conditions +** contained in the 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$ +** +****************************************************************************/ +#ifndef INSTRUMENT_H +#define INSTRUMENT_H + +#include <QObject> + +//![0] +class Instrument : public QObject +{ + Q_OBJECT + Q_PROPERTY(QString type READ type WRITE setType) + +public: + Instrument(QObject *parent = 0); + + QString type() const; + void setType(const QString &type); + +private: + QString m_type; +}; +//![0] + +#endif + diff --git a/examples/declarative/tutorials/extending/chapter4-customPropertyTypes/main.cpp b/examples/declarative/tutorials/extending/chapter4-customPropertyTypes/main.cpp new file mode 100644 index 0000000..cbbbc0f --- /dev/null +++ b/examples/declarative/tutorials/extending/chapter4-customPropertyTypes/main.cpp @@ -0,0 +1,67 @@ +/**************************************************************************** +** +** 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 documentation of the Qt Toolkit. +** +** $QT_BEGIN_LICENSE:LGPL$ +** No Commercial Usage +** This file contains pre-release code and may not be distributed. +** You may use this file in accordance with the terms and conditions +** contained in the 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 "musician.h" +#include "instrument.h" + +#include <qdeclarative.h> +#include <QDeclarativeView> +#include <QApplication> + +//![0] +int main(int argc, char *argv[]) +{ +//![0] + QApplication app(argc, argv); + + qmlRegisterType<Musician>("Music", 1, 0, "Musician"); + +//![1] + qmlRegisterType<Instrument>("Music", 1, 0, "Instrument"); +//![1] + + QDeclarativeView view; + view.setSource(QUrl::fromLocalFile("app.qml")); + view.show(); + return app.exec(); + +//![2] +} +//![2] diff --git a/examples/declarative/tutorials/extending/chapter4-customPropertyTypes/musician.cpp b/examples/declarative/tutorials/extending/chapter4-customPropertyTypes/musician.cpp new file mode 100644 index 0000000..6b66d5d --- /dev/null +++ b/examples/declarative/tutorials/extending/chapter4-customPropertyTypes/musician.cpp @@ -0,0 +1,68 @@ +/**************************************************************************** +** +** 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 documentation of the Qt Toolkit. +** +** $QT_BEGIN_LICENSE:LGPL$ +** No Commercial Usage +** This file contains pre-release code and may not be distributed. +** You may use this file in accordance with the terms and conditions +** contained in the 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 "musician.h" +#include "instrument.h" + +Musician::Musician(QObject *parent) + : QObject(parent) +{ +} + +QString Musician::name() const +{ + return m_name; +} + +void Musician::setName(const QString &name) +{ + m_name = name; +} + +Instrument *Musician::instrument() const +{ + return m_instrument; +} + +void Musician::setInstrument(Instrument *instrument) +{ + m_instrument = instrument; +} + diff --git a/examples/declarative/tutorials/extending/chapter4-customPropertyTypes/musician.h b/examples/declarative/tutorials/extending/chapter4-customPropertyTypes/musician.h new file mode 100644 index 0000000..d0aa118 --- /dev/null +++ b/examples/declarative/tutorials/extending/chapter4-customPropertyTypes/musician.h @@ -0,0 +1,79 @@ +/**************************************************************************** +** +** 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 documentation of the Qt Toolkit. +** +** $QT_BEGIN_LICENSE:LGPL$ +** No Commercial Usage +** This file contains pre-release code and may not be distributed. +** You may use this file in accordance with the terms and conditions +** contained in the 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$ +** +****************************************************************************/ +#ifndef MUSICIAN_H +#define MUSICIAN_H + +#include <QObject> + +class Instrument; + +//![0] +class Musician : public QObject +{ + Q_OBJECT + Q_PROPERTY(Instrument* instrument READ instrument WRITE setInstrument) +//![0] + Q_PROPERTY(QString name READ name WRITE setName) + +//![1] +public: +//![1] + + Musician(QObject *parent = 0); + + QString name() const; + void setName(const QString &name); + +//![2] + Instrument *instrument() const; + void setInstrument(Instrument *instrument); +//![2] + +private: + QString m_name; + Instrument *m_instrument; + +//![3] +}; +//![3] + +#endif + diff --git a/examples/declarative/tutorials/extending/chapter5-plugins/app.qml b/examples/declarative/tutorials/extending/chapter5-plugins/app.qml new file mode 100644 index 0000000..51c1232 --- /dev/null +++ b/examples/declarative/tutorials/extending/chapter5-plugins/app.qml @@ -0,0 +1,13 @@ +import Qt 4.7 + +Item { + + Musician { + id: reddy + name: "Reddy the Rocker" + instrument: Instrument { type: "Guitar" } + } + + Component.onCompleted: console.log("Reddy plays the " + reddy.instrument.type) +} + diff --git a/examples/declarative/tutorials/extending/chapter5-plugins/chapter5-plugins.pro b/examples/declarative/tutorials/extending/chapter5-plugins/chapter5-plugins.pro new file mode 100644 index 0000000..7ec68e9 --- /dev/null +++ b/examples/declarative/tutorials/extending/chapter5-plugins/chapter5-plugins.pro @@ -0,0 +1,15 @@ +TEMPLATE = lib +CONFIG += qt plugin +QT += declarative + +HEADERS += musician.h \ + instrument.h \ + musicplugin.h + +SOURCES += musician.cpp \ + instrument.cpp \ + musicplugin.cpp + +DESTDIR = lib +OBJECTS_DIR = tmp +MOC_DIR = tmp diff --git a/examples/declarative/tutorials/extending/chapter5-plugins/instrument.cpp b/examples/declarative/tutorials/extending/chapter5-plugins/instrument.cpp new file mode 100644 index 0000000..13cd2fe --- /dev/null +++ b/examples/declarative/tutorials/extending/chapter5-plugins/instrument.cpp @@ -0,0 +1,57 @@ +/**************************************************************************** +** +** 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 documentation of the Qt Toolkit. +** +** $QT_BEGIN_LICENSE:LGPL$ +** No Commercial Usage +** This file contains pre-release code and may not be distributed. +** You may use this file in accordance with the terms and conditions +** contained in the 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 "instrument.h" + +Instrument::Instrument(QObject *parent) + : QObject(parent) +{ +} + +QString Instrument::type() const +{ + return m_type; +} + +void Instrument::setType(const QString &type) +{ + m_type = type; +} + diff --git a/examples/declarative/tutorials/extending/chapter5-plugins/instrument.h b/examples/declarative/tutorials/extending/chapter5-plugins/instrument.h new file mode 100644 index 0000000..15f9fae --- /dev/null +++ b/examples/declarative/tutorials/extending/chapter5-plugins/instrument.h @@ -0,0 +1,62 @@ +/**************************************************************************** +** +** 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 documentation of the Qt Toolkit. +** +** $QT_BEGIN_LICENSE:LGPL$ +** No Commercial Usage +** This file contains pre-release code and may not be distributed. +** You may use this file in accordance with the terms and conditions +** contained in the 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$ +** +****************************************************************************/ +#ifndef INSTRUMENT_H +#define INSTRUMENT_H + +#include <QObject> + +class Instrument : public QObject +{ + Q_OBJECT + Q_PROPERTY(QString type READ type WRITE setType) + +public: + Instrument(QObject *parent = 0); + + QString type() const; + void setType(const QString &type); + +private: + QString m_type; +}; + +#endif + diff --git a/examples/declarative/tutorials/extending/chapter5-plugins/musician.cpp b/examples/declarative/tutorials/extending/chapter5-plugins/musician.cpp new file mode 100644 index 0000000..6b66d5d --- /dev/null +++ b/examples/declarative/tutorials/extending/chapter5-plugins/musician.cpp @@ -0,0 +1,68 @@ +/**************************************************************************** +** +** 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 documentation of the Qt Toolkit. +** +** $QT_BEGIN_LICENSE:LGPL$ +** No Commercial Usage +** This file contains pre-release code and may not be distributed. +** You may use this file in accordance with the terms and conditions +** contained in the 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 "musician.h" +#include "instrument.h" + +Musician::Musician(QObject *parent) + : QObject(parent) +{ +} + +QString Musician::name() const +{ + return m_name; +} + +void Musician::setName(const QString &name) +{ + m_name = name; +} + +Instrument *Musician::instrument() const +{ + return m_instrument; +} + +void Musician::setInstrument(Instrument *instrument) +{ + m_instrument = instrument; +} + diff --git a/examples/declarative/tutorials/extending/chapter5-plugins/musician.h b/examples/declarative/tutorials/extending/chapter5-plugins/musician.h new file mode 100644 index 0000000..3c3eb2e --- /dev/null +++ b/examples/declarative/tutorials/extending/chapter5-plugins/musician.h @@ -0,0 +1,69 @@ +/**************************************************************************** +** +** 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 documentation of the Qt Toolkit. +** +** $QT_BEGIN_LICENSE:LGPL$ +** No Commercial Usage +** This file contains pre-release code and may not be distributed. +** You may use this file in accordance with the terms and conditions +** contained in the 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$ +** +****************************************************************************/ +#ifndef MUSICIAN_H +#define MUSICIAN_H + +#include <QObject> + +class Instrument; + +class Musician : public QObject +{ + Q_OBJECT + Q_PROPERTY(QString name READ name WRITE setName) + Q_PROPERTY(Instrument* instrument READ instrument WRITE setInstrument) + +public: + Musician(QObject *parent = 0); + + QString name() const; + void setName(const QString &name); + + Instrument *instrument() const; + void setInstrument(Instrument *instrument); + +private: + QString m_name; + Instrument *m_instrument; +}; + +#endif + diff --git a/examples/declarative/tutorials/extending/chapter5-plugins/musicplugin.cpp b/examples/declarative/tutorials/extending/chapter5-plugins/musicplugin.cpp new file mode 100644 index 0000000..e2f6244 --- /dev/null +++ b/examples/declarative/tutorials/extending/chapter5-plugins/musicplugin.cpp @@ -0,0 +1,55 @@ +/**************************************************************************** +** +** 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 documentation of the Qt Toolkit. +** +** $QT_BEGIN_LICENSE:LGPL$ +** No Commercial Usage +** This file contains pre-release code and may not be distributed. +** You may use this file in accordance with the terms and conditions +** contained in the 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 "musicplugin.h" +//![0] +#include "musician.h" +#include "instrument.h" +#include <QtDeclarative/qdeclarative.h> + +void MusicPlugin::registerTypes(const char *uri) +{ + qmlRegisterType<Musician>(uri, 1, 0, "Musician"); + qmlRegisterType<Instrument>(uri, 1, 0, "Instrument"); +} + +Q_EXPORT_PLUGIN2(musicplugin, MusicPlugin); +//![0] + diff --git a/examples/declarative/tutorials/extending/chapter5-plugins/musicplugin.h b/examples/declarative/tutorials/extending/chapter5-plugins/musicplugin.h new file mode 100644 index 0000000..df8c9ab --- /dev/null +++ b/examples/declarative/tutorials/extending/chapter5-plugins/musicplugin.h @@ -0,0 +1,56 @@ +/**************************************************************************** +** +** 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 documentation of the Qt Toolkit. +** +** $QT_BEGIN_LICENSE:LGPL$ +** No Commercial Usage +** This file contains pre-release code and may not be distributed. +** You may use this file in accordance with the terms and conditions +** contained in the 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$ +** +****************************************************************************/ +#ifndef MUSICPLUGIN_H +#define MUSICPLUGIN_H + +//![0] +#include <QtDeclarative/QDeclarativeExtensionPlugin> + +class MusicPlugin : public QDeclarativeExtensionPlugin +{ + Q_OBJECT +public: + void registerTypes(const char *uri); +}; +//![0] + +#endif + diff --git a/examples/declarative/tutorials/extending/chapter5-plugins/qmldir b/examples/declarative/tutorials/extending/chapter5-plugins/qmldir new file mode 100644 index 0000000..c3afd6b --- /dev/null +++ b/examples/declarative/tutorials/extending/chapter5-plugins/qmldir @@ -0,0 +1 @@ +plugin chapter5-plugins lib diff --git a/examples/declarative/tutorials/samegame/samegame1/samegame1.qmlproject b/examples/declarative/tutorials/samegame/samegame1/samegame1.qmlproject new file mode 100644 index 0000000..d4909f8 --- /dev/null +++ b/examples/declarative/tutorials/samegame/samegame1/samegame1.qmlproject @@ -0,0 +1,16 @@ +import QmlProject 1.0 + +Project { + /* Include .qml, .js, and image files from current directory and subdirectories */ + QmlFiles { + directory: "." + } + JavaScriptFiles { + directory: "." + } + ImageFiles { + directory: "." + } + /* List of plugin directories passed to QML runtime */ + // importPaths: [ " ../exampleplugin " ] +} diff --git a/examples/declarative/tutorials/samegame/samegame2/samegame.js b/examples/declarative/tutorials/samegame/samegame2/samegame.js index 81da31b..e5c790d 100644 --- a/examples/declarative/tutorials/samegame/samegame2/samegame.js +++ b/examples/declarative/tutorials/samegame/samegame2/samegame.js @@ -43,8 +43,8 @@ function createBlock(column, row) { if (component.isReady) { var dynamicObject = component.createObject(); if (dynamicObject == null) { - print("error creating block"); - print(component.errorsString()); + console.log("error creating block"); + console.log(component.errorsString()); return false; } dynamicObject.parent = background; @@ -54,8 +54,8 @@ function createBlock(column, row) { dynamicObject.height = blockSize; board[index(column, row)] = dynamicObject; } else { - print("error loading block component"); - print(component.errorsString()); + console.log("error loading block component"); + console.log(component.errorsString()); return false; } return true; diff --git a/examples/declarative/tutorials/samegame/samegame2/samegame2.qmlproject b/examples/declarative/tutorials/samegame/samegame2/samegame2.qmlproject new file mode 100644 index 0000000..d4909f8 --- /dev/null +++ b/examples/declarative/tutorials/samegame/samegame2/samegame2.qmlproject @@ -0,0 +1,16 @@ +import QmlProject 1.0 + +Project { + /* Include .qml, .js, and image files from current directory and subdirectories */ + QmlFiles { + directory: "." + } + JavaScriptFiles { + directory: "." + } + ImageFiles { + directory: "." + } + /* List of plugin directories passed to QML runtime */ + // importPaths: [ " ../exampleplugin " ] +} diff --git a/examples/declarative/tutorials/samegame/samegame3/samegame.js b/examples/declarative/tutorials/samegame/samegame3/samegame.js index eaf47d9..da0f76e 100644 --- a/examples/declarative/tutorials/samegame/samegame3/samegame.js +++ b/examples/declarative/tutorials/samegame/samegame3/samegame.js @@ -40,8 +40,8 @@ function createBlock(column, row) { if (component.isReady) { var dynamicObject = component.createObject(); if (dynamicObject == null) { - print("error creating block"); - print(component.errorsString()); + console.log("error creating block"); + console.log(component.errorsString()); return false; } dynamicObject.type = Math.floor(Math.random() * 3); @@ -52,8 +52,8 @@ function createBlock(column, row) { dynamicObject.height = gameCanvas.blockSize; board[index(column, row)] = dynamicObject; } else { - print("error loading block component"); - print(component.errorsString()); + console.log("error loading block component"); + console.log(component.errorsString()); return false; } return true; diff --git a/examples/declarative/tutorials/samegame/samegame3/samegame3.qmlproject b/examples/declarative/tutorials/samegame/samegame3/samegame3.qmlproject new file mode 100644 index 0000000..d4909f8 --- /dev/null +++ b/examples/declarative/tutorials/samegame/samegame3/samegame3.qmlproject @@ -0,0 +1,16 @@ +import QmlProject 1.0 + +Project { + /* Include .qml, .js, and image files from current directory and subdirectories */ + QmlFiles { + directory: "." + } + JavaScriptFiles { + directory: "." + } + ImageFiles { + directory: "." + } + /* List of plugin directories passed to QML runtime */ + // importPaths: [ " ../exampleplugin " ] +} diff --git a/examples/declarative/tutorials/samegame/samegame4/content/samegame.js b/examples/declarative/tutorials/samegame/samegame4/content/samegame.js index c527f66..1454f0b 100755 --- a/examples/declarative/tutorials/samegame/samegame4/content/samegame.js +++ b/examples/declarative/tutorials/samegame/samegame4/content/samegame.js @@ -51,8 +51,8 @@ function createBlock(column, row) { if (component.isReady) { var dynamicObject = component.createObject(); if (dynamicObject == null) { - print("error creating block"); - print(component.errorsString()); + console.log("error creating block"); + console.log(component.errorsString()); return false; } dynamicObject.type = Math.floor(Math.random() * 3); @@ -65,8 +65,8 @@ function createBlock(column, row) { dynamicObject.spawned = true; board[index(column, row)] = dynamicObject; } else { - print("error loading block component"); - print(component.errorsString()); + console.log("error loading block component"); + console.log(component.errorsString()); return false; } return true; diff --git a/examples/declarative/tutorials/samegame/samegame4/samegame4.qmlproject b/examples/declarative/tutorials/samegame/samegame4/samegame4.qmlproject new file mode 100644 index 0000000..d4909f8 --- /dev/null +++ b/examples/declarative/tutorials/samegame/samegame4/samegame4.qmlproject @@ -0,0 +1,16 @@ +import QmlProject 1.0 + +Project { + /* Include .qml, .js, and image files from current directory and subdirectories */ + QmlFiles { + directory: "." + } + JavaScriptFiles { + directory: "." + } + ImageFiles { + directory: "." + } + /* List of plugin directories passed to QML runtime */ + // importPaths: [ " ../exampleplugin " ] +} diff --git a/examples/declarative/workerscript/workerscript.qml b/examples/declarative/workerscript/workerscript.qml index 6c6253b..2294a81 100644 --- a/examples/declarative/workerscript/workerscript.qml +++ b/examples/declarative/workerscript/workerscript.qml @@ -8,9 +8,9 @@ Rectangle { source: "workerscript.js" onMessage: { - print("Moved " + messageObject.xmove + " along the X axis."); - print("Moved " + messageObject.ymove + " along the Y axis."); - print("Moved " + messageObject.move + " pixels."); + console.log("Moved " + messageObject.xmove + " along the X axis."); + console.log("Moved " + messageObject.ymove + " along the Y axis."); + console.log("Moved " + messageObject.move + " pixels."); } } diff --git a/mkspecs/features/win32/embed_manifest_dll.prf b/mkspecs/features/win32/embed_manifest_dll.prf index 76a8ed1..408efd2 100644 --- a/mkspecs/features/win32/embed_manifest_dll.prf +++ b/mkspecs/features/win32/embed_manifest_dll.prf @@ -1,6 +1,6 @@ MANIFEST_DIR = $$OBJECTS_DIR isEmpty(MANIFEST_DIR):MANIFEST_DIR = . -!if(plugin:no_plugin_manifest):if(win32-msvc2005|win32-msvc2008):!static:!equals(TEMPLATE_PREFIX, "vc"):equals(TEMPLATE, "lib") { +!if(plugin:no_plugin_manifest):if(win32-msvc2005|win32-msvc2008|win32-msvc2010):!static:!equals(TEMPLATE_PREFIX, "vc"):equals(TEMPLATE, "lib") { NOPATH_TARGET = $$TARGET NOPATH_TARGET ~= s,\\ , ,q # Remove space escaping (NOPATH_TARGET is quoted) NOPATH_TARGET ~= s,\\,/,g # Change to single type separators diff --git a/mkspecs/features/win32/embed_manifest_exe.prf b/mkspecs/features/win32/embed_manifest_exe.prf index d2800a1..6f63103 100644 --- a/mkspecs/features/win32/embed_manifest_exe.prf +++ b/mkspecs/features/win32/embed_manifest_exe.prf @@ -1,6 +1,6 @@ MANIFEST_DIR = $$OBJECTS_DIR isEmpty(MANIFEST_DIR):MANIFEST_DIR = . -if(win32-msvc2005|win32-msvc2008):!equals(TEMPLATE_PREFIX, "vc"):equals(TEMPLATE, "app") { +if(win32-msvc2005|win32-msvc2008|win32-msvc2010):!equals(TEMPLATE_PREFIX, "vc"):equals(TEMPLATE, "app") { NOPATH_TARGET = $$TARGET NOPATH_TARGET ~= s,\\ , ,q # Remove space escaping (NOPATH_TARGET is quoted) NOPATH_TARGET ~= s,\\,/,g # Change to single type separators diff --git a/mkspecs/win32-msvc2010/qmake.conf b/mkspecs/win32-msvc2010/qmake.conf new file mode 100644 index 0000000..2a48938 --- /dev/null +++ b/mkspecs/win32-msvc2010/qmake.conf @@ -0,0 +1,91 @@ +# +# qmake configuration for win32-msvc2010 +# +# Written for Microsoft VC2005.NET +# + +MAKEFILE_GENERATOR = MSBUILD +TEMPLATE = app +CONFIG += qt warn_on release incremental flat link_prl precompile_header autogen_precompile_source copy_dir_files debug_and_release debug_and_release_target embed_manifest_dll embed_manifest_exe +QT += core gui +DEFINES += UNICODE WIN32 QT_LARGEFILE_SUPPORT +QMAKE_COMPILER_DEFINES += _MSC_VER=1600 WIN32 + +QMAKE_CC = cl +QMAKE_LEX = flex +QMAKE_LEXFLAGS = +QMAKE_YACC = byacc +QMAKE_YACCFLAGS = -d +QMAKE_CFLAGS = -nologo -Zm200 -Zc:wchar_t- +QMAKE_CFLAGS_WARN_ON = -W3 +QMAKE_CFLAGS_WARN_OFF = -W0 +QMAKE_CFLAGS_RELEASE = -O2 -MD +QMAKE_CFLAGS_DEBUG = -Zi -MDd +QMAKE_CFLAGS_YACC = +QMAKE_CFLAGS_LTCG = -GL + +QMAKE_CXX = $$QMAKE_CC +QMAKE_CXXFLAGS = $$QMAKE_CFLAGS +QMAKE_CXXFLAGS_WARN_ON = $$QMAKE_CFLAGS_WARN_ON -w34100 -w34189 +QMAKE_CXXFLAGS_WARN_OFF = $$QMAKE_CFLAGS_WARN_OFF +QMAKE_CXXFLAGS_RELEASE = $$QMAKE_CFLAGS_RELEASE +QMAKE_CXXFLAGS_DEBUG = $$QMAKE_CFLAGS_DEBUG +QMAKE_CXXFLAGS_YACC = $$QMAKE_CFLAGS_YACC +QMAKE_CXXFLAGS_LTCG = $$QMAKE_CFLAGS_LTCG +QMAKE_CXXFLAGS_STL_ON = -EHsc +QMAKE_CXXFLAGS_STL_OFF = +QMAKE_CXXFLAGS_RTTI_ON = -GR +QMAKE_CXXFLAGS_RTTI_OFF = +QMAKE_CXXFLAGS_EXCEPTIONS_ON = -EHsc +QMAKE_CXXFLAGS_EXCEPTIONS_OFF = + +QMAKE_INCDIR = +QMAKE_INCDIR_QT = $$[QT_INSTALL_HEADERS] +QMAKE_LIBDIR_QT = $$[QT_INSTALL_LIBS] + +QMAKE_RUN_CC = $(CC) -c $(CFLAGS) $(INCPATH) -Fo$obj $src +QMAKE_RUN_CC_IMP = $(CC) -c $(CFLAGS) $(INCPATH) -Fo$@ $< +QMAKE_RUN_CC_IMP_BATCH = $(CC) -c $(CFLAGS) $(INCPATH) -Fo$@ @<< +QMAKE_RUN_CXX = $(CXX) -c $(CXXFLAGS) $(INCPATH) -Fo$obj $src +QMAKE_RUN_CXX_IMP = $(CXX) -c $(CXXFLAGS) $(INCPATH) -Fo$@ $< +QMAKE_RUN_CXX_IMP_BATCH = $(CXX) -c $(CXXFLAGS) $(INCPATH) -Fo$@ @<< + +QMAKE_LINK = link +QMAKE_LFLAGS = /NOLOGO +QMAKE_LFLAGS_RELEASE = /INCREMENTAL:NO +QMAKE_LFLAGS_DEBUG = /DEBUG +QMAKE_LFLAGS_CONSOLE = /SUBSYSTEM:CONSOLE +QMAKE_LFLAGS_WINDOWS = /SUBSYSTEM:WINDOWS \"/MANIFESTDEPENDENCY:type=\'win32\' name=\'Microsoft.Windows.Common-Controls\' version=\'6.0.0.0\' publicKeyToken=\'6595b64144ccf1df\' language=\'*\' processorArchitecture=\'*\'\" +QMAKE_LFLAGS_DLL = /DLL +QMAKE_LFLAGS_LTCG = /LTCG + +QMAKE_LIBS_CORE = kernel32.lib user32.lib shell32.lib uuid.lib ole32.lib advapi32.lib ws2_32.lib +QMAKE_LIBS_GUI = gdi32.lib comdlg32.lib oleaut32.lib imm32.lib winmm.lib winspool.lib ws2_32.lib ole32.lib user32.lib advapi32.lib +QMAKE_LIBS_NETWORK = ws2_32.lib +QMAKE_LIBS_OPENGL = opengl32.lib glu32.lib gdi32.lib user32.lib +QMAKE_LIBS_COMPAT = advapi32.lib shell32.lib comdlg32.lib user32.lib gdi32.lib ws2_32.lib + +QMAKE_LIBS_QT_ENTRY = -lqtmain + +QMAKE_MOC = $$[QT_INSTALL_BINS]\moc.exe +QMAKE_UIC = $$[QT_INSTALL_BINS]\uic.exe +QMAKE_IDC = $$[QT_INSTALL_BINS]\idc.exe + +QMAKE_IDL = midl +QMAKE_LIB = lib /NOLOGO +QMAKE_RC = rc + +QMAKE_ZIP = zip -r -9 + +QMAKE_COPY = copy /y +QMAKE_COPY_DIR = xcopy /s /q /y /i +QMAKE_MOVE = move +QMAKE_DEL_FILE = del +QMAKE_DEL_DIR = rmdir +QMAKE_CHK_DIR_EXISTS = if not exist +QMAKE_MKDIR = mkdir + +VCPROJ_EXTENSION = .vcxproj +VCSOLUTION_EXTENSION = .sln +VCPROJ_KEYWORD = Qt4VSv1.0 +load(qt_config) diff --git a/mkspecs/win32-msvc2010/qplatformdefs.h b/mkspecs/win32-msvc2010/qplatformdefs.h new file mode 100644 index 0000000..68f9ee0 --- /dev/null +++ b/mkspecs/win32-msvc2010/qplatformdefs.h @@ -0,0 +1,42 @@ +/**************************************************************************** +** +** 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 qmake spec 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 "../win32-msvc2005/qplatformdefs.h" diff --git a/qmake/generators/metamakefile.cpp b/qmake/generators/metamakefile.cpp index f42a489..9c64544 100644 --- a/qmake/generators/metamakefile.cpp +++ b/qmake/generators/metamakefile.cpp @@ -529,7 +529,7 @@ MetaMakefileGenerator::modesForGenerator(const QString &gen, *host_mode = Option::HOST_UNIX_MODE; *target_mode = Option::TARG_UNIX_MODE; #endif - } else if (gen == "MSVC.NET" || gen == "MINGW" || gen == "BMAKE") { + } else if (gen == "MSVC.NET" || gen == "MINGW" || gen == "BMAKE" || gen == "MSBUILD") { *host_mode = Option::HOST_WIN_MODE; *target_mode = Option::TARG_WIN_MODE; } else if (gen == "PROJECTBUILDER" || gen == "XCODE") { diff --git a/src/declarative/graphicsitems/qdeclarativegridview.cpp b/src/declarative/graphicsitems/qdeclarativegridview.cpp index f8b773e..f79a853 100644 --- a/src/declarative/graphicsitems/qdeclarativegridview.cpp +++ b/src/declarative/graphicsitems/qdeclarativegridview.cpp @@ -375,9 +375,11 @@ FxGridItem *QDeclarativeGridViewPrivate::createItem(int modelIndex) if (QDeclarativeItem *item = model->item(modelIndex, false)) { listItem = new FxGridItem(item, q); listItem->index = modelIndex; - listItem->item->setZValue(1); - // complete - model->completeItem(); + if (model->completePending()) { + // complete + listItem->item->setZValue(1); + model->completeItem(); + } listItem->item->setParentItem(q->viewport()); unrequestedItems.remove(listItem->item); } diff --git a/src/declarative/graphicsitems/qdeclarativelistview.cpp b/src/declarative/graphicsitems/qdeclarativelistview.cpp index 60e8f6c..c88dab2 100644 --- a/src/declarative/graphicsitems/qdeclarativelistview.cpp +++ b/src/declarative/graphicsitems/qdeclarativelistview.cpp @@ -570,9 +570,11 @@ FxListItem *QDeclarativeListViewPrivate::createItem(int modelIndex) listItem->attached->m_prevSection = sectionAt(modelIndex-1); } } - listItem->item->setZValue(1); - // complete - model->completeItem(); + if (model->completePending()) { + // complete + listItem->item->setZValue(1); + model->completeItem(); + } listItem->item->setParentItem(q->viewport()); QDeclarativeItemPrivate *itemPrivate = static_cast<QDeclarativeItemPrivate*>(QGraphicsItemPrivate::get(item)); itemPrivate->addItemChangeListener(this, QDeclarativeItemPrivate::Geometry); diff --git a/src/declarative/graphicsitems/qdeclarativerepeater.cpp b/src/declarative/graphicsitems/qdeclarativerepeater.cpp index 95f6276..d49bb02 100644 --- a/src/declarative/graphicsitems/qdeclarativerepeater.cpp +++ b/src/declarative/graphicsitems/qdeclarativerepeater.cpp @@ -346,21 +346,26 @@ void QDeclarativeRepeater::itemsInserted(int index, int count) void QDeclarativeRepeater::itemsRemoved(int index, int count) { Q_D(QDeclarativeRepeater); - if (!isComponentComplete()) + if (!isComponentComplete() || count <= 0) return; while (count--) { QDeclarativeItem *item = d->deletables.takeAt(index); - if (item) { + if (item) d->model->release(item); - } + else + break; } } void QDeclarativeRepeater::itemsMoved(int from, int to, int count) { Q_D(QDeclarativeRepeater); - if (!isComponentComplete()) + if (!isComponentComplete() || count <= 0) return; + if (from + count > d->deletables.count()) { + regenerate(); + return; + } QList<QDeclarativeItem*> removed; int removedCount = count; while (removedCount--) diff --git a/src/declarative/graphicsitems/qdeclarativetext.cpp b/src/declarative/graphicsitems/qdeclarativetext.cpp index 0b59503..2b8da8e 100644 --- a/src/declarative/graphicsitems/qdeclarativetext.cpp +++ b/src/declarative/graphicsitems/qdeclarativetext.cpp @@ -717,6 +717,7 @@ void QDeclarativeTextPrivate::updateSize() dy -= size.height(); } else { singleline = false; // richtext can't elide or be optimized for single-line case + ensureDoc(); doc->setDefaultFont(font); QTextOption option((Qt::Alignment)int(hAlign | vAlign)); option.setWrapMode(QTextOption::WrapMode(wrapMode)); diff --git a/src/declarative/graphicsitems/qdeclarativetextinput.cpp b/src/declarative/graphicsitems/qdeclarativetextinput.cpp index 2161e23..b618183 100644 --- a/src/declarative/graphicsitems/qdeclarativetextinput.cpp +++ b/src/declarative/graphicsitems/qdeclarativetextinput.cpp @@ -726,8 +726,18 @@ void QDeclarativeTextInput::setEchoMode(QDeclarativeTextInput::EchoMode echo) Q_D(QDeclarativeTextInput); if (echoMode() == echo) return; - + Qt::InputMethodHints imHints = inputMethodHints(); + if (echo == Password || echo == NoEcho) + imHints |= Qt::ImhHiddenText; + else + imHints &= ~Qt::ImhHiddenText; + if (echo != Normal) + imHints |= (Qt::ImhNoAutoUppercase | Qt::ImhNoPredictiveText); + else + imHints &= ~(Qt::ImhNoAutoUppercase | Qt::ImhNoPredictiveText); + setInputMethodHints(imHints); d->control->setEchoMode((uint)echo); + update(); emit echoModeChanged(echoMode()); } diff --git a/src/declarative/graphicsitems/qdeclarativevisualitemmodel.cpp b/src/declarative/graphicsitems/qdeclarativevisualitemmodel.cpp index e2d8bc7..43cafe3 100644 --- a/src/declarative/graphicsitems/qdeclarativevisualitemmodel.cpp +++ b/src/declarative/graphicsitems/qdeclarativevisualitemmodel.cpp @@ -176,6 +176,11 @@ QDeclarativeVisualModel::ReleaseFlags QDeclarativeVisualItemModel::release(QDecl return 0; } +bool QDeclarativeVisualItemModel::completePending() const +{ + return false; +} + void QDeclarativeVisualItemModel::completeItem() { // Nothing to do @@ -352,9 +357,10 @@ public: VDMDelegateDataType *m_delegateDataType; friend class QDeclarativeVisualDataModelData; - bool m_metaDataCreated; - bool m_metaDataCacheable; - bool m_delegateValidated; + bool m_metaDataCreated : 1; + bool m_metaDataCacheable : 1; + bool m_delegateValidated : 1; + bool m_completePending : 1; QDeclarativeVisualDataModelData *data(QObject *item); @@ -567,7 +573,7 @@ QDeclarativeVisualDataModelParts::QDeclarativeVisualDataModelParts(QDeclarativeV QDeclarativeVisualDataModelPrivate::QDeclarativeVisualDataModelPrivate(QDeclarativeContext *ctxt) : m_listModelInterface(0), m_abstractItemModel(0), m_visualItemModel(0), m_delegate(0) , m_context(ctxt), m_parts(0), m_delegateDataType(0), m_metaDataCreated(false) -, m_metaDataCacheable(false), m_delegateValidated(false), m_listAccessor(0) +, m_metaDataCacheable(false), m_delegateValidated(false), m_completePending(false), m_listAccessor(0) { } @@ -1026,11 +1032,14 @@ QDeclarativeItem *QDeclarativeVisualDataModel::item(int index, const QByteArray QDeclarativeVisualDataModelData *data = new QDeclarativeVisualDataModelData(index, this); ctxt->setContextProperty(QLatin1String("model"), data); ctxt->setContextObject(data); + d->m_completePending = false; nobj = d->m_delegate->beginCreate(ctxt); - if (complete) + if (complete) { d->m_delegate->completeCreate(); - else + } else { + d->m_completePending = true; needComplete = true; + } if (nobj) { QDeclarative_setParent_noEvent(ctxt, nobj); QDeclarative_setParent_noEvent(data, nobj); @@ -1066,6 +1075,14 @@ QDeclarativeItem *QDeclarativeVisualDataModel::item(int index, const QByteArray return item; } +bool QDeclarativeVisualDataModel::completePending() const +{ + Q_D(const QDeclarativeVisualDataModel); + if (d->m_visualItemModel) + return d->m_visualItemModel->completePending(); + return d->m_completePending; +} + void QDeclarativeVisualDataModel::completeItem() { Q_D(QDeclarativeVisualDataModel); @@ -1075,6 +1092,7 @@ void QDeclarativeVisualDataModel::completeItem() } d->m_delegate->completeCreate(); + d->m_completePending = false; } QString QDeclarativeVisualDataModel::stringValue(int index, const QString &name) diff --git a/src/declarative/graphicsitems/qdeclarativevisualitemmodel_p.h b/src/declarative/graphicsitems/qdeclarativevisualitemmodel_p.h index 0a9173f..edfd387 100644 --- a/src/declarative/graphicsitems/qdeclarativevisualitemmodel_p.h +++ b/src/declarative/graphicsitems/qdeclarativevisualitemmodel_p.h @@ -82,6 +82,7 @@ public: virtual bool isValid() const = 0; virtual QDeclarativeItem *item(int index, bool complete=true) = 0; virtual ReleaseFlags release(QDeclarativeItem *item) = 0; + virtual bool completePending() const = 0; virtual void completeItem() = 0; virtual QVariant evaluate(int index, const QString &expression, QObject *objectContext) = 0; virtual QString stringValue(int, const QString &) { return QString(); } @@ -123,6 +124,7 @@ public: virtual bool isValid() const; virtual QDeclarativeItem *item(int index, bool complete=true); virtual ReleaseFlags release(QDeclarativeItem *item); + virtual bool completePending() const; virtual void completeItem(); virtual QString stringValue(int index, const QString &role); virtual QVariant evaluate(int index, const QString &expression, QObject *objectContext); @@ -177,6 +179,7 @@ public: QDeclarativeItem *item(int index, bool complete=true); QDeclarativeItem *item(int index, const QByteArray &, bool complete=true); ReleaseFlags release(QDeclarativeItem *item); + bool completePending() const; void completeItem(); virtual QString stringValue(int index, const QString &role); QVariant evaluate(int index, const QString &expression, QObject *objectContext); diff --git a/src/declarative/qml/qdeclarativecomponent.cpp b/src/declarative/qml/qdeclarativecomponent.cpp index 3899e73..d8bbb70 100644 --- a/src/declarative/qml/qdeclarativecomponent.cpp +++ b/src/declarative/qml/qdeclarativecomponent.cpp @@ -142,6 +142,8 @@ int statusId = qRegisterMetaType<QDeclarativeComponent::Status>("QDeclarativeCom } } \endqml + + \sa QtDeclarative */ /*! @@ -152,7 +154,7 @@ int statusId = qRegisterMetaType<QDeclarativeComponent::Status>("QDeclarativeCom \value Null This QDeclarativeComponent has no data. Call loadUrl() or setData() to add QML content. \value Ready This QDeclarativeComponent is ready and create() may be called. \value Loading This QDeclarativeComponent is loading network data. - \value Error An error has occured. Calling errorDescription() to retrieve a description. + \value Error An error has occured. Call errors() to retrieve a list of \{QDeclarativeError}{errors}. */ void QDeclarativeComponentPrivate::typeDataReady() @@ -237,6 +239,18 @@ QDeclarativeComponent::~QDeclarativeComponent() } /*! + \qmlproperty enumeration Component::status + This property holds the status of component loading. It can be one of: + \list + \o Null - no data is available for the component + \o Ready - the component has been loaded, and can be used to create instances. + \o Loading - the component is currently being loaded + \o Error - an error occurred while loading the component. + Calling errorsString() will provide a human-readable description of any errors. + \endlist + */ + +/*! \property QDeclarativeComponent::status The component's current \l{QDeclarativeComponent::Status} {status}. */ @@ -255,6 +269,14 @@ QDeclarativeComponent::Status QDeclarativeComponent::status() const } /*! + \qmlproperty bool Component::isNull + + Is true if the component is in the Null state, false otherwise. + + Equivalent to status == Component.Null. +*/ + +/*! \property QDeclarativeComponent::isNull Is true if the component is in the Null state, false otherwise. @@ -267,6 +289,14 @@ bool QDeclarativeComponent::isNull() const } /*! + \qmlproperty bool Component::isReady + + Is true if the component is in the Ready state, false otherwise. + + Equivalent to status == Component.Ready. +*/ + +/*! \property QDeclarativeComponent::isReady Is true if the component is in the Ready state, false otherwise. @@ -279,6 +309,16 @@ bool QDeclarativeComponent::isReady() const } /*! + \qmlproperty bool Component::isError + + Is true if the component is in the Error state, false otherwise. + + Equivalent to status == Component.Error. + + Calling errorsString() will provide a human-readable description of any errors. +*/ + +/*! \property QDeclarativeComponent::isError Is true if the component is in the Error state, false otherwise. @@ -291,6 +331,14 @@ bool QDeclarativeComponent::isError() const } /*! + \qmlproperty bool Component::isLoading + + Is true if the component is in the Loading state, false otherwise. + + Equivalent to status == Component::Loading. +*/ + +/*! \property QDeclarativeComponent::isLoading Is true if the component is in the Loading state, false otherwise. @@ -303,6 +351,12 @@ bool QDeclarativeComponent::isLoading() const } /*! + \qmlproperty real Component::progress + The progress of loading the component, from 0.0 (nothing loaded) + to 1.0 (finished). +*/ + +/*! \property QDeclarativeComponent::progress The progress of loading the component, from 0.0 (nothing loaded) to 1.0 (finished). @@ -488,6 +542,17 @@ QList<QDeclarativeError> QDeclarativeComponent::errors() const } /*! + \qmlmethod string Component::errorsString() + + Returns a human-readable description of any errors. + + The string includes the file, location, and description of each error. + If multiple errors are present they are separated by a newline character. + + If no errors are present, an empty string is returned. +*/ + +/*! \internal errorsString is only meant as a way to get the errors in script */ @@ -506,6 +571,11 @@ QString QDeclarativeComponent::errorsString() const } /*! + \qmlproperty url Component::url + The component URL. This is the URL that was used to construct the component. +*/ + +/*! \property QDeclarativeComponent::url The component URL. This is the URL passed to either the constructor, or the loadUrl() or setData() methods. @@ -525,6 +595,13 @@ QDeclarativeComponent::QDeclarativeComponent(QDeclarativeComponentPrivate &dd, Q } /*! + \qmlmethod object Component::createObject() + Returns an object instance from this component, or null if object creation fails. + + The object will be created in the same context as the component was created in. +*/ + +/*! \internal A version of create which returns a scriptObject, for use in script */ @@ -533,10 +610,10 @@ QScriptValue QDeclarativeComponent::createObject() Q_D(QDeclarativeComponent); QDeclarativeContext* ctxt = creationContext(); if(!ctxt) - return QScriptValue(); + return QScriptValue(QScriptValue::NullValue); QObject* ret = create(ctxt); if (!ret) - return QScriptValue(); + return QScriptValue(QScriptValue::NullValue); QDeclarativeEnginePrivate *priv = QDeclarativeEnginePrivate::get(d->engine); QDeclarativeData::get(ret, true)->setImplicitDestructible(); return priv->objectClass->newQObject(ret, QMetaType::QObjectStar); diff --git a/src/declarative/qml/qdeclarativecompositetypemanager.cpp b/src/declarative/qml/qdeclarativecompositetypemanager.cpp index adeb7a5..0eb7e1b 100644 --- a/src/declarative/qml/qdeclarativecompositetypemanager.cpp +++ b/src/declarative/qml/qdeclarativecompositetypemanager.cpp @@ -617,7 +617,8 @@ int QDeclarativeCompositeTypeManager::resolveTypes(QDeclarativeCompositeTypeData int majorVersion; int minorVersion; QDeclarativeEnginePrivate::ImportedNamespace *typeNamespace = 0; - if (!QDeclarativeEnginePrivate::get(engine)->resolveType(unit->imports, typeName, &ref.type, &url, &majorVersion, &minorVersion, &typeNamespace) + QString errorString; + if (!QDeclarativeEnginePrivate::get(engine)->resolveType(unit->imports, typeName, &ref.type, &url, &majorVersion, &minorVersion, &typeNamespace, &errorString) || typeNamespace) { // Known to not be a type: @@ -630,7 +631,8 @@ int QDeclarativeCompositeTypeManager::resolveTypes(QDeclarativeCompositeTypeData if (typeNamespace) error.setDescription(tr("Namespace %1 cannot be used as a type").arg(userTypeName)); else - error.setDescription(tr("%1 is not a type").arg(userTypeName)); + error.setDescription(tr("%1 %2").arg(userTypeName).arg(errorString)); + if (!parserRef->refObjects.isEmpty()) { QDeclarativeParser::Object *obj = parserRef->refObjects.first(); error.setLine(obj->location.start.line); diff --git a/src/declarative/qml/qdeclarativeengine.cpp b/src/declarative/qml/qdeclarativeengine.cpp index 8eae120..0ee6dfe 100644 --- a/src/declarative/qml/qdeclarativeengine.cpp +++ b/src/declarative/qml/qdeclarativeengine.cpp @@ -112,6 +112,7 @@ Q_DECLARE_METATYPE(QDeclarativeProperty) QT_BEGIN_NAMESPACE DEFINE_BOOL_CONFIG_OPTION(qmlImportTrace, QML_IMPORT_TRACE) +DEFINE_BOOL_CONFIG_OPTION(qmlCheckTypes, QML_CHECK_TYPES) /*! \qmlclass QtObject QObject @@ -293,6 +294,10 @@ QNetworkAccessManager *QDeclarativeScriptEngine::networkAccessManager() QDeclarativeEnginePrivate::~QDeclarativeEnginePrivate() { + Q_ASSERT(inProgressCreations == 0); + Q_ASSERT(bindValues.isEmpty()); + Q_ASSERT(parserStatus.isEmpty()); + while (cleanup) { QDeclarativeCleanup *c = cleanup; cleanup = c->next; @@ -317,10 +322,6 @@ QDeclarativeEnginePrivate::~QDeclarativeEnginePrivate() delete globalClass; globalClass = 0; - for(int ii = 0; ii < bindValues.count(); ++ii) - clear(bindValues[ii]); - for(int ii = 0; ii < parserStatus.count(); ++ii) - clear(parserStatus[ii]); for(QHash<int, QDeclarativeCompiledData*>::ConstIterator iter = m_compositeTypes.constBegin(); iter != m_compositeTypes.constEnd(); ++iter) (*iter)->release(); for(QHash<const QMetaObject *, QDeclarativePropertyCache *>::Iterator iter = propertyCache.begin(); iter != propertyCache.end(); ++iter) @@ -770,7 +771,9 @@ void QDeclarativeEngine::setObjectOwnership(QObject *object, ObjectOwnership own if (!object) return; - QDeclarativeData *ddata = QDeclarativeData::get(object, true); + // No need to do anything if CppOwnership and there is no QDeclarativeData as + // the current ownership must be CppOwnership + QDeclarativeData *ddata = QDeclarativeData::get(object, ownership == JavaScriptOwnership); if (!ddata) return; @@ -808,9 +811,6 @@ void qmlExecuteDeferred(QObject *object) data->deferredComponent = 0; QDeclarativeComponentPrivate::complete(ep, &state); - - if (!state.errors.isEmpty()) - ep->warning(state.errors); } } @@ -1161,7 +1161,7 @@ QScriptValue QDeclarativeEnginePrivate::formatDateTime(QScriptContext*ctxt, QScr } else if (ctxt->argument(1).isNumber()) { enumFormat = Qt::DateFormat(ctxt->argument(1).toUInt32()); } else { - return ctxt->throwError("Qt.formatDateTime(): Invalid datetime formate"); + return ctxt->throwError("Qt.formatDateTime(): Invalid datetime format"); } } return engine->newVariant(qVariantFromValue(date.toString(enumFormat))); @@ -1543,55 +1543,65 @@ struct QDeclarativeEnginePrivate::ImportedNamespace { QList<bool> isLibrary; QList<QDeclarativeDirComponents> qmlDirComponents; - bool find(const QByteArray& type, int *vmajor, int *vminor, QDeclarativeType** type_return, QUrl* url_return, - QUrl *base = 0) + + bool find_helper(int i, const QByteArray& type, int *vmajor, int *vminor, + QDeclarativeType** type_return, QUrl* url_return, + QUrl *base = 0, bool *typeRecursionDetected = 0) { - for (int i=0; i<urls.count(); ++i) { - int vmaj = majversions.at(i); - int vmin = minversions.at(i); - - QByteArray qt = uris.at(i).toUtf8(); - qt += '/'; - qt += type; - - QDeclarativeType *t = QDeclarativeMetaType::qmlType(qt,vmaj,vmin); - if (t) { - if (vmajor) *vmajor = vmaj; - if (vminor) *vminor = vmin; - if (type_return) - *type_return = t; - return true; - } + int vmaj = majversions.at(i); + int vmin = minversions.at(i); + + QByteArray qt = uris.at(i).toUtf8(); + qt += '/'; + qt += type; + + QDeclarativeType *t = QDeclarativeMetaType::qmlType(qt,vmaj,vmin); + if (t) { + if (vmajor) *vmajor = vmaj; + if (vminor) *vminor = vmin; + if (type_return) + *type_return = t; + return true; + } - QUrl url = QUrl(urls.at(i) + QLatin1Char('/') + QString::fromUtf8(type) + QLatin1String(".qml")); - QDeclarativeDirComponents qmldircomponents = qmlDirComponents.at(i); - - bool typeWasDeclaredInQmldir = false; - if (!qmldircomponents.isEmpty()) { - const QString typeName = QString::fromUtf8(type); - foreach (const QDeclarativeDirParser::Component &c, qmldircomponents) { - if (c.typeName == typeName) { - typeWasDeclaredInQmldir = true; - - // importing version -1 means import ALL versions - if ((vmaj == -1) || (c.majorVersion < vmaj || (c.majorVersion == vmaj && vmin >= c.minorVersion))) { - QUrl candidate = url.resolved(QUrl(c.fileName)); - if (c.internal && base) { - if (base->resolved(QUrl(c.fileName)) != candidate) - continue; // failed attempt to access an internal type - } - if (url_return) - *url_return = candidate; - return true; + QUrl url = QUrl(urls.at(i) + QLatin1Char('/') + QString::fromUtf8(type) + QLatin1String(".qml")); + QDeclarativeDirComponents qmldircomponents = qmlDirComponents.at(i); + + bool typeWasDeclaredInQmldir = false; + if (!qmldircomponents.isEmpty()) { + const QString typeName = QString::fromUtf8(type); + foreach (const QDeclarativeDirParser::Component &c, qmldircomponents) { + if (c.typeName == typeName) { + typeWasDeclaredInQmldir = true; + + // importing version -1 means import ALL versions + if ((vmaj == -1) || (c.majorVersion < vmaj || (c.majorVersion == vmaj && vmin >= c.minorVersion))) { + QUrl candidate = url.resolved(QUrl(c.fileName)); + if (c.internal && base) { + if (base->resolved(QUrl(c.fileName)) != candidate) + continue; // failed attempt to access an internal type } + if (base && *base == candidate) { + if (typeRecursionDetected) + *typeRecursionDetected = true; + continue; // no recursion + } + if (url_return) + *url_return = candidate; + return true; } } } + } - if (!typeWasDeclaredInQmldir && !isLibrary.at(i)) { - // XXX search non-files too! (eg. zip files, see QT-524) - QFileInfo f(toLocalFileOrQrc(url)); - if (f.exists()) { + if (!typeWasDeclaredInQmldir && !isLibrary.at(i)) { + // XXX search non-files too! (eg. zip files, see QT-524) + QFileInfo f(toLocalFileOrQrc(url)); + if (f.exists()) { + if (base && *base == url) { // no recursion + if (typeRecursionDetected) + *typeRecursionDetected = true; + } else { if (url_return) *url_return = url; return true; @@ -1600,6 +1610,63 @@ struct QDeclarativeEnginePrivate::ImportedNamespace { } return false; } + + bool find(const QByteArray& type, int *vmajor, int *vminor, QDeclarativeType** type_return, + QUrl* url_return, QUrl *base = 0, QString *errorString = 0) + { + bool typeRecursionDetected = false; + for (int i=0; i<urls.count(); ++i) { + if (find_helper(i, type, vmajor, vminor, type_return, url_return, base, &typeRecursionDetected)) { + if (qmlCheckTypes()) { + // check for type clashes + for (int j = i+1; j<urls.count(); ++j) { + if (find_helper(j, type, vmajor, vminor, 0, 0, base)) { + if (errorString) { + QString u1 = urls.at(i); + QString u2 = urls.at(j); + if (base) { + QString b = base->toString(); + int slash = b.lastIndexOf(QLatin1Char('/')); + if (slash >= 0) { + b = b.left(slash+1); + QString l = b.left(slash); + if (u1.startsWith(b)) + u1 = u1.mid(b.count()); + else if (u1 == l) + u1 = QDeclarativeEngine::tr("local directory"); + if (u2.startsWith(b)) + u2 = u2.mid(b.count()); + else if (u2 == l) + u2 = QDeclarativeEngine::tr("local directory"); + } + } + + if (u1 != u2) + *errorString + = QDeclarativeEngine::tr("is ambiguous. Found in %1 and in %2") + .arg(u1).arg(u2); + else + *errorString + = QDeclarativeEngine::tr("is ambiguous. Found in %1 in version %2.%3 and %4.%5") + .arg(u1) + .arg(majversions.at(i)).arg(minversions.at(i)) + .arg(majversions.at(j)).arg(minversions.at(j)); + } + return false; + } + } + } + return true; + } + } + if (errorString) { + if (typeRecursionDetected) + *errorString = QDeclarativeEngine::tr("is instantiated recursively"); + else + *errorString = QDeclarativeEngine::tr("is not a type"); + } + return false; + } }; static bool greaterThan(const QString &s1, const QString &s2) @@ -1809,30 +1876,37 @@ public: return true; } - bool find(const QByteArray& type, int *vmajor, int *vminor, QDeclarativeType** type_return, QUrl* url_return) + bool find(const QByteArray& type, int *vmajor, int *vminor, QDeclarativeType** type_return, + QUrl* url_return, QString *errorString) { QDeclarativeEnginePrivate::ImportedNamespace *s = 0; int slash = type.indexOf('/'); if (slash >= 0) { - s = set.value(QString::fromUtf8(type.left(slash))); - if (!s) - return false; // qualifier must be a namespace + QString namespaceName = QString::fromUtf8(type.left(slash)); + s = set.value(namespaceName); + if (!s) { + if (errorString) + *errorString = QDeclarativeEngine::tr("- %1 is not a namespace").arg(namespaceName); + return false; + } int nslash = type.indexOf('/',slash+1); - if (nslash > 0) - return false; // only single qualification allowed + if (nslash > 0) { + if (errorString) + *errorString = QDeclarativeEngine::tr("- nested namespaces not allowed"); + return false; + } } else { s = &unqualifiedset; } QByteArray unqualifiedtype = slash < 0 ? type : type.mid(slash+1); // common-case opt (QString::mid works fine, but slower) if (s) { - if (s->find(unqualifiedtype,vmajor,vminor,type_return,url_return, &base)) + if (s->find(unqualifiedtype,vmajor,vminor,type_return,url_return, &base, errorString)) return true; if (s->urls.count() == 1 && !s->isLibrary[0] && url_return && s != &unqualifiedset) { // qualified, and only 1 url *url_return = QUrl(s->urls[0]+QLatin1Char('/')).resolved(QUrl(QString::fromUtf8(unqualifiedtype) + QLatin1String(".qml"))); return true; } - } return false; @@ -2329,7 +2403,7 @@ bool QDeclarativeEnginePrivate::addToImport(Imports* imports, const QDeclarative \sa addToImport() */ -bool QDeclarativeEnginePrivate::resolveType(const Imports& imports, const QByteArray& type, QDeclarativeType** type_return, QUrl* url_return, int *vmaj, int *vmin, ImportedNamespace** ns_return) const +bool QDeclarativeEnginePrivate::resolveType(const Imports& imports, const QByteArray& type, QDeclarativeType** type_return, QUrl* url_return, int *vmaj, int *vmin, ImportedNamespace** ns_return, QString *errorString) const { ImportedNamespace* ns = imports.d->findNamespace(QString::fromUtf8(type)); if (ns) { @@ -2338,7 +2412,7 @@ bool QDeclarativeEnginePrivate::resolveType(const Imports& imports, const QByteA return true; } if (type_return || url_return) { - if (imports.d->find(type,vmaj,vmin,type_return,url_return)) { + if (imports.d->find(type,vmaj,vmin,type_return,url_return, errorString)) { if (qmlImportTrace()) { if (type_return && *type_return && url_return && !url_return->isEmpty()) qDebug() << "QDeclarativeEngine::resolveType" << type << '=' << (*type_return)->typeName() << *url_return; diff --git a/src/declarative/qml/qdeclarativeengine_p.h b/src/declarative/qml/qdeclarativeengine_p.h index f6b9bcb..743275e 100644 --- a/src/declarative/qml/qdeclarativeengine_p.h +++ b/src/declarative/qml/qdeclarativeengine_p.h @@ -290,7 +290,8 @@ public: bool resolveType(const Imports&, const QByteArray& type, QDeclarativeType** type_return, QUrl* url_return, int *version_major, int *version_minor, - ImportedNamespace** ns_return) const; + ImportedNamespace** ns_return, + QString *errorString = 0) const; void resolveTypeInNamespace(ImportedNamespace*, const QByteArray& type, QDeclarativeType** type_return, QUrl* url_return, int *version_major, int *version_minor ) const; diff --git a/src/declarative/qml/qdeclarativeextensionplugin.cpp b/src/declarative/qml/qdeclarativeextensionplugin.cpp index 863bfc4..2c15385 100644 --- a/src/declarative/qml/qdeclarativeextensionplugin.cpp +++ b/src/declarative/qml/qdeclarativeextensionplugin.cpp @@ -64,8 +64,11 @@ QT_BEGIN_NAMESPACE as any manipulation of the engine's root context may cause conflicts or other issues in the library user's code. - See \l {Extending QML in C++} for details how to write a QML extension plugin. - See \l {How to Create Qt Plugins} for general Qt plugin documentation. + See \l {Tutorial: Writing QML extensions with C++} for details on creating + QML extensions, including how to build a plugin with with QDeclarativeExtensionPlugin. + For a simple overview, see the \l{declarative/plugins}{plugins} example. + + Also see \l {How to Create Qt Plugins} for general Qt plugin documentation. \sa QDeclarativeEngine::importPlugin() */ @@ -73,8 +76,12 @@ QT_BEGIN_NAMESPACE /*! \fn void QDeclarativeExtensionPlugin::registerTypes(const char *uri) - Registers the QML types in the given \a uri. Here you call qmlRegisterType() for - all types which are provided by the extension plugin. + Registers the QML types in the given \a uri. Subclasses should implement + this to call qmlRegisterType() for all types which are provided by the extension + plugin. + + The \a uri is an identifier for the plugin generated by the QML engine + based on the name and path of the extension's plugin library. */ /*! diff --git a/src/declarative/qml/qdeclarativemetatype.cpp b/src/declarative/qml/qdeclarativemetatype.cpp index d9ea8dc..5fcb7ee 100644 --- a/src/declarative/qml/qdeclarativemetatype.cpp +++ b/src/declarative/qml/qdeclarativemetatype.cpp @@ -247,7 +247,7 @@ static void clone(QMetaObjectBuilder &builder, const QMetaObject *mo, QMetaProperty property = mo->property(ii); int otherIndex = ignoreEnd->indexOfProperty(property.name()); - if (otherIndex >= ignoreStart->classInfoOffset() + ignoreStart->classInfoCount()) { + if (otherIndex >= ignoreStart->propertyOffset() + ignoreStart->propertyCount()) { builder.addProperty(QByteArray("__qml_ignore__") + property.name(), QByteArray("void")); // Skip } else { diff --git a/src/declarative/qml/qdeclarativenetworkaccessmanagerfactory.cpp b/src/declarative/qml/qdeclarativenetworkaccessmanagerfactory.cpp index b116129..399831d 100644 --- a/src/declarative/qml/qdeclarativenetworkaccessmanagerfactory.cpp +++ b/src/declarative/qml/qdeclarativenetworkaccessmanagerfactory.cpp @@ -59,10 +59,6 @@ QT_BEGIN_NAMESPACE To use a factory, assign it to the relevant QDeclarativeEngine using QDeclarativeEngine::setNetworkAccessManagerFactory(). - If the created QNetworkAccessManager becomes invalid, due to a - change in proxy settings, for example, call the invalidate() method. - This will cause all QNetworkAccessManagers to be recreated. - Note: the create() method may be called by multiple threads, so ensure the implementation of this method is reentrant. @@ -82,7 +78,10 @@ QDeclarativeNetworkAccessManagerFactory::~QDeclarativeNetworkAccessManagerFactor Implement this method to create a QNetworkAccessManager with \a parent. This allows proxies, caching and cookie support to be setup appropriately. - This method should return a new QNetworkAccessManager each time it is called. + This method must return a new QNetworkAccessManager each time it is called. + The parent of the QNetworkAccessManager must be the \a parent provided. + The QNetworkAccessManager(s) created by this + function will be destroyed automatically when their parent is destroyed. Note: this method may be called by multiple threads, so ensure the implementation of this method is reentrant. diff --git a/src/declarative/qml/qdeclarativescriptparser.cpp b/src/declarative/qml/qdeclarativescriptparser.cpp index e7c8a12..8b96733 100644 --- a/src/declarative/qml/qdeclarativescriptparser.cpp +++ b/src/declarative/qml/qdeclarativescriptparser.cpp @@ -449,6 +449,14 @@ bool ProcessAST::visit(AST::UiImport *node) _parser->_errors << error; return false; } + if (import.qualifier == QLatin1String("Qt")) { + QDeclarativeError error; + error.setDescription(QCoreApplication::translate("QDeclarativeParser","Reserved name \"Qt\" cannot be used as an qualifier")); + error.setLine(node->importIdToken.startLine); + error.setColumn(node->importIdToken.startColumn); + _parser->_errors << error; + return false; + } // Check for script qualifier clashes bool isScript = import.type == QDeclarativeScriptParser::Import::Script; diff --git a/src/declarative/util/qdeclarativeanimation.cpp b/src/declarative/util/qdeclarativeanimation.cpp index 3b0d264..4059522 100644 --- a/src/declarative/util/qdeclarativeanimation.cpp +++ b/src/declarative/util/qdeclarativeanimation.cpp @@ -834,6 +834,8 @@ QAbstractAnimation *QDeclarativeScriptAction::qtAnimation() The PropertyAction is immediate - the target property is not animated to the selected value in any way. + + \sa QtDeclarative */ /*! \internal diff --git a/src/declarative/util/qdeclarativebehavior.cpp b/src/declarative/util/qdeclarativebehavior.cpp index a6c578e..1089d31 100644 --- a/src/declarative/util/qdeclarativebehavior.cpp +++ b/src/declarative/util/qdeclarativebehavior.cpp @@ -90,6 +90,8 @@ public: Currently only a single Behavior may be specified for a property; this Behavior can be enabled and disabled via the \l{enabled} property. + + \sa QtDeclarative */ diff --git a/src/declarative/util/qdeclarativebind.cpp b/src/declarative/util/qdeclarativebind.cpp index b7bd4e8..5516628 100644 --- a/src/declarative/util/qdeclarativebind.cpp +++ b/src/declarative/util/qdeclarativebind.cpp @@ -92,6 +92,8 @@ public: If the binding target or binding property is changed, the bound value is immediately pushed onto the new target. + + \sa QtDeclarative */ /*! \internal diff --git a/src/declarative/util/qdeclarativeconnections.cpp b/src/declarative/util/qdeclarativeconnections.cpp index c188521..20d878b 100644 --- a/src/declarative/util/qdeclarativeconnections.cpp +++ b/src/declarative/util/qdeclarativeconnections.cpp @@ -116,6 +116,8 @@ public: onClicked: foo(...) } \endqml + + \sa QtDeclarative */ /*! diff --git a/src/declarative/util/qdeclarativelistmodel.cpp b/src/declarative/util/qdeclarativelistmodel.cpp index 6e980d0..3810256 100644 --- a/src/declarative/util/qdeclarativelistmodel.cpp +++ b/src/declarative/util/qdeclarativelistmodel.cpp @@ -244,7 +244,7 @@ QDeclarativeListModelParser::ListInstruction *QDeclarativeListModelParser::ListM In addition, the WorkerScript cannot add any list data to the model. - \sa {qmlmodels}{Data Models}, WorkerScript + \sa {qmlmodels}{Data Models}, WorkerScript, QtDeclarative */ diff --git a/src/declarative/util/qdeclarativepackage.cpp b/src/declarative/util/qdeclarativepackage.cpp index ac0788f..20e9907 100644 --- a/src/declarative/util/qdeclarativepackage.cpp +++ b/src/declarative/util/qdeclarativepackage.cpp @@ -70,6 +70,7 @@ QT_BEGIN_NAMESPACE \snippet examples/declarative/package/view.qml 0 + \sa QtDeclarative */ diff --git a/src/declarative/util/qdeclarativepropertychanges.cpp b/src/declarative/util/qdeclarativepropertychanges.cpp index 2641dcf..4b2d5a0 100644 --- a/src/declarative/util/qdeclarativepropertychanges.cpp +++ b/src/declarative/util/qdeclarativepropertychanges.cpp @@ -125,10 +125,11 @@ QT_BEGIN_NAMESPACE } \endqml - Changes to an Item's parent or anchors should be done using the associated change elements - (ParentChange and AnchorChanges, respectively) rather than PropertyChanges. + Anchor margins should be changed with PropertyChanges, but other anchor changes or changes to + an Item's parent should be done using the associated change elements + (ParentChange and AnchorChanges, respectively). - \sa {qmlstate}{States} + \sa {qmlstate}{States}, QtDeclarative */ /*! diff --git a/src/declarative/util/qdeclarativestate.cpp b/src/declarative/util/qdeclarativestate.cpp index 684f527..861cbc8 100644 --- a/src/declarative/util/qdeclarativestate.cpp +++ b/src/declarative/util/qdeclarativestate.cpp @@ -141,7 +141,7 @@ QDeclarativeStateOperation::QDeclarativeStateOperation(QObjectPrivate &dd, QObje \note setting the state of an object from within another state of the same object is not allowed. - \sa {qmlstates}{States}, {state-transitions}{Transitions} + \sa {qmlstates}{States}, {state-transitions}{Transitions}, QtDeclarative */ /*! diff --git a/src/declarative/util/qdeclarativestategroup.cpp b/src/declarative/util/qdeclarativestategroup.cpp index 2349ce1..5b51495 100644 --- a/src/declarative/util/qdeclarativestategroup.cpp +++ b/src/declarative/util/qdeclarativestategroup.cpp @@ -110,7 +110,7 @@ public: } \endqml - \sa {qmlstate}{States} {state-transitions}{Transitions} + \sa {qmlstate}{States} {state-transitions}{Transitions}, {QtDeclarative} */ QDeclarativeStateGroup::QDeclarativeStateGroup(QObject *parent) diff --git a/src/declarative/util/qdeclarativestateoperations.cpp b/src/declarative/util/qdeclarativestateoperations.cpp index 9049b83..689f53c 100644 --- a/src/declarative/util/qdeclarativestateoperations.cpp +++ b/src/declarative/util/qdeclarativestateoperations.cpp @@ -612,6 +612,11 @@ QString QDeclarativeStateChangeScript::typeName() const anchors.top: window.top; anchors.bottom: window.bottom } + PropertyChanges { + target: content; + anchors.topMargin: 3 + anchors.bottomMargin: 3; + } } \endqml @@ -623,6 +628,8 @@ QString QDeclarativeStateChangeScript::typeName() const } \endqml + Margin animations can be animated using NumberAnimation. + For more information on anchors see \l {anchor-layout}{Anchor Layouts}. */ diff --git a/src/declarative/util/qdeclarativetimer.cpp b/src/declarative/util/qdeclarativetimer.cpp index 76e6d5e..53a9d83 100644 --- a/src/declarative/util/qdeclarativetimer.cpp +++ b/src/declarative/util/qdeclarativetimer.cpp @@ -98,6 +98,8 @@ public: 1000ms has its \e repeat property changed 500ms after starting, the elapsed time will be reset to 0, and the Timer will be triggered 1000ms later. + + \sa {QtDeclarative} */ QDeclarativeTimer::QDeclarativeTimer(QObject *parent) diff --git a/src/declarative/util/qdeclarativetransition.cpp b/src/declarative/util/qdeclarativetransition.cpp index 815dc4c..f284156 100644 --- a/src/declarative/util/qdeclarativetransition.cpp +++ b/src/declarative/util/qdeclarativetransition.cpp @@ -56,7 +56,7 @@ QT_BEGIN_NAMESPACE \since 4.7 \brief The Transition element defines animated transitions that occur on state changes. - \sa {qmlstates}{States}, {state-transitions}{Transitions} + \sa {qmlstates}{States}, {state-transitions}{Transitions}, {QtDeclarative} */ /*! diff --git a/src/declarative/util/qdeclarativeutilmodule.cpp b/src/declarative/util/qdeclarativeutilmodule.cpp index eb59fb1..3cf07a7 100644 --- a/src/declarative/util/qdeclarativeutilmodule.cpp +++ b/src/declarative/util/qdeclarativeutilmodule.cpp @@ -122,6 +122,6 @@ void QDeclarativeUtilModule::defineModule() qmlRegisterUncreatableType<QDeclarativeAbstractAnimation>("Qt",4,7,"Animation",QDeclarativeAbstractAnimation::tr("Animation is an abstract class")); qmlRegisterCustomType<QDeclarativeListModel>("Qt", 4,7, "ListModel", new QDeclarativeListModelParser); - qmlRegisterCustomType<QDeclarativePropertyChanges>("Qt", 4, 6, "PropertyChanges", new QDeclarativePropertyChangesParser); - qmlRegisterCustomType<QDeclarativeConnections>("Qt", 4, 6, "Connections", new QDeclarativeConnectionsParser); + qmlRegisterCustomType<QDeclarativePropertyChanges>("Qt", 4, 7, "PropertyChanges", new QDeclarativePropertyChangesParser); + qmlRegisterCustomType<QDeclarativeConnections>("Qt", 4, 7, "Connections", new QDeclarativeConnectionsParser); } diff --git a/src/declarative/util/qdeclarativexmllistmodel.cpp b/src/declarative/util/qdeclarativexmllistmodel.cpp index 55e768e..bdebadf 100644 --- a/src/declarative/util/qdeclarativexmllistmodel.cpp +++ b/src/declarative/util/qdeclarativexmllistmodel.cpp @@ -74,6 +74,8 @@ typedef QPair<int, int> QDeclarativeXmlListRange; \qmlclass XmlRole QDeclarativeXmlListModelRole \since 4.7 \brief The XmlRole element allows you to specify a role for an XmlListModel. + + \sa {QtDeclarative} */ /*! @@ -502,6 +504,8 @@ void QDeclarativeXmlListModelPrivate::clear_role(QDeclarativeListProperty<QDecla This is useful to provide incremental updates and avoid repainting an entire model in a view. + + \sa {QtDeclarative} */ QDeclarativeXmlListModel::QDeclarativeXmlListModel(QObject *parent) diff --git a/src/gui/dialogs/qdialog.cpp b/src/gui/dialogs/qdialog.cpp index e4f45ba..a6bd78a 100644 --- a/src/gui/dialogs/qdialog.cpp +++ b/src/gui/dialogs/qdialog.cpp @@ -393,6 +393,7 @@ void QDialogPrivate::resetModalitySetByOpen() resetModalityTo = -1; } +#if defined(Q_WS_WINCE) || defined(Q_WS_S60) #ifdef Q_WS_WINCE_WM void QDialogPrivate::_q_doneAction() { @@ -407,12 +408,12 @@ void QDialogPrivate::_q_doneAction() bool QDialog::event(QEvent *e) { bool result = QWidget::event(e); -#if defined(Q_WS_WINCE) +#ifdef Q_WS_WINCE if (e->type() == QEvent::OkRequest) { accept(); result = true; - } else -#elif defined(Q_WS_S60) + } +#else if ((e->type() == QEvent::StyleChange) || (e->type() == QEvent::Resize )) { if (!testAttribute(Qt::WA_Moved)) { Qt::WindowStates state = windowState(); @@ -421,14 +422,11 @@ bool QDialog::event(QEvent *e) if (state != windowState()) setWindowState(state); } - } else -#endif - if (e->type() == QEvent::Move) { - setAttribute(Qt::WA_Moved, true); // as explicit as the user wants it to be } - +#endif return result; } +#endif /*! Returns the modal dialog's result code, \c Accepted or \c Rejected. diff --git a/src/gui/dialogs/qdialog.h b/src/gui/dialogs/qdialog.h index 7ab0cb6..777256a 100644 --- a/src/gui/dialogs/qdialog.h +++ b/src/gui/dialogs/qdialog.h @@ -107,7 +107,9 @@ public Q_SLOTS: protected: QDialog(QDialogPrivate &, QWidget *parent, Qt::WindowFlags f = 0); +#if defined(Q_WS_WINCE) || defined(Q_WS_S60) bool event(QEvent *e); +#endif void keyPressEvent(QKeyEvent *); void closeEvent(QCloseEvent *); void showEvent(QShowEvent *); diff --git a/src/gui/dialogs/qfiledialog_mac.mm b/src/gui/dialogs/qfiledialog_mac.mm index 14a5f15..28acf24 100644 --- a/src/gui/dialogs/qfiledialog_mac.mm +++ b/src/gui/dialogs/qfiledialog_mac.mm @@ -493,7 +493,7 @@ QT_USE_NAMESPACE for (int i=0; i<mNameFilterDropDownList->size(); ++i) { QString filter = hideDetails ? [self removeExtensions:filters->at(i)] : filters->at(i); [mPopUpButton addItemWithTitle:QT_PREPEND_NAMESPACE(qt_mac_QStringToNSString)(filter)]; - if (filters->at(i) == selectedFilter) + if (filters->at(i).startsWith(selectedFilter)) [mPopUpButton selectItemAtIndex:i]; } } diff --git a/src/gui/graphicsview/qgraphicsitem.cpp b/src/gui/graphicsview/qgraphicsitem.cpp index 6cc3f7d..326f130 100644 --- a/src/gui/graphicsview/qgraphicsitem.cpp +++ b/src/gui/graphicsview/qgraphicsitem.cpp @@ -7325,6 +7325,18 @@ void QGraphicsItem::setInputMethodHints(Qt::InputMethodHints hints) { Q_D(QGraphicsItem); d->imHints = hints; + if (!hasFocus()) + return; + d->scene->d_func()->updateInputMethodSensitivityInViews(); +#if !defined(QT_NO_IM) && (defined(Q_WS_X11) || defined(Q_WS_QWS) || defined(Q_OS_SYMBIAN)) + QWidget *fw = QApplication::focusWidget(); + if (!fw) + return; + for (int i = 0 ; i < scene()->views().count() ; ++i) + if (scene()->views().at(i) == fw) + if (QInputContext *inputContext = fw->inputContext()) + inputContext->update(); +#endif } /*! @@ -7337,13 +7349,11 @@ void QGraphicsItem::setInputMethodHints(Qt::InputMethodHints hints) void QGraphicsItem::updateMicroFocus() { #if !defined(QT_NO_IM) && (defined(Q_WS_X11) || defined(Q_WS_QWS) || defined(Q_OS_SYMBIAN)) - if (QWidget *fw = qApp->focusWidget()) { - if (qt_widget_private(fw)->ic || qApp->d_func()->inputContext) { - if (QInputContext *ic = fw->inputContext()) { - if (ic) - ic->update(); - } - } + if (QWidget *fw = QApplication::focusWidget()) { + for (int i = 0 ; i < scene()->views().count() ; ++i) + if (scene()->views().at(i) == fw) + if (QInputContext *inputContext = fw->inputContext()) + inputContext->update(); #ifndef QT_NO_ACCESSIBILITY // ##### is this correct QAccessible::updateAccessibility(fw, 0, QAccessible::StateChanged); diff --git a/src/gui/graphicsview/qgraphicsitem_p.h b/src/gui/graphicsview/qgraphicsitem_p.h index 61e9bfe..569a329 100644 --- a/src/gui/graphicsview/qgraphicsitem_p.h +++ b/src/gui/graphicsview/qgraphicsitem_p.h @@ -868,7 +868,7 @@ inline void QGraphicsItemPrivate::markParentDirty(bool updateBoundingRect) static_cast<QGraphicsItemEffectSourcePrivate *>(parentp->graphicsEffect->d_func() ->source->d_func())->invalidateCache(); } - if (parentp->graphicsEffect->isEnabled()) { + if (parentp->scene && parentp->graphicsEffect->isEnabled()) { parentp->dirty = 1; parentp->fullUpdatePending = 1; } diff --git a/src/gui/graphicsview/qgraphicsview.cpp b/src/gui/graphicsview/qgraphicsview.cpp index 114de85..c951dce 100644 --- a/src/gui/graphicsview/qgraphicsview.cpp +++ b/src/gui/graphicsview/qgraphicsview.cpp @@ -1037,10 +1037,28 @@ QList<QGraphicsItem *> QGraphicsViewPrivate::findItems(const QRegion &exposedReg void QGraphicsViewPrivate::updateInputMethodSensitivity() { Q_Q(QGraphicsView); - bool enabled = scene && scene->focusItem() - && (scene->focusItem()->flags() & QGraphicsItem::ItemAcceptsInputMethod); + QGraphicsItem *focusItem = 0; + bool enabled = scene && (focusItem = scene->focusItem()) + && (focusItem->d_ptr->flags & QGraphicsItem::ItemAcceptsInputMethod); q->setAttribute(Qt::WA_InputMethodEnabled, enabled); q->viewport()->setAttribute(Qt::WA_InputMethodEnabled, enabled); + + if (!enabled) { + q->setInputMethodHints(0); + return; + } + + QGraphicsProxyWidget *proxy = focusItem->d_ptr->isWidget && focusItem->d_ptr->isProxyWidget() + ? static_cast<QGraphicsProxyWidget *>(focusItem) : 0; + if (!proxy) { + q->setInputMethodHints(focusItem->inputMethodHints()); + } else if (QWidget *widget = proxy->widget()) { + if (QWidget *fw = widget->focusWidget()) + widget = fw; + q->setInputMethodHints(widget->inputMethodHints()); + } else { + q->setInputMethodHints(0); + } } /*! diff --git a/src/gui/kernel/qwidget.cpp b/src/gui/kernel/qwidget.cpp index 441e823..b59824c 100644 --- a/src/gui/kernel/qwidget.cpp +++ b/src/gui/kernel/qwidget.cpp @@ -7307,9 +7307,9 @@ void QWidgetPrivate::show_helper() setVisible(false). - \note Since Qt 4.7, when calling hide() and then show() on QDialog - derived widgets will show on the previous (as in "Where the user moved it to") - position. + \note If you are working with QDialog or its subclasses and you invoke + the show() function after this function, the dialog will be displayed in + its original position. \sa hideEvent(), isHidden(), show(), setVisible(), isVisible(), close() */ diff --git a/src/imports/gestures/plugin.cpp b/src/imports/gestures/plugin.cpp index 9f5d923..b8a9751 100644 --- a/src/imports/gestures/plugin.cpp +++ b/src/imports/gestures/plugin.cpp @@ -53,8 +53,7 @@ public: virtual void registerTypes(const char *uri) { Q_ASSERT(QLatin1String(uri) == QLatin1String("Qt.labs.gestures")); - qmlRegisterCustomType<QDeclarativeGestureArea>(uri,1,0, "GestureArea", "QDeclarativeGestureArea", - new QDeclarativeGestureAreaParser); + qmlRegisterCustomType<QDeclarativeGestureArea>(uri,1,0, "GestureArea", new QDeclarativeGestureAreaParser); } }; diff --git a/src/imports/gestures/qdeclarativegesturearea_p.h b/src/imports/gestures/qdeclarativegesturearea_p.h index 8e2c066..0195511 100644 --- a/src/imports/gestures/qdeclarativegesturearea_p.h +++ b/src/imports/gestures/qdeclarativegesturearea_p.h @@ -59,7 +59,7 @@ QT_MODULE(Declarative) class QDeclarativeBoundSignal; class QDeclarativeContext; class QDeclarativeGestureAreaPrivate; -class Q_DECLARATIVE_EXPORT QDeclarativeGestureArea : public QDeclarativeItem +class QDeclarativeGestureArea : public QDeclarativeItem { Q_OBJECT diff --git a/src/multimedia/mediaservices/base/qmediapluginloader.cpp b/src/multimedia/mediaservices/base/qmediapluginloader.cpp index d6da0ba..8b0ddf4 100644 --- a/src/multimedia/mediaservices/base/qmediapluginloader.cpp +++ b/src/multimedia/mediaservices/base/qmediapluginloader.cpp @@ -108,7 +108,11 @@ void QMediaPluginLoader::load() if (!pluginDir.exists()) continue; - foreach (QString pluginLib, pluginDir.entryList(QDir::Files)) { + foreach (const QString &pluginLib, pluginDir.entryList(QDir::Files)) { +#if defined(Q_OS_UNIX) && !defined(Q_OS_MAC) + if (pluginLib.endsWith(QLatin1String(".debug"))) + continue; +#endif QPluginLoader loader(pluginPathName + pluginLib); QObject *o = loader.instance(); diff --git a/src/multimedia/mediaservices/base/qtmedianamespace.qdoc b/src/multimedia/mediaservices/base/qtmedianamespace.qdoc index 277b1a5..54b856f 100644 --- a/src/multimedia/mediaservices/base/qtmedianamespace.qdoc +++ b/src/multimedia/mediaservices/base/qtmedianamespace.qdoc @@ -40,15 +40,15 @@ ****************************************************************************/ /*! - \namespace QtMultimedia - \ingroup multimedia + \namespace QtMediaServices + \ingroup multimedia-serv - \brief The QtMultimedia namespace contains miscellaneous identifiers used - throughout the Qt Multimedia library. + \brief The QtMediaServices namespace contains miscellaneous identifiers used + throughout the Qt Media Services library. */ /*! - \enum QtMultimedia::MetaData + \enum QtMediaServices::MetaData This enum provides identifiers for meta-data attributes. @@ -169,7 +169,7 @@ */ /*! - \enum QtMultimedia::SupportEstimate + \enum QtMediaServices::SupportEstimate Enumerates the levels of support a media service provider may have for a feature. @@ -180,7 +180,7 @@ */ /*! - \enum QtMultimedia::EncodingQuality + \enum QtMediaServices::EncodingQuality Enumerates quality encoding levels. @@ -192,7 +192,7 @@ */ /*! - \enum QtMultimedia::EncodingMode + \enum QtMediaServices::EncodingMode Enumerates encoding modes. @@ -203,7 +203,7 @@ */ /*! - \enum QtMultimedia::AvailabilityError + \enum QtMediaServices::AvailabilityError Enumerates Service status errors. diff --git a/src/opengl/gl2paintengineex/qtextureglyphcache_gl_p.h b/src/opengl/gl2paintengineex/qtextureglyphcache_gl_p.h index 04731b1..75c2bb1 100644 --- a/src/opengl/gl2paintengineex/qtextureglyphcache_gl_p.h +++ b/src/opengl/gl2paintengineex/qtextureglyphcache_gl_p.h @@ -62,7 +62,7 @@ QT_BEGIN_NAMESPACE class QGL2PaintEngineExPrivate; -class QGLTextureGlyphCache : public QObject, public QTextureGlyphCache +class Q_OPENGL_EXPORT QGLTextureGlyphCache : public QObject, public QTextureGlyphCache { Q_OBJECT public: diff --git a/src/plugins/mediaservices/directshow/mediaplayer/directshowsamplescheduler.cpp b/src/plugins/mediaservices/directshow/mediaplayer/directshowsamplescheduler.cpp index 733080e..150860f 100644 --- a/src/plugins/mediaservices/directshow/mediaplayer/directshowsamplescheduler.cpp +++ b/src/plugins/mediaservices/directshow/mediaplayer/directshowsamplescheduler.cpp @@ -255,11 +255,11 @@ HRESULT DirectShowSampleScheduler::Receive(IMediaSample *pSample) if (m_state == Running) { if (!timedSample->schedule(m_clock, m_startTime, m_timeoutEvent)) { // Timing information is unavailable, so schedule frames immediately. - QMetaObject::invokeMethod(this, "timerActivated", Qt::QueuedConnection); + QMetaObject::invokeMethod(this, "sampleReady", Qt::QueuedConnection); } } else if (m_tail == m_head) { // If this is the first frame make is available. - QMetaObject::invokeMethod(this, "timerActivated", Qt::QueuedConnection); + QMetaObject::invokeMethod(this, "sampleReady", Qt::QueuedConnection); } return S_OK; diff --git a/tests/auto/declarative/examples/tst_examples.cpp b/tests/auto/declarative/examples/tst_examples.cpp index c650346..16b0cbe 100644 --- a/tests/auto/declarative/examples/tst_examples.cpp +++ b/tests/auto/declarative/examples/tst_examples.cpp @@ -81,6 +81,7 @@ tst_examples::tst_examples() // Add directories you want excluded here excludedDirs << "examples/declarative/extending"; + excludedDirs << "examples/declarative/tutorials/extending"; excludedDirs << "examples/declarative/plugins"; excludedDirs << "examples/declarative/proxywidgets"; excludedDirs << "examples/declarative/gestures"; diff --git a/tests/auto/declarative/qdeclarativeecmascript/data/deferredPropertiesErrors.qml b/tests/auto/declarative/qdeclarativeecmascript/data/deferredPropertiesErrors.qml new file mode 100644 index 0000000..9c46c3f --- /dev/null +++ b/tests/auto/declarative/qdeclarativeecmascript/data/deferredPropertiesErrors.qml @@ -0,0 +1,10 @@ +import Qt.test 1.0 +import Qt 4.7 + +MyDeferredObject { + value: undefined // error is resolved before complete + objectProperty: undefined // immediate error + objectProperty2: QtObject { + Component.onCompleted: value = 10 + } +} diff --git a/tests/auto/declarative/qdeclarativeecmascript/testtypes.cpp b/tests/auto/declarative/qdeclarativeecmascript/testtypes.cpp index 154ff4d..8a4605a 100644 --- a/tests/auto/declarative/qdeclarativeecmascript/testtypes.cpp +++ b/tests/auto/declarative/qdeclarativeecmascript/testtypes.cpp @@ -39,6 +39,8 @@ ** ****************************************************************************/ #include "testtypes.h" +#include <QWidget> +#include <QPlainTextEdit> class BaseExtensionObject : public QObject { @@ -80,6 +82,24 @@ public: DefaultPropertyExtensionObject(QObject *parent) : QObject(parent) {} }; +class QWidgetDeclarativeUI : public QObject +{ + Q_OBJECT + + Q_PROPERTY(int width READ width WRITE setWidth NOTIFY widthChanged) + +signals: + void widthChanged(); + +public: + QWidgetDeclarativeUI(QObject *other) : QObject(other) { } + +public: + int width() const { return 0; } + void setWidth(int) { } +}; + + void registerTypes() { qmlRegisterType<MyQmlObject>("Qt.test", 1,0, "MyQmlObject"); @@ -91,6 +111,9 @@ void registerTypes() qmlRegisterType<NumberAssignment>("Qt.test", 1,0, "NumberAssignment"); qmlRegisterExtendedType<DefaultPropertyExtendedObject, DefaultPropertyExtensionObject>("Qt.test", 1,0, "DefaultPropertyExtendedObject"); qmlRegisterType<OverrideDefaultPropertyObject>("Qt.test", 1,0, "OverrideDefaultPropertyObject"); + + qmlRegisterExtendedType<QWidget,QWidgetDeclarativeUI>("Qt.test",1,0,"QWidget"); + qmlRegisterType<QPlainTextEdit>("Qt.test",1,0,"QPlainTextEdit"); } #include "testtypes.moc" diff --git a/tests/auto/declarative/qdeclarativeecmascript/tst_qdeclarativeecmascript.cpp b/tests/auto/declarative/qdeclarativeecmascript/tst_qdeclarativeecmascript.cpp index 97fced4..491a736 100644 --- a/tests/auto/declarative/qdeclarativeecmascript/tst_qdeclarativeecmascript.cpp +++ b/tests/auto/declarative/qdeclarativeecmascript/tst_qdeclarativeecmascript.cpp @@ -89,6 +89,7 @@ private slots: void contextPropertiesTriggerReeval(); void objectPropertiesTriggerReeval(); void deferredProperties(); + void deferredPropertiesErrors(); void extensionObjects(); void overrideExtensionProperties(); void attachedProperties(); @@ -133,6 +134,7 @@ private slots: void numberAssignment(); void bug1(); + void bug2(); void dynamicCreationCrash(); void regExpBug(); void nullObjectBinding(); @@ -543,6 +545,25 @@ void tst_qdeclarativeecmascript::deferredProperties() QCOMPARE(qmlObject->value(), 19); } +// Check errors on deferred properties are correctly emitted +void tst_qdeclarativeecmascript::deferredPropertiesErrors() +{ + QDeclarativeComponent component(&engine, TEST_FILE("deferredPropertiesErrors.qml")); + MyDeferredObject *object = + qobject_cast<MyDeferredObject *>(component.create()); + QVERIFY(object != 0); + QCOMPARE(object->value(), 0); + QVERIFY(object->objectProperty() == 0); + QVERIFY(object->objectProperty2() == 0); + + QString warning = component.url().toString() + ":6: Unable to assign [undefined] to QObject*"; + QTest::ignoreMessage(QtWarningMsg, qPrintable(warning)); + + qmlExecuteDeferred(object); + + delete object; +} + void tst_qdeclarativeecmascript::extensionObjects() { QDeclarativeComponent component(&engine, TEST_FILE("extensionObjects.qml")); @@ -1231,6 +1252,17 @@ void tst_qdeclarativeecmascript::bug1() delete object; } +void tst_qdeclarativeecmascript::bug2() +{ + QDeclarativeComponent component(&engine); + component.setData("import Qt.test 1.0;\nQPlainTextEdit { width: 100 }", QUrl()); + + QObject *object = component.create(); + QVERIFY(object != 0); + + delete object; +} + // Don't crash in createObject when the component has errors. void tst_qdeclarativeecmascript::dynamicCreationCrash() { diff --git a/tests/auto/declarative/qdeclarativeengine/tst_qdeclarativeengine.cpp b/tests/auto/declarative/qdeclarativeengine/tst_qdeclarativeengine.cpp index ee320aa..b0db771 100644 --- a/tests/auto/declarative/qdeclarativeengine/tst_qdeclarativeengine.cpp +++ b/tests/auto/declarative/qdeclarativeengine/tst_qdeclarativeengine.cpp @@ -297,6 +297,8 @@ void tst_qdeclarativeengine::objectOwnership() { QObject o; QCOMPARE(QDeclarativeEngine::objectOwnership(&o), QDeclarativeEngine::CppOwnership); + QDeclarativeEngine::setObjectOwnership(&o, QDeclarativeEngine::CppOwnership); + QCOMPARE(QDeclarativeEngine::objectOwnership(&o), QDeclarativeEngine::CppOwnership); QDeclarativeEngine::setObjectOwnership(&o, QDeclarativeEngine::JavaScriptOwnership); QCOMPARE(QDeclarativeEngine::objectOwnership(&o), QDeclarativeEngine::JavaScriptOwnership); QDeclarativeEngine::setObjectOwnership(&o, QDeclarativeEngine::CppOwnership); diff --git a/tests/auto/declarative/qdeclarativelanguage/data/assignToNamespace.qml b/tests/auto/declarative/qdeclarativelanguage/data/assignToNamespace.qml index 8eb9768..2f49418 100644 --- a/tests/auto/declarative/qdeclarativelanguage/data/assignToNamespace.qml +++ b/tests/auto/declarative/qdeclarativelanguage/data/assignToNamespace.qml @@ -1,5 +1,5 @@ -import Qt 4.7 as Qt +import Qt 4.7 as Qt47 -Qt.QtObject { - Qt: 10 +Qt47.QtObject { + Qt47: 10 } diff --git a/tests/auto/declarative/qdeclarativelanguage/data/dynamicObjectProperties.qml b/tests/auto/declarative/qdeclarativelanguage/data/dynamicObjectProperties.qml index e870046..c997356 100644 --- a/tests/auto/declarative/qdeclarativelanguage/data/dynamicObjectProperties.qml +++ b/tests/auto/declarative/qdeclarativelanguage/data/dynamicObjectProperties.qml @@ -1,6 +1,6 @@ import Test 1.0 import Qt 4.7 -import Qt 4.7 as Qt +import Qt 4.7 as Qt47 QtObject { property QtObject objectProperty diff --git a/tests/auto/declarative/qdeclarativelanguage/data/lib/com/nokia/installedtest/InstalledTest.qml b/tests/auto/declarative/qdeclarativelanguage/data/lib/com/nokia/installedtest/InstalledTest.qml index 6d33361..303b5a5 100644 --- a/tests/auto/declarative/qdeclarativelanguage/data/lib/com/nokia/installedtest/InstalledTest.qml +++ b/tests/auto/declarative/qdeclarativelanguage/data/lib/com/nokia/installedtest/InstalledTest.qml @@ -1,2 +1,2 @@ -import Qt 4.7 as Qt -Qt.Rectangle {} +import Qt 4.7 as Qt47 +Qt47.Rectangle {} diff --git a/tests/auto/declarative/qdeclarativelanguage/tst_qdeclarativelanguage.cpp b/tests/auto/declarative/qdeclarativelanguage/tst_qdeclarativelanguage.cpp index c39e6f7..ff03005 100644 --- a/tests/auto/declarative/qdeclarativelanguage/tst_qdeclarativelanguage.cpp +++ b/tests/auto/declarative/qdeclarativelanguage/tst_qdeclarativelanguage.cpp @@ -48,12 +48,16 @@ #include <private/qdeclarativeproperty_p.h> #include <private/qdeclarativemetatype_p.h> +#include <private/qdeclarativeglobal_p.h> #include "testtypes.h" #include "../../../shared/util.h" #include "testhttpserver.h" +DEFINE_BOOL_CONFIG_OPTION(qmlCheckTypes, QML_CHECK_TYPES) + + /* This test case covers QML language issues. This covers everything that does not involve evaluating ECMAScript expressions and bindings. @@ -1257,14 +1261,14 @@ void tst_qdeclarativelanguage::importsBuiltin_data() << "import com.nokia.Test 1.11\n" "import com.nokia.Test 1.12\n" "Test {}" - << "TestType2" - << ""; + << (!qmlCheckTypes()?"TestType2":"") + << (!qmlCheckTypes()?"":"Test is ambiguous. Found in com/nokia/Test in version 1.12 and 1.11"); QTest::newRow("multiversion 2") << "import com.nokia.Test 1.11\n" "import com.nokia.Test 1.12\n" "OldTest {}" - << "TestType" - << ""; + << (!qmlCheckTypes()?"TestType":"") + << (!qmlCheckTypes()?"":"OldTest is ambiguous. Found in com/nokia/Test in version 1.12 and 1.11"); QTest::newRow("qualified multiversion 3") << "import com.nokia.Test 1.0 as T0\n" "import com.nokia.Test 1.8 as T8\n" @@ -1312,12 +1316,12 @@ void tst_qdeclarativelanguage::importsLocal_data() QTest::newRow("local import QTBUG-7721 A") << "subdir.Test {}" // no longer allowed (QTBUG-7721) << "" - << "subdir.Test is not a type"; + << "subdir.Test - subdir is not a namespace"; QTest::newRow("local import QTBUG-7721 B") << "import \"subdir\" as X\n" "X.subsubdir.SubTest {}" // no longer allowed (QTBUG-7721) << "" - << "X.subsubdir.SubTest is not a type"; + << "X.subsubdir.SubTest - nested namespaces not allowed"; QTest::newRow("local import as") << "import \"subdir\" as T\n" "T.Test {}" @@ -1332,8 +1336,8 @@ void tst_qdeclarativelanguage::importsLocal_data() << "import \"subdir\"\n" "import com.nokia.Test 1.0\n" "Test {}" - << "TestType" - << ""; + << (!qmlCheckTypes()?"TestType":"") + << (!qmlCheckTypes()?"":"Test is ambiguous. Found in com/nokia/Test and in subdir"); } void tst_qdeclarativelanguage::importsLocal() @@ -1478,46 +1482,52 @@ void tst_qdeclarativelanguage::importsOrder_data() QTest::addColumn<QString>("type"); QTest::addColumn<QString>("error"); + QTest::newRow("double import") << + "import com.nokia.installedtest 1.4\n" + "import com.nokia.installedtest 1.4\n" + "InstalledTest {}" + << (!qmlCheckTypes()?"QDeclarativeText":"") + << (!qmlCheckTypes()?"":"InstalledTest is ambiguous. Found in lib/com/nokia/installedtest in version 1.4 and 1.4"); QTest::newRow("installed import overrides 1") << "import com.nokia.installedtest 1.0\n" "import com.nokia.installedtest 1.4\n" "InstalledTest {}" - << "QDeclarativeText" - << ""; + << (!qmlCheckTypes()?"QDeclarativeText":"") + << (!qmlCheckTypes()?"":"InstalledTest is ambiguous. Found in lib/com/nokia/installedtest in version 1.4 and 1.0"); QTest::newRow("installed import overrides 2") << "import com.nokia.installedtest 1.4\n" "import com.nokia.installedtest 1.0\n" "InstalledTest {}" - << "QDeclarativeRectangle" - << ""; + << (!qmlCheckTypes()?"QDeclarativeRectangle":"") + << (!qmlCheckTypes()?"":"InstalledTest is ambiguous. Found in lib/com/nokia/installedtest in version 1.0 and 1.4"); QTest::newRow("installed import re-overrides 1") << "import com.nokia.installedtest 1.4\n" "import com.nokia.installedtest 1.0\n" "import com.nokia.installedtest 1.4\n" "InstalledTest {}" - << "QDeclarativeText" - << ""; + << (!qmlCheckTypes()?"QDeclarativeText":"") + << (!qmlCheckTypes()?"":"InstalledTest is ambiguous. Found in lib/com/nokia/installedtest in version 1.4 and 1.0"); QTest::newRow("installed import re-overrides 2") << "import com.nokia.installedtest 1.4\n" "import com.nokia.installedtest 1.0\n" "import com.nokia.installedtest 1.4\n" "import com.nokia.installedtest 1.0\n" "InstalledTest {}" - << "QDeclarativeRectangle" - << ""; + << (!qmlCheckTypes()?"QDeclarativeRectangle":"") + << (!qmlCheckTypes()?"":"InstalledTest is ambiguous. Found in lib/com/nokia/installedtest in version 1.0 and 1.4"); QTest::newRow("installed import versus builtin 1") << "import com.nokia.installedtest 1.5\n" "import Qt 4.7\n" "Rectangle {}" - << "QDeclarativeRectangle" - << ""; + << (!qmlCheckTypes()?"QDeclarativeRectangle":"") + << (!qmlCheckTypes()?"":"Rectangle is ambiguous. Found in Qt and in lib/com/nokia/installedtest"); QTest::newRow("installed import versus builtin 2") << "import Qt 4.7\n" "import com.nokia.installedtest 1.5\n" "Rectangle {}" - << "QDeclarativeText" - << ""; + << (!qmlCheckTypes()?"QDeclarativeText":"") + << (!qmlCheckTypes()?"":"Rectangle is ambiguous. Found in lib/com/nokia/installedtest and in Qt"); QTest::newRow("namespaces cannot be overridden by types 1") << "import Qt 4.7 as Rectangle\n" "import com.nokia.installedtest 1.5\n" @@ -1537,8 +1547,8 @@ void tst_qdeclarativelanguage::importsOrder_data() QTest::newRow("local last 2") << "import com.nokia.installedtest 1.0\n" "LocalLast {}" - << "QDeclarativeRectangle" - << ""; // i.e. from com.nokia.installedtest, not data/LocalLast.qml + << (!qmlCheckTypes()?"QDeclarativeRectangle":"")// i.e. from com.nokia.installedtest, not data/LocalLast.qml + << (!qmlCheckTypes()?"":"LocalLast is ambiguous. Found in lib/com/nokia/installedtest and in local directory"); } void tst_qdeclarativelanguage::importsOrder() diff --git a/tests/auto/declarative/qdeclarativelistview/tst_qdeclarativelistview.cpp b/tests/auto/declarative/qdeclarativelistview/tst_qdeclarativelistview.cpp index cab4d52..22eb734 100644 --- a/tests/auto/declarative/qdeclarativelistview/tst_qdeclarativelistview.cpp +++ b/tests/auto/declarative/qdeclarativelistview/tst_qdeclarativelistview.cpp @@ -571,6 +571,7 @@ void tst_QDeclarativeListView::removed(bool animated) // Remove items not visible model.removeItem(18); + qApp->processEvents(); // Confirm items positioned correctly itemCount = findItems<QDeclarativeItem>(viewport, "wrapper").count(); @@ -586,6 +587,7 @@ void tst_QDeclarativeListView::removed(bool animated) listview->setCurrentIndex(10); model.removeItem(1); // post: top item will be at 40 + qApp->processEvents(); // Confirm items positioned correctly for (int i = 2; i < 18; ++i) { diff --git a/tests/auto/declarative/qdeclarativeqt/data/formatting.qml b/tests/auto/declarative/qdeclarativeqt/data/formatting.qml index 59a15929..7f48639 100644 --- a/tests/auto/declarative/qdeclarativeqt/data/formatting.qml +++ b/tests/auto/declarative/qdeclarativeqt/data/formatting.qml @@ -16,4 +16,14 @@ QtObject { property string test8: Qt.formatDateTime(dateTime1) property string test9: Qt.formatDateTime(dateTime1, Qt.DefaultLocaleLongDate) property string test10: Qt.formatDateTime(dateTime1, "M/d/yy H:m:s a") + + // Error cases + property string test11: Qt.formatDate() + property string test12: Qt.formatDate(new Date, new Object) + + property string test13: Qt.formatTime() + property string test14: Qt.formatTime(new Date, new Object) + + property string test15: Qt.formatDateTime() + property string test16: Qt.formatDateTime(new Date, new Object) } diff --git a/tests/auto/declarative/qdeclarativeqt/tst_qdeclarativeqt.cpp b/tests/auto/declarative/qdeclarativeqt/tst_qdeclarativeqt.cpp index f5d5926..7cbd8db 100644 --- a/tests/auto/declarative/qdeclarativeqt/tst_qdeclarativeqt.cpp +++ b/tests/auto/declarative/qdeclarativeqt/tst_qdeclarativeqt.cpp @@ -398,6 +398,21 @@ void tst_qdeclarativeqt::consoleLog() void tst_qdeclarativeqt::formatting() { QDeclarativeComponent component(&engine, TEST_FILE("formatting.qml")); + + QString warning1 = component.url().toString() + ":22: Error: Qt.formatDate(): Invalid date format"; + QString warning2 = component.url().toString() + ":21: Error: Qt.formatDate(): Invalid arguments"; + QString warning3 = component.url().toString() + ":28: Error: Qt.formatDateTime(): Invalid datetime format"; + QString warning4 = component.url().toString() + ":27: Error: Qt.formatDateTime(): Invalid arguments"; + QString warning5 = component.url().toString() + ":25: Error: Qt.formatTime(): Invalid time format"; + QString warning6 = component.url().toString() + ":24: Error: Qt.formatTime(): Invalid arguments"; + + QTest::ignoreMessage(QtWarningMsg, qPrintable(warning1)); + QTest::ignoreMessage(QtWarningMsg, qPrintable(warning2)); + QTest::ignoreMessage(QtWarningMsg, qPrintable(warning3)); + QTest::ignoreMessage(QtWarningMsg, qPrintable(warning4)); + QTest::ignoreMessage(QtWarningMsg, qPrintable(warning5)); + QTest::ignoreMessage(QtWarningMsg, qPrintable(warning6)); + QObject *object = component.create(); QVERIFY(object != 0); diff --git a/tests/auto/declarative/qdeclarativetextinput/tst_qdeclarativetextinput.cpp b/tests/auto/declarative/qdeclarativetextinput/tst_qdeclarativetextinput.cpp index fcd7527..83ebe6c 100644 --- a/tests/auto/declarative/qdeclarativetextinput/tst_qdeclarativetextinput.cpp +++ b/tests/auto/declarative/qdeclarativetextinput/tst_qdeclarativetextinput.cpp @@ -644,21 +644,38 @@ void tst_qdeclarativetextinput::echoMode() QVERIFY(input != 0); QTRY_VERIFY(input->hasFocus() == true); QString initial = input->text(); + Qt::InputMethodHints ref; QCOMPARE(initial, QLatin1String("ABCDefgh")); QCOMPARE(input->echoMode(), QDeclarativeTextInput::Normal); QCOMPARE(input->displayText(), input->text()); + //Normal + ref &= ~Qt::ImhHiddenText; + ref &= ~(Qt::ImhNoAutoUppercase | Qt::ImhNoPredictiveText); + QCOMPARE(input->inputMethodHints(), ref); input->setEchoMode(QDeclarativeTextInput::NoEcho); QCOMPARE(input->text(), initial); QCOMPARE(input->displayText(), QLatin1String("")); QCOMPARE(input->passwordCharacter(), QLatin1String("*")); + //NoEcho + ref |= Qt::ImhHiddenText; + ref |= (Qt::ImhNoAutoUppercase | Qt::ImhNoPredictiveText); + QCOMPARE(input->inputMethodHints(), ref); input->setEchoMode(QDeclarativeTextInput::Password); + //Password + ref |= Qt::ImhHiddenText; + ref |= (Qt::ImhNoAutoUppercase | Qt::ImhNoPredictiveText); QCOMPARE(input->text(), initial); QCOMPARE(input->displayText(), QLatin1String("********")); + QCOMPARE(input->inputMethodHints(), ref); input->setPasswordCharacter(QChar('Q')); QCOMPARE(input->passwordCharacter(), QLatin1String("Q")); QCOMPARE(input->text(), initial); QCOMPARE(input->displayText(), QLatin1String("QQQQQQQQ")); input->setEchoMode(QDeclarativeTextInput::PasswordEchoOnEdit); + //PasswordEchoOnEdit + ref &= ~Qt::ImhHiddenText; + ref |= (Qt::ImhNoAutoUppercase | Qt::ImhNoPredictiveText); + QCOMPARE(input->inputMethodHints(), ref); QCOMPARE(input->text(), initial); QCOMPARE(input->displayText(), QLatin1String("QQQQQQQQ")); QTest::keyPress(canvas, Qt::Key_A);//Clearing previous entry is part of PasswordEchoOnEdit diff --git a/tests/auto/macnativeevents/nativeeventlist.cpp b/tests/auto/macnativeevents/nativeeventlist.cpp index d5d7b95..1a90ee0 100644 --- a/tests/auto/macnativeevents/nativeeventlist.cpp +++ b/tests/auto/macnativeevents/nativeeventlist.cpp @@ -88,11 +88,6 @@ void NativeEventList::append(int waitMs, QNativeEvent *event) eventList.append(QPair<int, QNativeEvent *>(waitMs, event)); } -void NativeEventList::append(int waitMs) -{ - eventList.append(QPair<int, QNativeEvent *>(waitMs, 0)); -} - void NativeEventList::play(Playback playback) { waitNextEvent(); diff --git a/tests/auto/macnativeevents/nativeeventlist.h b/tests/auto/macnativeevents/nativeeventlist.h index 688665d..efcca43 100644 --- a/tests/auto/macnativeevents/nativeeventlist.h +++ b/tests/auto/macnativeevents/nativeeventlist.h @@ -57,7 +57,6 @@ class NativeEventList : public QObject void append(QNativeEvent *event); void append(int waitMs, QNativeEvent *event = 0); - void append(int waitMs); void play(Playback playback = WaitUntilFinished); void stop(); diff --git a/tests/auto/qgraphicsitem/tst_qgraphicsitem.cpp b/tests/auto/qgraphicsitem/tst_qgraphicsitem.cpp index e2f7f18..055ae80 100644 --- a/tests/auto/qgraphicsitem/tst_qgraphicsitem.cpp +++ b/tests/auto/qgraphicsitem/tst_qgraphicsitem.cpp @@ -63,6 +63,7 @@ #include <QGraphicsEffect> #include <QInputContext> #include <QPushButton> +#include <QLineEdit> #include "../../shared/util.h" @@ -445,6 +446,7 @@ private slots: void QT_2653_fullUpdateDiscardingOpacityUpdate(); void QT_2649_focusScope(); void sortItemsWhileAdding(); + void doNotMarkFullUpdateIfNotInScene(); private: QList<QGraphicsItem *> paintedItems; @@ -945,8 +947,52 @@ class ImhTester : public QGraphicsItem void tst_QGraphicsItem::inputMethodHints() { - ImhTester item; - QCOMPARE(item.inputMethodHints(), Qt::ImhNone); + ImhTester *item = new ImhTester; + item->setFlag(QGraphicsItem::ItemAcceptsInputMethod, true); + item->setFlag(QGraphicsItem::ItemIsFocusable, true); + QCOMPARE(item->inputMethodHints(), Qt::ImhNone); + ImhTester *item2 = new ImhTester; + item2->setFlag(QGraphicsItem::ItemAcceptsInputMethod, true); + item2->setFlag(QGraphicsItem::ItemIsFocusable, true); + Qt::InputMethodHints imHints = item2->inputMethodHints(); + imHints |= Qt::ImhHiddenText; + item2->setInputMethodHints(imHints); + QGraphicsScene scene; + scene.addItem(item); + scene.addItem(item2); + QGraphicsView view(&scene); + QApplication::setActiveWindow(&view); + view.show(); + QTest::qWaitForWindowShown(&view); + item->setFocus(); + QTRY_VERIFY(item->hasFocus()); + QCOMPARE(view.inputMethodHints(), item->inputMethodHints()); + item2->setFocus(); + QTRY_VERIFY(item2->hasFocus()); + QCOMPARE(view.inputMethodHints(), item2->inputMethodHints()); + item->setFlag(QGraphicsItem::ItemAcceptsInputMethod, false); + item->setFocus(); + QTRY_VERIFY(item->hasFocus()); + //Focus has changed but the new item doesn't accept input method, no hints. + QCOMPARE(view.inputMethodHints(), 0); + item2->setFocus(); + QTRY_VERIFY(item2->hasFocus()); + QCOMPARE(view.inputMethodHints(), item2->inputMethodHints()); + imHints = item2->inputMethodHints(); + imHints |= (Qt::ImhNoAutoUppercase | Qt::ImhNoPredictiveText); + item2->setInputMethodHints(imHints); + QCOMPARE(view.inputMethodHints(), item2->inputMethodHints()); + QGraphicsProxyWidget *widget = new QGraphicsProxyWidget; + QLineEdit *edit = new QLineEdit; + edit->setEchoMode(QLineEdit::Password); + scene.addItem(widget); + widget->setFocus(); + QTRY_VERIFY(widget->hasFocus()); + //No widget on the proxy, so no hints + QCOMPARE(view.inputMethodHints(), 0); + widget->setWidget(edit); + //View should match with the line edit + QCOMPARE(view.inputMethodHints(), edit->inputMethodHints()); } void tst_QGraphicsItem::toolTip() @@ -10055,6 +10101,9 @@ void tst_QGraphicsItem::updateMicroFocus() QApplication::setActiveWindow(&parent); QTest::qWaitForWindowShown(&parent); QTRY_COMPARE(QApplication::activeWindow(), static_cast<QWidget *>(&parent)); + //We reset the number of updates that happened previously (initialisation) + ic.nbUpdates = 0; + ic2.nbUpdates = 0; input.doUpdateMicroFocus(); QApplication::processEvents(); QTRY_COMPARE(ic.nbUpdates, 1); @@ -10383,5 +10432,51 @@ void tst_QGraphicsItem::sortItemsWhileAdding() grandParent.setParentItem(&grandGrandParent); } +void tst_QGraphicsItem::doNotMarkFullUpdateIfNotInScene() +{ + struct Item : public QGraphicsTextItem + { + int painted; + void paint(QPainter *painter, const QStyleOptionGraphicsItem *opt, QWidget *wid) + { + painted++; + QGraphicsTextItem::paint(painter, opt, wid); + } + }; + QGraphicsScene scene; + MyGraphicsView view(&scene); + Item *item = new Item; + item->painted = 0; + item->setPlainText("Grandparent"); + Item *item2 = new Item; + item2->setPlainText("parent"); + item2->painted = 0; + Item *item3 = new Item; + item3->setPlainText("child"); + item3->painted = 0; + QGraphicsOpacityEffect *effect = new QGraphicsOpacityEffect; + effect->setOpacity(0.5); + item2->setGraphicsEffect(effect); + item3->setParentItem(item2); + item2->setParentItem(item); + scene.addItem(item); + view.show(); + QTest::qWaitForWindowShown(&view); + QTRY_COMPARE(view.repaints, 1); + QTRY_COMPARE(item->painted, 1); + QTRY_COMPARE(item2->painted, 1); + QTRY_COMPARE(item3->painted, 1); + item2->update(); + QApplication::processEvents(); + QTRY_COMPARE(item->painted, 2); + QTRY_COMPARE(item2->painted, 2); + QTRY_COMPARE(item3->painted, 2); + item2->update(); + QApplication::processEvents(); + QTRY_COMPARE(item->painted, 3); + QTRY_COMPARE(item2->painted, 3); + QTRY_COMPARE(item3->painted, 3); +} + QTEST_MAIN(tst_QGraphicsItem) #include "tst_qgraphicsitem.moc" diff --git a/tools/qml/loggerwidget.cpp b/tools/qml/loggerwidget.cpp index 015d1b0..9eca4a6 100644 --- a/tools/qml/loggerwidget.cpp +++ b/tools/qml/loggerwidget.cpp @@ -50,7 +50,7 @@ LoggerWidget::LoggerWidget(QWidget *parent) : m_keepClosed(false) { setAttribute(Qt::WA_QuitOnClose, false); - setWindowTitle(tr("Qt Declarative UI Viewer - Logger")); + setWindowTitle(tr("Logger")); } void LoggerWidget::append(const QString &msg) diff --git a/tools/qml/main.cpp b/tools/qml/main.cpp index cba5650..9ccc3d2 100644 --- a/tools/qml/main.cpp +++ b/tools/qml/main.cpp @@ -198,7 +198,7 @@ int main(int argc, char ** argv) #endif QApplication app(argc, argv); - app.setApplicationName("viewer"); + app.setApplicationName("QtQmlRuntime"); app.setOrganizationName("Nokia"); app.setOrganizationDomain("nokia.com"); @@ -281,7 +281,7 @@ int main(int argc, char ** argv) if (lastArg) usage(); app.setStartDragDistance(QString(argv[++i]).toInt()); } else if (arg == QLatin1String("-v") || arg == QLatin1String("-version")) { - qWarning("Qt Declarative UI Viewer version %s", QT_VERSION_STR); + qWarning("Qt Qml Runtime version %s", QT_VERSION_STR); exit(0); } else if (arg == "-translation") { if (lastArg) usage(); @@ -389,8 +389,6 @@ int main(int argc, char ** argv) usage(); } - viewer->addLibraryPath(QCoreApplication::applicationDirPath()); - foreach (QString lib, imports) viewer->addLibraryPath(lib); diff --git a/tools/qml/qmlruntime.cpp b/tools/qml/qmlruntime.cpp index 87a4d21..008f163 100644 --- a/tools/qml/qmlruntime.cpp +++ b/tools/qml/qmlruntime.cpp @@ -341,14 +341,14 @@ private: data.append("\n"); } } - QSettings settings("Nokia", "QtQmlViewer"); + QSettings settings; settings.setValue("Cookies",data); } void load() { QMutexLocker lock(&mutex); - QSettings settings("Nokia", "QtQmlViewer"); + QSettings settings; QByteArray data = settings.value("Cookies").toByteArray(); setAllCookies(QNetworkCookie::parseCookies(data)); } @@ -466,6 +466,7 @@ QDeclarativeViewer::QDeclarativeViewer(QWidget *parent, Qt::WindowFlags flags) , m_scriptOptions(0), tester(0), useQmlFileBrowser(true) { QDeclarativeViewer::registerTypes(); + setWindowTitle(tr("Qt Qml Runtime")); devicemode = false; skin = 0; @@ -537,6 +538,14 @@ QDeclarativeViewer::~QDeclarativeViewer() delete namFactory; } +int QDeclarativeViewer::menuBarHeight() const +{ + if (!(windowFlags() & Qt::FramelessWindowHint)) + return menuBar()->height(); + else + return 0; // don't create menu +} + QMenuBar *QDeclarativeViewer::menuBar() const { #if !defined(Q_OS_SYMBIAN) @@ -916,7 +925,7 @@ void QDeclarativeViewer::statusChanged() initialSize = canvas->sizeHint(); if (canvas->resizeMode() == QDeclarativeView::SizeRootObjectToView) { QSize newWindowSize = initialSize; - newWindowSize.setHeight(newWindowSize.height()+menuBar()->height()); + newWindowSize.setHeight(newWindowSize.height()+menuBarHeight()); updateSizeHints(); resize(newWindowSize); } @@ -938,7 +947,7 @@ bool QDeclarativeViewer::open(const QString& file_or_url) url = QUrl::fromLocalFile(fi.absoluteFilePath()); else url = QUrl(file_or_url); - setWindowTitle(tr("%1 - Qt Declarative UI Viewer").arg(file_or_url)); + setWindowTitle(tr("%1 - Qt Qml Runtime").arg(file_or_url)); if (!m_script.isEmpty()) tester = new QDeclarativeTester(m_script, m_scriptOptions, canvas); @@ -1065,8 +1074,10 @@ void QDeclarativeViewer::setSkin(const QString& skinDirOrName) } else if (skin) { skin = 0; clearMask(); - menuBar()->clear(); - createMenu(menuBar(),0); + if ((windowFlags() & Qt::FramelessWindowHint)) { + menuBar()->clear(); + createMenu(menuBar(),0); + } canvas->setParent(this, Qt::SubWindow); setParent(0,windowFlags()); // recreate mb->show(); @@ -1079,7 +1090,7 @@ void QDeclarativeViewer::setSkin(const QString& skinDirOrName) canvas->setFixedSize(initialSize); } QSize newWindowSize = canvas->size(); - newWindowSize.setHeight(newWindowSize.height()+menuBar()->height()); + newWindowSize.setHeight(newWindowSize.height()+menuBarHeight()); resize(newWindowSize); show(); } @@ -1401,9 +1412,8 @@ void QDeclarativeViewer::updateSizeHints() { if (canvas->resizeMode() == QDeclarativeView::SizeViewToRootObject) { QSize newWindowSize = canvas->sizeHint(); - if (!skin) { - newWindowSize.setHeight(newWindowSize.height()+menuBar()->height()); - } + if (!skin) + newWindowSize.setHeight(newWindowSize.height()+menuBarHeight()); if (!isFullScreen() && !isMaximized()) { resize(newWindowSize); setFixedSize(newWindowSize); @@ -1430,7 +1440,7 @@ void QDeclarativeViewer::registerTypes() if (!registered) { // registering only for exposing the DeviceOrientation::Orientation enum - qmlRegisterUncreatableType<DeviceOrientation>("Qt",4,6,"Orientation",""); + qmlRegisterUncreatableType<DeviceOrientation>("Qt",4,7,"Orientation",""); registered = true; } } diff --git a/tools/qml/qmlruntime.h b/tools/qml/qmlruntime.h index a00a703..2a0a07d 100644 --- a/tools/qml/qmlruntime.h +++ b/tools/qml/qmlruntime.h @@ -146,6 +146,7 @@ private slots: private: QString getVideoFileName(); + int menuBarHeight() const; PreviewDeviceSkin *skin; QSize skinscreensize; diff --git a/translations/qt_pl.ts b/translations/qt_pl.ts index db7d2c5..dd8a160 100644 --- a/translations/qt_pl.ts +++ b/translations/qt_pl.ts @@ -2,6 +2,27 @@ <!DOCTYPE TS> <TS version="2.0" language="pl"> <context> + <name>CloseButton</name> + <message> + <location filename="../src/gui/widgets/qtabbar.cpp" line="+2266"/> + <source>Close Tab</source> + <translation>Zamknij kartę</translation> + </message> +</context> +<context> + <name>FakeReply</name> + <message> + <location filename="../src/3rdparty/webkit/WebKit/qt/tests/qwebframe/tst_qwebframe.cpp" line="+2217"/> + <source>Fake error !</source> + <translation>Fałszywy błąd!</translation> + </message> + <message> + <location line="+3"/> + <source>Invalid URL</source> + <translation>Niepoprawny URL</translation> + </message> +</context> +<context> <name>MAC_APPLICATION_MENU</name> <message> <location filename="../src/gui/kernel/qapplication.cpp" line="+2316"/> @@ -40,27 +61,6 @@ </message> </context> <context> - <name>CloseButton</name> - <message> - <location filename="../src/gui/widgets/qtabbar.cpp" line="+2264"/> - <source>Close Tab</source> - <translation>Zamknij kartę</translation> - </message> -</context> -<context> - <name>FakeReply</name> - <message> - <location filename="../src/3rdparty/webkit/WebKit/qt/tests/qwebframe/tst_qwebframe.cpp" line="+2199"/> - <source>Fake error !</source> - <translation type="unfinished"></translation> - </message> - <message> - <location line="+3"/> - <source>Invalid URL</source> - <translation>Niepoprawny URL</translation> - </message> -</context> -<context> <name>Phonon::</name> <message> <location filename="../src/3rdparty/phonon/phonon/phononnamespace.cpp" line="+55"/> @@ -96,25 +96,32 @@ <context> <name>Phonon::AudioOutput</name> <message> - <location filename="../src/3rdparty/phonon/phonon/audiooutput.cpp" line="+385"/> + <location filename="../src/3rdparty/phonon/phonon/audiooutput.cpp" line="+444"/> + <location line="+34"/> <source><html>The audio playback device <b>%1</b> does not work.<br/>Falling back to <b>%2</b>.</html></source> <translation><html>Urządzenie dźwiękowe <b>%1</b> nie działa.<br/>Przywracanie do <b>%2</b>.</html></translation> </message> <message> - <location line="+13"/> + <location line="-21"/> <source><html>Switching to the audio playback device <b>%1</b><br/>which just became available and has higher preference.</html></source> <translation><html>Przełączanie na urządzenie dźwiękowe <b>%1</b><br/>które właśnie stało się dostępne i ma wyższy priorytet.</html></translation> </message> <message> <location line="+3"/> + <location line="+14"/> <source>Revert back to device '%1'</source> <translation>Przywróć do urządzenia '%1'</translation> </message> + <message> + <location line="-3"/> + <source><html>Switching to the audio playback device <b>%1</b><br/>which has higher preference or is specifically configured for this stream.</html></source> + <translation type="unfinished"></translation> + </message> </context> <context> <name>Phonon::Gstreamer::Backend</name> <message> - <location filename="../src/3rdparty/phonon/gstreamer/backend.cpp" line="+182"/> + <location filename="../src/3rdparty/phonon/gstreamer/backend.cpp" line="+188"/> <source>Warning: You do not seem to have the package gstreamer0.10-plugins-good installed. Some video features have been disabled.</source> <translation>Ostrzeżenie: Wygląda na to, że pakiet gstreamer0.10-plugins-good nie jest zainstalowany w tym systemie. @@ -131,7 +138,7 @@ Obsługa dźwięku i wideo została wyłączona</translation> <context> <name>Phonon::Gstreamer::MediaObject</name> <message> - <location filename="../src/3rdparty/phonon/gstreamer/mediaobject.cpp" line="+90"/> + <location filename="../src/3rdparty/phonon/gstreamer/mediaobject.cpp" line="+93"/> <source>Cannot start playback. Check your GStreamer installation and make sure you @@ -142,29 +149,39 @@ Sprawdź instalację Gstreamer i upewnij się że zainstalowałeś libgstreamer-plugins-base.</translation> </message> <message> - <location line="+113"/> + <location line="+129"/> + <source>Missing codec helper script assistant.</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+2"/> + <source>Plugin codec installation failed for codec: %0</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+11"/> <source>A required codec is missing. You need to install the following codec(s) to play this content: %0</source> <translation>Brak wymaganego kodeka. Aby odtworzyć zawartość musisz zainstalować poniższy kodek: %0</translation> </message> <message> - <location line="+702"/> - <location line="+8"/> - <location line="+15"/> - <location line="+26"/> + <location line="+730"/> <location line="+6"/> - <location line="+19"/> - <location line="+339"/> + <location line="+13"/> + <location line="+24"/> + <location line="+6"/> + <location line="+18"/> + <location line="+434"/> <location line="+24"/> <source>Could not open media source.</source> <translation>Nie można otworzyć źródła mediów.</translation> </message> <message> - <location line="-424"/> + <location line="-514"/> <source>Invalid source type.</source> <translation>Niepoprawny typ źródła.</translation> </message> <message> - <location line="+398"/> + <location line="+488"/> <source>Could not locate media source.</source> <translation>Nie można znaleźć źródła mediów.</translation> </message> @@ -182,7 +199,7 @@ zainstalowałeś libgstreamer-plugins-base.</translation> <context> <name>Phonon::MMF</name> <message> - <location filename="../src/3rdparty/phonon/mmf/audiooutput.cpp" line="+98"/> + <location filename="../src/3rdparty/phonon/mmf/audiooutput.cpp" line="+103"/> <source>Audio Output</source> <translation>Wyjście dźwięku</translation> </message> @@ -191,60 +208,341 @@ zainstalowałeś libgstreamer-plugins-base.</translation> <source>The audio output device</source> <translation>Wyjściowe urządzenie dźwiękowe</translation> </message> -</context> -<context> - <name>Phonon::MMF::AudioEqualizer</name> <message> - <location filename="../src/3rdparty/phonon/mmf/audioequalizer.cpp" line="+75"/> - <source>Frequency band, %1 Hz</source> - <translation>Częstotliwość środkowa, %1 Hz</translation> + <location filename="../src/3rdparty/phonon/mmf/utils.cpp" line="+89"/> + <source>No error</source> + <translation>Brak błędu</translation> </message> -</context> -<context> - <name>Phonon::MMF::EffectFactory</name> <message> - <location filename="../src/3rdparty/phonon/mmf/effectfactory.cpp" line="+65"/> - <source>Audio Equalizer</source> - <translation>Korektor graficzny</translation> + <location line="+2"/> + <source>Not found</source> + <translation>Nie znaleziono</translation> </message> <message> <location line="+2"/> - <source>Bass Boost</source> - <translation>Wzmocnienie basów</translation> + <source>Out of memory</source> + <translation>Brak pamięci</translation> </message> <message> <location line="+2"/> - <source>Distance Attenuation</source> - <translation type="unfinished"></translation> + <source>Not supported</source> + <translation>Nieobsługiwane</translation> + </message> + <message> + <location line="+2"/> + <source>Overflow</source> + <translation>Przepełnienie</translation> </message> <message> <location line="+2"/> + <source>Underflow</source> + <translation>Niedopełnienie</translation> + </message> + <message> <location line="+2"/> - <source>Environmental Reverb</source> - <translation>Pogłos środowiskowy</translation> + <source>Already exists</source> + <translation>Już istnieje</translation> </message> <message> <location line="+2"/> - <source>Loudness</source> - <translation>Głośność</translation> + <source>Path not found</source> + <translation>Nie znaleziono ścieżki</translation> </message> <message> <location line="+2"/> - <source>Source Orientation</source> - <translation type="unfinished"></translation> + <source>In use</source> + <translation>W użyciu</translation> </message> <message> <location line="+2"/> - <source>Stereo Widening</source> - <translation type="unfinished"></translation> + <source>Not ready</source> + <translation>Brak gotowości</translation> + </message> + <message> + <location line="+2"/> + <source>Access denied</source> + <translation>Odmowa dostępu</translation> + </message> + <message> + <location line="+2"/> + <source>Could not connect</source> + <translation>Nie można połączyć</translation> + </message> + <message> + <location line="+2"/> + <source>Disconnected</source> + <translation>Rozłączono</translation> + </message> + <message> + <location line="+2"/> + <source>Permission denied</source> + <translation>Brak uprawnień</translation> + </message> + <message> + <location line="+4"/> + <source>Insufficient bandwidth</source> + <translation>Niewystarczająca szerokość pasma</translation> + </message> + <message> + <location line="+3"/> + <source>Network unavailable</source> + <translation>Sieć niedostępna</translation> + </message> + <message> + <location line="+4"/> + <source>Network communication error</source> + <translation>Błąd komunikacji sieciowej</translation> + </message> + <message> + <location line="+2"/> + <source>Streaming not supported</source> + <translation>Transmisje strumieniowe nie są obsługiwane</translation> + </message> + <message> + <location line="+2"/> + <source>Server alert</source> + <translation>Ostrzeżenie serwera</translation> + </message> + <message> + <location line="+2"/> + <source>Invalid protocol</source> + <translation>Nieprawidłowy protokół</translation> + </message> + <message> + <location line="+2"/> + <source>Invalid URL</source> + <translation>Nieprawidłowy adres URL</translation> + </message> + <message> + <location line="+2"/> + <source>Multicast error</source> + <translation>Błąd multiemisji</translation> + </message> + <message> + <location line="+3"/> + <source>Proxy server error</source> + <translation>Błąd serwera pośredniczącego</translation> + </message> + <message> + <location line="+2"/> + <source>Proxy server not supported</source> + <translation>Nieobsługiwany serwer pośredniczący</translation> + </message> + <message> + <location line="+2"/> + <source>Audio output error</source> + <translation>Błąd wyjściowego sygnału dźwiękowego</translation> + </message> + <message> + <location line="+2"/> + <source>Video output error</source> + <translation>Błąd wyjściowego sygnału wideo</translation> + </message> + <message> + <location line="+2"/> + <source>Decoder error</source> + <translation>Błąd dekodera</translation> + </message> + <message> + <location line="+2"/> + <source>Audio or video components could not be played</source> + <translation>Nie można odtworzyć dźwięku lub wideo</translation> + </message> + <message> + <location line="+2"/> + <source>DRM error</source> + <translation>Błąd DRM</translation> + </message> + <message> + <location line="+15"/> + <source>Unknown error (%1)</source> + <translation>Nieznany błąd (%1)</translation> + </message> +</context> +<context> + <name>Phonon::MMF::AbstractMediaPlayer</name> + <message> + <location filename="../src/3rdparty/phonon/mmf/abstractmediaplayer.cpp" line="+73"/> + <source>Not ready to play</source> + <translation>Brak gotowości odtwarzania</translation> + </message> + <message> + <location line="+161"/> + <location line="+10"/> + <source>Error opening file</source> + <translation>Błąd otwierania pliku</translation> + </message> + <message> + <location line="+4"/> + <source>Error opening URL</source> + <translation>Błąd otwierania adresu URL</translation> + </message> + <message> + <location line="+83"/> + <source>Setting volume failed</source> + <translation>Ustawienie głośności zakończone błędem</translation> + </message> + <message> + <location line="+45"/> + <source>Loading clip failed</source> + <translation>Załadowanie klipu zakończone błędem</translation> + </message> + <message> + <location line="+24"/> + <source>Playback complete</source> + <translation>Zakończono odtwarzanie</translation> + </message> +</context> +<context> + <name>Phonon::MMF::AbstractVideoPlayer</name> + <message> + <location filename="../src/3rdparty/phonon/mmf/abstractvideoplayer.cpp" line="+108"/> + <source>Pause failed</source> + <translation>Zatrzymanie zakończone błędem</translation> + </message> + <message> + <location line="+16"/> + <source>Seek failed</source> + <translation>Wyszukiwanie zakończone błędem</translation> + </message> + <message> + <location line="+54"/> + <source>Getting position failed</source> + <translation>Ustalanie pozycji zakończone błędem</translation> + </message> + <message> + <location line="+66"/> + <source>Opening clip failed</source> + <translation>Otwieranie klipu zakończone błędem</translation> + </message> +</context> +<context> + <name>Phonon::MMF::AudioEqualizer</name> + <message> + <location filename="../src/3rdparty/phonon/mmf/audioequalizer.cpp" line="+92"/> + <source>%1 Hz</source> + <translation>%1 Hz</translation> + </message> +</context> +<context> + <name>Phonon::MMF::AudioPlayer</name> + <message> + <location filename="../src/3rdparty/phonon/mmf/audioplayer.cpp" line="+173"/> + <source>Getting position failed</source> + <translation>Ustalanie pozycji zakończone błędem</translation> + </message> +</context> +<context> + <name>Phonon::MMF::DsaVideoPlayer</name> + <message> + <location filename="../src/3rdparty/phonon/mmf/videoplayer_dsa.cpp" line="+238"/> + <location line="+15"/> + <location line="+8"/> + <location line="+22"/> + <location line="+22"/> + <source>Video display error</source> + <translation type="unfinished">Błąd wyświetlacza wideo</translation> + </message> +</context> +<context> + <name>Phonon::MMF::EffectFactory</name> + <message> + <location filename="../src/3rdparty/phonon/mmf/effectfactory.cpp" line="+181"/> + <source>Enabled</source> + <translation>Włączono</translation> + </message> +</context> +<context> + <name>Phonon::MMF::EnvironmentalReverb</name> + <message> + <location filename="../src/3rdparty/phonon/mmf/environmentalreverb.cpp" line="+146"/> + <source>Decay HF ratio (%)</source> + <extracomment>DecayHFRatio: Ratio of high-frequency decay time to the value specified by DecayTime.</extracomment> + <translation>Współczynnik zanikania HF (%)</translation> + </message> + <message> + <location line="+6"/> + <source>Decay time (ms)</source> + <extracomment>DecayTime: Time over which reverberation is diminished.</extracomment> + <translation>Czas zanikania (ms)</translation> + </message> + <message> + <location line="+7"/> + <source>Density (%)</source> + <extracomment>Density Delay between first and subsequent reflections. Note that the S60 platform documentation does not make clear the distinction between this value and the Diffusion value.</extracomment> + <translation>Gęstość (%)</translation> + </message> + <message> + <location line="+6"/> + <source>Diffusion (%)</source> + <extracomment>Diffusion: Delay between first and subsequent reflections. Note that the S60 platform documentation does not make clear the distinction between this value and the Density value.</extracomment> + <translation>Rozpraszanie (%)</translation> + </message> + <message> + <location line="+5"/> + <source>Reflections delay (ms)</source> + <extracomment>ReflectionsDelay: Amount of delay between the arrival the direct path from the source and the arrival of the first reflection.</extracomment> + <translation>Opóźnienie odbić (ms)</translation> + </message> + <message> + <location line="+7"/> + <source>Reflections level (mB)</source> + <extracomment>ReflectionsLevel: Amplitude of reflections. This value is corrected by the RoomLevel to give the final reflection amplitude.</extracomment> + <translation>Poziom odbić (mB)</translation> + </message> + <message> + <location line="+7"/> + <source>Reverb delay (ms)</source> + <extracomment>ReverbDelay: Amount of time between arrival of the first reflection and start of the late reverberation.</extracomment> + <translation>Opóźnienie pogłosu (ms)</translation> + </message> + <message> + <location line="+8"/> + <source>Reverb level (mB)</source> + <extracomment>ReverbLevel Amplitude of reverberations. This value is corrected by the RoomLevel to give the final reverberation amplitude.</extracomment> + <translation>Poziom pogłosu (mB)</translation> + </message> + <message> + <location line="+7"/> + <source>Room HF level</source> + <extracomment>RoomHFLevel: Amplitude of low-pass filter used to attenuate the high frequency component of reflected sound.</extracomment> + <translation>Poziom HF pomieszczenia</translation> + </message> + <message> + <location line="+6"/> + <source>Room level (mB)</source> + <extracomment>RoomLevel: Master volume control for all reflected sound.</extracomment> + <translation>Poziom pomieszczenia (mB)</translation> </message> </context> <context> <name>Phonon::MMF::MediaObject</name> <message> - <location filename="../src/3rdparty/phonon/mmf/mediaobject.cpp" line="+291"/> - <source>Media type could not be determined</source> - <translation>Nie można określić typu mediów</translation> + <location filename="../src/3rdparty/phonon/mmf/mediaobject.cpp" line="+276"/> + <source>Error opening source: type not supported</source> + <translation>Błąd otwierania źródła: typ źródła nie jest obsługiwany</translation> + </message> + <message> + <location line="+18"/> + <source>Error opening source: media type could not be determined</source> + <translation>Błąd otwierania źródła: nie można określić typu multimediów</translation> + </message> +</context> +<context> + <name>Phonon::MMF::StereoWidening</name> + <message> + <location filename="../src/3rdparty/phonon/mmf/stereowidening.cpp" line="+79"/> + <source>Level (%)</source> + <translation>Poziom (%)</translation> + </message> +</context> +<context> + <name>Phonon::MMF::SurfaceVideoPlayer</name> + <message> + <location filename="../src/3rdparty/phonon/mmf/videoplayer_surface.cpp" line="+126"/> + <location line="+16"/> + <source>Video display error</source> + <translation type="unfinished">Błąd wyświetlacza wideo</translation> </message> </context> <context> @@ -314,7 +612,7 @@ zainstalowałeś libgstreamer-plugins-base.</translation> <context> <name>Q3FileDialog</name> <message> - <location filename="../src/qt3support/dialogs/q3filedialog.cpp" line="+4493"/> + <location filename="../src/qt3support/dialogs/q3filedialog.cpp" line="+4501"/> <source>%1 File not found. Check path and filename.</source> @@ -585,7 +883,7 @@ Sprawdź ścieżkę i nazwę pliku.</translation> <message> <location line="+2"/> <source>Symlink to Special</source> - <translation>Specjalny dowiązanie symboliczne</translation> + <translation>Dowiązanie symboliczne do pliku specjalnego</translation> </message> <message> <location line="+1551"/> @@ -951,8 +1249,8 @@ na <context> <name>QAbstractSocket</name> <message> - <location filename="../src/network/socket/qabstractsocket.cpp" line="+949"/> - <location filename="../src/network/socket/qhttpsocketengine.cpp" line="+646"/> + <location filename="../src/network/socket/qabstractsocket.cpp" line="+966"/> + <location filename="../src/network/socket/qhttpsocketengine.cpp" line="+632"/> <location filename="../src/network/socket/qsocks5socketengine.cpp" line="+691"/> <source>Connection refused</source> <translation>Połączenie odrzucone</translation> @@ -971,19 +1269,20 @@ na <translation>Przekroczony czas połączenia</translation> </message> <message> - <location line="-555"/> - <location line="+805"/> - <location line="+208"/> + <location line="-559"/> + <location line="+809"/> + <location line="+220"/> <source>Operation on socket is not supported</source> - <translation>Operacja na gnieździe nieobsługiwana</translation> + <translation>Operacja na gnieździe nie jest obsługiwana</translation> </message> <message> - <location line="+580"/> + <location line="+583"/> <source>Socket is not connected</source> <translation>Gniazdo nie jest podłączone</translation> </message> <message> - <location line="-380"/> + <location filename="../src/network/access/qhttpnetworkconnection.cpp" line="+614"/> + <location filename="../src/network/socket/qabstractsocket.cpp" line="-380"/> <source>Socket operation timed out</source> <translation>Przekroczony czas operacji gniazda</translation> </message> @@ -996,7 +1295,7 @@ na <context> <name>QAbstractSpinBox</name> <message> - <location filename="../src/gui/widgets/qabstractspinbox.cpp" line="+1219"/> + <location filename="../src/gui/widgets/qabstractspinbox.cpp" line="+1265"/> <source>Step &down</source> <translation>Krok w &dół</translation> </message> @@ -1042,7 +1341,7 @@ na <translation>Niekompatybilność biblioteki Qt</translation> </message> <message> - <location filename="../src/gui/kernel/qapplication.cpp" line="+2280"/> + <location filename="../src/gui/kernel/qapplication.cpp" line="-13"/> <source>QT_LAYOUT_DIRECTION</source> <comment>Translate this string to the string 'LTR' in left-to-right languages or to 'RTL' in right-to-left languages (such as Hebrew and Arabic) to get proper widget layout.</comment> <translation>LTR</translation> @@ -1092,12 +1391,12 @@ na <context> <name>QColorDialog</name> <message> - <location filename="../src/gui/dialogs/qcolordialog.cpp" line="+1638"/> + <location filename="../src/gui/dialogs/qcolordialog.cpp" line="+1670"/> <source>&Add to Custom Colors</source> <translation>&Dodaj do własnych kolorów</translation> </message> <message> - <location line="-283"/> + <location line="-286"/> <source>A&lpha channel:</source> <translation>Kanał &alfa:</translation> </message> @@ -1107,22 +1406,22 @@ na <translation>Wybierz kolor</translation> </message> <message> - <location line="+180"/> + <location line="+183"/> <source>&Basic colors</source> <translation>&Kolory podstawowe</translation> </message> <message> - <location line="-282"/> + <location line="-285"/> <source>Bl&ue:</source> <translation>Błęki&t:</translation> </message> <message> - <location line="+283"/> + <location line="+286"/> <source>&Custom colors</source> <translation>Wła&sne kolory</translation> </message> <message> - <location line="-284"/> + <location line="-287"/> <source>&Green:</source> <translation>&Zieleń:</translation> </message> @@ -1150,7 +1449,7 @@ na <context> <name>QComboBox</name> <message> - <location filename="../src/plugins/accessible/widgets/complexwidgets.cpp" line="+1771"/> + <location filename="../src/plugins/accessible/widgets/complexwidgets.cpp" line="+1772"/> <location line="+65"/> <source>Open</source> <translation>Otwórz</translation> @@ -1297,6 +1596,1069 @@ na </message> </context> <context> + <name>QDeclarativeAbstractAnimation</name> + <message> + <location filename="../src/declarative/util/qdeclarativeanimation.cpp" line="+165"/> + <source>Cannot animate non-existent property "%1"</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+3"/> + <source>Cannot animate read-only property "%1"</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../src/declarative/util/qdeclarativeutilmodule.cpp" line="+122"/> + <source>Animation is an abstract class</source> + <translation type="unfinished"></translation> + </message> +</context> +<context> + <name>QDeclarativeAnchorAnimation</name> + <message> + <location filename="../src/declarative/util/qdeclarativeanimation.cpp" line="+2540"/> + <source>Cannot set a duration of < 0</source> + <translation type="unfinished"></translation> + </message> +</context> +<context> + <name>QDeclarativeAnchors</name> + <message> + <location filename="../src/declarative/graphicsitems/qdeclarativeanchors.cpp" line="+181"/> + <source>Possible anchor loop detected on fill.</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+29"/> + <source>Possible anchor loop detected on centerIn.</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+201"/> + <location line="+34"/> + <location line="+610"/> + <location line="+37"/> + <source>Cannot anchor to an item that isn't a parent or sibling.</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="-534"/> + <source>Possible anchor loop detected on vertical anchor.</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+59"/> + <source>Possible anchor loop detected on horizontal anchor.</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+422"/> + <source>Cannot specify left, right, and hcenter anchors.</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+10"/> + <location line="+37"/> + <source>Cannot anchor to a null item.</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="-34"/> + <source>Cannot anchor a horizontal edge to a vertical edge.</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+6"/> + <location line="+37"/> + <source>Cannot anchor item to self.</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="-25"/> + <source>Cannot specify top, bottom, and vcenter anchors.</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+6"/> + <source>Baseline anchor cannot be used in conjunction with top, bottom, or vcenter anchors.</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+13"/> + <source>Cannot anchor a vertical edge to a horizontal edge.</source> + <translation type="unfinished"></translation> + </message> +</context> +<context> + <name>QDeclarativeAnimatedImage</name> + <message> + <location filename="../src/declarative/graphicsitems/qdeclarativeitemsmodule.cpp" line="+86"/> + <source>Qt was built without support for QMovie</source> + <translation type="unfinished"></translation> + </message> +</context> +<context> + <name>QDeclarativeBehavior</name> + <message> + <location filename="../src/declarative/util/qdeclarativebehavior.cpp" line="+122"/> + <source>Cannot change the animation assigned to a Behavior.</source> + <translation type="unfinished"></translation> + </message> +</context> +<context> + <name>QDeclarativeBinding</name> + <message> + <location filename="../src/declarative/qml/qdeclarativebinding.cpp" line="+225"/> + <source>Binding loop detected for property "%1"</source> + <translation type="unfinished"></translation> + </message> +</context> +<context> + <name>QDeclarativeCompiledBindings</name> + <message> + <location filename="../src/declarative/qml/qdeclarativecompiledbindings.cpp" line="+305"/> + <source>Binding loop detected for property "%1"</source> + <translation type="unfinished"></translation> + </message> +</context> +<context> + <name>QDeclarativeCompiler</name> + <message> + <location filename="../src/declarative/qml/qdeclarativecompiler.cpp" line="+186"/> + <location line="+1561"/> + <location line="+187"/> + <location line="+82"/> + <location line="+75"/> + <location line="+488"/> + <source>Invalid property assignment: "%1" is a read-only property</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="-2384"/> + <source>Invalid property assignment: unknown enumeration</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+8"/> + <source>Invalid property assignment: string expected</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+3"/> + <source>Invalid property assignment: url expected</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+6"/> + <source>Invalid property assignment: unsigned int expected</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+7"/> + <source>Invalid property assignment: int expected</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+7"/> + <source>Invalid property assignment: float expected</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+7"/> + <source>Invalid property assignment: double expected</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+7"/> + <source>Invalid property assignment: color expected</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+7"/> + <source>Invalid property assignment: date expected</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+7"/> + <source>Invalid property assignment: time expected</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+7"/> + <source>Invalid property assignment: datetime expected</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+8"/> + <source>Invalid property assignment: point expected</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+8"/> + <source>Invalid property assignment: size expected</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+8"/> + <source>Invalid property assignment: rect expected</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+5"/> + <source>Invalid property assignment: boolean expected</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+7"/> + <source>Invalid property assignment: 3D vector expected</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+9"/> + <source>Invalid property assignment: unsupported type "%1"</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+271"/> + <source>Element is not creatable.</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+592"/> + <source>Component elements may not contain properties other than id</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+7"/> + <source>Invalid component id specification</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+6"/> + <location line="+477"/> + <source>id is not unique</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="-467"/> + <source>Invalid component body specification</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+3"/> + <source>Component objects cannot declare new properties.</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+2"/> + <source>Component objects cannot declare new signals.</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+2"/> + <source>Component objects cannot declare new functions.</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+7"/> + <source>Cannot create empty component specification</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+89"/> + <source>Incorrectly specified signal assignment</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+13"/> + <source>Empty signal assignment</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+38"/> + <source>Empty property assignment</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+12"/> + <source>Attached properties cannot be used here</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+15"/> + <location line="+104"/> + <source>Non-existent attached object</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="-100"/> + <location line="+103"/> + <source>Invalid attached object assignment</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="-50"/> + <source>Cannot assign to non-existent default property</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+2"/> + <location line="+355"/> + <source>Cannot assign to non-existent property "%1"</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="-324"/> + <source>Invalid use of namespace</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+5"/> + <source>Not an attached property name</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+183"/> + <source>Invalid use of id property</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+89"/> + <location line="+2"/> + <source>Property has already been assigned a value</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+12"/> + <location line="+8"/> + <source>Invalid grouped property access</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+3"/> + <source>Cannot assign a value directly to a grouped property</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+16"/> + <source>Invalid property use</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+13"/> + <source>Property assignment expected</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+3"/> + <source>Single property assignment expected</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+5"/> + <source>Unexpected object assignment</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+57"/> + <source>Cannot assign object to list</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+6"/> + <source>Can only assign one binding to lists</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+6"/> + <source>Cannot assign primitives to lists</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+13"/> + <source>Cannot assign multiple values to a script property</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+3"/> + <source>Invalid property assignment: script expected</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+106"/> + <source>Cannot assign object to property</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+50"/> + <source>"%1" cannot operate on "%2"</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+117"/> + <source>Duplicate default property</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+5"/> + <source>Duplicate property name</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+3"/> + <source>Property names cannot begin with an upper case letter</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+7"/> + <source>Duplicate signal name</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+2"/> + <source>Signal names cannot begin with an upper case letter</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+6"/> + <source>Duplicate method name</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+2"/> + <source>Method names cannot begin with an upper case letter</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+21"/> + <source>Property value set multiple times</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+4"/> + <source>Invalid property nesting</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+53"/> + <source>Cannot override FINAL property</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+25"/> + <source>Invalid property type</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+159"/> + <source>Invalid empty ID</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+3"/> + <source>IDs cannot start with an uppercase letter</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+6"/> + <source>IDs must start with a letter or underscore</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+2"/> + <source>IDs must contain only letters, numbers, and underscores</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+6"/> + <source>ID illegally masks global JavaScript property</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+31"/> + <location line="+9"/> + <source>No property alias location</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="-4"/> + <location line="+25"/> + <source>Invalid alias location</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="-16"/> + <source>Invalid alias reference. An alias reference must be specified as <id> or <id>.<property></source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+3"/> + <source>Invalid alias reference. Unable to find id "%1"</source> + <translation type="unfinished"></translation> + </message> +</context> +<context> + <name>QDeclarativeComponent</name> + <message> + <location filename="../src/declarative/qml/qdeclarativecomponent.cpp" line="+454"/> + <source>Invalid empty URL</source> + <translation type="unfinished"></translation> + </message> +</context> +<context> + <name>QDeclarativeCompositeTypeManager</name> + <message> + <location filename="../src/declarative/qml/qdeclarativecompositetypemanager.cpp" line="+482"/> + <location line="+268"/> + <source>Resource %1 unavailable</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="-119"/> + <source>Namespace %1 cannot be used as a type</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+2"/> + <source>%1 is not a type</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+46"/> + <source>Type %1 unavailable</source> + <translation type="unfinished"></translation> + </message> +</context> +<context> + <name>QDeclarativeConnections</name> + <message> + <location filename="../src/declarative/util/qdeclarativeconnections.cpp" line="+178"/> + <location line="+54"/> + <location line="+7"/> + <source>Cannot assign to non-existent property "%1"</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="-51"/> + <source>Connections: nested objects not allowed</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+3"/> + <source>Connections: syntax error</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+8"/> + <source>Connections: script expected</source> + <translation type="unfinished"></translation> + </message> +</context> +<context> + <name>QDeclarativeEngine</name> + <message> + <location filename="../src/declarative/qml/qdeclarativeengine.cpp" line="+1633"/> + <source>module "%1" definition "%2" not readable</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+23"/> + <source>plugin cannot be loaded for module "%1": %2</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+5"/> + <source>module "%1" plugin "%2" not found</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+82"/> + <location line="+55"/> + <source>module "%1" version %2.%3 is not installed</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="-53"/> + <source>module "%1" is not installed</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+14"/> + <location line="+19"/> + <source>"%1": no such directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="-2"/> + <source>import "%1" has no qmldir and no namespace</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../src/declarative/qml/qdeclarativesqldatabase.cpp" line="+204"/> + <source>executeSql called outside transaction()</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+58"/> + <source>Read-only Transaction</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+20"/> + <source>Version mismatch: expected %1, found %2</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+14"/> + <source>SQL transaction failed</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+21"/> + <source>transaction: missing callback</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+57"/> + <location line="+16"/> + <source>SQL: database version mismatch</source> + <translation type="unfinished"></translation> + </message> +</context> +<context> + <name>QDeclarativeFlipable</name> + <message> + <location filename="../src/declarative/graphicsitems/qdeclarativeflipable.cpp" line="+129"/> + <source>front is a write-once property</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+19"/> + <source>back is a write-once property</source> + <translation type="unfinished"></translation> + </message> +</context> +<context> + <name>QDeclarativeKeyNavigationAttached</name> + <message> + <location filename="../src/declarative/graphicsitems/qdeclarativeitemsmodule.cpp" line="+62"/> + <source>KeyNavigation is only available via attached properties</source> + <translation type="unfinished"></translation> + </message> +</context> +<context> + <name>QDeclarativeKeysAttached</name> + <message> + <location line="+1"/> + <source>Keys is only available via attached properties</source> + <translation type="unfinished"></translation> + </message> +</context> +<context> + <name>QDeclarativeListModel</name> + <message> + <location filename="../src/declarative/util/qdeclarativelistmodel.cpp" line="+399"/> + <source>remove: index %1 out of range</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+33"/> + <source>insert: value is not an object</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+5"/> + <source>insert: index %1 out of range</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+30"/> + <source>move: out of range</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+40"/> + <source>append: value is not an object</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+34"/> + <source>get: index %1 out of range</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+25"/> + <source>set: value is not an object</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+4"/> + <location line="+34"/> + <source>set: index %1 out of range</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+39"/> + <location line="+15"/> + <source>ListElement: cannot contain nested elements</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+4"/> + <source>ListElement: cannot use reserved "id" property</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+49"/> + <source>ListElement: cannot use script for property value</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+29"/> + <source>ListModel: undefined property '%1'</source> + <translation type="unfinished"></translation> + </message> +</context> +<context> + <name>QDeclarativeLoader</name> + <message> + <location filename="../src/declarative/graphicsitems/qdeclarativeloader.cpp" line="+317"/> + <source>Loader does not support loading non-visual elements.</source> + <translation type="unfinished"></translation> + </message> +</context> +<context> + <name>QDeclarativeParentAnimation</name> + <message> + <location filename="../src/declarative/util/qdeclarativeanimation.cpp" line="-169"/> + <source>Unable to preserve appearance under complex transform</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+10"/> + <location line="+7"/> + <source>Unable to preserve appearance under non-uniform scale</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+7"/> + <source>Unable to preserve appearance under scale of 0</source> + <translation type="unfinished"></translation> + </message> +</context> +<context> + <name>QDeclarativeParentChange</name> + <message> + <location filename="../src/declarative/util/qdeclarativestateoperations.cpp" line="+95"/> + <source>Unable to preserve appearance under complex transform</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+10"/> + <location line="+7"/> + <source>Unable to preserve appearance under non-uniform scale</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+7"/> + <source>Unable to preserve appearance under scale of 0</source> + <translation type="unfinished"></translation> + </message> +</context> +<context> + <name>QDeclarativeParser</name> + <message> + <location filename="../src/declarative/qml/parser/qdeclarativejslexer.cpp" line="+542"/> + <location line="+123"/> + <location line="+54"/> + <source>Illegal unicode escape sequence</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="-140"/> + <source>Illegal character</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+14"/> + <source>Unclosed string at end of line</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+26"/> + <source>Illegal escape squence</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+72"/> + <source>Unclosed comment at end of file</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+102"/> + <source>Illegal syntax for exponential number</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+26"/> + <source>Identifier cannot start with numeric literal</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+338"/> + <source>Unterminated regular expression literal</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+15"/> + <source>Invalid regular expression flag '%0'</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+16"/> + <location line="+22"/> + <source>Unterminated regular expression backslash sequence</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+13"/> + <source>Unterminated regular expression class</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../src/declarative/qml/parser/qdeclarativejsparser.cpp" line="+1828"/> + <location line="+67"/> + <source>Syntax error</source> + <translation>Błąd składni</translation> + </message> + <message> + <location line="-65"/> + <source>Unexpected token `%1'</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+28"/> + <location line="+24"/> + <source>Expected token `%1'</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../src/declarative/qml/qdeclarativescriptparser.cpp" line="+264"/> + <location line="+456"/> + <location line="+59"/> + <source>Property value set multiple times</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="-504"/> + <source>Expected type name</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+171"/> + <source>Invalid import qualifier ID</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+15"/> + <source>Script import qualifiers must be unique.</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+10"/> + <source>Script import requires a qualifier</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+11"/> + <source>Library import requires a version</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+59"/> + <source>Expected parameter type</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+42"/> + <source>Invalid property type modifier</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+9"/> + <source>Unexpected property type modifier</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+9"/> + <source>Expected property type</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+9"/> + <source>Readonly not yet supported</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+213"/> + <source>JavaScript declaration outside Script element</source> + <translation type="unfinished"></translation> + </message> +</context> +<context> + <name>QDeclarativePauseAnimation</name> + <message> + <location filename="../src/declarative/util/qdeclarativeanimation.cpp" line="-1973"/> + <source>Cannot set a duration of < 0</source> + <translation type="unfinished"></translation> + </message> +</context> +<context> + <name>QDeclarativePixmapCache</name> + <message> + <location filename="../src/declarative/util/qdeclarativepixmapcache.cpp" line="+197"/> + <source>Error decoding: %1: %2</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+70"/> + <source>Failed to get image from provider: %1</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+19"/> + <location line="+342"/> + <source>Cannot open: %1</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+37"/> + <source>Unknown Error loading %1</source> + <translation type="unfinished"></translation> + </message> +</context> +<context> + <name>QDeclarativePropertyAnimation</name> + <message> + <location filename="../src/declarative/util/qdeclarativeanimation.cpp" line="+1100"/> + <source>Cannot set a duration of < 0</source> + <translation type="unfinished"></translation> + </message> +</context> +<context> + <name>QDeclarativePropertyChanges</name> + <message> + <location filename="../src/declarative/util/qdeclarativepropertychanges.cpp" line="+231"/> + <source>PropertyChanges does not support creating state-specific objects.</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+151"/> + <source>Cannot assign to non-existent property "%1"</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+3"/> + <source>Cannot assign to read-only property "%1"</source> + <translation type="unfinished"></translation> + </message> +</context> +<context> + <name>QDeclarativeTextInput</name> + <message> + <location filename="../src/declarative/graphicsitems/qdeclarativetextinput.cpp" line="+783"/> + <location line="+8"/> + <source>Could not load cursor delegate</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+11"/> + <source>Could not instantiate cursor delegate</source> + <translation type="unfinished"></translation> + </message> +</context> +<context> + <name>QDeclarativeVME</name> + <message> + <location filename="../src/declarative/qml/qdeclarativevme.cpp" line="+194"/> + <source>Unable to create object of type %1</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+380"/> + <source>Cannot assign value %1 to property %2</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+22"/> + <source>Cannot assign object type %1 with no default method</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+3"/> + <source>Cannot connect mismatched signal/slot %1 %vs. %2</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+5"/> + <source>Cannot assign an object to signal property %1</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+146"/> + <source>Cannot assign object to list</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+41"/> + <source>Cannot assign object to interface property</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+11"/> + <source>Unable to create attached object</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+32"/> + <source>Cannot set properties on %1 as it is null</source> + <translation type="unfinished"></translation> + </message> +</context> +<context> + <name>QDeclarativeVisualDataModel</name> + <message> + <location filename="../src/declarative/graphicsitems/qdeclarativevisualitemmodel.cpp" line="+1061"/> + <source>Delegate component must be Item type.</source> + <translation type="unfinished"></translation> + </message> +</context> +<context> + <name>QDeclarativeXmlListModel</name> + <message> + <location filename="../src/declarative/util/qdeclarativeutilmodule.cpp" line="-12"/> + <location line="+2"/> + <source>Qt was built without support for xmlpatterns</source> + <translation type="unfinished"></translation> + </message> +</context> +<context> + <name>QDeclarativeXmlListModelRole</name> + <message> + <location filename="../src/declarative/util/qdeclarativexmllistmodel_p.h" line="+168"/> + <source>An XmlRole query must not start with '/'</source> + <translation type="unfinished"></translation> + </message> +</context> +<context> + <name>QDeclarativeXmlRoleList</name> + <message> + <location filename="../src/declarative/util/qdeclarativexmllistmodel.cpp" line="+638"/> + <source>An XmlListModel query must start with '/' or "//"</source> + <translation type="unfinished"></translation> + </message> +</context> +<context> <name>QDial</name> <message> <location filename="../src/plugins/accessible/widgets/rangecontrols.cpp" line="+951"/> @@ -1317,12 +2679,12 @@ na <context> <name>QDialog</name> <message> - <location filename="../src/gui/dialogs/qdialog.cpp" line="+636"/> + <location filename="../src/gui/dialogs/qdialog.cpp" line="+647"/> <source>What's This?</source> <translation>Co to jest?</translation> </message> <message> - <location line="-135"/> + <location line="-122"/> <source>Done</source> <translation>Wykonano</translation> </message> @@ -1330,7 +2692,7 @@ na <context> <name>QDialogButtonBox</name> <message> - <location filename="../src/gui/widgets/qdialogbuttonbox.cpp" line="+669"/> + <location filename="../src/gui/widgets/qdialogbuttonbox.cpp" line="+696"/> <source>Abort</source> <translation>Przerwij</translation> </message> @@ -1400,7 +2762,7 @@ na <translation>Ni&e dla wszystkich</translation> </message> <message> - <location filename="../src/gui/dialogs/qmessagebox.cpp" line="+1872"/> + <location filename="../src/gui/dialogs/qmessagebox.cpp" line="+1920"/> <location line="+464"/> <location filename="../src/gui/widgets/qdialogbuttonbox.cpp" line="-41"/> <source>OK</source> @@ -1544,7 +2906,7 @@ na <context> <name>QFile</name> <message> - <location filename="../src/corelib/io/qfile.cpp" line="+697"/> + <location filename="../src/corelib/io/qfile.cpp" line="+703"/> <location line="+155"/> <source>Destination file exists</source> <translation>Plik wyjściowy już istnieje</translation> @@ -1583,7 +2945,7 @@ na <context> <name>QFileDialog</name> <message> - <location filename="../src/gui/dialogs/qfiledialog.cpp" line="+2049"/> + <location filename="../src/gui/dialogs/qfiledialog.cpp" line="+2078"/> <source>%1 already exists. Do you want to replace it?</source> <translation>%1 już istnieje. @@ -1637,7 +2999,7 @@ Proszę o sprawdzenie podanej nazwy pliku.</translation> <translation>Nie można skasować katalogu.</translation> </message> <message> - <location line="-2106"/> + <location line="-2135"/> <source>&Delete</source> <translation>&Skasuj</translation> </message> @@ -1648,18 +3010,18 @@ Proszę o sprawdzenie podanej nazwy pliku.</translation> <translation>Szczegóły</translation> </message> <message> - <location filename="../src/gui/dialogs/qfiledialog.cpp" line="+662"/> + <location filename="../src/gui/dialogs/qfiledialog.cpp" line="+682"/> <source>Directories</source> <translation>Katalogi</translation> </message> <message> - <location line="-655"/> - <location line="+659"/> + <location line="-675"/> + <location line="+679"/> <source>Directory:</source> <translation>Katalog:</translation> </message> <message> - <location filename="../src/gui/itemviews/qfileiconprovider.cpp" line="+461"/> + <location filename="../src/gui/itemviews/qfileiconprovider.cpp" line="+464"/> <source>Drive</source> <translation>Urządzenie</translation> </message> @@ -1712,8 +3074,8 @@ Proszę o sprawdzenie podanej nazwy pliku.</translation> </message> <message> <location filename="../src/gui/dialogs/qfiledialog.cpp" line="-7"/> - <location line="+50"/> - <location line="+1528"/> + <location line="+55"/> + <location line="+1532"/> <source>&Open</source> <translation>&Otwórz</translation> </message> @@ -1724,18 +3086,18 @@ Proszę o sprawdzenie podanej nazwy pliku.</translation> <translation>Katalog wyżej</translation> </message> <message> - <location filename="../src/gui/dialogs/qfiledialog.cpp" line="-2238"/> + <location filename="../src/gui/dialogs/qfiledialog.cpp" line="-2267"/> <source>&Rename</source> <translation>&Zmień nazwę</translation> </message> <message> - <location line="+660"/> - <location line="+50"/> + <location line="+680"/> + <location line="+55"/> <source>&Save</source> <translation>&Zachowaj</translation> </message> <message> - <location line="-708"/> + <location line="-733"/> <source>Show &hidden files</source> <translation>Pokaż &ukryte pliki</translation> </message> @@ -1760,7 +3122,7 @@ Proszę o sprawdzenie podanej nazwy pliku.</translation> <translation>Znajdź katalog</translation> </message> <message> - <location filename="../src/gui/dialogs/qfiledialog_win.cpp" line="+174"/> + <location filename="../src/gui/dialogs/qfiledialog_win.cpp" line="+148"/> <source>All Files (*.*)</source> <translation>Wszystkie pliki (*.*)</translation> </message> @@ -1776,18 +3138,18 @@ Proszę o sprawdzenie podanej nazwy pliku.</translation> <translation>Do przodu</translation> </message> <message> - <location filename="../src/gui/dialogs/qfiledialog.cpp" line="+1963"/> + <location filename="../src/gui/dialogs/qfiledialog.cpp" line="+1992"/> <source>New Folder</source> <translation>Nowy katalog</translation> </message> <message> - <location line="-1956"/> + <location line="-1985"/> <source>&New Folder</source> <translation>&Nowy katalog</translation> </message> <message> - <location line="+667"/> - <location line="+38"/> + <location line="+687"/> + <location line="+43"/> <source>&Choose</source> <translation>&Wybierz</translation> </message> @@ -1797,14 +3159,14 @@ Proszę o sprawdzenie podanej nazwy pliku.</translation> <translation>Usuń</translation> </message> <message> - <location filename="../src/gui/dialogs/qfiledialog.cpp" line="-722"/> - <location line="+450"/> + <location filename="../src/gui/dialogs/qfiledialog.cpp" line="-747"/> + <location line="+481"/> <source>All Files (*)</source> <translation>Wszystkie pliki (*)</translation> </message> <message> - <location line="-426"/> - <location line="+663"/> + <location line="-457"/> + <location line="+683"/> <source>File &name:</source> <translation>Nazwa &pliku:</translation> </message> @@ -1820,12 +3182,42 @@ Proszę o sprawdzenie podanej nazwy pliku.</translation> <source>Create New Folder</source> <translation>Utwórz nowy katalog</translation> </message> + <message> + <location/> + <source>Go back</source> + <translation type="unfinished"></translation> + </message> + <message> + <location/> + <source>Go forward</source> + <translation type="unfinished"></translation> + </message> + <message> + <location/> + <source>Go to the parent directory</source> + <translation type="unfinished"></translation> + </message> + <message> + <location/> + <source>Create a New Folder</source> + <translation type="unfinished"></translation> + </message> + <message> + <location/> + <source>Change to list view mode</source> + <translation type="unfinished"></translation> + </message> + <message> + <location/> + <source>Change to detail view mode</source> + <translation type="unfinished"></translation> + </message> </context> <context> <name>QFileSystemModel</name> <message> - <location filename="../src/gui/dialogs/qfilesystemmodel.cpp" line="+744"/> - <location filename="../src/gui/itemviews/qdirmodel.cpp" line="+476"/> + <location filename="../src/gui/dialogs/qfilesystemmodel.cpp" line="+740"/> + <location filename="../src/gui/itemviews/qdirmodel.cpp" line="+482"/> <source>%1 TB</source> <translation>%1 TB</translation> </message> @@ -1853,7 +3245,7 @@ Proszę o sprawdzenie podanej nazwy pliku.</translation> <translation>%1 bajtów</translation> </message> <message> - <location line="+77"/> + <location line="+89"/> <source>Invalid filename</source> <translation>Niepoprawna nazwa pliku</translation> </message> @@ -1890,7 +3282,7 @@ Proszę o sprawdzenie podanej nazwy pliku.</translation> <translation>Data modyfikacji</translation> </message> <message> - <location filename="../src/gui/dialogs/qfilesystemmodel_p.h" line="+258"/> + <location filename="../src/gui/dialogs/qfilesystemmodel_p.h" line="+261"/> <source>My Computer</source> <translation>Mój komputer</translation> </message> @@ -2132,7 +3524,7 @@ Proszę o sprawdzenie podanej nazwy pliku.</translation> <context> <name>QFontDialog</name> <message> - <location filename="../src/gui/dialogs/qfontdialog.cpp" line="+782"/> + <location filename="../src/gui/dialogs/qfontdialog.cpp" line="+774"/> <source>Effects</source> <translation>Efekty</translation> </message> @@ -2152,13 +3544,12 @@ Proszę o sprawdzenie podanej nazwy pliku.</translation> <translation>Przykład</translation> </message> <message> - <location line="-608"/> - <location line="+257"/> + <location line="-595"/> <source>Select Font</source> <translation>Wybierz czcionkę</translation> </message> <message> - <location line="+343"/> + <location line="+587"/> <source>&Size</source> <translation>&Rozmiar</translation> </message> @@ -2181,7 +3572,7 @@ Proszę o sprawdzenie podanej nazwy pliku.</translation> <context> <name>QFtp</name> <message> - <location filename="../src/network/access/qftp.cpp" line="+2337"/> + <location filename="../src/network/access/qftp.cpp" line="+2343"/> <location filename="../src/qt3support/network/q3ftp.cpp" line="+2024"/> <source>Changing directory failed: %1</source> @@ -2194,14 +3585,14 @@ Proszę o sprawdzenie podanej nazwy pliku.</translation> <translation>Podłączony do hosta</translation> </message> <message> - <location filename="../src/network/access/qftp.cpp" line="-1329"/> + <location filename="../src/network/access/qftp.cpp" line="-1335"/> <location filename="../src/qt3support/network/q3ftp.cpp" line="-1458"/> <location line="+1451"/> <source>Connected to host %1</source> <translation>Podłączony do hosta %1</translation> </message> <message> - <location line="+1317"/> + <location line="+1323"/> <location filename="../src/qt3support/network/q3ftp.cpp" line="-290"/> <source>Connecting to host failed: %1</source> @@ -2216,7 +3607,7 @@ Proszę o sprawdzenie podanej nazwy pliku.</translation> <translation>Połączenie zamknięte</translation> </message> <message> - <location line="-1158"/> + <location line="-1164"/> <location filename="../src/qt3support/network/q3ftp.cpp" line="-1299"/> <source>Connection refused for data connection</source> <translation>Połączenie do przesyłu danych odrzucone</translation> @@ -2233,7 +3624,7 @@ Proszę o sprawdzenie podanej nazwy pliku.</translation> <translation>Połączenie do %1 zakończone</translation> </message> <message> - <location filename="../src/network/access/qftp.cpp" line="+1453"/> + <location filename="../src/network/access/qftp.cpp" line="+1459"/> <location filename="../src/qt3support/network/q3ftp.cpp" line="-271"/> <source>Creating directory failed: %1</source> @@ -2254,7 +3645,7 @@ Proszę o sprawdzenie podanej nazwy pliku.</translation> <translation>Host %1 znaleziony</translation> </message> <message> - <location filename="../src/network/access/qftp.cpp" line="-1445"/> + <location filename="../src/network/access/qftp.cpp" line="-1451"/> <location filename="../src/qt3support/network/q3ftp.cpp" line="-1555"/> <source>Host %1 not found</source> <translation>Host %1 nie znaleziony</translation> @@ -2265,7 +3656,7 @@ Proszę o sprawdzenie podanej nazwy pliku.</translation> <translation>Host znaleziony</translation> </message> <message> - <location filename="../src/network/access/qftp.cpp" line="+1437"/> + <location filename="../src/network/access/qftp.cpp" line="+1443"/> <location filename="../src/qt3support/network/q3ftp.cpp" line="-289"/> <source>Listing directory failed: %1</source> @@ -2277,11 +3668,11 @@ Proszę o sprawdzenie podanej nazwy pliku.</translation> <location filename="../src/qt3support/network/q3ftp.cpp" line="-3"/> <source>Login failed: %1</source> - <translation>Logowanie nie powiodło się: + <translation>Logowanie zakończone błędem: %1</translation> </message> <message> - <location line="-1501"/> + <location line="-1507"/> <location filename="../src/qt3support/network/q3ftp.cpp" line="-1335"/> <source>Not connected</source> <translation>Nie podłączony</translation> @@ -2292,7 +3683,7 @@ Proszę o sprawdzenie podanej nazwy pliku.</translation> <translation>Przekroczony czas połączenia do hosta %1</translation> </message> <message> - <location line="+1453"/> + <location line="+1459"/> <location filename="../src/qt3support/network/q3ftp.cpp" line="+1356"/> <source>Removing directory failed: %1</source> @@ -2308,7 +3699,7 @@ Proszę o sprawdzenie podanej nazwy pliku.</translation> %1</translation> </message> <message> - <location line="-944"/> + <location line="-950"/> <location line="+29"/> <location filename="../src/qt3support/network/q3ftp.cpp" line="-823"/> <location line="+728"/> @@ -2316,7 +3707,7 @@ Proszę o sprawdzenie podanej nazwy pliku.</translation> <translation>Nieznany błąd</translation> </message> <message> - <location line="+911"/> + <location line="+917"/> <location filename="../src/qt3support/network/q3ftp.cpp" line="+92"/> <source>Uploading file failed: %1</source> @@ -2325,19 +3716,33 @@ Proszę o sprawdzenie podanej nazwy pliku.</translation> </message> </context> <context> + <name>QGstreamerPlayerSession</name> + <message> + <location filename="../src/plugins/mediaservices/gstreamer/mediaplayer/qgstreamerplayersession.cpp" line="+423"/> + <location line="+16"/> + <source>Unable to play %1</source> + <translation type="unfinished"></translation> + </message> +</context> +<context> <name>QHostInfo</name> <message> - <location filename="../src/network/kernel/qhostinfo_p.h" line="+185"/> + <location filename="../src/network/kernel/qhostinfo_p.h" line="+103"/> <source>Unknown error</source> <translation>Nieznany błąd</translation> </message> + <message> + <location filename="../src/network/kernel/qhostinfo.cpp" line="+175"/> + <source>No host name given</source> + <translation>Nie podano nazwy hosta</translation> + </message> </context> <context> <name>QHostInfoAgent</name> <message> - <location filename="../src/network/kernel/qhostinfo_unix.cpp" line="+257"/> + <location filename="../src/network/kernel/qhostinfo_unix.cpp" line="+259"/> <location line="+32"/> - <location filename="../src/network/kernel/qhostinfo_win.cpp" line="+220"/> + <location filename="../src/network/kernel/qhostinfo_win.cpp" line="+216"/> <location line="+27"/> <source>Host not found</source> <translation>Host nie znaleziony</translation> @@ -2358,12 +3763,14 @@ Proszę o sprawdzenie podanej nazwy pliku.</translation> <translation>Nieznany błąd</translation> </message> <message> + <location line="-98"/> <location filename="../src/network/kernel/qhostinfo_win.cpp" line="-67"/> <source>No host name given</source> <translation>Nie podano nazwy hosta</translation> </message> <message> - <location line="+0"/> + <location line="+1"/> + <location filename="../src/network/kernel/qhostinfo_win.cpp" line="+0"/> <source>Invalid hostname</source> <translation>Niepoprawna nazwa hosta</translation> </message> @@ -2381,7 +3788,7 @@ Proszę o sprawdzenie podanej nazwy pliku.</translation> <translation>Podłączony do hosta %1</translation> </message> <message> - <location filename="../src/network/access/qhttpnetworkconnection.cpp" line="+581"/> + <location filename="../src/network/access/qhttpnetworkconnection.cpp" line="-3"/> <location filename="../src/qt3support/network/q3http.cpp" line="+17"/> <source>Connection closed</source> <translation>Połączenie zakończone</translation> @@ -2416,8 +3823,6 @@ Proszę o sprawdzenie podanej nazwy pliku.</translation> </message> <message> <location filename="../src/network/access/qhttp.cpp" line="+20"/> - <location filename="../src/network/access/qhttpnetworkconnection.cpp" line="+10"/> - <location line="+19"/> <location filename="../src/qt3support/network/q3http.cpp" line="-464"/> <source>HTTP request failed</source> <translation>Komenda HTTP zakończona błędem</translation> @@ -2494,7 +3899,7 @@ Proszę o sprawdzenie podanej nazwy pliku.</translation> <translation>Błąd zapisywania odpowiedzi do urządzenia</translation> </message> <message> - <location filename="../src/network/access/qhttpnetworkconnection.cpp" line="-16"/> + <location filename="../src/network/access/qhttpnetworkconnection.cpp" line="+13"/> <source>Proxy requires authentication</source> <translation>Pośrednik wymaga autoryzacji</translation> </message> @@ -2516,7 +3921,7 @@ Proszę o sprawdzenie podanej nazwy pliku.</translation> <message> <location line="+3"/> <source>SSL handshake failed</source> - <translation>Nawiązanie sesji SSL nie powiodło się</translation> + <translation>Nawiązanie sesji SSL zakończone błędem</translation> </message> <message> <location filename="../src/network/access/qhttp.cpp" line="-328"/> @@ -2688,7 +4093,7 @@ Proszę o sprawdzenie podanej nazwy pliku.</translation> <context> <name>QIODevice</name> <message> - <location filename="../src/corelib/global/qglobal.cpp" line="+2081"/> + <location filename="../src/corelib/global/qglobal.cpp" line="+2108"/> <source>No space left on device</source> <translation>Brak wolnego miejsca na urządzeniu</translation> </message> @@ -2700,7 +4105,7 @@ Proszę o sprawdzenie podanej nazwy pliku.</translation> <message> <location line="-6"/> <source>Permission denied</source> - <translation>Brak dostępu</translation> + <translation>Brak uprawnień</translation> </message> <message> <location line="+3"/> @@ -2708,7 +4113,7 @@ Proszę o sprawdzenie podanej nazwy pliku.</translation> <translation>Zbyt wiele otwartych plików</translation> </message> <message> - <location filename="../src/corelib/io/qiodevice.cpp" line="+1556"/> + <location filename="../src/corelib/io/qiodevice.cpp" line="+1596"/> <source>Unknown error</source> <translation>Nieznany błąd</translation> </message> @@ -2716,7 +4121,7 @@ Proszę o sprawdzenie podanej nazwy pliku.</translation> <context> <name>QInputContext</name> <message> - <location filename="../src/gui/inputmethod/qinputcontextfactory.cpp" line="+291"/> + <location filename="../src/gui/inputmethod/qinputcontextfactory.cpp" line="+336"/> <source>Mac OS X input method</source> <translation>Metoda wprowadzania Mac OS X</translation> </message> @@ -2772,7 +4177,7 @@ Proszę o sprawdzenie podanej nazwy pliku.</translation> <translation>Błąd podczas weryfikacji danych we wtyczce '%1'</translation> </message> <message> - <location line="+350"/> + <location line="+381"/> <source>The plugin '%1' uses incompatible Qt library. (%2.%3.%4) [%5]</source> <translation>Wtyczka '%1' używa niepoprawnej wersji biblioteki QT. (%2.%3.%4) [%5]</translation> </message> @@ -2787,7 +4192,8 @@ Proszę o sprawdzenie podanej nazwy pliku.</translation> <translation>Nieznany błąd</translation> </message> <message> - <location line="-402"/> + <location line="-540"/> + <location line="+138"/> <location filename="../src/corelib/plugin/qpluginloader.cpp" line="+343"/> <source>The shared library was not found.</source> <translation>Biblioteka współdzielona niedostępna.</translation> @@ -2824,7 +4230,7 @@ Proszę o sprawdzenie podanej nazwy pliku.</translation> <context> <name>QLineEdit</name> <message> - <location filename="../src/gui/widgets/qlineedit.cpp" line="+2033"/> + <location filename="../src/gui/widgets/qlineedit.cpp" line="+2089"/> <source>&Copy</source> <translation>S&kopiuj</translation> </message> @@ -2870,7 +4276,7 @@ Proszę o sprawdzenie podanej nazwy pliku.</translation> <message> <location filename="../src/network/socket/qlocalserver_unix.cpp" line="-8"/> <source>%1: Permission denied</source> - <translation>%1: Brak dostępu</translation> + <translation>%1: Brak uprawnień</translation> </message> <message> <location line="+12"/> @@ -2900,8 +4306,8 @@ Proszę o sprawdzenie podanej nazwy pliku.</translation> <message> <location line="+3"/> <location filename="../src/network/socket/qlocalsocket_unix.cpp" line="+3"/> - <location filename="../src/network/socket/qlocalsocket_win.cpp" line="+80"/> - <location line="+45"/> + <location filename="../src/network/socket/qlocalsocket_win.cpp" line="+79"/> + <location line="+59"/> <source>%1: Invalid name</source> <translation>%1: Niepoprawna nazwa</translation> </message> @@ -2932,7 +4338,7 @@ Proszę o sprawdzenie podanej nazwy pliku.</translation> <message> <location line="+3"/> <location filename="../src/network/socket/qlocalsocket_unix.cpp" line="+3"/> - <location filename="../src/network/socket/qlocalsocket_win.cpp" line="-50"/> + <location filename="../src/network/socket/qlocalsocket_win.cpp" line="-64"/> <source>%1: Connection error</source> <translation>%1: Błąd połączenia</translation> </message> @@ -2957,7 +4363,7 @@ Proszę o sprawdzenie podanej nazwy pliku.</translation> <context> <name>QMYSQLDriver</name> <message> - <location filename="../src/sql/drivers/mysql/qsql_mysql.cpp" line="+1431"/> + <location filename="../src/sql/drivers/mysql/qsql_mysql.cpp" line="+1448"/> <source>Unable to begin transaction</source> <translation>Nie można rozpocząć transakcji</translation> </message> @@ -3145,6 +4551,39 @@ Proszę o sprawdzenie podanej nazwy pliku.</translation> </message> </context> <context> + <name>QMediaPlayer</name> + <message> + <location filename="../src/multimedia/playback/qmediaplayer.cpp" line="+496"/> + <source>The QMediaPlayer object does not have a valid service</source> + <translation type="unfinished"></translation> + </message> +</context> +<context> + <name>QMediaPlaylist</name> + <message> + <location filename="../src/multimedia/base/qmediaplaylist.cpp" line="+455"/> + <location line="+46"/> + <source>Could not add items to read only playlist.</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="-27"/> + <location line="+46"/> + <source>Playlist format is not supported</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+26"/> + <source>The file could not be accessed.</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+35"/> + <source>Playlist format is not supported.</source> + <translation type="unfinished"></translation> + </message> +</context> +<context> <name>QMenu</name> <message> <location filename="../src/plugins/accessible/widgets/qaccessiblemenu.cpp" line="+157"/> @@ -3169,7 +4608,7 @@ Proszę o sprawdzenie podanej nazwy pliku.</translation> <context> <name>QMenuBar</name> <message> - <location filename="../src/gui/widgets/qmenu_symbian.cpp" line="+410"/> + <location filename="../src/gui/widgets/qmenu_symbian.cpp" line="+452"/> <source>Actions</source> <translation>Akcje</translation> </message> @@ -3187,12 +4626,12 @@ Proszę o sprawdzenie podanej nazwy pliku.</translation> <translation>Pomoc</translation> </message> <message> - <location line="-1098"/> + <location line="-1129"/> <source>Hide Details...</source> <translation>Ukryj szczegóły...</translation> </message> <message> - <location line="+250"/> + <location line="+281"/> <location line="+847"/> <location filename="../src/gui/dialogs/qmessagebox.h" line="-52"/> <location line="+8"/> @@ -3207,10 +4646,10 @@ Proszę o sprawdzenie podanej nazwy pliku.</translation> <message> <location line="+5"/> <source><p>Qt is a C++ toolkit for cross-platform application development.</p><p>Qt provides single-source portability across MS&nbsp;Windows, Mac&nbsp;OS&nbsp;X, Linux, and all major commercial Unix variants. Qt is also available for embedded devices as Qt for Embedded Linux and Qt for Windows CE.</p><p>Qt is available under three different licensing options designed to accommodate the needs of our various users.</p><p>Qt licensed under our commercial license agreement is appropriate for development of proprietary/commercial software where you do not want to share any source code with third parties or otherwise cannot comply with the terms of the GNU LGPL version 2.1 or GNU GPL version 3.0.</p><p>Qt licensed under the GNU LGPL version 2.1 is appropriate for the development of Qt applications (proprietary or open source) provided you can comply with the terms and conditions of the GNU LGPL version 2.1.</p><p>Qt licensed under the GNU General Public License version 3.0 is appropriate for the development of Qt applications where you wish to use such applications in combination with software subject to the terms of the GNU GPL version 3.0 or where you are otherwise willing to comply with the terms of the GNU GPL version 3.0.</p><p>Please see <a href="http://qt.nokia.com/products/licensing">qt.nokia.com/products/licensing</a> for an overview of Qt licensing.</p><p>Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies).</p><p>Qt is a Nokia product. See <a href="http://qt.nokia.com/">qt.nokia.com</a> for more information.</p></source> - <translation type="unfinished"></translation> + <translation type="unfinished"><p>Qt jest zestawem narzędzi programistycznych dedykowanym dla języka C++. Służy on do opracowywania aplikacji międzyplatformowych.</p><p>Qt umożliwia jednoźródłowe przenoszenie między systemami MS&nbsp;Windows, Mac&nbsp;OS&nbsp;X, Linux i wszystkimi głównymi wersjami komercyjnymi systemu Unix. Środowisko Qt jest dostępne dla urządzeń wbudowanych opartych na systemie Linux ( Qt dla wbudowanego systemu Linux) oraz Windows CE.</p><p>Zestaw Qt jest dostępny w trzech różnych opcjach licencjonowania stworzonych w celu zadowolenia naszych różnych użytkowników.</p><p>Qt podlegający licencji zgodnie z naszą komercyjną umową licencyjną jest odpowiedni do opracowywania oprogramowań własnościowych/komercyjnych, dzięki czemu kod źródłowy nie jest udostępniany osobom trzecim. W przeciwnym razie zestaw Qt jest niezgodny z warunkami licencji GNU LGPL w wersji 2.1 lub GNU GPL w wersji 3.0.</p><p>Środowisko Qt objęte licencją GNU LGPL w wersji 2.1 nadaje się do tworzenia aplikacji Qt (własnościowych lub oprogramowań otwartych) tylko wtedy, gdy przestrzegane są warunki licencji GNU LGPL w wersji 2.1.</p><p>Qt objęty Powszechną Licencją Publiczną GNU w wersji 3.0 jest odpowiedni do opracowywania aplikacji QT, aby móc korzystać z aplikacji w połączeniu z oprogramowaniem podlegającym warunkom licencji GNU GPL w wersji 3.0 lub aby przestrzegać warunków licencji GNU GPL w wersji 3.0.</p><p>Więcej informacji na temat licencji Qt można znaleźć na stronie <a href="http://qt.nokia.com/products/licensing">qt.nokia.com/products/licensing</a>.</p><p>Copyright (C) 2010 Nokia Corporation i/lub oddziały firmy.</p><p>Qt jest produktem firmy Nokia. Dodatkowe informacje znajdują się na stronie <a href="http://qt.nokia.com/">qt.nokia.com</a> </p></translation> </message> <message> - <location line="-1580"/> + <location line="-1610"/> <source>Show Details...</source> <translation>Pokaż szczegóły...</translation> </message> @@ -3239,7 +4678,7 @@ Proszę o sprawdzenie podanej nazwy pliku.</translation> <context> <name>QNativeSocketEngine</name> <message> - <location filename="../src/network/socket/qnativesocketengine.cpp" line="+263"/> + <location filename="../src/network/socket/qnativesocketengine.cpp" line="+266"/> <source>Another socket is already listening on the same port</source> <translation>Inne gniazdo nasłuchuje już na tym porcie</translation> </message> @@ -3301,7 +4740,7 @@ Proszę o sprawdzenie podanej nazwy pliku.</translation> <message> <location line="+18"/> <source>Permission denied</source> - <translation>Brak dostępu</translation> + <translation>Brak uprawnień</translation> </message> <message> <location line="-12"/> @@ -3378,23 +4817,46 @@ Proszę o sprawdzenie podanej nazwy pliku.</translation> </message> </context> <context> + <name>QNetworkAccessDataBackend</name> + <message> + <location filename="../src/network/access/qnetworkaccessdatabackend.cpp" line="+76"/> + <source>Operation not supported on %1</source> + <translation type="unfinished">Operacja nieobsługiwana na %1</translation> + </message> + <message> + <location line="+25"/> + <source>Invalid URI: %1</source> + <translation type="unfinished">Niepoprawny URI: %1</translation> + </message> +</context> +<context> <name>QNetworkAccessDebugPipeBackend</name> <message> <location filename="../src/network/access/qnetworkaccessdebugpipebackend.cpp" line="+195"/> <source>Write error writing to %1: %2</source> <translation>Błąd w trakcie zapisywania do %1: %2</translation> </message> + <message> + <location line="+60"/> + <source>Socket error on %1: %2</source> + <translation type="unfinished">Błąd gniazda na %1: %2</translation> + </message> + <message> + <location line="+15"/> + <source>Remote host closed the connection prematurely on %1</source> + <translation type="unfinished">Zdalny host przedwcześnie zakończył połączenie na %1</translation> + </message> </context> <context> <name>QNetworkAccessFileBackend</name> <message> - <location filename="../src/network/access/qfilenetworkreply.cpp" line="+83"/> + <location filename="../src/network/access/qfilenetworkreply.cpp" line="+85"/> <location filename="../src/network/access/qnetworkaccessfilebackend.cpp" line="+100"/> <source>Request for opening non-local file %1</source> <translation>Żądanie otwarcia zdalnego pliku %1</translation> </message> <message> - <location line="+31"/> + <location line="+33"/> <location filename="../src/network/access/qnetworkaccessfilebackend.cpp" line="+45"/> <source>Error opening %1: %2</source> <translation>Błąd otwierania %1: %2</translation> @@ -3405,7 +4867,7 @@ Proszę o sprawdzenie podanej nazwy pliku.</translation> <translation>Błąd w trakcie zapisywania do %1: %2</translation> </message> <message> - <location filename="../src/network/access/qfilenetworkreply.cpp" line="-11"/> + <location filename="../src/network/access/qfilenetworkreply.cpp" line="-13"/> <location filename="../src/network/access/qnetworkaccessfilebackend.cpp" line="+48"/> <source>Cannot open %1: Path is a directory</source> <translation>Nie można otworzyć %1: Ścieżka jest katalogiem</translation> @@ -3447,37 +4909,111 @@ Proszę o sprawdzenie podanej nazwy pliku.</translation> <context> <name>QNetworkAccessHttpBackend</name> <message> - <location filename="../src/network/access/qnetworkaccesshttpbackend.cpp" line="+585"/> + <location filename="../src/network/access/qnetworkaccesshttpbackend.cpp" line="+645"/> <source>No suitable proxy found</source> <translation>Nie odnaleziono odpowiedniego pośrednika</translation> </message> </context> <context> + <name>QNetworkAccessManager</name> + <message> + <location filename="../src/network/access/qnetworkreplyimpl.cpp" line="+910"/> + <source>Network access is disabled.</source> + <translation type="unfinished"></translation> + </message> +</context> +<context> <name>QNetworkReply</name> <message> - <location line="+95"/> + <location filename="../src/network/access/qnetworkaccesshttpbackend.cpp" line="+101"/> <source>Error downloading %1 - server replied: %2</source> <translation>Błąd podczas pobierania %1 - odpowiedź serwera: %2</translation> </message> <message> - <location filename="../src/network/access/qnetworkreplyimpl.cpp" line="+77"/> + <location filename="../src/network/access/qnetworkreplyimpl.cpp" line="-828"/> <source>Protocol "%1" is unknown</source> <translation>Protokół "%1" nie jest znany</translation> </message> + <message> + <location line="+192"/> + <source>Network session error.</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+329"/> + <source>Temporary network failure.</source> + <translation type="unfinished"></translation> + </message> </context> <context> <name>QNetworkReplyImpl</name> <message> - <location line="+519"/> + <location line="+111"/> <location line="+28"/> <source>Operation canceled</source> <translation>Operacja anulowana</translation> </message> </context> <context> + <name>QNetworkSession</name> + <message> + <location filename="../src/network/bearer/qnetworksession.cpp" line="+449"/> + <source>Invalid configuration.</source> + <translation type="unfinished"></translation> + </message> +</context> +<context> + <name>QNetworkSessionPrivateImpl</name> + <message> + <location filename="../src/plugins/bearer/icd/qnetworksession_impl.cpp" line="+1005"/> + <source>Roaming error</source> + <translation>Błąd roamingu</translation> + </message> + <message> + <location line="+3"/> + <source>Session aborted by user or system</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+4"/> + <source>Unidentified Error</source> + <translation>Niezidentyfikowany błąd</translation> + </message> + <message> + <location filename="../src/plugins/bearer/qnetworksession_impl.cpp" line="+272"/> + <location filename="../src/plugins/bearer/symbian/qnetworksession_impl.cpp" line="+227"/> + <source>Unknown session error.</source> + <translation>Nieznany błąd sesji.</translation> + </message> + <message> + <location line="+2"/> + <location filename="../src/plugins/bearer/symbian/qnetworksession_impl.cpp" line="+2"/> + <source>The session was aborted by the user or system.</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+2"/> + <location filename="../src/plugins/bearer/symbian/qnetworksession_impl.cpp" line="+2"/> + <source>The requested operation is not supported by the system.</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+2"/> + <location filename="../src/plugins/bearer/symbian/qnetworksession_impl.cpp" line="+2"/> + <source>The specified configuration cannot be used.</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+2"/> + <location filename="../src/plugins/bearer/symbian/qnetworksession_impl.cpp" line="+2"/> + <source>Roaming was aborted or is not possible.</source> + <translation type="unfinished"></translation> + </message> +</context> +<context> <name>QOCIDriver</name> <message> - <location filename="../src/sql/drivers/oci/qsql_oci.cpp" line="+1939"/> + <location filename="../src/sql/drivers/oci/qsql_oci.cpp" line="+1944"/> <source>Unable to initialize</source> <comment>QOCIDriver</comment> <translation>Nie można dokonać inicjalizacji</translation> @@ -3551,17 +5087,17 @@ Proszę o sprawdzenie podanej nazwy pliku.</translation> <context> <name>QODBCDriver</name> <message> - <location filename="../src/sql/drivers/odbc/qsql_odbc.cpp" line="+2045"/> + <location filename="../src/sql/drivers/odbc/qsql_odbc.cpp" line="+2174"/> <source>Unable to commit transaction</source> <translation>Nie można potwierdzić transakcji</translation> </message> <message> - <location line="-255"/> + <location line="-286"/> <source>Unable to connect</source> <translation>Nie można nawiązać połączenia</translation> </message> <message> - <location line="+238"/> + <location line="+269"/> <source>Unable to disable autocommit</source> <translation>Nie można wyłączyć trybu automatycznego dokonywania transakcji</translation> </message> @@ -3576,7 +5112,7 @@ Proszę o sprawdzenie podanej nazwy pliku.</translation> <translation>Nie można wycofać transakcji</translation> </message> <message> - <location line="-266"/> + <location line="-297"/> <source>Unable to connect - Driver doesn't support all functionality required</source> <translation>Nie można nawiązać połączenia - sterownik nie obsługuje całej potrzebnej funkcjonalności</translation> </message> @@ -3584,24 +5120,24 @@ Proszę o sprawdzenie podanej nazwy pliku.</translation> <context> <name>QODBCResult</name> <message> - <location line="-932"/> - <location line="+346"/> + <location line="-941"/> + <location line="+351"/> <source>QODBCResult::reset: Unable to set 'SQL_CURSOR_STATIC' as statement attribute. Please check your ODBC driver configuration</source> <translation>QODBCResult::reset: Nie można ustawić 'SQL_CURSOR_STATIC' jako atrybutu polecenia. Proszę sprawdzić konfiguracje sterownika ODBC</translation> </message> <message> - <location line="+286"/> + <location line="+285"/> <source>Unable to bind variable</source> <translation>Nie można powiązać zmiennej</translation> </message> <message> - <location line="-615"/> - <location line="+623"/> + <location line="-619"/> + <location line="+627"/> <source>Unable to execute statement</source> <translation>Nie można wykonać polecenia</translation> </message> <message> - <location line="-547"/> + <location line="-546"/> <source>Unable to fetch next</source> <translation>Nie można pobrać kolejnych danych</translation> </message> @@ -3613,12 +5149,12 @@ Proszę o sprawdzenie podanej nazwy pliku.</translation> <message> <location filename="../src/sql/drivers/db2/qsql_db2.cpp" line="+189"/> <location filename="../src/sql/drivers/odbc/qsql_odbc.cpp" line="-199"/> - <location line="+576"/> + <location line="+578"/> <source>Unable to fetch last</source> <translation>Nie można pobrać ostatnich danych</translation> </message> <message> - <location filename="../src/sql/drivers/odbc/qsql_odbc.cpp" line="-670"/> + <location filename="../src/sql/drivers/odbc/qsql_odbc.cpp" line="-672"/> <source>Unable to fetch</source> <translation>Nie można pobrać</translation> </message> @@ -3636,41 +5172,21 @@ Proszę o sprawdzenie podanej nazwy pliku.</translation> <context> <name>QObject</name> <message> - <location filename="../src/network/kernel/qhostinfo_unix.cpp" line="-97"/> - <source>Invalid hostname</source> - <translation>Niepoprawna nazwa hosta</translation> - </message> - <message> - <location filename="../src/network/access/qnetworkaccessdatabackend.cpp" line="+74"/> - <source>Operation not supported on %1</source> - <translation>Operacja nieobsługiwana na %1</translation> - </message> - <message> - <location line="+57"/> - <source>Invalid URI: %1</source> - <translation>Niepoprawny URI: %1</translation> - </message> - <message> - <location filename="../src/network/access/qnetworkaccessdebugpipebackend.cpp" line="+60"/> - <source>Socket error on %1: %2</source> - <translation>Błąd gniazda na %1: %2</translation> - </message> - <message> - <location line="+15"/> - <source>Remote host closed the connection prematurely on %1</source> - <translation>Zdalny host przedwcześnie zakończył połączenie na %1</translation> + <location filename="../src/3rdparty/phonon/phonon/pulsesupport.cpp" line="+162"/> + <location line="+11"/> + <source>PulseAudio Sound Server</source> + <translation type="unfinished"></translation> </message> <message> - <location filename="../src/network/kernel/qhostinfo.cpp" line="+175"/> - <location filename="../src/network/kernel/qhostinfo_unix.cpp" line="+0"/> - <source>No host name given</source> - <translation>Nie podano nazwy hosta</translation> + <location filename="../src/declarative/util/qdeclarativexmllistmodel.cpp" line="-194"/> + <source>"%1" duplicates a previous role name and will be disabled.</source> + <translation type="unfinished"></translation> </message> </context> <context> <name>QPPDOptionsModel</name> <message> - <location filename="../src/gui/dialogs/qprintdialog_unix.cpp" line="+1197"/> + <location filename="../src/gui/dialogs/qprintdialog_unix.cpp" line="+1238"/> <source>Name</source> <translation>Nazwa</translation> </message> @@ -3845,7 +5361,7 @@ Proszę o sprawdzenie podanej nazwy pliku.</translation> <context> <name>QPrintDialog</name> <message> - <location filename="../src/gui/dialogs/qprintdialog_qws.cpp" line="+329"/> + <location filename="../src/gui/dialogs/qprintdialog_qws.cpp" line="+333"/> <source>A0 (841 x 1189 mm)</source> <translation>A0 (841 x 1189 mm)</translation> </message> @@ -3895,13 +5411,18 @@ Proszę o sprawdzenie podanej nazwy pliku.</translation> <translation>A9 (37 x 52 mm)</translation> </message> <message> - <location filename="../src/gui/painting/qprinterinfo_unix.cpp" line="+131"/> + <location line="+40"/> + <source>Print current page</source> + <translation type="unfinished"></translation> + </message> + <message> + <location filename="../src/gui/painting/qprinterinfo_unix.cpp" line="+133"/> <location line="+225"/> <source>Aliases: %1</source> <translation>Aliasy: %1</translation> </message> <message> - <location filename="../src/gui/dialogs/qprintdialog_qws.cpp" line="+1"/> + <location filename="../src/gui/dialogs/qprintdialog_qws.cpp" line="-39"/> <source>B0 (1000 x 1414 mm)</source> <translation>B0 (1000 x 1414 mm)</translation> </message> @@ -3971,7 +5492,7 @@ Proszę o sprawdzenie podanej nazwy pliku.</translation> <translation>podłączony lokalnie</translation> </message> <message> - <location filename="../src/gui/dialogs/qprintdialog_win.cpp" line="+266"/> + <location filename="../src/gui/dialogs/qprintdialog_win.cpp" line="+272"/> <source>OK</source> <translation>OK</translation> </message> @@ -4027,14 +5548,14 @@ Proszę o sprawdzenie podanej nazwy pliku.</translation> <translation>US Common #10 Envelope (105 x 241 mm)</translation> </message> <message> - <location filename="../src/gui/dialogs/qabstractprintdialog.cpp" line="+112"/> + <location filename="../src/gui/dialogs/qabstractprintdialog.cpp" line="+113"/> <location line="+13"/> <location filename="../src/gui/dialogs/qprintdialog_win.cpp" line="-2"/> <source>Print</source> <translation>Drukowanie</translation> </message> <message> - <location filename="../src/gui/dialogs/qprintdialog_unix.cpp" line="-359"/> + <location filename="../src/gui/dialogs/qprintdialog_unix.cpp" line="-392"/> <source>Print To File ...</source> <translation>Drukuj do pliku ...</translation> </message> @@ -4060,7 +5581,7 @@ Please choose a different file name.</source> Proszę wybrać inną nazwę pliku.</translation> </message> <message> - <location filename="../src/gui/dialogs/qprintdialog_qws.cpp" line="-210"/> + <location filename="../src/gui/dialogs/qprintdialog_qws.cpp" line="-214"/> <source>File exists</source> <translation>Plik istnieje</translation> </message> @@ -4070,7 +5591,7 @@ Proszę wybrać inną nazwę pliku.</translation> <translation><qt>Czy chcesz nadpisać?</qt></translation> </message> <message> - <location line="+227"/> + <location line="+231"/> <source>Print selection</source> <translation>Drukuj zaznaczone</translation> </message> @@ -4230,7 +5751,7 @@ Proszę wybrać inną nazwę pliku.</translation> <translation>Niestandardowy</translation> </message> <message> - <location filename="../src/gui/dialogs/qprintdialog_unix.cpp" line="-523"/> + <location filename="../src/gui/dialogs/qprintdialog_unix.cpp" line="-530"/> <location line="+68"/> <source>&Options >></source> <translation>&Opcje >></translation> @@ -4246,7 +5767,7 @@ Proszę wybrać inną nazwę pliku.</translation> <translation>&Opcje <<</translation> </message> <message> - <location line="+253"/> + <location line="+260"/> <source>Print to File (PDF)</source> <translation>Drukuj do pliku (PDF)</translation> </message> @@ -4274,12 +5795,12 @@ Proszę wybrać inną nazwę pliku.</translation> <context> <name>QPrintPreviewDialog</name> <message> - <location filename="../src/gui/dialogs/qprintpreviewdialog.cpp" line="+246"/> + <location filename="../src/gui/dialogs/qprintpreviewdialog.cpp" line="+249"/> <source>%1%</source> <translation>%1%</translation> </message> <message> - <location line="+68"/> + <location line="+84"/> <source>Print Preview</source> <translation>Podgląd wydruku</translation> </message> @@ -4359,7 +5880,12 @@ Proszę wybrać inną nazwę pliku.</translation> <translation>Ustawienia strony</translation> </message> <message> - <location line="+150"/> + <location line="+6"/> + <source>Close</source> + <translation>Zamknij</translation> + </message> + <message> + <location line="+148"/> <source>Export to PDF</source> <translation>Wyeksportuj do PDF</translation> </message> @@ -4490,6 +6016,11 @@ Proszę wybrać inną nazwę pliku.</translation> <source>Short side</source> <translation>Krótka strona</translation> </message> + <message> + <location/> + <source>Current Page</source> + <translation type="unfinished"></translation> + </message> </context> <context> <name>QPrintWidget</name> @@ -4572,7 +6103,7 @@ Proszę wybrać inną nazwę pliku.</translation> <translation>Przekroczony czas operacji procesu</translation> </message> <message> - <location filename="../src/corelib/io/qprocess.cpp" line="+855"/> + <location filename="../src/corelib/io/qprocess.cpp" line="+866"/> <location line="+52"/> <location filename="../src/corelib/io/qprocess_win.cpp" line="-211"/> <location line="+50"/> @@ -4687,7 +6218,7 @@ Proszę wybrać inną nazwę pliku.</translation> <context> <name>QSQLite2Driver</name> <message> - <location filename="../src/sql/drivers/sqlite2/qsql_sqlite2.cpp" line="+391"/> + <location filename="../src/sql/drivers/sqlite2/qsql_sqlite2.cpp" line="+399"/> <source>Error opening database</source> <translation>Błąd otwierania bazy danych</translation> </message> @@ -4715,7 +6246,7 @@ Proszę wybrać inną nazwę pliku.</translation> <translation>Nie można wykonać polecenia</translation> </message> <message> - <location line="-143"/> + <location line="-150"/> <source>Unable to fetch results</source> <translation>Nie można pobrać wyników</translation> </message> @@ -4723,7 +6254,7 @@ Proszę wybrać inną nazwę pliku.</translation> <context> <name>QSQLiteDriver</name> <message> - <location filename="../src/sql/drivers/sqlite/qsql_sqlite.cpp" line="+551"/> + <location filename="../src/sql/drivers/sqlite/qsql_sqlite.cpp" line="+549"/> <source>Error closing database</source> <translation>Błąd zamykania bazy danych</translation> </message> @@ -4751,7 +6282,7 @@ Proszę wybrać inną nazwę pliku.</translation> <context> <name>QSQLiteResult</name> <message> - <location line="-203"/> + <location line="-194"/> <source>Parameter count mismatch</source> <translation>Niezgodna liczba parametrów</translation> </message> @@ -5009,7 +6540,7 @@ Proszę wybrać inną nazwę pliku.</translation> <context> <name>QScriptDebuggerLocalsModel</name> <message> - <location filename="../src/scripttools/debugging/qscriptdebuggerlocalsmodel.cpp" line="+872"/> + <location filename="../src/scripttools/debugging/qscriptdebuggerlocalsmodel.cpp" line="+897"/> <source>Name</source> <translation>Nazwa</translation> </message> @@ -5229,7 +6760,7 @@ Proszę wybrać inną nazwę pliku.</translation> <location filename="../src/corelib/kernel/qsharedmemory_unix.cpp" line="+81"/> <location filename="../src/corelib/kernel/qsharedmemory_win.cpp" line="+87"/> <source>%1: permission denied</source> - <translation>%1: brak dostępu</translation> + <translation>%1: brak uprawnień</translation> </message> <message> <location line="-16"/> @@ -5310,7 +6841,7 @@ Proszę wybrać inną nazwę pliku.</translation> <message> <location filename="../src/corelib/kernel/qsharedmemory_win.cpp" line="+32"/> <source>%1: size query failed</source> - <translation>%1: zapytanie o rozmiar nie powiodło się</translation> + <translation>%1: zapytanie o rozmiar zakończone błędem</translation> </message> <message> <location filename="../src/corelib/kernel/qsharedmemory.cpp" line="-271"/> @@ -5321,7 +6852,7 @@ Proszę wybrać inną nazwę pliku.</translation> <context> <name>QShortcut</name> <message> - <location filename="../src/gui/kernel/qkeysequence.cpp" line="+1249"/> + <location filename="../src/gui/kernel/qkeysequence.cpp" line="+1312"/> <source>+</source> <translation>+</translation> </message> @@ -5332,7 +6863,7 @@ Proszę wybrać inną nazwę pliku.</translation> <translation>Alt</translation> </message> <message> - <location line="-871"/> + <location line="-934"/> <source>Back</source> <translation>Back</translation> </message> @@ -5389,27 +6920,27 @@ Proszę wybrać inną nazwę pliku.</translation> <message> <location line="+1"/> <source>Keyboard Light On/Off</source> - <translation type="unfinished"></translation> + <translation>Włącz/wyłącz podświetlenie klawiatury</translation> </message> <message> <location line="+1"/> <source>Keyboard Brightness Up</source> - <translation type="unfinished"></translation> + <translation>Zwiększ jasność klawiatury</translation> </message> <message> <location line="+1"/> <source>Keyboard Brightness Down</source> - <translation type="unfinished"></translation> + <translation>Zmniejsz jasność klawiatury</translation> </message> <message> <location line="+1"/> <source>Power Off</source> - <translation type="unfinished"></translation> + <translation>Wyłącz zasilanie</translation> </message> <message> <location line="+1"/> <source>Wake Up</source> - <translation type="unfinished"></translation> + <translation>Przebudzenie</translation> </message> <message> <location line="+1"/> @@ -5429,12 +6960,12 @@ Proszę wybrać inną nazwę pliku.</translation> <message> <location line="+1"/> <source>Sleep</source> - <translation type="unfinished"></translation> + <translation>Uśpienie</translation> </message> <message> <location line="+1"/> <source>LightBulb</source> - <translation type="unfinished"></translation> + <translation>Żarówka</translation> </message> <message> <location line="+1"/> @@ -5454,17 +6985,17 @@ Proszę wybrać inną nazwę pliku.</translation> <message> <location line="+1"/> <source>Hot Links</source> - <translation type="unfinished"></translation> + <translation>Popularne łącza</translation> </message> <message> <location line="+1"/> <source>Adjust Brightness</source> - <translation type="unfinished"></translation> + <translation>Ustaw jasność</translation> </message> <message> <location line="+1"/> <source>Finance</source> - <translation type="unfinished"></translation> + <translation>Finanse</translation> </message> <message> <location line="+1"/> @@ -5474,7 +7005,7 @@ Proszę wybrać inną nazwę pliku.</translation> <message> <location line="+1"/> <source>Audio Rewind</source> - <translation type="unfinished"></translation> + <translation>Przewijanie do tyłu</translation> </message> <message> <location line="+1"/> @@ -5534,7 +7065,7 @@ Proszę wybrać inną nazwę pliku.</translation> <message> <location line="+1"/> <source>Display</source> - <translation type="unfinished"></translation> + <translation>Wyświetlacz</translation> </message> <message> <location line="+1"/> @@ -5549,7 +7080,7 @@ Proszę wybrać inną nazwę pliku.</translation> <message> <location line="+1"/> <source>Spreadsheet</source> - <translation type="unfinished"></translation> + <translation>Arkusz kalkulacyjny</translation> </message> <message> <location line="+1"/> @@ -5559,7 +7090,7 @@ Proszę wybrać inną nazwę pliku.</translation> <message> <location line="+1"/> <source>Game</source> - <translation type="unfinished"></translation> + <translation>Gra</translation> </message> <message> <location line="+1"/> @@ -5574,7 +7105,7 @@ Proszę wybrać inną nazwę pliku.</translation> <message> <location line="+1"/> <source>Logoff</source> - <translation type="unfinished"></translation> + <translation>Wyloguj</translation> </message> <message> <location line="+1"/> @@ -5589,12 +7120,12 @@ Proszę wybrać inną nazwę pliku.</translation> <message> <location line="+1"/> <source>Keyboard Menu</source> - <translation type="unfinished"></translation> + <translation>Menu klawiatury</translation> </message> <message> <location line="+1"/> <source>Menu PB</source> - <translation type="unfinished"></translation> + <translation>Menu PB</translation> </message> <message> <location line="+1"/> @@ -5609,7 +7140,7 @@ Proszę wybrać inną nazwę pliku.</translation> <message> <location line="+1"/> <source>Home Office</source> - <translation type="unfinished"></translation> + <translation>Biuro domowe</translation> </message> <message> <location line="+1"/> @@ -5644,12 +7175,12 @@ Proszę wybrać inną nazwę pliku.</translation> <message> <location line="+1"/> <source>Rotation PB</source> - <translation type="unfinished"></translation> + <translation>Obrót PB</translation> </message> <message> <location line="+1"/> <source>Rotation KB</source> - <translation type="unfinished"></translation> + <translation>Obrót KB</translation> </message> <message> <location line="+1"/> @@ -5664,7 +7195,7 @@ Proszę wybrać inną nazwę pliku.</translation> <message> <location line="+1"/> <source>Spellchecker</source> - <translation type="unfinished"></translation> + <translation>Sprawdzanie pisowni</translation> </message> <message> <location line="+1"/> @@ -5679,7 +7210,7 @@ Proszę wybrać inną nazwę pliku.</translation> <message> <location line="+1"/> <source>Task Panel</source> - <translation type="unfinished"></translation> + <translation>Panel zadań</translation> </message> <message> <location line="+1"/> @@ -5704,12 +7235,12 @@ Proszę wybrać inną nazwę pliku.</translation> <message> <location line="+1"/> <source>Word Processor</source> - <translation type="unfinished"></translation> + <translation>Procesor tekstu</translation> </message> <message> <location line="+1"/> <source>XFer</source> - <translation type="unfinished"></translation> + <translation>XFer</translation> </message> <message> <location line="+1"/> @@ -5729,7 +7260,7 @@ Proszę wybrać inną nazwę pliku.</translation> <message> <location line="+1"/> <source>Messenger</source> - <translation type="unfinished"></translation> + <translation>Komunikator</translation> </message> <message> <location line="+1"/> @@ -5739,7 +7270,7 @@ Proszę wybrać inną nazwę pliku.</translation> <message> <location line="+1"/> <source>Mail Forward</source> - <translation type="unfinished"></translation> + <translation>Przekazanie poczty</translation> </message> <message> <location line="+1"/> @@ -5769,22 +7300,22 @@ Proszę wybrać inną nazwę pliku.</translation> <message> <location line="+1"/> <source>Ultra Wide Band</source> - <translation type="unfinished"></translation> + <translation>Ultraszerokie pasmo</translation> </message> <message> <location line="+1"/> <source>Audio Forward</source> - <translation type="unfinished"></translation> + <translation>Przewijanie do przodu</translation> </message> <message> <location line="+1"/> <source>Audio Repeat</source> - <translation type="unfinished"></translation> + <translation>Powtarzanie</translation> </message> <message> <location line="+1"/> <source>Audio Random Play</source> - <translation type="unfinished"></translation> + <translation>Odtwarzanie losowe</translation> </message> <message> <location line="+1"/> @@ -5814,12 +7345,12 @@ Proszę wybrać inną nazwę pliku.</translation> <message> <location line="+1"/> <source>Suspend</source> - <translation type="unfinished"></translation> + <translation>Wstrzymanie</translation> </message> <message> <location line="+1"/> <source>Hibernate</source> - <translation type="unfinished"></translation> + <translation>Hibernacja</translation> </message> <message> <location line="+24"/> @@ -5842,13 +7373,163 @@ Proszę wybrać inną nazwę pliku.</translation> <translation>Kontekst4</translation> </message> <message> - <location line="+578"/> + <location line="+7"/> + <source>Kanji</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+1"/> + <source>Muhenkan</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+1"/> + <source>Henkan</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+1"/> + <source>Romaji</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+1"/> + <source>Hiragana</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+1"/> + <source>Katakana</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+1"/> + <source>Hiragana Katakana</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+1"/> + <source>Zenkaku</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+1"/> + <source>Hankaku</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+1"/> + <source>Zenkaku Hankaku</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+1"/> + <source>Touroku</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+1"/> + <source>Massyo</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+1"/> + <source>Kana Lock</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+1"/> + <source>Kana Shift</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+1"/> + <source>Eisu Shift</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+1"/> + <source>Eisu toggle</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+1"/> + <source>Code input</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+1"/> + <source>Multiple Candidate</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+1"/> + <source>Previous Candidate</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+4"/> + <source>Hangul</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+1"/> + <source>Hangul Start</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+1"/> + <source>Hangul End</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+1"/> + <source>Hangul Hanja</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+1"/> + <source>Hangul Jamo</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+1"/> + <source>Hangul Romaja</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+1"/> + <source>Hangul Jeonja</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+1"/> + <source>Hangul Banja</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+1"/> + <source>Hangul PreHanja</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+1"/> + <source>Hangul PostHanja</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+1"/> + <source>Hangul Special</source> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+602"/> <location line="+135"/> <source>Ctrl</source> <translation>Ctrl</translation> </message> <message> - <location line="-890"/> + <location line="-953"/> <source>Del</source> <translation>Del</translation> </message> @@ -5883,12 +7564,12 @@ Proszę wybrać inną nazwę pliku.</translation> <translation>Escape</translation> </message> <message> - <location line="+746"/> + <location line="+809"/> <source>F%1</source> <translation>F%1</translation> </message> <message> - <location line="-870"/> + <location line="-933"/> <source>Favorites</source> <translation>Ulubione</translation> </message> @@ -6058,13 +7739,13 @@ Proszę wybrać inną nazwę pliku.</translation> <translation>Menu</translation> </message> <message> - <location line="+743"/> + <location line="+806"/> <location line="+130"/> <source>Meta</source> <translation>Meta</translation> </message> <message> - <location line="-718"/> + <location line="-781"/> <source>No</source> <translation>Nie</translation> </message> @@ -6160,13 +7841,13 @@ Proszę wybrać inną nazwę pliku.</translation> <translation>Wybierz</translation> </message> <message> - <location line="+588"/> + <location line="+651"/> <location line="+138"/> <source>Shift</source> <translation>Shift</translation> </message> <message> - <location line="-902"/> + <location line="-965"/> <source>Space</source> <translation>Spacja</translation> </message> @@ -6335,7 +8016,7 @@ Proszę wybrać inną nazwę pliku.</translation> <context> <name>QSoftKeyManager</name> <message> - <location filename="../src/gui/kernel/qsoftkeymanager.cpp" line="+79"/> + <location filename="../src/gui/kernel/qsoftkeymanager.cpp" line="+63"/> <source>Ok</source> <translation>OK</translation> </message> @@ -6360,7 +8041,7 @@ Proszę wybrać inną nazwę pliku.</translation> <translation>Anuluj</translation> </message> <message> - <location line="+176"/> + <location filename="../src/gui/kernel/qsoftkeymanager_s60.cpp" line="+319"/> <source>Exit</source> <translation>Wyjście</translation> </message> @@ -6438,12 +8119,17 @@ Proszę wybrać inną nazwę pliku.</translation> <context> <name>QSslSocket</name> <message> - <location filename="../src/network/ssl/qsslsocket_openssl.cpp" line="+546"/> + <location filename="../src/network/ssl/qsslsocket_openssl.cpp" line="+550"/> <source>Unable to write data: %1</source> - <translation>Nie można zapisać danych: %1</translation> + <translation></translation> </message> <message> - <location line="+119"/> + <location line="+63"/> + <source>Unable to decrypt data: %1</source> + <translation>Nie można odszyfrować danych: %1</translation> + </message> + <message> + <location line="+76"/> <source>Error while reading: %1</source> <translation>Błąd podczas czytania: %1</translation> </message> @@ -6453,7 +8139,7 @@ Proszę wybrać inną nazwę pliku.</translation> <translation>Błąd podczas nawiązania sesji SSL: %1</translation> </message> <message> - <location line="-501"/> + <location line="-524"/> <source>Error creating SSL context (%1)</source> <translation>Błąd tworzenia kontekstu (%1)</translation> </message> @@ -6463,7 +8149,7 @@ Proszę wybrać inną nazwę pliku.</translation> <translation>Niepoprawna lub pusta lista szyfrów (%1)</translation> </message> <message> - <location line="+42"/> + <location line="+45"/> <source>Private key does not certify public key, %1</source> <translation>Prywatny klucz nie uwiarygodnia publicznego, %1</translation> </message> @@ -6478,7 +8164,7 @@ Proszę wybrać inną nazwę pliku.</translation> <translation>Błąd tworzenia sesji SSL: %1</translation> </message> <message> - <location line="-61"/> + <location line="-64"/> <source>Cannot provide a certificate with no key, %1</source> <translation>Nie można dostarczyć certyfikatu bez klucza, %1</translation> </message> @@ -6488,7 +8174,7 @@ Proszę wybrać inną nazwę pliku.</translation> <translation>Błąd ładowania lokalnego certyfikatu, %1</translation> </message> <message> - <location line="+12"/> + <location line="+15"/> <source>Error loading private key, %1</source> <translation>Błąd ładowania prywatnego klucza, %1</translation> </message> @@ -6540,67 +8226,67 @@ Proszę wybrać inną nazwę pliku.</translation> <message> <location line="+3"/> <source>The certificate is self-signed, and untrusted</source> - <translation type="unfinished"></translation> + <translation>Niewiarygodny certyfikat z podpisem własnym</translation> </message> <message> <location line="+3"/> <source>The root certificate of the certificate chain is self-signed, and untrusted</source> - <translation type="unfinished"></translation> + <translation>Główny certyfikat łańcucha zaufania ma własny podpis i jest niewiarygodny</translation> </message> <message> <location line="+3"/> <source>The issuer certificate of a locally looked up certificate could not be found</source> - <translation type="unfinished"></translation> + <translation>Nie można odnaleźć certyfikatu wydawcy wyszukanego lokalnie certyfikatu</translation> </message> <message> <location line="+3"/> <source>No certificates could be verified</source> - <translation type="unfinished"></translation> + <translation>Nie można zweryfikować żadnych certyfikatów</translation> </message> <message> <location line="+3"/> <source>One of the CA certificates is invalid</source> - <translation type="unfinished"></translation> + <translation>Jeden z certyfikatów urzędu certyfikacji jest nieprawidłowy</translation> </message> <message> <location line="+3"/> <source>The basicConstraints path length parameter has been exceeded</source> - <translation type="unfinished"></translation> + <translation>Długość ścieżki określona w podstawowych warunkach ograniczających została przekroczona</translation> </message> <message> <location line="+3"/> <source>The supplied certificate is unsuitable for this purpose</source> - <translation type="unfinished"></translation> + <translation>Dostarczony certyfikat jest nieodpowiedni dla tego przeznaczenia</translation> </message> <message> <location line="+3"/> <source>The root CA certificate is not trusted for this purpose</source> - <translation type="unfinished"></translation> + <translation>Główny certyfikat urzędu certyfikacji nie jest wiarygodny dla tego przeznaczenia</translation> </message> <message> <location line="+3"/> <source>The root CA certificate is marked to reject the specified purpose</source> - <translation type="unfinished"></translation> + <translation>Główny certyfikat urzędu certyfikacji jest wyznaczony do odrzucania podanego przeznaczenia</translation> </message> <message> <location line="+3"/> <source>The current candidate issuer certificate was rejected because its subject name did not match the issuer name of the current certificate</source> - <translation type="unfinished"></translation> + <translation>Certyfikat wydawcy obecnego kandydata został odrzucony, ponieważ nazwa podmiotu nie odpowiadała nazwie wydawcy obecnego certyfikatu</translation> </message> <message> <location line="+4"/> <source>The current candidate issuer certificate was rejected because its issuer name and serial number was present and did not match the authority key identifier of the current certificate</source> - <translation type="unfinished"></translation> + <translation>Certyfikat wydawcy obecnego kandydata został odrzucony, ponieważ nazwa wydawcy i przedstawiony numer seryjny nie odpowiadały identyfikatorowi klucza urzędu certyfikacji obecnego certyfikatu</translation> </message> <message> <location line="+5"/> <source>The peer did not present any certificate</source> - <translation type="unfinished"></translation> + <translation>Element równorzędny nie przedstawił żadnego certyfikatu</translation> </message> <message> <location line="+3"/> <source>The host name did not match any of the valid hosts for this certificate</source> - <translation type="unfinished"></translation> + <translation>Nazwa hosta nie odpowiadała żadnemu z poprawnych hostów dla tego certyfikatu</translation> </message> <message> <location line="+6"/> @@ -6613,17 +8299,17 @@ Proszę wybrać inną nazwę pliku.</translation> <message> <location filename="../src/corelib/statemachine/qstatemachine.cpp" line="+1028"/> <source>Missing initial state in compound state '%1'</source> - <translation>Brak stanu początkowego w stanie złożonym '%1'</translation> + <translation>Brak stanu początkowego w stanie złożonym "%1"</translation> </message> <message> <location line="+7"/> <source>Missing default state in history state '%1'</source> - <translation>Brak domyślnego stanu w historycznym stanie '%1'</translation> + <translation>Brak domyślnego stanu w historycznym stanie "%1"</translation> </message> <message> <location line="+7"/> <source>No common ancestor for targets and source of transition from state '%1'</source> - <translation>Brak wspólnego przodka dla stanów docelowych i stanu źródłowego w przejściu ze stanu '%1'</translation> + <translation>Brak wspólnego przodka dla stanów docelowych i stanu źródłowego w przejściu ze stanu "%1"</translation> </message> <message> <location line="+4"/> @@ -6643,7 +8329,7 @@ Proszę wybrać inną nazwę pliku.</translation> <location line="-13"/> <location filename="../src/corelib/kernel/qsystemsemaphore_win.cpp" line="+4"/> <source>%1: permission denied</source> - <translation>%1: brak dostępu</translation> + <translation>%1: brak uprawnień</translation> </message> <message> <location line="+4"/> @@ -6691,7 +8377,7 @@ Proszę wybrać inną nazwę pliku.</translation> <context> <name>QTcpServer</name> <message> - <location filename="../src/network/socket/qtcpserver.cpp" line="+282"/> + <location filename="../src/network/socket/qtcpserver.cpp" line="+292"/> <source>Operation on socket is not supported</source> <translation>Operacja na gnieździe nieobsługiwana</translation> </message> @@ -6699,7 +8385,7 @@ Proszę wybrać inną nazwę pliku.</translation> <context> <name>QTextControl</name> <message> - <location filename="../src/gui/text/qtextcontrol.cpp" line="+2034"/> + <location filename="../src/gui/text/qtextcontrol.cpp" line="+2047"/> <source>&Copy</source> <translation>S&kopiuj</translation> </message> @@ -6711,7 +8397,7 @@ Proszę wybrać inną nazwę pliku.</translation> <message> <location line="-12"/> <source>Cu&t</source> - <translation>&Wytnij</translation> + <translation>W&ytnij</translation> </message> <message> <location line="+21"/> @@ -6757,7 +8443,7 @@ Proszę wybrać inną nazwę pliku.</translation> <context> <name>QUdpSocket</name> <message> - <location filename="../src/network/socket/qudpsocket.cpp" line="+179"/> + <location filename="../src/network/socket/qudpsocket.cpp" line="+189"/> <source>This platform does not support IPv6</source> <translation>Ta platforma nie obsługuje IPv6</translation> </message> @@ -6857,7 +8543,7 @@ Proszę wybrać inną nazwę pliku.</translation> <context> <name>QWebFrame</name> <message> - <location filename="../src/3rdparty/webkit/WebKit/qt/WebCoreSupport/FrameLoaderClientQt.cpp" line="+712"/> + <location filename="../src/3rdparty/webkit/WebKit/qt/WebCoreSupport/FrameLoaderClientQt.cpp" line="+753"/> <source>Request cancelled</source> <translation>Prośba anulowana</translation> </message> @@ -6890,7 +8576,7 @@ Proszę wybrać inną nazwę pliku.</translation> <context> <name>QWebPage</name> <message> - <location filename="../src/3rdparty/webkit/WebCore/platform/qt/Localizations.cpp" line="+42"/> + <location filename="../src/3rdparty/webkit/WebCore/platform/qt/Localizations.cpp" line="+44"/> <source>Submit</source> <comment>default label for Submit buttons in forms on web pages</comment> <translation>Wyślij</translation> @@ -7130,7 +8816,13 @@ Proszę wybrać inną nazwę pliku.</translation> <translation>Domyślny</translation> </message> <message> - <location line="+115"/> + <location line="+110"/> + <source>Missing Plug-in</source> + <comment>Label text to be used when a plug-in is missing</comment> + <translation type="unfinished"></translation> + </message> + <message> + <location line="+20"/> <source>Loading...</source> <comment>Media controller status message when the media is loading</comment> <translation>Ładowanie...</translation> @@ -7271,7 +8963,7 @@ Proszę wybrać inną nazwę pliku.</translation> <location line="+2"/> <source>Pause playback</source> <comment>Media controller element</comment> - <translation>Wstrzymaj odtwarzanie</translation> + <translation>Zatrzymaj odtwarzanie</translation> </message> <message> <location line="+2"/> @@ -7364,7 +9056,7 @@ Proszę wybrać inną nazwę pliku.</translation> <translation>%1 sekund</translation> </message> <message> - <location line="-210"/> + <location line="-225"/> <source>Inspect</source> <comment>Inspect Element context menu item</comment> <translation>Zwiedzaj</translation> @@ -7388,23 +9080,23 @@ Proszę wybrać inną nazwę pliku.</translation> <translation>Wyczyść ostatnie wyszukiwania</translation> </message> <message> - <location line="+75"/> + <location line="+90"/> <source>Unknown</source> <comment>Unknown filesize FTP directory listing item</comment> <translation>Nieznany</translation> </message> <message> - <location filename="../src/3rdparty/webkit/WebKit/qt/WebCoreSupport/InspectorClientQt.cpp" line="+167"/> + <location filename="../src/3rdparty/webkit/WebKit/qt/WebCoreSupport/InspectorClientQt.cpp" line="+236"/> <source>Web Inspector - %2</source> <translation>Wizytator sieciowy - %2</translation> </message> <message> - <location filename="../src/3rdparty/webkit/WebCore/platform/network/qt/QNetworkReplyHandler.cpp" line="+416"/> + <location filename="../src/3rdparty/webkit/WebCore/platform/network/qt/QNetworkReplyHandler.cpp" line="+456"/> <source>Bad HTTP request</source> <translation>Niepoprawna komenda HTTP</translation> </message> <message> - <location filename="../src/3rdparty/webkit/WebCore/platform/qt/Localizations.cpp" line="-286"/> + <location filename="../src/3rdparty/webkit/WebCore/platform/qt/Localizations.cpp" line="-301"/> <source>This is a searchable index. Enter search keywords: </source> <comment>text that appears at the start of nearly-obsolete web pages in the form of a 'searchable index'</comment> <translation>To jest indeks wyszukiwawczy. Podaj słowa do wyszukania:</translation> @@ -7422,7 +9114,7 @@ Proszę wybrać inną nazwę pliku.</translation> <translation>Z prawej na lewą</translation> </message> <message> - <location line="+100"/> + <location line="+115"/> <source>%1 (%2x%3 pixels)</source> <comment>Title string for images</comment> <translation>%1 (%2x%3 piksli)</translation> @@ -7503,22 +9195,22 @@ Proszę wybrać inną nazwę pliku.</translation> </translation> </message> <message> - <location filename="../src/3rdparty/webkit/WebKit/qt/Api/qwebpage.cpp" line="+1827"/> + <location filename="../src/3rdparty/webkit/WebKit/qt/Api/qwebpage.cpp" line="+1959"/> <source>JavaScript Alert - %1</source> <translation>Ostrzeżenie JavaScript - %1</translation> </message> <message> - <location line="+16"/> + <location line="+17"/> <source>JavaScript Confirm - %1</source> <translation>Potwierdzenie JavaScript - %1</translation> </message> <message> - <location line="+18"/> + <location line="+20"/> <source>JavaScript Prompt - %1</source> <translation>Zachęta JavaScript - %1</translation> </message> <message> - <location line="+25"/> + <location line="+26"/> <source>JavaScript Problem - %1</source> <translation>Problem JavaScript - %1</translation> </message> @@ -7528,7 +9220,7 @@ Proszę wybrać inną nazwę pliku.</translation> <translation>Skrypt na tej stronie nie działa poprawnie. Czy chcesz przerwać ten skrypt?</translation> </message> <message> - <location line="+381"/> + <location line="+374"/> <source>Move the cursor to the next character</source> <translation>Przesuń kursor do następnego znaku</translation> </message> @@ -7749,7 +9441,7 @@ Proszę wybrać inną nazwę pliku.</translation> <context> <name>QWidget</name> <message> - <location filename="../src/gui/kernel/qwidget.cpp" line="+5723"/> + <location filename="../src/gui/kernel/qwidget.cpp" line="+5809"/> <source>*</source> <translation>*</translation> </message> @@ -7757,7 +9449,7 @@ Proszę wybrać inną nazwę pliku.</translation> <context> <name>QWizard</name> <message> - <location filename="../src/gui/dialogs/qwizard.cpp" line="+649"/> + <location filename="../src/gui/dialogs/qwizard.cpp" line="+689"/> <source>Go Back</source> <translation>Wróć</translation> </message> @@ -8001,6 +9693,34 @@ Proszę wybrać inną nazwę pliku.</translation> </message> </context> <context> + <name>QXmlPatternistCLI</name> + <message> + <location filename="../src/xmlpatterns/api/qcoloringmessagehandler.cpp" line="+87"/> + <source>Warning in %1, at line %2, column %3: %4</source> + <translation>Ostrzeżenie w %1, wiersz %2, kolumna %3: %4</translation> + </message> + <message> + <location line="+7"/> + <source>Warning in %1: %2</source> + <translation>Ostrzeżenie w %1: %2</translation> + </message> + <message> + <location line="+16"/> + <source>Unknown location</source> + <translation>Nieznane położenie</translation> + </message> + <message> + <location line="+14"/> + <source>Error %1 in %2, at line %3, column %4: %5</source> + <translation>Błąd %1 w %2, wiersz %3, kolumna %4: %5</translation> + </message> + <message> + <location line="+8"/> + <source>Error %1 in %2: %3</source> + <translation>Błąd %1 w %2: %3</translation> + </message> +</context> +<context> <name>QXmlStream</name> <message> <location filename="../src/corelib/xml/qxmlstream.cpp" line="+611"/> @@ -9834,7 +11554,7 @@ Proszę wybrać inną nazwę pliku.</translation> <translation>Brak podelementu w tym zakresie, możliwymi podelementami są: %1.</translation> </message> <message> - <location line="+127"/> + <location line="+143"/> <source>Document is not a XML schema.</source> <translation>Dokument nie jest schematem XML.</translation> </message> @@ -9860,7 +11580,7 @@ Proszę wybrać inną nazwę pliku.</translation> <translation>Docelowa przestrzeń nazw %1 zaimportowanego schematu jest różna od docelowej przestrzeni nazw %2 która jest zdefiniowana w schemacie importującym.</translation> </message> <message> - <location line="+237"/> + <location line="+243"/> <source>%1 element is not allowed to have the same %2 attribute value as the target namespace %3.</source> <translation>Element %1 nie może zawierać tej samej wartości atrybutu %2 co docelowa przestrzeń nazw %3.</translation> </message> @@ -9870,7 +11590,7 @@ Proszę wybrać inną nazwę pliku.</translation> <translation>Element %1 bez atrybutu %2 jest niedozwolony wewnątrz schematu bez docelowej przestrzeni nazw.</translation> </message> <message> - <location line="+833"/> + <location line="+851"/> <location line="+158"/> <source>%1 element is not allowed inside %2 element if %3 attribute is present.</source> <translation>Element %1 jest niedozwolony wewnątrz elementu %2 jeśli jest obecny atrybut %3.</translation> @@ -10555,4 +12275,12 @@ Proszę wybrać inną nazwę pliku.</translation> <translation>Atrybut "%1" zawiera niepoprawną zawartość QName: %2.</translation> </message> </context> +<context> + <name>Widget</name> + <message> + <location filename="../src/3rdparty/webkit/WebKit/qt/tests/hybridPixmap/widget.ui"/> + <source>about:blank</source> + <translation type="unfinished"></translation> + </message> +</context> </TS> |