platform/upstream/qtdeclarative.git
9 years agoReturn a Heap::Object in Object::prototype()
Lars Knoll [Thu, 27 Nov 2014 07:56:03 +0000 (08:56 +0100)]
Return a Heap::Object in Object::prototype()

Change-Id: Ice0265ae558ba14497421a5bbf25ee9db76adab5
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
9 years agoUpdate scenegraph docs regarding threaded render loop usage
Laszlo Agocs [Fri, 12 Dec 2014 11:18:08 +0000 (12:18 +0100)]
Update scenegraph docs regarding threaded render loop usage

Change-Id: I4f8aa9b209096bbcdabcb689007e4166279f8a4c
Reviewed-by: Gunnar Sletta <gunnar@sletta.org>
9 years agorendercontrol example: Add missing flushes
Laszlo Agocs [Tue, 16 Dec 2014 11:56:00 +0000 (12:56 +0100)]
rendercontrol example: Add missing flushes

Otherwise we will show broken output with some drivers.
QQuickWidget does this already.

Change-Id: I5193595c4606d0497dbe85f6f8c670618ca366e9
Reviewed-by: Jørgen Lind <jorgen.lind@theqtcompany.com>
9 years agoSimple cache of url for QQmlCompiledData
Robin Burchell [Tue, 9 Dec 2014 08:47:46 +0000 (00:47 -0800)]
Simple cache of url for QQmlCompiledData

Removes URL parsing and allocation/deallocation overhead as a bottleneck from
cached instantiation. Takes total runtime percentage of beginCreate from 6208ms
to 4987ms out of a 15 second trace of the instantiation_cached librarymetrics
benchmark with the empty Item data.

Task-number: QTBUG-43096
Change-Id: Ie4ec8e83461b4926e502dd78a7178cc8e8131e70
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
9 years agoAllow batching of GL_LINES and GL_POINTS geometry
Ulf Hermann [Tue, 2 Dec 2014 10:57:41 +0000 (11:57 +0100)]
Allow batching of GL_LINES and GL_POINTS geometry

This is analogous to GL_TRIANGLES and GL_TRIANGLE_STRIP. There is no
reason why we shouldn't batch it. In the case of GL_LINES this means a
slight behavior change, though: If you provided geometry with an uneven
number of vertices, it would draw lines the way opengl specifies it and
drop the last vertex. Now, with batching, it will draw a line from the
last vertex of an "uneven" node to the first vertex of the next node.
This, however, is exactly like it already works for GL_TRIANGLES if you
specify a number of vertices not divisible by 3. We assume the user
should specify a number of vertices that matches the drawing mode.

Change-Id: I372b9c15a19f065d3aeb3727688cca408ce9608e
Reviewed-by: Gunnar Sletta <gunnar@sletta.org>
9 years agofix the build with -no-qml-debug
Shawn Rutledge [Thu, 11 Dec 2014 12:55:02 +0000 (13:55 +0100)]
fix the build with -no-qml-debug

The "cleanup" variable doesn't exist in this case.

Change-Id: Ia7ed654d5c9ae57bc3f7cff39acbd72214ff4188
Reviewed-by: Ulf Hermann <ulf.hermann@theqtcompany.com>
9 years agoSimplify QFont value type wrapper in preparation for gadgets
Simon Hausmann [Fri, 14 Nov 2014 07:08:32 +0000 (08:08 +0100)]
Simplify QFont value type wrapper in preparation for gadgets

The value type wrapper for QFont tries to keep track whether pixel or point
sizes were set and warns the programmer accordingly if both were set. This is
implemented using separate boolean variables, but this can also be done using
QFont's resolve mask.

This move is motivated by the ability of the value type wrappers to operate
only on the type they wrap in the future, without requiring additional
helper variables.

Change-Id: Ia05093b5dcc950281ef89b2bb6fe96c18329cdfa
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
Reviewed-by: Michael Brasser <michael.brasser@live.com>
9 years agoRead and write QObject pointer properties in QML without registration.
Mitch Curtis [Mon, 1 Dec 2014 13:37:09 +0000 (14:37 +0100)]
Read and write QObject pointer properties in QML without registration.

Previously, accessing QObject pointer properties from QML would require
these types to be registered with qRegisterMetaType(), but this
shouldn't be necessary if we're able to read/write the property, because
the moc generates code that calls qRegisterMetaType in the static meta-call
implementation. So when resolving a property in the property cache and we
can't resolve, fall back to placing the static meta-call to register the
type, similar to what QMetaType::userType() does.

Change-Id: Ic8b00ed93a1e5e42cf7aaaf1c355e89557485c59
Reviewed-by: Christopher Adams <chris.adams@jollamobile.com>
Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@theqtcompany.com>
9 years agoSimplify calling methods on value types
Simon Hausmann [Fri, 14 Nov 2014 15:12:14 +0000 (16:12 +0100)]
Simplify calling methods on value types

We don't need to go deep through the QObject wrapper, we can use QObjectMethod
directly after we've determined a Q_INVOKABLE property.

Change-Id: I2a8e3e827991a365758dd106d2ba92a1bd0d7aab
Reviewed-by: Michael Brasser <michael.brasser@live.com>
9 years agoDocument behavior of JavaScript Date with negative years
Ulf Hermann [Fri, 12 Dec 2014 12:50:30 +0000 (13:50 +0100)]
Document behavior of JavaScript Date with negative years

Task-number: QTBUG-29491
Change-Id: Icc9620abc3bc606f1cd0ab89762f370ac259893e
Reviewed-by: Mitch Curtis <mitch.curtis@digia.com>
9 years agoFix QQmlPropertyCache population with gadgets
Simon Hausmann [Wed, 19 Nov 2014 15:56:40 +0000 (16:56 +0100)]
Fix QQmlPropertyCache population with gadgets

The property cache excludes the destroyed() signals as well as the deleteLater()
slot from the accessible methods. It does that by comparing the method index
against the indices of these signals/slots, which works as long as every
meta-object is through some way derived from QObject's meta object. However
that's not the case for gadgets, where these indices don't apply and
will instead accidentally hide methods.

Change-Id: I5f2b3f578192ff0df607af67832389c30bb11beb
Reviewed-by: Michael Brasser <michael.brasser@live.com>
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
9 years agoRevert "Properly handle negative years when printing JS Dates to strings."
Ulf Hermann [Thu, 11 Dec 2014 13:05:31 +0000 (14:05 +0100)]
Revert "Properly handle negative years when printing JS Dates to strings."

This reverts commit f06daaf3d8747c6c0a277bf055c80d8f2e7bcc81.

The only things actually specified by the ECMAScript standard on dates
are:

1. Reparsing a date output from any of the to*String() functions has to
result in the same date representation.

2. The ISO 8601 standard has to be followed for the ISO format.

Currently we clearly don't follow rule 1. Date.parse(d.toString()) will
not yield the same as d.valueOf() for negative dates.

The ISO 8601 standard clearly has a year 0 while common human language
has not. All non ISO date representations are considered
"implementation-dependent" in the ECMAScript standard. We can thus
define the relation between our representations and the ISO standard any
way we like. If we try to match up the dates so that the negative years
look equal in each representation we cannot properly interact with QDate
for dates in the year 0 as that doesn't exist in QDate. We can, however,
choose not to make the dates look equal. That means a date with a
negative year will be "one off" when represented in ISO 8601. "333 BC"
in human language is "-332" in ISO 8601. Our internal representation is
aligned to ISO 8601 and the to*String() methods may output something
else. That means we can easily set the year in ISO 8601 sense from the
Date constructor as well as from setYear() and setFullYear().

This, of course, is somewhat unintuitive and also differs from most
other JavaScript implementations (which don't have to interoperate with
QDate). However, it is still correct.

Change-Id: I5fc26b709a486cb520a075918b184a80bec56c9b
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
9 years agoSupport threading with QQuickRenderControl
Laszlo Agocs [Tue, 25 Nov 2014 10:38:46 +0000 (11:38 +0100)]
Support threading with QQuickRenderControl

Reorganize the rendercontrol example to demonstrate both the single
and multi threaded approaches.

A small helper function is introduced to the QQuickRenderControl API:
The QSGRenderContext has to live on the render thread. Previously there
was no way for applications to move it to the desired thread. This is
now possible.

Pass --threaded to the rendercontrol example to use a separate render thread.

[ChangeLog][QtQuick] QQuickRenderControl can now be used to render the Qt Quick
scene on a dedicated render thread, similarly to how the built-in threaded render
loop operates.

Task-number: QTBUG-42813
Change-Id: I01c3b2ffca8a174d9d2c267a51f2e484ed7b34b3
Reviewed-by: Gunnar Sletta <gunnar@sletta.org>
Reviewed-by: Jørgen Lind <jorgen.lind@theqtcompany.com>
9 years agoFix the V4 valgrind integration
Jocelyn Turcotte [Fri, 12 Dec 2014 10:41:21 +0000 (11:41 +0100)]
Fix the V4 valgrind integration

87a055bc8eee653a18d51f94a546cd452732223a broke the build and
introduced invalid writes to chunks outside of the existing
VALGRIND_DISABLE_ERROR_REPORTING block.

Fix the build by using MemoryManager::Data* instead of MemoryManager*
as the pool argument to VALGRIND MEMPOOL calls since the Data pointer
is protected.

Change-Id: I24136e25291570ade825dcd84a9568d8169a235b
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
9 years agoDefault to threaded when using opengl32
Laszlo Agocs [Sat, 22 Nov 2014 19:47:07 +0000 (20:47 +0100)]
Default to threaded when using opengl32

This appplies only when using opengl32.dll. When using ANGLE or
when using another non-opengl32 DLL, the "windows" single-threaded
loop is chosen, just like before.

One badly written autotest is fixed. We must never assume that
performing some QQuickWindow related work will leave a context
current on the main thread. The assumption worked by accident with
the single-threaded render loop.

[ChangeLog][QtQuick] Changed to use the threaded render loop by
default on Windows when running with desktop OpenGL (opengl32.dll).

Change-Id: I21798622c19ca510a97a96c19c1e70e29f086e3a
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@theqtcompany.com>
Reviewed-by: Jørgen Lind <jorgen.lind@theqtcompany.com>
9 years agoRemove QML bundle code
Simon Hausmann [Tue, 9 Dec 2014 11:26:59 +0000 (12:26 +0100)]
Remove QML bundle code

This feature is effectively not maintained, experimental and undocumented.
Consensus on the mailing list is to remove it:

    http://lists.qt-project.org/pipermail/development/2014-December/019384.html

Change-Id: Iaa73b3e90806c338ef81bbd4307ddd2addd37964
Reviewed-by: Christopher Adams <chris.adams@jollamobile.com>
9 years agoAdd default parameter value for ExecutionEngine::newString()
Oleg Shparber [Fri, 28 Nov 2014 08:20:29 +0000 (00:20 -0800)]
Add default parameter value for ExecutionEngine::newString()

Change-Id: I8efbfb07ea61e2c6d03eeb79671006d209e4d48e
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
9 years agoAdd default parameter value for ScopedCallData()
Oleg Shparber [Fri, 28 Nov 2014 09:19:11 +0000 (01:19 -0800)]
Add default parameter value for ScopedCallData()

Change-Id: I16b6662a47c682e145d3e2201f9e90f58405a599
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
9 years agoRelease the VM of unused heap chunks
Jocelyn Turcotte [Wed, 3 Dec 2014 16:25:11 +0000 (17:25 +0100)]
Release the VM of unused heap chunks

This changes the way that available items are linked together to
allow releasing chunks not containing any inUse item after being
swept. Instead of putting a freed item at the top of the stack and
make it link to the item previously at the top, relink all
items !inUse to point to the previously visited unused item during
sweeping.

This allows any chunk to be released in the process while making sure
that no previous or next item will link to an address in that chunk.

The performance penality of relinking the list has been measured
to be ~0.6% with v8-bench.js tst_QJSEngine::largeSweep. In exchange,
this helps keeping the amount of chunks to sweep lower after peaks
of heap allocation, even though that ability will be restrained by
heap fragmentation in long running applications.

Task-number: QTBUG-41099
Change-Id: I81a70f0a930b679a1bef47e630b23dab5f6d1218
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
9 years agoMove prototype back from the vtable into Object
Lars Knoll [Mon, 24 Nov 2014 14:38:41 +0000 (15:38 +0100)]
Move prototype back from the vtable into Object

This is the only way we can support a GC that moves
objects around in memory.

Change-Id: I1d168fae4aa9f575b730e469e762bc5b5549b886
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
9 years agoBetter encapsulate access to the global object
Lars Knoll [Fri, 21 Nov 2014 12:18:23 +0000 (13:18 +0100)]
Better encapsulate access to the global object

Change-Id: I8a76112d821cb3fc172ba0d16ee8410d39b4422a
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
9 years agoEncapsulate accesses to the root context
Lars Knoll [Fri, 21 Nov 2014 08:17:01 +0000 (09:17 +0100)]
Encapsulate accesses to the root context

Change-Id: I668cef1363a5c1a5c5b9a7e138f3bd0338712eea
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
9 years agoFix Object::arrayData() accessor to return a heap object
Lars Knoll [Thu, 20 Nov 2014 16:46:46 +0000 (17:46 +0100)]
Fix Object::arrayData() accessor to return a heap object

Change-Id: Iffc82c2f415251d73bb7446848399b54b16589c9
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
9 years agoGet rid of a not required reinterpret_cast
Lars Knoll [Tue, 18 Nov 2014 16:37:26 +0000 (17:37 +0100)]
Get rid of a not required reinterpret_cast

Change-Id: I076fa02589cc91eca46dd652375585bc7ca5b559
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
9 years agoCleanup header inclusion order
Lars Knoll [Tue, 18 Nov 2014 16:35:48 +0000 (17:35 +0100)]
Cleanup header inclusion order

Change-Id: I6f7973370c4468e7d1686a147efca66bfbfdd5b1
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
9 years agoRemove arrayData() calls from qv4object.cpp
Lars Knoll [Mon, 17 Nov 2014 19:55:41 +0000 (20:55 +0100)]
Remove arrayData() calls from qv4object.cpp

Change-Id: I92c74e87918a5f958ff17f4cbbc1888b58833fc6
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
9 years agoChanged value type property index encoding
Simon Hausmann [Mon, 10 Nov 2014 07:03:08 +0000 (08:03 +0100)]
Changed value type property index encoding

We used to encode property index and value type property index in one int
with 16 bits each, for example font.pixelSize with index of "font" in the
lower 16 bits and "pixelSize" in the upper 16 bits.

Detecting if a given encoded index was using value types or not was based on
whether the value type index (upper 16 bits) were non-zero. That assumption
holds given that all valid property indicies of value types are > 0 because
they are all sub-classes of QObject, which provides the first property
(objectName).

With the introduction of gadgets property index zero will become popular again,
and value types are a core use-case for gadgets. Therefore we need to change
the encoding to allow for zero to be a valid value type property index. This is
implemented by centralizing all decoding call sites to call one function that
indicates -1 as non-present value type core index return value. That way we can
encode the index with an offset of 1.

Change-Id: I266abf140211a4f7204b47b94d07c364f0a8f408
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
9 years agoFix arrayData accesses in qv4lookup.cpp
Lars Knoll [Mon, 17 Nov 2014 18:48:15 +0000 (19:48 +0100)]
Fix arrayData accesses in qv4lookup.cpp

Change-Id: I39a2e4f14afda2c0e909584682ef24a8b030025b
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
9 years agoRemove non required arrayData() accesses from qv4arrayobject.cpp
Lars Knoll [Mon, 17 Nov 2014 18:43:57 +0000 (19:43 +0100)]
Remove non required arrayData() accesses from qv4arrayobject.cpp

Change-Id: Iaa012b85cad20fa3887c1308dd38d35da8c423b4
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
9 years agoMove readonly accessors into Heap::ArrayData
Lars Knoll [Mon, 17 Nov 2014 20:08:13 +0000 (21:08 +0100)]
Move readonly accessors into Heap::ArrayData

these methods don't modify the object, so it's safe to have them
there and this simplifies quite a bit of the code.

Change-Id: I2f591758efba9cb8d17b956bc7c02e2d7a468ea4
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
9 years agoMove function definition where it belongs
Lars Knoll [Mon, 24 Nov 2014 08:52:23 +0000 (09:52 +0100)]
Move function definition where it belongs

Change-Id: I93e98813d2ffaf7dc648ad81b15e907dfdc276d0
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
9 years agoMerge remote-tracking branch 'origin/5.4' into dev
Simon Hausmann [Tue, 9 Dec 2014 14:09:20 +0000 (15:09 +0100)]
Merge remote-tracking branch 'origin/5.4' into dev

Conflicts:
src/qml/jsruntime/qv4arraydata.cpp
src/qml/jsruntime/qv4context_p.h
src/qml/jsruntime/qv4globalobject.cpp
src/qml/jsruntime/qv4internalclass.cpp
src/quick/items/qquicktext_p.h
src/quick/items/qquicktextedit_p.h
src/quick/items/qquicktextinput_p.h

Change-Id: If07e483e03197cb997ef47a9c647a479cdb09f4c

9 years agoCleanup: Remove unused code
Simon Hausmann [Mon, 8 Dec 2014 14:51:47 +0000 (15:51 +0100)]
Cleanup: Remove unused code

isConcurrent is not virtual and always returns true, so we can remove
it and remove the if() on the caller side.

Change-Id: Ie750fdeddaf8c339e1fcab99ebd967e3446bd975
Reviewed-by: Michael Brasser <michael.brasser@live.com>
9 years agoCleanup: Merge QQmlDataLoader and QQmlTypeLoader
Simon Hausmann [Mon, 8 Dec 2014 14:48:17 +0000 (15:48 +0100)]
Cleanup: Merge QQmlDataLoader and QQmlTypeLoader

There exists only one sub-class of QQmlDataLoader and there are no virtual
functions.

This also clears up a confusion reported in Jira that suggested QQmlDataLoader
should get a virtual destructor as it is being subclassed and somebody might
have a pointer only to a QQmlDataLoader and deleting that would not do proper
polymorphic destruction.

Change-Id: I34611be5a95522bc85a87fb7df97b6d1de7a3d37
Reviewed-by: Michael Brasser <michael.brasser@live.com>
Reviewed-by: Christopher Adams <chris.adams@jollamobile.com>
9 years agoQML: fix warning in tests
Erik Verbruggen [Mon, 8 Dec 2014 09:25:09 +0000 (10:25 +0100)]
QML: fix warning in tests

Remove unused function that wouldn't be emitted anyway.

Change-Id: I623d5d44bca9a1358cf9e66ff557992aba9ae451
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
9 years agoQML: fix warning in tests
Erik Verbruggen [Mon, 8 Dec 2014 09:24:42 +0000 (10:24 +0100)]
QML: fix warning in tests

Remove unused constant.

Change-Id: I3fb3512f7ea54102450eeeda1a56c73fe6b26025
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
9 years agoMerge "Merge remote-tracking branch 'origin/5.4.0' into 5.4" into refs/staging/5.4
Simon Hausmann [Tue, 9 Dec 2014 08:53:01 +0000 (09:53 +0100)]
Merge "Merge remote-tracking branch 'origin/5.4.0' into 5.4" into refs/staging/5.4

9 years agoQML: fix warning in tests
Erik Verbruggen [Mon, 8 Dec 2014 09:24:06 +0000 (10:24 +0100)]
QML: fix warning in tests

Remove unused class field.

Change-Id: I90981546e33d4839a91c418a8746e6f2ebc3bf46
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
9 years agoQuick: fix test
Erik Verbruggen [Mon, 8 Dec 2014 09:22:47 +0000 (10:22 +0100)]
Quick: fix test

/Users/erik/dev/qt5-stable/qtdeclarative/tests/auto/quick/qquickgridview/tst_qquickgridview.cpp:1561:60: warning: adding 'int' to a string does not append to the string [-Wstring-plus-int]
                    items << qMakePair(QString("new item " + j), QString::number(j));
                                               ~~~~~~~~~~~~^~~

Change-Id: I94bd952abf82a8f174772482330b5fdd636578ad
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
9 years agoMay it rest in pieces.
Robin Burchell [Mon, 8 Dec 2014 10:33:57 +0000 (02:33 -0800)]
May it rest in pieces.

Change-Id: I58a2ac56e099da44314feb1614067626b015710a
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
9 years agoAvoid inadvertent copies of the windows list
Roger Maclean [Thu, 4 Dec 2014 21:28:42 +0000 (16:28 -0500)]
Avoid inadvertent copies of the windows list

There are a couple of ways in which this code creates
temporary copies of the window list, m_windows.  This is often
benign but there are also places (e.g. startOrStopAnimationTimer)
which get non-const references to items which results
in m_windows being detached from the temporary resulting in a real
copy of the list items.  Again the copy is often fairly benign,
however, as the code also relies heavily on pointers to items
in the list, it can also result in crashes.

I think it might be advisable to store a list of pointers to
Window structures rather than store the structure themselves as
it appears really easy to introduce copies of the list accidentally.
The removal of the use of foreach for example is not made here for
aesthetics but because it introduces a hidden temporary copy of
the list.

Change-Id: I504951a897c4fb0cf106f5a4792b5cfcd532ba8f
Reviewed-by: Laszlo Agocs <laszlo.agocs@theqtcompany.com>
9 years agoAvoid string-based connect in QQuickImageBase.
Michael Brasser [Sat, 6 Dec 2014 16:38:34 +0000 (10:38 -0600)]
Avoid string-based connect in QQuickImageBase.

String-based connect is relatively slow, and should be avoided in core
items. This improves performance of the

tst_librarymetrics_performance::instantiation_cached(043) image - empty

test case (approximately halving the time).

Task-number: QTBUG-43096
Change-Id: I02485c515435eceacc95c55f877fc8566e7406d7
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
9 years agoFix \inqmlmodule usage: only use one parameter
Alejandro Exojo [Fri, 5 Dec 2014 19:14:20 +0000 (20:14 +0100)]
Fix \inqmlmodule usage: only use one parameter

Since the command just links back to the corresponding module page, only the
first parameter is used, and the version causes more confusion.

Change-Id: I73ed289550c576747132f77b83c1257094059cd1
Reviewed-by: Mitch Curtis <mitch.curtis@digia.com>
9 years agoFix crash with when evaluating bindings with QQmlExpression that throw exceptions
Simon Hausmann [Mon, 1 Dec 2014 11:27:28 +0000 (12:27 +0100)]
Fix crash with when evaluating bindings with QQmlExpression that throw exceptions

We must handle a thrown exception and cannot pass the undefined value back to
QV8Engine::toVariant.

Change-Id: Ia466b175706dccd513895ef5bb166b811fbdc26b
Task-number: QTBUG-41860
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
9 years agoQmlDebug: Provide public method for starting a debug server
Ulf Hermann [Fri, 10 Oct 2014 11:32:38 +0000 (13:32 +0200)]
QmlDebug: Provide public method for starting a debug server

With QQmlDebuggingEnabler::startTcpDebugServer you can create a debug
server for debugging or profiling also without the qmljsdebugger
command line argument.

Change-Id: I642f73680585f9c7578762bcc0b247c736fe1338
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
9 years agoQmlDebug: Allow tests to ignore a number of bind errors
Ulf Hermann [Fri, 10 Oct 2014 14:14:57 +0000 (16:14 +0200)]
QmlDebug: Allow tests to ignore a number of bind errors

Like this we can effectively test the port range feature of the debug
server.

Change-Id: Id0d0b47525177f0cfbb8c35a267962a82338f047
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
9 years agoQmlDebug: Test the debugging enabler
Ulf Hermann [Fri, 10 Oct 2014 14:15:58 +0000 (16:15 +0200)]
QmlDebug: Test the debugging enabler

Change-Id: I7c9aff4474850139fe96afc4b300fa0e2ded8874
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
9 years agoMark parameter to QQmlDebuggingEnabler as unused if it isn't used.
Ulf Hermann [Tue, 2 Dec 2014 13:37:16 +0000 (14:37 +0100)]
Mark parameter to QQmlDebuggingEnabler as unused if it isn't used.

Change-Id: I6e843dee8e25b3aacfe3de7c584effd36efdb708
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
9 years agoSkip failing test temporarily
Simon Hausmann [Fri, 5 Dec 2014 11:25:59 +0000 (12:25 +0100)]
Skip failing test temporarily

Skip this until commit 155306ffee1941194d44dd632a7993fce4a05606 from qtbase
has hit the dev branch through merges.

Change-Id: I3e58d288fcc45c511bc1b8b4e7dbb6c41d367eba
Reviewed-by: Shawn Rutledge <shawn.rutledge@digia.com>
9 years agoMerge remote-tracking branch 'origin/5.4.0' into 5.4
Simon Hausmann [Fri, 5 Dec 2014 10:58:05 +0000 (11:58 +0100)]
Merge remote-tracking branch 'origin/5.4.0' into 5.4

Change-Id: I5978bab8a4fde4c2ee33907fd81f49cb69e4fb26

9 years agoQQmlInspectorService: handle views only with supported plugins. v5.4.0
Ulf Hermann [Tue, 2 Dec 2014 17:26:46 +0000 (18:26 +0100)]
QQmlInspectorService: handle views only with supported plugins.

Task-number: QTBUG-43048
Change-Id: I5b32bd0a1e28fdf56b5346580daf21e7ec1b9f8c
Reviewed-by: Kevin Funk <kevin.funk@kdab.com>
Reviewed-by: Kai Koehne <kai.koehne@theqtcompany.com>
9 years agoqttest: make findChild available only for QtTest 1.1
Fawzi Mohamed [Thu, 4 Dec 2014 17:00:40 +0000 (18:00 +0100)]
qttest: make findChild available only for QtTest 1.1

Change-Id: I4ceb1a969bd4296b82f899088b02b5e8cf100bcd
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
9 years agoUpdate plugins.qmltypes
Kai Koehne [Thu, 4 Dec 2014 08:50:44 +0000 (09:50 +0100)]
Update plugins.qmltypes

Change-Id: I9b6c54b572d4653d609b154000e274b9e64d591f
Reviewed-by: Fawzi Mohamed <fawzi.mohamed@theqtcompany.com>
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
9 years agoAdd string::arg method in installTranslatorFunctions
Kai Koehne [Thu, 4 Dec 2014 13:19:09 +0000 (14:19 +0100)]
Add string::arg method in installTranslatorFunctions

QJSEngine::installTranslatorFunctions install the translator functions
to any given JS object. However, the custom string::arg() method is only
added in qqmlbuiltinfunctions.cpp, making the use of qsTr() in other
pure-JS programs quite hard.

Task-number: QTBUG-43113
Change-Id: Ia9ed97a4c07a4d167c792f3ea13e4f6e96c97423
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
9 years agoCorrect QtQml.Models \qmlmodule version.
Mitch Curtis [Tue, 18 Nov 2014 09:16:52 +0000 (10:16 +0100)]
Correct QtQml.Models \qmlmodule version.

For example, the following documentation [1] says:

Import Statement:   import QtQml.Models 2.0

This should be:

Import Statement:   import QtQml.Models 2.1

The module documentation [2] is correct, but there's no visible link to
that page from [1].

[1] http://qt-project.org/doc/qt-5/qml-qtqml-models-objectmodel.html
[2] http://qt-project.org/doc/qt-5/qtqml-models-qmlmodule.html

Change-Id: Ib2ab7b821ad7e98c20b396b26f745ee39434b7fb
Reviewed-by: Topi Reiniö <topi.reinio@digia.com>
9 years agoFix QtQuick2 module unload support
Chris Adams [Mon, 1 Dec 2014 04:32:57 +0000 (14:32 +1000)]
Fix QtQuick2 module unload support

This commit ensures that the value type providers installed by the
QtQuick2 QML module during initialization are uninstalled when the
plugin is unloaded.

It also fixes a bug in the type compiler so that it now works with
types from plugins which get unloaded and then reloaded.

Task-number: QTBUG-43004
Change-Id: I4b3fb75aae65dfbc5de9c88701ed82514087ab7d
Reviewed-by: Matthew Vogt <matthew.vogt@qinetic.com.au>
9 years agoError out when trying to set an item as its own parent
Frederik Gladhorn [Wed, 3 Dec 2014 13:42:12 +0000 (14:42 +0100)]
Error out when trying to set an item as its own parent

Task-number: QTBUG-43063
Change-Id: I92a33047ac7fa2afeff4986b6e42c07afbc59918
Reviewed-by: J-P Nurmi <jpnurmi@theqtcompany.com>
9 years agoFix crashes on QNX/x86
Simon Hausmann [Wed, 3 Dec 2014 09:37:16 +0000 (10:37 +0100)]
Fix crashes on QNX/x86

On x86 we assume that ebx holds the address of the global offset table for
position independent code. So before placing a run-time call we restore the
register from it's position we saved it on earlier on the stack. However after
commit d9f33ccdef985badc56fd8940373748626beffc7 the register wasn't saved on the
stack anymore in the prologue because we skipped because it's caller saved. So
when we seemingly reloaded ebx with the GOT from the stack, we loaded it from a location
we never saved it to. This patch makes sure to always save it on the stack so that
we can always restore it.

Change-Id: I8f6a8e38779151fff517f17220f29a7cb45ca89d
Task-number: QTBUG-43036
Reviewed-by: Erik Verbruggen <erik.verbruggen@theqtcompany.com>
9 years agoFix application build when combining with Mac OS X Cocoa headers
Simon Hausmann [Mon, 1 Dec 2014 12:11:03 +0000 (13:11 +0100)]
Fix application build when combining with Mac OS X Cocoa headers

OSX's AssertMacros.h unconditionally defines macros like "check" and that
clashes with qml's type discovery templates that define a check function
and that are used by qmlRegisterType and friends.

There's a comment in the OS X headers suggesting that this will be fixed
in the "next" release, but that hasn't happened for a while and the bug
is still present in 10.10. So let's work around it and make life easier
for people using Qml and Cocoa at the same time.

Change-Id: I005d21188f92deaebd45bce2e6484cd4deeb9a34
Task-number: QTBUG-36309
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
9 years agoFix conditional breakpoints in QML
Simon Hausmann [Mon, 1 Dec 2014 14:51:05 +0000 (15:51 +0100)]
Fix conditional breakpoints in QML

We need to set "inheritContext" to true for the QV4::Script that's used during
conditional break point evaluation, because that will also disable fast
property lookups, which is still required for QML lookups to work.

Change-Id: I8976df1c827b5058eae9bdce6e86e5ea856cbfe1
Task-number: QTBUG-43018
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
9 years agoFix expression evaluation in specific frames in the debugger
Simon Hausmann [Fri, 28 Nov 2014 08:24:35 +0000 (09:24 +0100)]
Fix expression evaluation in specific frames in the debugger

Expressions from the QML/JS console are intended to be executed in a specific
frame / context. However that wasn't implemented properly, we should pop the
current context frameNr times.

[ChangeLog][QtQml] Fix inspecting objects in QML/JS console in different frames.

Change-Id: If575d4005c52a9fe6805538a7b1a02b9e32049d6
Task-number: QTBUG-42831
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
9 years agoRemove dead code
Simon Hausmann [Thu, 27 Nov 2014 14:45:02 +0000 (15:45 +0100)]
Remove dead code

The eval code tracking was used last time for the old exception handling,
but that's long gone :)

Change-Id: I6fa80a5197745fde461e4da66cd65a50149c6048
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
9 years agoQtQuick.Window: add missing documentation for Window methods
Shawn Rutledge [Fri, 7 Nov 2014 11:55:03 +0000 (12:55 +0100)]
QtQuick.Window: add missing documentation for Window methods

Several more methods/slots are inherited from QWindow but are not
documented for the QML Window type.  Also some other documentation
improvements.

Task-number: QTBUG-40093
Task-number: QTBUG-42426
Change-Id: Ib753be269cbc41ee540e6556e0ef483758eefe62
Reviewed-by: Topi Reiniö <topi.reinio@digia.com>
9 years agoMerge "Merge remote-tracking branch 'origin/5.4.0' into 5.4" into refs/staging/5.4
Simon Hausmann [Tue, 2 Dec 2014 18:56:43 +0000 (19:56 +0100)]
Merge "Merge remote-tracking branch 'origin/5.4.0' into 5.4" into refs/staging/5.4

9 years agoMerge remote-tracking branch 'origin/5.4.0' into 5.4
Simon Hausmann [Tue, 2 Dec 2014 12:41:31 +0000 (13:41 +0100)]
Merge remote-tracking branch 'origin/5.4.0' into 5.4

Change-Id: I89bbb2977350a03c156d531f810d08a5560ffbb3

9 years agoFix permissions of files
Kai Koehne [Wed, 26 Nov 2014 08:59:11 +0000 (09:59 +0100)]
Fix permissions of files

Change-Id: I22958892d846da348325ba608084f8d9a05473d4
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
9 years agoAdded change log for 5.4.0
Simon Hausmann [Sat, 29 Nov 2014 08:55:50 +0000 (09:55 +0100)]
Added change log for 5.4.0

Change-Id: Ie3e238a3ccac1d95978229316977d131be3010d6
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
9 years agoRegression: Fix array data corruption
Simon Hausmann [Mon, 1 Dec 2014 09:21:27 +0000 (10:21 +0100)]
Regression: Fix array data corruption

When inserting into a sparse JS array, we may have to re-allocate the
underlying data vector. When that happens we must reload the ArrayData
pointer, to avoid returning a wrong pointer in ArrayData::insert.

This patch also fixes the valgrind support in the memory allocator by correctly
marking the mmap'ed memory region as inaccessible.

Change-Id: I86aabc2cec74a4f3c8396463910d90c8968a741d
Task-number: QTBUG-42956
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
9 years agoSkip tst_qquickwindow::headless() when using ANGLE/Windows.
Friedemann Kleint [Mon, 1 Dec 2014 09:45:00 +0000 (10:45 +0100)]
Skip tst_qquickwindow::headless() when using ANGLE/Windows.

The test crashes frequently.

Task-number: QTBUG-42967
Change-Id: Ic17c6187bfa657154a9b04eb9c5b9a3de291cb1e
Reviewed-by: Andrew Knight <andrew.knight@theqtcompany.com>
Reviewed-by: Laszlo Agocs <laszlo.agocs@theqtcompany.com>
9 years agoFix loading of .ui.qml form files with cached compilation units
Simon Hausmann [Mon, 24 Nov 2014 14:52:42 +0000 (15:52 +0100)]
Fix loading of .ui.qml form files with cached compilation units

Simplify the type loading logic and try the Type -> Type.qml and Type ->
Type.ui.qml mapping in a simple loop that tries off-disk and cached
compilation unit loading.

Change-Id: I537feabd0a158a71f330bede9e6988291298ae81
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
9 years agoDon't default to HighQualitySubPixelAntialiasing on WinRT
Andrew Knight [Fri, 28 Nov 2014 11:43:12 +0000 (13:43 +0200)]
Don't default to HighQualitySubPixelAntialiasing on WinRT

The subpixel shader is probably not a good default here because most
devices are mobile (can change screen orientation) and have high pixel
densities. Furthermore, it breaks text rendering on the Surface RT, where
the graphics hardware is too weak to support the number of uniforms the
subpixel shader uses.

Task-number: QTBUG-41769
Change-Id: I10210af91976ab55e611025c0452a1ee1f3114a9
Reviewed-by: Oliver Wolff <oliver.wolff@theqtcompany.com>
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@theqtcompany.com>
9 years agoMake effectiveDevicePixelRatio() return a qreal.
Morten Johan Sørvig [Tue, 25 Nov 2014 13:22:15 +0000 (14:22 +0100)]
Make effectiveDevicePixelRatio() return a qreal.

Fractional scale factors are not as broken as previously
believed, especially for Qt Quick. Keep the door open
for finding a way to support it at some point in the
future.

Change-Id: Ifeadcc53175ac6c25ea0288d5fe1966e3de408f9
Reviewed-by: Laszlo Agocs <laszlo.agocs@theqtcompany.com>
9 years agoAdd missing call to rendercontrol
Laszlo Agocs [Sat, 22 Nov 2014 20:17:34 +0000 (21:17 +0100)]
Add missing call to rendercontrol

Change-Id: Ic8c8e6d7a9d99216292b8b4faa2926d849333a05
Reviewed-by: Paul Olav Tvete <paul.tvete@theqtcompany.com>
9 years agoAdd since 5.4 markers
Albert Astals Cid [Tue, 25 Nov 2014 21:56:30 +0000 (22:56 +0100)]
Add since 5.4 markers

Change-Id: Ic0e594cb53016e6f68fbfb6e6064707344afefef
Reviewed-by: Laszlo Agocs <laszlo.agocs@theqtcompany.com>
Reviewed-by: Gunnar Sletta <gunnar@sletta.org>
9 years agoStabilize tst_qquickflickable.
Friedemann Kleint [Wed, 26 Nov 2014 09:01:15 +0000 (10:01 +0100)]
Stabilize tst_qquickflickable.

- Use one engine per test
- Use QQuickView for the margins test
- Verify QWindow cleanup.

Change-Id: Id2a10b56101832c362822963a2a7bd1d66daa143
Reviewed-by: Laszlo Agocs <laszlo.agocs@theqtcompany.com>
9 years agoDocument Qt.application.supportsMultipleWindows property.
Mitch Curtis [Thu, 13 Nov 2014 15:30:03 +0000 (16:30 +0100)]
Document Qt.application.supportsMultipleWindows property.

The documentation was not added in
0df606e2ab8f3b60e1ad57dba245acf2e7810612.

Change-Id: I0a5802a66021e17d1280f3969981c9e8a62c8119
Reviewed-by: Topi Reiniö <topi.reinio@digia.com>
Reviewed-by: Shawn Rutledge <shawn.rutledge@digia.com>
9 years agoDoc: Remove text that claims aliases cannot be read-only
Simon Hausmann [Mon, 24 Nov 2014 12:10:04 +0000 (13:10 +0100)]
Doc: Remove text that claims aliases cannot be read-only

It's very well possible to have read-only aliases :)

Task-number: QTBUG-33709
Change-Id: I2ad8854cd0b412d1d2e7afde6dfd585519b69e27
Reviewed-by: Michael Brasser <michael.brasser@live.com>
9 years agoOperate directly on Heap::ArrayData where possible
Lars Knoll [Mon, 17 Nov 2014 13:54:52 +0000 (14:54 +0100)]
Operate directly on Heap::ArrayData where possible

Change-Id: I87dfb3e9a07673b5c405619eab8b6ee292d5c097
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
9 years agoReduce usage of Object::arrayData()
Lars Knoll [Mon, 17 Nov 2014 13:33:40 +0000 (14:33 +0100)]
Reduce usage of Object::arrayData()

This will simplify porting over to returning Heap::ArrayData
from the method (as required for the new GC).

Change-Id: I5fb9ca7dfeab1aa63cc17c8948ef0966716f1bcb
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
9 years agoMove the indexing methods from SimpleArrayData to Heap::SimpleArrayData
Lars Knoll [Mon, 17 Nov 2014 10:45:24 +0000 (11:45 +0100)]
Move the indexing methods from SimpleArrayData to Heap::SimpleArrayData

Change-Id: I7d126999fb813bd9c0f224f7229d66854079f793
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
9 years agoRemove two reinterpret_casts in Object
Lars Knoll [Fri, 14 Nov 2014 08:31:59 +0000 (09:31 +0100)]
Remove two reinterpret_casts in Object

Change-Id: I921cd8129acb47cffd58be9551a6925c4f296d41
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
9 years agoLet the memory manager operate on Heap::Base objects, not Managed
Lars Knoll [Thu, 13 Nov 2014 20:53:27 +0000 (21:53 +0100)]
Let the memory manager operate on Heap::Base objects, not Managed

Change-Id: Ib5c9b51dbf9c69abeda088094e6348dd545bf3c8
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
9 years agoCleanup destruction of heap objects
Lars Knoll [Thu, 13 Nov 2014 20:38:25 +0000 (21:38 +0100)]
Cleanup destruction of heap objects

Generate the code from a macro instead of duplicating boiler
plate code. Operate on Heap::Base instead of Managed.

Change-Id: I84c5a705980899be3e5b931a093645e50d3923bf
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
9 years agoMake QV4::RegExpObject header independent from masm headers
Oleg Shparber [Fri, 21 Nov 2014 06:16:53 +0000 (22:16 -0800)]
Make QV4::RegExpObject header independent from masm headers

Also remove pointless uint32_t for uint values and replace
a few inconsistent uint16_t uses with quint16. MSVC was using uintN_t
defined in masm headers instead of cstdint, so this change eliminates
such situation.

Change-Id: Ibd7dd50fc047dcdc78e057299883311a24dd3960
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
9 years agoWe should never construct a managed derived type directly anymore
Lars Knoll [Thu, 13 Nov 2014 11:25:08 +0000 (12:25 +0100)]
We should never construct a managed derived type directly anymore

Change-Id: I77e4065429a49bb3409bd1518ce910298d6141ee
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
9 years agoRemove the executioncontext in a few more places where it's not needed
Lars Knoll [Thu, 13 Nov 2014 11:14:09 +0000 (12:14 +0100)]
Remove the executioncontext in a few more places where it's not needed

Change-Id: I4c92c7bc9d94d8265e306f45d863fdc080a5e2a6
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
9 years agoFix the qmlProperty accessors to not require a context anymore
Lars Knoll [Thu, 13 Nov 2014 10:41:52 +0000 (11:41 +0100)]
Fix the qmlProperty accessors to not require a context anymore

Change-Id: Ied5ad5b2fef494de77aefdb4a7ee25aff4d7722a
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
9 years agoChanged InternalClass to store Identifier* instead of String*
Simon Hausmann [Wed, 12 Nov 2014 19:07:27 +0000 (20:07 +0100)]
Changed InternalClass to store Identifier* instead of String*

All members are identifiers anyway, so this gets rid of a ### and
also simplifies some of the call sites by removing the need for a
scoped string.

Change-Id: Ic6b550cdb97afa5a4b0fa7e9b13e7768ed3f6bd8
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
9 years agoMerge "Merge remote-tracking branch 'origin/5.4.0' into 5.4" into refs/staging/5.4
Frederik Gladhorn [Fri, 21 Nov 2014 12:47:31 +0000 (13:47 +0100)]
Merge "Merge remote-tracking branch 'origin/5.4.0' into 5.4" into refs/staging/5.4

9 years agoMerge remote-tracking branch 'origin/5.4.0' into 5.4
Frederik Gladhorn [Fri, 21 Nov 2014 12:45:07 +0000 (13:45 +0100)]
Merge remote-tracking branch 'origin/5.4.0' into 5.4

Change-Id: I2e7fc085663e00dd0390593a91c30d23d1369c4e

9 years agoFix run-time string handling with regards to the new heap
Simon Hausmann [Wed, 12 Nov 2014 15:07:56 +0000 (16:07 +0100)]
Fix run-time string handling with regards to the new heap

Changed runtimeStrings to be an array of Heap::String pointers instead of
indirect String pointers. Later that member along with other GC related members
will go into a managed subclass. Meanwhile the generated code no more loads
String pointers directly but just passes the index into the run-time strings to
the run-time functions, which in turn will load the heap string into a scoped
string.

Also replaced the template<T> Value::operator=(T *m) with a non-template
overload that takes a Managed *, in order to help the compiler choose the
non-template operator=(Heap::Base *) overload. This allows removing a bunch
of Value::fromHeapObject calls.

Change-Id: I20415c0549d33cca6813441a2495976b66d4c00e
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
9 years agoFix multirow spritesheet rendering in paused state
Joni Poikelin [Thu, 20 Nov 2014 12:10:03 +0000 (14:10 +0200)]
Fix multirow spritesheet rendering in paused state

Task-number: QTBUG-42777
Change-Id: I8027f100c593ae7c57df7c952e66cc2b3fae1dd9
Reviewed-by: Laszlo Agocs <laszlo.agocs@digia.com>
9 years agoGet rid of one PersistentValue usage
Simon Hausmann [Wed, 19 Nov 2014 14:07:30 +0000 (15:07 +0100)]
Get rid of one PersistentValue usage

We don't need to store a PersistentValue in a place that is reachable through
regular object marking.

Change-Id: I2a8764970e6d37b707921c65e6066d33c558576c
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
9 years agoExpose a getter for the QSGEnginePrivate
Jocelyn Turcotte [Fri, 17 Oct 2014 16:14:30 +0000 (18:14 +0200)]
Expose a getter for the QSGEnginePrivate

This allows getting its underlying QSGContext and QSGRenderContext.

Change-Id: If0773d09b6faa360e706949757db1a6ddbe244e1
Reviewed-by: Gunnar Sletta <gunnar@sletta.org>
9 years agoAllow setting the source rect on QSGSimpleTextureNode
Jocelyn Turcotte [Fri, 17 Oct 2014 15:36:57 +0000 (17:36 +0200)]
Allow setting the source rect on QSGSimpleTextureNode

This allows the QtQuick 2D Renderer to get this information without
having to extract it from the QSGGeometry.

Change-Id: Iec99c4bc910fea9c7d0e6712a418787254a70cb2
Reviewed-by: Allan Sandfeld Jensen <allan.jensen@theqtcompany.com>
9 years agoUpdate qml to use new QMetaType::registerNormalizedType signature
Jędrzej Nowacki [Thu, 13 Nov 2014 10:03:20 +0000 (11:03 +0100)]
Update qml to use new QMetaType::registerNormalizedType signature

Change-Id: Ia2ead9768669db4ee9c7b7c8fc14d0e4b09420b0
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
9 years agoDo not send deferred deletes from QQuickRenderControl::invalidate()
Laszlo Agocs [Mon, 17 Nov 2014 15:11:22 +0000 (16:11 +0100)]
Do not send deferred deletes from QQuickRenderControl::invalidate()

Leave it up to the clients of QQuickRenderControl to do this, if they
want it. It is usually not necessary.

In the single-threaded widget world forcing deferred deletes to execute
on every invalidate(), so for example from the hide event handler of
QQuickWidget, is dangerous because widget apps tend to deleteLater()
all sorts of widgets which can then be destroyed at unexpected times.

From windowDestroyed() we continue to send the deferred deletes, just
like all the render loops do.

Task-number: QTBUG-42618
Task-number: QTBUG-40435
Change-Id: I8189124e2e7675361ee97bd8ba3e88b10ef193fa
Reviewed-by: Gunnar Sletta <gunnar@sletta.org>
9 years agoDoc: removed reference to sizeHint
Nico Vertriest [Mon, 27 Oct 2014 13:58:40 +0000 (14:58 +0100)]
Doc: removed reference to sizeHint

sizeHint is not a property of QQuickView
Task-number: QTBUG-39044
Change-Id: I6e19e975ab71f73ddaf703956afb90f2e607b6f8
Reviewed-by: Martin Smith <martin.smith@digia.com>
Reviewed-by: Topi Reiniö <topi.reinio@digia.com>
9 years agoChange test data from 6.7 to 6.5
Thiago Macieira [Tue, 18 Nov 2014 07:14:19 +0000 (23:14 -0800)]
Change test data from 6.7 to 6.5

6.5 is an exact binary number (4 + 2 + 0.5), so all conversions to
string will result in "6.5", regardless of how many digits of precision
are used.

This is done in advance of changing QVariant to add more digits of
precision, which would cause toString() of 6.7 to result in
"6.7000000000000002".

Change-Id: I19ea4c5bb02b99f0655c0b9bc9dc09f06ec654e5
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
9 years agoFix render control docs
Laszlo Agocs [Thu, 13 Nov 2014 13:47:21 +0000 (14:47 +0100)]
Fix render control docs

Fix a typo and add a note to the signals.

Change-Id: Ia8810562c5b5f192d7e54bc965807b8e78a26985
Reviewed-by: Karim Pinter <karim.pinter@digia.com>
Reviewed-by: Paul Olav Tvete <paul.tvete@theqtcompany.com>