platform/upstream/qtdeclarative.git
9 years agoAdd inheritance documentation markup to animator classes.
Friedemann Kleint [Mon, 30 Mar 2015 15:18:26 +0000 (17:18 +0200)]
Add inheritance documentation markup to animator classes.

Task-number: QTBUG-45220
Change-Id: Ie817275897f860b0d6c4dcac2f92a4f3469a4611
Reviewed-by: Leena Miettinen <riitta-leena.miettinen@theqtcompany.com>
9 years agoFix some qdoc warnings.
Friedemann Kleint [Wed, 25 Mar 2015 14:34:03 +0000 (15:34 +0100)]
Fix some qdoc warnings.

qtdeclarative/src/qml/qml/qqmlinfo.cpp:46: warning: Cannot find 'qmlInfo(...)' in '\fn' QQmlInfo qmlInfo(const QObject *object)
qtdeclarative/src/qml/qml/qqmlexpression.cpp:366: warning: Undocumented parameter 'column' in QQmlExpression::setSourceLocation()
qtdeclarative/src/qml/doc/src/qmlfunctions.qdoc:176: warning: Undocumented parameter 'reason' in qmlRegisterExtendedUncreatableType()
qtdeclarative/src/qml/doc/src/qmlfunctions.qdoc:176: warning: No such parameter 'message' in qmlRegisterExtendedUncreatableType()

Change-Id: Iec801b33b11bd57abadd968a90c49f8eba1280d5
Reviewed-by: Leena Miettinen <riitta-leena.miettinen@theqtcompany.com>
Reviewed-by: Alan Alpert (Personal) <416365416c@gmail.com>
9 years agoHonor setFocusOnTouchRelease in QQuickTextInput
Kai Uwe Broulik [Tue, 17 Mar 2015 13:26:35 +0000 (14:26 +0100)]
Honor setFocusOnTouchRelease in QQuickTextInput

[ChangeLog][QtQuick][TextInput] SetFocusOnTouchRelease is honored

Change-Id: I0c5150465effadb7b1221250875aedf16a83bb2c
Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@theqtcompany.com>
9 years agoadd qt.quick.touch.target logging category
Shawn Rutledge [Mon, 9 Mar 2015 16:16:34 +0000 (17:16 +0100)]
add qt.quick.touch.target logging category

qt.quick.touch produces a lot of output.  This instead tracks only
the changes to the itemForTouchPointId hash: which touchpoints are
being sent to which items.

Change-Id: I5119b4716a43fb35fd6c6712bf7d4ec46d762a9f
Reviewed-by: Laszlo Agocs <laszlo.agocs@theqtcompany.com>
9 years agoUpdate the shader when devicePixelRatio changes
Paul Olav Tvete [Fri, 27 Mar 2015 14:32:16 +0000 (15:32 +0100)]
Update the shader when devicePixelRatio changes

Task-number: QTBUG-45076
Change-Id: I03de20da2e3f436339dcf48fc7d7d3d11a509577
Reviewed-by: Gunnar Sletta <gunnar@sletta.org>
9 years agoGuard profiler service test against unusual clock behavior.
Ulf Hermann [Fri, 27 Mar 2015 14:07:32 +0000 (15:07 +0100)]
Guard profiler service test against unusual clock behavior.

Apparently a monotonic timer can return the exact same timestamp
multiple times in a row. In this case the events may be sorted in a
different way than we expect. By scanning all events with equal
timestamps for the one we're looking for, we can still keep the test
useful.

Change-Id: I08e1d7ed8d74359a127ac34ebc077375aa70f492
Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
9 years agoQQuickWidget: expose the underlying QQuickWindow
Giuseppe D'Angelo [Thu, 26 Mar 2015 20:34:42 +0000 (21:34 +0100)]
QQuickWidget: expose the underlying QQuickWindow

There's a number of APIs (such as all the scenegraph-related
signals) that are currently missing from QQuickWidget.
Instead of duplicating every API in QQuickWidget, simply expose
the underlying offscreen QQuickWindow.

Task-number: QTBUG-45260
Change-Id: I1a89fe600ce675963ea24ee6dd56d6ca4fea9cd2
Reviewed-by: Andy Shaw <andy.shaw@digia.com>
Reviewed-by: Gunnar Sletta <gunnar@sletta.org>
Reviewed-by: Laszlo Agocs <laszlo.agocs@theqtcompany.com>
9 years agoFix flushing QQuickWidget
Laszlo Agocs [Thu, 19 Mar 2015 15:18:16 +0000 (16:18 +0100)]
Fix flushing QQuickWidget

Like it was done for QOpenGLWidget.

Task-number: QTBUG-45106
Change-Id: I69c11f53f781f57ceebb9b7ed95a2753bff31492
Reviewed-by: Giuseppe D'Angelo <giuseppe.dangelo@kdab.com>
9 years agoRemove the old headersclean unit test
Thiago Macieira [Thu, 18 Dec 2014 03:37:18 +0000 (19:37 -0800)]
Remove the old headersclean unit test

We have configure -headersclean now

Change-Id: If48fb86c9f130450d8ffa94a9e52584141a2d793
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
9 years agoFixing yet another memory leak
Robert Griebl [Mon, 23 Mar 2015 13:40:03 +0000 (14:40 +0100)]
Fixing yet another memory leak

Change-Id: I1c083a488f963f8dd40f3bd6db5a46ac9db66ffb
Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
9 years agoAnother fix to avoid detaching the m_windows list.
Robert Griebl [Mon, 23 Mar 2015 12:38:28 +0000 (13:38 +0100)]
Another fix to avoid detaching the m_windows list.

Just like commit 310fd3ed, this fixes another unnecessary detach.

Change-Id: I5108ea5112a4b0e877f86d06868375abb9a80409
Reviewed-by: Gunnar Sletta <gunnar@sletta.org>
9 years agoFixed a memory-leak when changing property bindings in states.
Robert Griebl [Mon, 23 Mar 2015 12:28:49 +0000 (13:28 +0100)]
Fixed a memory-leak when changing property bindings in states.

Bindings that were still stored in the revert-list when the state
was destructed were not deleted before. This could lead to considerable
memory leaks in big applications.

Change-Id: I73250f7d03a42c25ca729c18082125fd8f3c8989
Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
9 years agoFix profiler adapter documentation
Ulf Hermann [Mon, 23 Mar 2015 14:53:23 +0000 (15:53 +0100)]
Fix profiler adapter documentation

Update it to include the features arguments and mark it as internal.

Change-Id: If0324d413c60d3d4bb203fb383dcd20e50db0e88
Reviewed-by: Leena Miettinen <riitta-leena.miettinen@theqtcompany.com>
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@theqtcompany.com>
9 years agoDoc: Removed a col from the table of qmldir statements
Venugopal Shivashankar [Wed, 18 Mar 2015 12:31:58 +0000 (13:31 +0100)]
Doc: Removed a col from the table of qmldir statements

The table was too wide for the online template, which
limits the width to 80 columns. Removed a redundant
column in the table so that the readability improves
in online version of the doc.

Change-Id: I633cd81225333d814b1d47aa155130b8d6958e3e
Reviewed-by: Leena Miettinen <riitta-leena.miettinen@theqtcompany.com>
Reviewed-by: Martin Smith <martin.smith@digia.com>
9 years agoFix disappearing text in selections
Eskil Abrahamsen Blomfeldt [Fri, 20 Mar 2015 13:21:46 +0000 (14:21 +0100)]
Fix disappearing text in selections

Change 11a595e30615943cd6c63f08cc44cde7861112eb introduced a
regression where selected text might disappear randomly because
we changed the order the nodes were added to the list. The
order is significant in cases where there is overlap, such as
for painting selections.

Instead of iterating over the hash and thus getting the regular
nodes in random order, we make the first node with any given
key the primary node, add this to the list immediately, and then
just do a look up in the hash for the nodes that should be
merged with it.

Change-Id: Id2208ab672294aa3dd2bc9741e6c6697c2c66746
Task-number: QTBUG-45133
Reviewed-by: aavit <eirik.aavitsland@theqtcompany.com>
9 years agoFix inconsistent overrides. [-Winconsistent-missing-override]
Sérgio Martins [Thu, 19 Mar 2015 20:34:49 +0000 (20:34 +0000)]
Fix inconsistent overrides. [-Winconsistent-missing-override]

Change-Id: Ia0f3b50fd14f846c4e36cdaa12d5579902137f1b
Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
9 years agoRemove QItemSelection value-type, use Array instead
Gabriel de Dietrich [Fri, 6 Mar 2015 18:27:22 +0000 (19:27 +0100)]
Remove QItemSelection value-type, use Array instead

We implement this by adding QItemSelection to the
set of sequence types.

Change-Id: Ia3db376c806d8f062639e22c7f4bf392f114c266
Reviewed-by: Stephen Kelly <steveire@gmail.com>
9 years agoRemove QModelIndexList value type, use Array instead
Gabriel de Dietrich [Tue, 3 Mar 2015 17:36:51 +0000 (18:36 +0100)]
Remove QModelIndexList value type, use Array instead

We implement this by adding QModelIndexList to the
set of sequence types.

Change-Id: If7e0e88ab0c2916c2b65a926f8241549520d7391
Reviewed-by: Stephen Kelly <steveire@gmail.com>
9 years agoRemove unused variable in InstructionSelection::run()
Maks Naumov [Sat, 21 Mar 2015 17:37:17 +0000 (19:37 +0200)]
Remove unused variable in InstructionSelection::run()

Change-Id: I61ebeab024cd3e31e9d94810454328b4e8d48364
Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
9 years agoFix conversion between char and string.
Christian Strømme [Thu, 12 Mar 2015 14:33:50 +0000 (15:33 +0100)]
Fix conversion between char and string.

If a QChar (or char) was used to set a QString property, the
intermediate value used by the QML engine (int), would be
converted to a string representation of the integer and not the actual
character. To avoid this behavior, characters are now stored as string
objects and the string is then converted to the target char type if
possible.
A side effect of this solution is that it is makes it possible to
assign a string to a char property as well, but only if the string
contains exactly one character.

[ChangeLog][QtQml][Important Behavior Changes] Assigning a char to a
string will now create a string with the actual character instead of a
string representation of the character's code-point. A side effect of
this change is that a one-character string also can be assigned to a
character type.

Task-number: QTBUG-44934
Change-Id: Ifd15386933ee11354ee1bbb5598a5f0b00a08616
Reviewed-by: Alan Alpert (Personal) <416365416c@gmail.com>
Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
9 years agoQQuickWindow touch event compression: retain previous positions
Shawn Rutledge [Fri, 13 Mar 2015 14:13:22 +0000 (15:13 +0100)]
QQuickWindow touch event compression: retain previous positions

The previous positions in the delayed touch event should be from
the first touchpoint which is being delayed, not updated based on
subsequent updates that are being merged into it.  Clarified
naming and comments in this section.

Task-number: QTBUG-40167
Change-Id: Ie419267e4a33277f9154bd80f5bce104e52d773e
Reviewed-by: Robin Burchell <robin.burchell@viroteck.net>
Reviewed-by: Gunnar Sletta <gunnar@sletta.org>
9 years agoDoc: Added info. about the singleton type declaration
Venugopal Shivashankar [Wed, 18 Mar 2015 13:25:11 +0000 (14:25 +0100)]
Doc: Added info. about the singleton type declaration

Task-number:QTBUG-37057
Change-Id: I458bc4fe3920b70c201da0a09b437965b651872e
Reviewed-by: Shawn Rutledge <shawn.rutledge@digia.com>
Reviewed-by: Caroline Chao <caroline.chao@theqtcompany.com>
Reviewed-by: Alan Alpert <aalpert@blackberry.com>
9 years agoAllow Flickable's grab to be stolen if dragging over bounds.
Andrew den Exter [Tue, 10 Mar 2015 01:59:23 +0000 (11:59 +1000)]
Allow Flickable's grab to be stolen if dragging over bounds.

This allows a parent item to intercept a drag gesture in one direction
when the flickable has reached it's limit in that direction without
disabling the drag over bounds for drag gestures in the opposite
direction.

Change-Id: I6ac60113f150dbb8da42d9b5593325b04be166f5
Reviewed-by: Martin Jones <martin.jones@qinetic.com.au>
9 years agoRemove forward declaration of QScriptContext
Lars Knoll [Wed, 18 Mar 2015 13:39:20 +0000 (14:39 +0100)]
Remove forward declaration of QScriptContext

Change-Id: I2ab642b73bf7fdd5d82085b0dc0f61d32a5c1fb5
Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
9 years agoqmltest: Make sure we inherit all of testlib's MODULE_CONFIG
Tor Arne Vestbø [Wed, 18 Mar 2015 12:18:43 +0000 (13:18 +0100)]
qmltest: Make sure we inherit all of testlib's MODULE_CONFIG

We don't know what's in testlib's MODULE_CONFIG, so we can't hard-code
the value. E.g., with the introduction of XCTest support in testlib [1],
we'll gain an additional member in testlib's module config set for taking
care of the XCTest framework include path, and this value also needs to
be propagated/inherited to the final target.

[1] https://codereview.qt-project.org/#/c/107477/

Change-Id: I28ee44ac41f148a873ab35adcae38e73bef3316f
Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
9 years agoMerge "Merge remote-tracking branch 'origin/5.4' into 5.5" into refs/staging/5.5
Frederik Gladhorn [Tue, 17 Mar 2015 12:08:08 +0000 (12:08 +0000)]
Merge "Merge remote-tracking branch 'origin/5.4' into 5.5" into refs/staging/5.5

9 years agoRepeater: Don't rely on the createFrom variable
Jørgen Lind [Wed, 11 Mar 2015 13:39:40 +0000 (14:39 +0100)]
Repeater: Don't rely on the createFrom variable

since this breaks for asynchronous models, because item creation order
is not guaranteed. We always have the index
for what item to create, so we do not need it either.

Change-Id: Ib8ce25ac342f5cce4784c56e6a91cf70136566b3
Task-number: QTBUG-38879
Task-number: QTBUG-39001
Task-number: QTBUG-44250
Reviewed-by: Ulf Hermann <ulf.hermann@theqtcompany.com>
9 years agoMerge remote-tracking branch 'origin/5.4' into 5.5
Frederik Gladhorn [Tue, 17 Mar 2015 08:48:35 +0000 (09:48 +0100)]
Merge remote-tracking branch 'origin/5.4' into 5.5

Change-Id: I4c338a44c1d64c2d8e637971ab3ec6982c40a685

9 years agoFix warning
Aleix Pol [Fri, 27 Feb 2015 15:39:21 +0000 (16:39 +0100)]
Fix warning

If the arguments of console.timeEnd are wrong, say it's timeEnd instead of
time.

Change-Id: Ida8a76cd452cf3aecc03e5064bbf213333d93a03
Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
9 years agoFix usage of QtQmlDevTools private headers on OSX with framework builds
Simon Hausmann [Mon, 9 Mar 2015 15:39:32 +0000 (16:39 +0100)]
Fix usage of QtQmlDevTools private headers on OSX with framework builds

Previously this module borrowed its private headers from QtQml, so that
when writing QT += qmldevtools-private, you'd get the private headers from
QtQml. This doesn't work when QtQml is built as a framework.

A cleaner solution is to give this module its headers proper by letting
syncqt create the forwarding headers correctly (and consequently also
include them in make install). In order for this to work, the included
headers themselves cannot include any headers from QtQml, which this
patch also takes care of, through a centralized inclusion of qv4global_p.h.

Change-Id: I9bb8337956a2774cfaca6b338369face6c6ee785
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
Reviewed-by: Frederik Gladhorn <frederik.gladhorn@theqtcompany.com>
9 years agoRemove QQmlDirParser from QtQmlDevTools
Simon Hausmann [Fri, 13 Mar 2015 11:47:16 +0000 (12:47 +0100)]
Remove QQmlDirParser from QtQmlDevTools

This class is not needed in the library.

Change-Id: Ie880086a849b62a2856d1f388a64d363b040cb56
Reviewed-by: Frederik Gladhorn <frederik.gladhorn@theqtcompany.com>
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
9 years agoPathView: use qt.quick.itemview.lifecycle logging category
Shawn Rutledge [Wed, 11 Mar 2015 15:02:33 +0000 (16:02 +0100)]
PathView: use qt.quick.itemview.lifecycle logging category

It is the same for debugging delegate cycling in ListView.

Task-number: QTBUG-42716
Change-Id: I54b83a25a5d8473c643cd326fe114317103bb24e
Reviewed-by: J-P Nurmi <jpnurmi@theqtcompany.com>
9 years agoAcknowledge QPersistentModelIndex is a built-in meta-type
Gabriel de Dietrich [Thu, 12 Mar 2015 17:45:54 +0000 (18:45 +0100)]
Acknowledge QPersistentModelIndex is a built-in meta-type

We remove the now unnecessary meta-type registration and
conversions for QPersistenModelIndex.

This reverts and amends commit 7b29a983fa794291ff8ec.

Change-Id: I4e8346bb7ab03766e1dd5c2c23bb6cf47ab1f455
Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com>
9 years agoRemove bogus autotests for invalid ports
Kai Koehne [Thu, 12 Mar 2015 08:41:08 +0000 (09:41 +0100)]
Remove bogus autotests for invalid ports

Qt itself doesn't prevent opening a socket in the reserved port range.
So what these tests actually check is the system configuration, not Qt.

Task-number: QTBUG-44952
Change-Id: Iee6d6d1a5a7a0f4d2039300ccbbbe8bf55a519b9
Reviewed-by: Ulf Hermann <ulf.hermann@theqtcompany.com>
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@theqtcompany.com>
Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
9 years agoFix qqmldebuggingenabler autotest
Kai Koehne [Thu, 12 Mar 2015 09:45:33 +0000 (10:45 +0100)]
Fix qqmldebuggingenabler autotest

The test calls itself as a qml debug server. This requires
the debugging functionality to be enabled.

Task-number: QTBUG-44952
Change-Id: I462d035ff7ed722008f3710c6db90e5640546be2
Reviewed-by: Ulf Hermann <ulf.hermann@theqtcompany.com>
9 years agoHandle context loss in the threaded render loop
Laszlo Agocs [Tue, 10 Mar 2015 15:59:08 +0000 (16:59 +0100)]
Handle context loss in the threaded render loop

Change-Id: I3f9219dd2fed15094c2f7d670a981406e601959b
Reviewed-by: Gunnar Sletta <gunnar@sletta.org>
9 years agotst_QQuickPathView::mouseDrag(): Skip on Windows if drag fails to start.
Friedemann Kleint [Thu, 26 Feb 2015 15:20:43 +0000 (16:20 +0100)]
tst_QQuickPathView::mouseDrag(): Skip on Windows if drag fails to start.

The test can be thrown off by external mouse move events which
influence the calculation of the drag distances. It is not clear where
they originate from on the CI.

FAIL!  : tst_QQuickPathView::mouseDrag() 'pathview->isMoving()' returned FALSE. ()
tst_qquickpathview.cpp(1506) : failure location

Change-Id: I398304b5597579033df81e1d0d32b2a3ab5516d6
Reviewed-by: Laszlo Agocs <laszlo.agocs@theqtcompany.com>
9 years agoDon't evaluate the expression in switch() multiple times
Lars Knoll [Mon, 9 Mar 2015 09:13:25 +0000 (10:13 +0100)]
Don't evaluate the expression in switch() multiple times

The old code would evaluate the expression in the switch
statement once for every case label. This is not only slower
than it should be, but can also lead to unexpected results in
case the expression doesn't always evaluate to the same value
or has side effects.

Task-number: QTBUG-41630
Change-Id: Id93baca7e3aa09ce884967ef6524d4c4f055bcd6
Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
9 years agoFix flickable stealing gestures when height >= contentHeight.
Andrew den Exter [Mon, 9 Mar 2015 06:47:16 +0000 (16:47 +1000)]
Fix flickable stealing gestures when height >= contentHeight.

Or width >= contentWidth.

If newY is equal to both maxY and minY then the second assignment to
rejectY can clobber the first.  Changing the second assignment to an
|= means rejectY is true if either is true.

Secondly maxY became positive when height was greater than contentHeight
instead of having a maximum of 0, which ensured rejectY evaluated to false
in the case newY <= maxY and the mouse was stolen.

Change-Id: I6416d0e23c3ef898887a7b3e3fcdc1dc12853548
Reviewed-by: Martin Jones <martin.jones@qinetic.com.au>
9 years agoqt quick particles: Fix const correctness in old style casts
Thiago Macieira [Sat, 7 Mar 2015 22:42:59 +0000 (14:42 -0800)]
qt quick particles: Fix const correctness in old style casts

Found with GCC's -Wcast-qual.

Change-Id: Ia0aac2f09e9245339951ffff13c958e1d7c929c0
Reviewed-by: Jørgen Lind <jorgen.lind@theqtcompany.com>
9 years agoFix clang warning
Andrew Knight [Mon, 9 Mar 2015 20:55:23 +0000 (22:55 +0200)]
Fix clang warning

Removes "warning: first declaration of static data member specialization
of 'static_vtbl' outside namespace 'QV4' is a C++11 extension" by
placing the declarations inside the QV4 namespace.

Change-Id: I9a31874430900a200e83c42ff6c1afc36f0431e1
Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
9 years agoQML Engine: ArrayBuffer XHR response type support
Valery Kotov [Wed, 4 Mar 2015 19:57:14 +0000 (21:57 +0200)]
QML Engine: ArrayBuffer XHR response type support

Support for "arraybuffer" response type for QQmlXMLHttpRequest was
added.

[ChangeLog][QtQml][QQmlXMLHttpRequest] QQmlXMLHttpRequest now
supports "arraybuffer" binary response type.

Change-Id: I866e543cc7bc6ab037ffff1ef6628057b73daf90
Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
9 years agotestlib: Fix qml objects not deleted between data tests
Caroline Chao [Wed, 4 Mar 2015 09:51:28 +0000 (10:51 +0100)]
testlib: Fix qml objects not deleted between data tests

Call wait(0) after the cleanup() function and not only at
the end of the test run (wait(0) is used to call processEvents()).
Otherwise, eventual destroy() calls in test function are not executed
between data tests.

Task-number: QTBUG-30523
Task-number: QTBUG-42185
Change-Id: I1d588ee28c61cda835e25307bc1c565d68b741fe
Reviewed-by: Jan Arve Sæther <jan-arve.saether@theqtcompany.com>
9 years agoDoc: Removed the release notes for Qt Quick and Qt Qml
Venugopal Shivashankar [Fri, 6 Mar 2015 13:18:03 +0000 (14:18 +0100)]
Doc: Removed the release notes for Qt Quick and Qt Qml

These pages were not maintained and were duplicating
info. provided in the what's new page provided for
each release.

Change-Id: I2ee4010de22ef3fb394e3bcdb6adb15db59a2cc9
Task-number: QTBUG-43235
Reviewed-by: Leena Miettinen <riitta-leena.miettinen@theqtcompany.com>
Reviewed-by: Sami Makkonen <sami.makkonen@digia.com>
Reviewed-by: Topi Reiniö <topi.reinio@digia.com>
9 years agoRe-enable readback test in tst_qquickwidget
Laszlo Agocs [Mon, 9 Mar 2015 10:46:25 +0000 (11:46 +0100)]
Re-enable readback test in tst_qquickwidget

This seems to work now.

Task-number: QTBUG-39917
Change-Id: I01bbc9b7ddfbb003265479eaa2282e39eebf35c5
Reviewed-by: Shawn Rutledge <shawn.rutledge@digia.com>
9 years agoAdd missing flush for multisampled QQuickWidget
Laszlo Agocs [Mon, 9 Mar 2015 10:51:31 +0000 (11:51 +0100)]
Add missing flush for multisampled QQuickWidget

Otherwise we might be using a half-ready texture when performing compositing.
The issue was very visible on OS X at least.

Task-number: QTBUG-39917
Change-Id: I71326cb99567f458a6ca7a2cad322a315ee6674f
Reviewed-by: Shawn Rutledge <shawn.rutledge@digia.com>
9 years agoReduce number of allocations when constructing text nodes
Eskil Abrahamsen Blomfeldt [Mon, 2 Mar 2015 08:51:44 +0000 (09:51 +0100)]
Reduce number of allocations when constructing text nodes

In cases where you have a huge number of text elements that
can be merged, we would do a lot of reallocations (one per
node that would be merged into another). As the number of
merges grew, this seemed to converge at about 50% of the time
spent in updatePaintNode() in the text classes.

We can almost eliminate this cost by only doing one realloc
per node that will actually end up in the scene graph.

This patch does a first pass where it simply bundles together
nodes that can be merged. Then it does a second pass where it
actually merges the nodes. In this second pass it can easily
precount the required size of the arrays and we can limit
it to a single realloc.

Task-number: QTBUG-37365
Change-Id: I4e44c01cd83df39304cbbce34f3b8f773763e091
Reviewed-by: Michael Brasser <michael.brasser@live.com>
9 years agoAdd test data for tst_GuiAppLauncher
Sergio Ahumada [Thu, 12 Feb 2015 10:47:53 +0000 (11:47 +0100)]
Add test data for tst_GuiAppLauncher

Change-Id: I6a93f19850325379598eb57f2a9ea304cebe558f
Reviewed-by: Liang Qi <liang.qi@theqtcompany.com>
Reviewed-by: Sergio Ahumada <sahumada@texla.cl>
9 years agoImplement cache property for QQuickAnimatedImage
Daiwei Li [Sat, 28 Feb 2015 07:56:12 +0000 (23:56 -0800)]
Implement cache property for QQuickAnimatedImage

Some longer and larger .gifs can consume a lot of memory
if every decoded frame is cached. Just as the backing QMovie
provides the ability to not cache frame, so should AnimatedImage.

This also allows a workaround for some animated image types
that can contain loops that aren't handled correctly (QTBUG-24869)
to not leak memory.

Change-Id: I0639461d75bb2c758917893e7a6ae5c215fffa9d
Task-number: QTBUG-44447
Task-number: QTBUG-24869
Task-number: QTBUG-28844
Reviewed-by: Alan Alpert <aalpert@blackberry.com>
9 years agoMerge "Merge remote-tracking branch 'origin/5.4' into 5.5" into refs/staging/5.5
Frederik Gladhorn [Fri, 6 Mar 2015 12:54:39 +0000 (12:54 +0000)]
Merge "Merge remote-tracking branch 'origin/5.4' into 5.5" into refs/staging/5.5

9 years agoQV4::Primitive: Help clang disambiguate symbols
Gabriel de Dietrich [Fri, 6 Mar 2015 12:48:10 +0000 (13:48 +0100)]
QV4::Primitive: Help clang disambiguate symbols

Change-Id: Ie20e6081b80e8f177991ac8aafda054c11b1620c
Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
9 years agoMake sure we deref an item from its window.
Gunnar Sletta [Fri, 6 Mar 2015 10:39:49 +0000 (11:39 +0100)]
Make sure we deref an item from its window.

We should compare against our own window, not our parent's.

The ref/deref logic for items is there to aid us with having "property
var foo: Image { }" in ShaderEffects, where the property is a
parentless member of a given window. The shader effect would ref
all member properties which are used as samplers, giving these items
the same d->window as itself.

As a consequence, it is wrong to check the old parent's window when it
is the item itself that knows which window it is attached to.

Change-Id: Ic34354fd86b52a7334f9757bf408bef0e25ecfd5
Task-number: QTBUG-43376
Reviewed-by: Andrew den Exter <andrew.den.exter@qinetic.com.au>
9 years agoFix build: QString needs to be fully-defined for QString()
Thiago Macieira [Mon, 16 Feb 2015 19:37:55 +0000 (11:37 -0800)]
Fix build: QString needs to be fully-defined for QString()

qqmldebug.h:46:71: error: invalid use of incomplete type ‘class QString’
qglobal.h:651:7: error: forward declaration of ‘class QString’

Change-Id: I1a800c709d3543699131ffff13c3797acbc19956
Reviewed-by: Ulf Hermann <ulf.hermann@theqtcompany.com>
9 years agotst_qqmlitemmodels: Remove pointless QVariant::type() checks
Gabriel de Dietrich [Thu, 5 Mar 2015 20:32:43 +0000 (21:32 +0100)]
tst_qqmlitemmodels: Remove pointless QVariant::type() checks

Change-Id: If817b30aad08fa32697feab7ba4035d66309ed10
Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@theqtcompany.com>
Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com>
9 years agoTextEdit: Block's update should update paint node
Ruslan Nigmatullin [Thu, 26 Feb 2015 22:52:11 +0000 (14:52 -0800)]
TextEdit: Block's update should update paint node

QQuickTextEdit::invalidateBlock method marks nodes as dirty but doesn't
call QQuickItem::update(). Because of that it's impossible to
rehighlight text by QSyntaxHighlighter.

Task-number: QTBUG-44765
Change-Id: Ibfd973430cf00927dbec027d129c6d722634575e
Reviewed-by: J-P Nurmi <jpnurmi@theqtcompany.com>
9 years agoWinRT: Set alignment boundary to page size
Maurice Kalinowski [Thu, 5 Mar 2015 07:31:50 +0000 (08:31 +0100)]
WinRT: Set alignment boundary to page size

This is a hard requirement from the QQmlEngine internals since 5.5 and
otherwise causes crashes inside the engine.

Change-Id: Id25f465576a0095f5b34da469abe761d3f3bd866
Reviewed-by: Andrew Knight <andrew.knight@intopalo.com>
9 years agoDoc: Changed title GridView example
Nico Vertriest [Fri, 27 Feb 2015 14:26:49 +0000 (15:26 +0100)]
Doc: Changed title GridView example

Changed title to avoid conflict
between GridView QML type and example

Task-number: QTBUG-44640
Change-Id: I59c83489e4029c1586ec462f6643fff0ef80155d
Reviewed-by: Topi Reiniö <topi.reinio@digia.com>
9 years agoWork around QPersistentModelIndex being a built-in meta-type
Gabriel de Dietrich [Thu, 5 Mar 2015 11:30:58 +0000 (12:30 +0100)]
Work around QPersistentModelIndex being a built-in meta-type

This is a temporary work-around and will be removed once
I63d733d1eb66aa61691e7afce27fe7372a83ac00 is merged in qtbase.

Change-Id: I6cfcf1ddc2c9d408c26c171be865d40141de7fa0
Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com>
9 years agoFix invocations of static methods of QGuiApplication/QCoreApplication.
Friedemann Kleint [Wed, 4 Mar 2015 10:27:27 +0000 (11:27 +0100)]
Fix invocations of static methods of QGuiApplication/QCoreApplication.

Change-Id: I7bcc209b0c6e77cf6d974af85a19487345a48975
Reviewed-by: Erik Verbruggen <erik.verbruggen@theqtcompany.com>
9 years agoDoc: Replace qt-project.org/doc with doc.qt.io
Sergio Ahumada [Wed, 4 Mar 2015 22:00:59 +0000 (23:00 +0100)]
Doc: Replace qt-project.org/doc with doc.qt.io

Change-Id: Ib693ac8d48ab943a3c26a49ab4fca91f0c5f0b0e
Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
9 years agoFix thread-safety: _POSIX_THREAD_SAFE_FUNCTIONS is in <unistd.h>
Thiago Macieira [Tue, 17 Feb 2015 00:17:21 +0000 (16:17 -0800)]
Fix thread-safety: _POSIX_THREAD_SAFE_FUNCTIONS is in <unistd.h>

If you don't include it, it isn't defined...

Change-Id: I1a800c709d3543699131ffff13c388ba652761fc
Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
9 years agoDisable JIT on x32 ABI
Dmitry Shachnev [Sat, 28 Feb 2015 11:29:52 +0000 (14:29 +0300)]
Disable JIT on x32 ABI

Linux x32 interface has a different ABI, and our JIT does not work there,
so it should be disabled.

See <http://en.wikipedia.org/wiki/X32_ABI>.

Done-with: Adam Borowski <kilobyte@angband.pl>
Change-Id: I0771e48a51f999a97b49abc01ee72621a5aaa6c3
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
9 years agoMerge remote-tracking branch 'origin/5.4' into 5.5
Frederik Gladhorn [Tue, 3 Mar 2015 17:21:56 +0000 (18:21 +0100)]
Merge remote-tracking branch 'origin/5.4' into 5.5

Conflicts:
src/qml/jsruntime/qv4numberobject.cpp

Change-Id: I4e66a03ef4d99cec192c9da30c028fd8c1f4ac0d

9 years agoUse of fullsize distance field textures should be font-dependent.
Michael Brasser [Mon, 2 Mar 2015 22:32:50 +0000 (16:32 -0600)]
Use of fullsize distance field textures should be font-dependent.

This shouldn't be a static decision as the glyph count depends on the
font.

Change-Id: I67ea98595505df4a3a30b16e867e76f89b28c1ef
Task-number: QTBUG-29264
Reviewed-by: Gunnar Sletta <gunnar@sletta.org>
Reviewed-by: Robin Burchell <robin.burchell@viroteck.net>
9 years agoV4: fix ToFixed rounding for 0 fraction digits.
Erik Verbruggen [Wed, 28 Jan 2015 08:34:10 +0000 (09:34 +0100)]
V4: fix ToFixed rounding for 0 fraction digits.

(12.5).toFixed() should return 13, not 12.

Task-number: QTBUG-43885
Task-number: QTBUG-44039
Change-Id: Id2b19641e8c12dd5755d8447508b74567e4a2b9b
Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
9 years agoV4: fix regalloc for loops with many life&changing vars.
Erik Verbruggen [Mon, 2 Mar 2015 13:35:28 +0000 (14:35 +0100)]
V4: fix regalloc for loops with many life&changing vars.

When all registers are in use, and one needs to be spilled, the register
whose use is the furthest in the future will be chosen. What needs to be
taken into account is that any use that can also work from the stack can
be skipped, because it does not require the value to be in a register.

Task-number: QTBUG-44687
Change-Id: Ide624b190603d9a22f992d4ae5daa3ce8d94472c
Reviewed-by: Fawzi Mohamed <fawzi.mohamed@theqtcompany.com>
9 years agoV4: fix phi node use position calculation.
Erik Verbruggen [Mon, 2 Mar 2015 13:22:24 +0000 (14:22 +0100)]
V4: fix phi node use position calculation.

As phi-nodes get transformed into moves, and the moves end up right
before the terminator of the basic block of the incoming edge, the
use by that phi-node is the position of that terminator minus one.

However, when checking if uses need a register, this was not taken into
account, resulting in an invalid life-time interval split position
calculation.

Task-number: QTBUG-44687
Change-Id: I0edd416f7ee5c8ea16bf7133870be45d0e6efea9
Reviewed-by: Fawzi Mohamed <fawzi.mohamed@theqtcompany.com>
9 years agobic: Add 5.{3,4}.0 bic data for QtQuickWidgets
Sergio Ahumada [Wed, 11 Feb 2015 18:44:35 +0000 (19:44 +0100)]
bic: Add 5.{3,4}.0 bic data for QtQuickWidgets

this is a new module since Qt 5.3

Change-Id: I9d33ba8f046190f649643302ddc343cbe6e649ed
Reviewed-by: Liang Qi <liang.qi@theqtcompany.com>
Reviewed-by: Sergio Ahumada <sahumada@texla.cl>
9 years agoAvoid assert in rich text when img width is invalid
Eskil Abrahamsen Blomfeldt [Mon, 2 Mar 2015 12:17:04 +0000 (13:17 +0100)]
Avoid assert in rich text when img width is invalid

If you set the width or height of an <img> tag to something
invalid, this will be registered as -2 by the HTML parser.
We should treat this case the same as if there is no width/height
specified and use the implicit size instead.

[ChangeLog][Text] Fixed assert when setting an invalid width or
height on an <img> tag in a text element.

Change-Id: Iae8c33fa184316632f72318e71f26ab005645a21
Task-number: QTBUG-44743
Reviewed-by: Gunnar Sletta <gunnar@sletta.org>
9 years agotestlib: Introduce MouseDoubleClickSequence() method
Caroline Chao [Fri, 27 Feb 2015 11:11:58 +0000 (12:11 +0100)]
testlib: Introduce MouseDoubleClickSequence() method

The existing method MouseDoubleClick() emulates the mouse
double click event only.

The added method MouseDoubleClickSequence() emulates the full
sequence of mouse events a physical double-click would generate:
Press-Release-Press-DoubleClick-Release

Introducing a new method in order to provide convenience when a
test requires to simulate a complete double-click action without
changing the behavior of MouseDoubleClick() and risking to break
existing tests.

Add autotest.

Task-number: QTBUG-42185
Change-Id: I1cdddd9e21d3b1d8a818f6d4e3717b06b7d70e08
Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
Reviewed-by: Laszlo Agocs <laszlo.agocs@theqtcompany.com>
9 years agoQQuickWindow: rename deliverGestureEvent to deliverNativeGestureEvent
Shawn Rutledge [Fri, 27 Feb 2015 07:14:49 +0000 (08:14 +0100)]
QQuickWindow: rename deliverGestureEvent to deliverNativeGestureEvent

Native gestures are distinct from QGestureEvent, and we might need
another deliver method for those eventually.

Change-Id: I969c9b830d1dc7a91ffbc6cae2bdb68552a58344
Reviewed-by: Andrew Knight <qt@panimo.net>
Reviewed-by: Morten Johan Sørvig <morten.sorvig@theqtcompany.com>
9 years agoQQuickWindow: move deliverGestureEvent outside QT_NO_WHEELEVENT section
Shawn Rutledge [Fri, 27 Feb 2015 07:11:20 +0000 (08:11 +0100)]
QQuickWindow: move deliverGestureEvent outside QT_NO_WHEELEVENT section

Turning off support for wheel events does not affect gesture support.

Change-Id: I64a110327179d62a69864979396b92472c53285e
Reviewed-by: Morten Johan Sørvig <morten.sorvig@theqtcompany.com>
Reviewed-by: Andrew Knight <qt@panimo.net>
9 years agoQtQuick: Micro-optimize iterator loops.
Friedemann Kleint [Mon, 23 Feb 2015 12:45:44 +0000 (13:45 +0100)]
QtQuick: Micro-optimize iterator loops.

Avoid repeated instantiation of end() in loops, use variable instead.

Change-Id: I6ab1fe2b82406d5ee91710a0333587ffb82c04d4
Reviewed-by: Erik Verbruggen <erik.verbruggen@theqtcompany.com>
9 years agoQtQml: Micro-optimize iterator loops.
Friedemann Kleint [Mon, 23 Feb 2015 12:44:12 +0000 (13:44 +0100)]
QtQml: Micro-optimize iterator loops.

Avoid repeated instantiation of end() in loops, use variable instead.

Change-Id: I3bb1c6918cfd16a5dcefbcc03c442e99fe9bf76b
Reviewed-by: Erik Verbruggen <erik.verbruggen@theqtcompany.com>
9 years agoOptimize distance field construction.
Michael Brasser [Fri, 20 Feb 2015 13:50:45 +0000 (07:50 -0600)]
Optimize distance field construction.

Reduce the number of times we construct a painter path from a glyph.

Change-Id: Ic1f32c78ab5dfd3b75d5442da163cda1dedab3ee
Task-number: QTBUG-42853
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
Reviewed-by: Yoann Lopes <yoann.lopes@theqtcompany.com>
Reviewed-by: Gunnar Sletta <gunnar@sletta.org>
9 years agoInclude <limits> in qqmlprofilerservice_p.h
Ulf Hermann [Fri, 20 Feb 2015 12:37:09 +0000 (13:37 +0100)]
Include <limits> in qqmlprofilerservice_p.h

As we use std::numeric_limits in that file we should do this.

Change-Id: Idd8da16ce062b2ef24f926bcf33de95559464bb9
Reviewed-by: Pasi Petäjäjärvi <pasi.petajajarvi@theqtcompany.com>
Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
9 years agoAllow glyph cache textures to be created at full size.
Michael Brasser [Tue, 24 Feb 2015 15:29:15 +0000 (09:29 -0600)]
Allow glyph cache textures to be created at full size.

On embedded hardware, texture resizes can be quite slow. The glyph
cache currently often needs to resize when new glyphs are added, and
glyph additions are very frequent when using a language with a large
set of glyphs (such as Chinese).

The current glyph cache design minimizes the amount of memory used.
When QSG_PREFER_FULLSIZE_GLYPHCACHE_TEXTURES is set, and we are using
a font with a large number of glyphs, we can instead allocate max-sized
textures. This leads to significantly less time when inserting glyphs
into the cache (often incurred over a span of time), at the cost of
higher initial memory and creation times (often incurred at
application startup).

Change-Id: Id1021b9d213e5f8635c4197b624474f28c6f44ff
Task-number: QTBUG-29264
Reviewed-by: Robin Burchell <robin.burchell@viroteck.net>
Reviewed-by: Gunnar Sletta <gunnar@sletta.org>
Reviewed-by: Yoann Lopes <yoann.lopes@theqtcompany.com>
9 years agoFix crash in overdraw and change visualizers
Daiwei Li [Tue, 3 Feb 2015 00:34:27 +0000 (16:34 -0800)]
Fix crash in overdraw and change visualizers

It appears to be possible for node->element()->batch to be NULL

Task-number: QTBUG-43129
Change-Id: If6e4e265a02ee305bf3aa9cad387b7a73648367a
Reviewed-by: Gunnar Sletta <gunnar@sletta.org>
9 years agoFix memory leak of QSGContext object in QSGThreadedRenderLoop
jian liang [Sun, 22 Feb 2015 04:27:05 +0000 (12:27 +0800)]
Fix memory leak of QSGContext object in QSGThreadedRenderLoop

Add destructor for QSGThreadedRenderLoop to destory QSGContext object.

Change-Id: I479947eb35a5d7888d45655a9b8e2ece5e30bc33
Reviewed-by: Gunnar Sletta <gunnar@sletta.org>
9 years agoMerge remote-tracking branch 'origin/5.4' into 5.5
Frederik Gladhorn [Tue, 24 Feb 2015 16:36:04 +0000 (17:36 +0100)]
Merge remote-tracking branch 'origin/5.4' into 5.5

Conflicts:
.qmake.conf
LICENSE.GPLv2
examples/qml/networkaccessmanagerfactory/view.qml
src/qml/jsruntime/qv4runtime.cpp
src/qml/jsruntime/qv4stringobject.cpp

Change-Id: I5d12f436d60995e51d5c2f59d364e9cbc24f8e32

9 years agoHandle TouchCancel events in QQuickPinchArea
Aaron McCarthy [Wed, 18 Feb 2015 05:53:09 +0000 (15:53 +1000)]
Handle TouchCancel events in QQuickPinchArea

QQuickPinchArea did not handle TouchCancel events and would recursively
call QQuickItem::event(). Cancel the pinch gesture by restoring the
pinch state to the start state. Don't recursively call
QQuickItem::event(), instead call QQuickItem::touchEvent() for
unhandled touch events.

[ChangeLog][QtQuick][PinchArea] Fix infinite recursion when TouchCancel
events are received.

Change-Id: Ifce4af91aec4285873cb701069e007bcee180851
Reviewed-by: Martin Jones <martin.jones@qinetic.com.au>
9 years agoFix deprecation warnings about constructing QString from const char*.
Friedemann Kleint [Mon, 16 Feb 2015 12:08:40 +0000 (13:08 +0100)]
Fix deprecation warnings about constructing QString from const char*.

types/qqmlmodelindexvaluetype.cpp: In static member function 'static QString QQmlModelIndexValueType::propertiesString(const QModelIndex&)':
types/qqmlmodelindexvaluetype.cpp:47:56: warning: 'QString::QString(const char*)' is deprecated (declared at qstring.h:649) [-Wdeprecated-declarations]
items/qquickimagebase.cpp: In member function 'virtual void QQuickImageBase::load()':
items/qquickimagebase.cpp:213:49: warning: 'QString::QString(const char*)' is deprecated (declared at qstring.h:649) [-Wdeprecated-declarations]
items/qquickimagebase.cpp:213:88: warning: 'QString::QString(const char*)' is deprecated (declared at qstring.h:649) [-Wdeprecated-declarations]

Change-Id: I03266aba589ade8228bc286cd3f3f237cd06a780
Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@theqtcompany.com>
9 years agoFix MSVC 64 bit warnings about loss of data when converting from 'size_t' to 'int'.
Friedemann Kleint [Wed, 18 Feb 2015 09:08:24 +0000 (10:08 +0100)]
Fix MSVC 64 bit warnings about loss of data when converting from 'size_t' to 'int'.

jsruntime\qv4arraybuffer.cpp(94) : warning C4267: '=' : conversion from 'size_t' to 'int', possible loss of data
jsruntime\qv4persistent.cpp(53) : warning C4267: 'initializing' : conversion from 'size_t' to 'const int', possible loss of data

Change-Id: I6ccef9a64ecfb53b18204b35e17421c0a5ac955b
Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
9 years agoFix some qdoc-warnings.
Friedemann Kleint [Fri, 20 Feb 2015 13:48:46 +0000 (14:48 +0100)]
Fix some qdoc-warnings.

qtdeclarative/src/quick/scenegraph/coreapi/qsgmaterial.cpp:384: warning: Class RenderState has no \inmodule command; using project name by default: QtQuick
qtdeclarative/src/quick/scenegraph/util/qsgsimplerectnode.cpp:39: warning: Class QSGSimpleRectNode has no \inmodule command; using project name by default: QtQuick
qtdeclarative/src/quick/scenegraph/util/qsgtextureprovider.cpp:38: warning: Class QSGTextureProvider has no \inmodule command; using project name by default: QtQuick
qtdeclarative/src/quick/items/qquickwindow.cpp:3156: warning: Cannot find 'closing(...)' in '\fn' void QQuickWindow::closing()
qtdeclarative/src/quick/items/qquickwindow.h:160: warning: No documentation for 'QQuickWindow::closing()'
qtdeclarative/src/quick/items/qquickwindow.cpp:3134: warning: Can't link to 'Window.closing()'
qtdeclarative/src/qml/qml/qqmlfileselector.cpp:90: warning: Undocumented parameter 'parent' in QQmlFileSelector::QQmlFileSelector()

Change-Id: I42cf1e06c9e7a63327acc470bd33a726acc69bfc
Reviewed-by: Leena Miettinen <riitta-leena.miettinen@theqtcompany.com>
9 years agoAccount for leading when drawing text decoration
Eskil Abrahamsen Blomfeldt [Wed, 18 Feb 2015 09:35:00 +0000 (10:35 +0100)]
Account for leading when drawing text decoration

When the text line is offset by the leading distance, the
text decoration needs to be offset by the same value, otherwise
it will be drawn in the wrong location.

[ChangeLog][TextEdit] Fixed positioning of text decoration with some
fonts.

Change-Id: Ic15134326b878255a9b424c14762c3817dfd3123
Task-number: QTBUG-44492
Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com>
Reviewed-by: Andrew Knight <qt@panimo.net>
Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
9 years agoremove unnecessary LICENSE.GPLv2
Jani Heikkinen [Tue, 7 Oct 2014 07:50:57 +0000 (10:50 +0300)]
remove unnecessary LICENSE.GPLv2

Change-Id: Iea5465791b2ac3b0303ffbae5378c43d8ae2f130
Reviewed-by: Iikka Eklund <iikka.eklund@theqtcompany.com>
9 years agoCleanup math function includes and usage
Allan Sandfeld Jensen [Fri, 13 Feb 2015 11:02:19 +0000 (12:02 +0100)]
Cleanup math function includes and usage

Use std::math on floats and doubles, and qMath on qreals, and only
include the math headers actually needed.

Change-Id: I1d511d7b1bac0050eaa947c7baee760b736858bf
Reviewed-by: Sean Harmer <sean.harmer@kdab.com>
9 years agoAdd Qt.hsva() function
Sean Harmer [Sun, 15 Feb 2015 10:51:51 +0000 (10:51 +0000)]
Add Qt.hsva() function

This is more convenient than the alternative hsla() function in many
cases as color pickers in other applications default to the HSV color
space e.g. GIMP, kcolorchooser.

[ChangeLog][QtQml] Added Qt.hsva() function

Change-Id: Id5c1a78173757bf9842b164d90b31682e9a41749
Reviewed-by: Laszlo Agocs <laszlo.agocs@theqtcompany.com>
Reviewed-by: Paul Lemire <paul.lemire@kdab.com>
9 years agoNamedNodeMap: Remove logically dead code
Holger Hans Peter Freyther [Sun, 8 Feb 2015 08:03:08 +0000 (09:03 +0100)]
NamedNodeMap: Remove logically dead code

The code has been changed by Lars in the git commit
47fbcb47771a36ab9fd0a4d5ede7b7504ab1410d. Now "r->engine()"
is called before the "if (!r)" check is being executed.

We can assume that "m->as<NamedNodeMap>()" will always
return a non nullptr and this allows us to remove the
extra null check.

Fixes CID: 86703

Change-Id: Ib4f1103e38c7e1e8e5175d91e795d2621e3a79c4
Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
9 years agodocs: Add a link to Drag and DropArea in MouseArea's drag section
Sérgio Martins [Sun, 15 Feb 2015 12:13:03 +0000 (12:13 +0000)]
docs: Add a link to Drag and DropArea in MouseArea's drag section

They are related subjects so deserve a mention.

Change-Id: I52f338402c8568f54dfd4b91845f9fafa762ca4d
Reviewed-by: Alan Alpert <aalpert@blackberry.com>
9 years agoFixed license headers
Jani Heikkinen [Fri, 13 Feb 2015 11:35:35 +0000 (13:35 +0200)]
Fixed license headers

Change-Id: I4d5640ff95e1361ec7e65fb3e87d7726d8185ff5
Reviewed-by: Sergio Ahumada <sahumada@texla.cl>
9 years agoUpdate url location for missing Qt logo
Sergio Ahumada [Thu, 12 Feb 2015 13:17:03 +0000 (14:17 +0100)]
Update url location for missing Qt logo

Change-Id: I21084651044f1db0c7863f2121431dffec8526e3
Reviewed-by: Topi Reiniö <topi.reinio@digia.com>
9 years agoFlickable: use wheel event pixel deltas when available
Shawn Rutledge [Tue, 27 Jan 2015 11:58:42 +0000 (12:58 +0100)]
Flickable: use wheel event pixel deltas when available

Flickable can now handle wheel events which come from touchpads,
providing pixel deltas instead of angle deltas.  It will interpret
them as distance to flick, rather than using an average-velocity
physics model as it does when handling events from a physical mouse
wheel. This enables much finer control and limits the tendency
to "zing" way out of bounds accidentally.  It is achieved by
refactoring the direct-drag code which is needed for mouse dragging
and for touchpad gesture dragging (and eventually touchscreen dragging)
into a new internal drag() method.

[ChangeLog][QtQuick][Flickable] Flickable handles pixel deltas from
trackpad gestures as drags, for a more native feel

Task-number: QTBUG-22407
Change-Id: Ia613ddb25f46d452603f7cb567b74e80c95a346c
Reviewed-by: Morten Johan Sørvig <morten.sorvig@theqtcompany.com>
9 years agoDoc: fix example
Joerg Bornemann [Thu, 12 Feb 2015 16:39:34 +0000 (17:39 +0100)]
Doc: fix example

Change-Id: I818e0a3235060fa48c61d4f21f1202d976b15d5e
Task-number: QTBUG-38456
Reviewed-by: Topi Reiniö <topi.reinio@digia.com>
9 years agoHigh-dpi SVG and QQuickImageProvider Images
Morten Johan Sørvig [Thu, 15 Jan 2015 12:38:40 +0000 (13:38 +0100)]
High-dpi SVG and QQuickImageProvider Images

Scale sourceSize by the target devicePixelRatio before
passing it to the providers.

Task-number: QTBUG-38127
Task-number: QTBUG-38991
Change-Id: I1746e0859b4e63eb0d28d1a1c8aac610b68a9eb9
Reviewed-by: Jocelyn Turcotte <jturcotte@woboq.com>
Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com>
Reviewed-by: Morten Johan Sørvig <morten.sorvig@theqtcompany.com>
9 years agoPinchArea: handle smart zoom gesture
Shawn Rutledge [Tue, 9 Dec 2014 09:28:25 +0000 (10:28 +0100)]
PinchArea: handle smart zoom gesture

This is the double-finger double-tap trackpad gesture on OS X.

Change-Id: Ie79dc533adf382170867318bc9b61b367f819e9b
Reviewed-by: Morten Johan Sørvig <morten.sorvig@theqtcompany.com>
9 years agoFix 590 inconsistent override warnings [-Winconsistent-missing-override]
Sérgio Martins [Wed, 4 Feb 2015 23:10:21 +0000 (23:10 +0000)]
Fix 590 inconsistent override warnings [-Winconsistent-missing-override]

Classes should either use or not use override, otherwise it hurts
code readability.

Change-Id: Ieb899a3475b0c36ab20285740b2cec2cd1677a54
Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
9 years agoFix width/height property assignment during animations.
Aaron McCarthy [Thu, 12 Feb 2015 05:36:44 +0000 (15:36 +1000)]
Fix width/height property assignment during animations.

During animations the behavior of

anchors.fill: parent

and

width: parent.width
height: parent.height

can be different resulting in subtle UI bugs where the final value of a
property is not applied because it is within epsilon of the previous
value. Fixed by directly comparing the width and height instead of
using operator==(QSize, QSize) which does a fuzzy comparison.

Change-Id: I4288b93db2b7baacd9f71ae1932ae743a428313a
Reviewed-by: Andrew den Exter <andrew.den.exter@qinetic.com.au>
Reviewed-by: Gunnar Sletta <gunnar@sletta.org>
9 years agoDoc: Bump QtQuick import version to 2.5
Shawn Rutledge [Thu, 12 Feb 2015 13:18:59 +0000 (14:18 +0100)]
Doc: Bump QtQuick import version to 2.5

Change-Id: I9b41d6c755f804aeb47564f10d7131df528ba61d
Reviewed-by: J-P Nurmi <jpnurmi@theqtcompany.com>
Reviewed-by: Caroline Chao <caroline.chao@theqtcompany.com>
9 years agoUse TabFocusBehavior in QStyleHints in QtQuick
Liang Qi [Wed, 4 Feb 2015 09:10:12 +0000 (10:10 +0100)]
Use TabFocusBehavior in QStyleHints in QtQuick

* QQuickItemPrivate::qt_tab_all_widgets was removed.
* qt_tab_all_widgets in test was updated.

Change-Id: I418d7a3edae0a4782a91289f6c0494ff5874d071
Reviewed-by: J-P Nurmi <jpnurmi@theqtcompany.com>