Laszlo Agocs [Thu, 28 Aug 2014 10:23:46 +0000 (12:23 +0200)]
QQuickWidget: Keep the offscreen quick window size in sync
The resizing logic has some faults: The size change is not always communicated
to the offscreen QQuickWindow. When hiding and showing a QQuickWidget we may
return early from the resize event handler, skipping the geometry change for
the offscreen window. This is wrong.
To make sure the sizes always match, set the geometry together with the
FBO creation instead. This is much more robust and guarantees that the
FBO size and the QQuickWindow size will not be out of sync.
Task-number: QTBUG-40517
Change-Id: I61ef3ad2d23dff4280dbf03b57c03c1aeda8dc91
Reviewed-by: Paul Olav Tvete <paul.tvete@digia.com>
Simo Fält [Fri, 29 Aug 2014 09:21:38 +0000 (12:21 +0300)]
tst_qquickcanvasitem: Setting as insignificant.
Task-number: QTBUG-41043
Change-Id: Ib438ddc890e9a1ede16731b950b195d4341b8fd0
Reviewed-by: Jani Heikkinen <jani.heikkinen@digia.com>
Tim Jenssen [Fri, 29 Aug 2014 11:09:53 +0000 (13:09 +0200)]
introduce *.ui.qml file types as new forms file type
Change-Id: I1f07b6c1ab8afac7ee7ad05e988fe313ba904705
Reviewed-by: Thomas Hartmann <Thomas.Hartmann@digia.com>
Gunnar Sletta [Fri, 29 Aug 2014 09:55:32 +0000 (09:55 +0000)]
Abort the application if the render thread fails to start
This is a system-level failure, with which we can do very little,
so we abort.
Change-Id: I945da8bd28df35a6c8987160a2f0177d27d6c95d
Reviewed-by: Robin Burchell <robin.burchell@viroteck.net>
Frederik Gladhorn [Thu, 28 Aug 2014 21:11:05 +0000 (23:11 +0200)]
Merge "Merge remote-tracking branch 'origin/5.3' into 5.4" into refs/staging/5.4
Tim Jenssen [Thu, 28 Aug 2014 14:51:00 +0000 (16:51 +0200)]
Add new property "designersupported" to qmldir
This patch adds a property called "designersupported" to qmldir.
This allows the Qt Quick Designer to only load plugins that
have the line ""designersupported"" in their qmldir file.
So the designer can load sub components without risking to load
plugins that have never been tested in the designer and that might crash.
The check for "designersupported"" is activated by using
QQmlImports::setDesignerSupportRequired().
Change-Id: I4bf07cc163faa47996eacb1365a7961c51c51060
Reviewed-by: Thomas Hartmann <Thomas.Hartmann@digia.com>
Reviewed-by: Tim Jenssen <tim.jenssen@digia.com>
Frederik Gladhorn [Thu, 28 Aug 2014 14:18:27 +0000 (16:18 +0200)]
Merge remote-tracking branch 'origin/5.3' into 5.4
Change-Id: I92b91cce499ed4bec64521a581276f397792e218
Mitch Curtis [Wed, 27 Aug 2014 10:35:47 +0000 (12:35 +0200)]
TestCase.qml: add missing closing parenthesis to example.
Change-Id: I93f1f8ec74808fc0a9f681cd88f7e5616089c80c
Reviewed-by: Gunnar Sletta <gunnar@sletta.org>
Laszlo Agocs [Tue, 26 Aug 2014 14:13:27 +0000 (16:13 +0200)]
Fix not having a context when making a QQuickWidget visible again
If we hit the size-is-zero path, the condition that got recently introduced
(if fakeHidden && d->context) is not really sufficient. It could be that
d->context is valid but the scenegraph is invalidated (i.e.
offscreenWindow->openglContext() is null).
This case has to be handled the same way.
Therefore, the function is now simplified to perform polish & sync
in one place.
Task-number: QTBUG-40794
Change-Id: Ia54f25fbdc199a0b88501a2d89edb5cee5411972
Reviewed-by: Paul Olav Tvete <paul.tvete@digia.com>
Gunnar Sletta [Wed, 27 Aug 2014 05:35:24 +0000 (07:35 +0200)]
Make minimum FBO size 1x1 on newer OSX.
This problem existed on 10.6, but is not reproducible on newer
MacBookPros, so disable it for 10.8 and up.
Change-Id: I0ae216c8e2307df5f77a783ec2d2031bf12ccbf2
Task-number: QTBUG-20193
Reviewed-by: Laszlo Agocs <laszlo.agocs@digia.com>
Kai Koehne [Tue, 26 Aug 2014 10:15:31 +0000 (12:15 +0200)]
Use QtQuick.Window 2.2
Use version 2.2 in the documentation and for the .qmltypes file.
The revision for properties got dropped in commit
7ceca6ac0 , and
is now dropped from the .qmltypes file, too. The removed signals
are also dropped because of that (because they are implicitly
declared by the property, anyway).
Change-Id: Ia14dd403ce1f098cb378bd7940e8f80f32b770a0
Reviewed-by: Fawzi Mohamed <fawzi.mohamed@digia.com>
Reviewed-by: Alan Alpert <aalpert@blackberry.com>
Andy Nichols [Tue, 19 Aug 2014 14:08:23 +0000 (16:08 +0200)]
Added QSGPainterNode abstraction to QSGAdaptationLayer
This allows the scenegraph backend to customize how QSGPainterNodes are
rendered.
Change-Id: I640dcf121d0be6bda615cf30591d502329fc89d0
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
Reviewed-by: Gunnar Sletta <gunnar@sletta.org>
Erik Verbruggen [Tue, 26 Aug 2014 12:21:01 +0000 (14:21 +0200)]
V4 JIT: fix stack layout.
Commit
d9f33ccdef985badc56fd8940373748626beffc7 introduced an off-by-one
in the calculation of the offset of a saved register (in
StackLayout::savedRegPointer), resulting in overwriting a callee saved
register with the tag of a QV4::Value. This method now calculates those
pointers relative to the bottom of the stack frame.
The off-by-one didn't happen before that patch, because there was a
magical +1 used in the constructor for the number of callee saved
registers, thereby prevented this from happening. However, that resulted
in a frame size that was unnecessary big.
Task-number: QTBUG-40927
Change-Id: If88fe9f3490a4d23a1e69c630c87219fcfef671f
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
Erik Verbruggen [Fri, 22 Aug 2014 10:11:40 +0000 (12:11 +0200)]
V4: disable type inference and loop peeling for the interpreter.
Loop peeling is always disabled. Type inference is still enabled for
QML code, because of the static-type nature of the properties.
This speeds up crypto.js by 20%.
Change-Id: Ibf51cb36f8904d64df0793980d463451dfd361e2
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
Simon Hausmann [Mon, 25 Aug 2014 09:06:58 +0000 (11:06 +0200)]
Fix cursor blinking for TextInput and TextEdit
Before commit
fb339b21b8a24b835cea7a057c47b7c5ad80dd72 relied on the simple
transparent rectangle node to remain invisible. After that commit we used the
regular rectangle node, which doesn't seem to like toggling the color between
transparent and solid black and therefore the cursor was always visible.
As advised by Gunnar this patch implements a much simpler logic: When the
cursor is supposed to be invisible, we just don't create a scene graph node for
it anymore.
Change-Id: I7b0e173f6d37997559ee0911f37903efdb14847f
Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@digia.com>
Reviewed-by: Gunnar Sletta <gunnar@sletta.org>
Gunnar Sletta [Sat, 23 Aug 2014 07:00:51 +0000 (09:00 +0200)]
Make QQuickFramebufferObject a texture provider.
Change-Id: Ib9cf0f99dc07e4125c4ccd2d45da2839d8af88b6
Reviewed-by: Laszlo Agocs <laszlo.agocs@digia.com>
Laszlo Agocs [Fri, 22 Aug 2014 17:31:13 +0000 (19:31 +0200)]
Fix up vao usage in qquickviewcomparison example
The binder calls create() if needed, so drop that call.
In the render function however, drop the binder.
Trying to create() again and again on every frame is a
waste of time.
Change-Id: I1e9cd8e2c97030b96e604256661e65ce75446e9d
Reviewed-by: Jørgen Lind <jorgen.lind@digia.com>
Laszlo Agocs [Tue, 26 Aug 2014 08:28:53 +0000 (10:28 +0200)]
Do not send deferred deletes from the QQuickWindow dtor
Otherwise doing deleteLater() on an ancestor of the QQuickWindow will
cause double deletion for that ancestor. This is typical when using
WA_DeleteOnClose since that uses deleteLater().
Task-number: QTBUG-40920
Change-Id: I9146fc0854f77c42cad2eda23b3cdaa7a9e22080
Reviewed-by: Gunnar Sletta <gunnar@sletta.org>
Simon Hausmann [Tue, 26 Aug 2014 07:51:49 +0000 (09:51 +0200)]
Merge "Merge remote-tracking branch 'origin/5.3' into 5.4" into refs/staging/5.4
Venu [Thu, 21 Aug 2014 12:52:49 +0000 (14:52 +0200)]
Doc: Added a link to the QML advanced tutorial
This avoids the need to duplicate the example details
that are already covered in the tutorial.
Task-number: QTBUG-37203
Change-Id: If7e762dc1d9a572b83bddffe7982aec9a6363408
Reviewed-by: Leena Miettinen <riitta-leena.miettinen@digia.com>
Simon Hausmann [Tue, 26 Aug 2014 07:43:33 +0000 (09:43 +0200)]
Merge remote-tracking branch 'origin/5.3' into 5.4
Conflicts:
src/qml/qml/qqmlobjectcreator_p.h
Change-Id: I60858ddb46866a8fa1a8576bb05b412afeeb4e41
Gunnar Sletta [Sat, 23 Aug 2014 13:27:51 +0000 (15:27 +0200)]
Make QQuickPaintedItem a texture provider.
Change-Id: I605dc35fcc2284a890851c41946cf95537e92d2e
Reviewed-by: Laszlo Agocs <laszlo.agocs@digia.com>
Gunnar Sletta [Sat, 23 Aug 2014 12:24:05 +0000 (14:24 +0200)]
Make use of QQuickWindowQObjectCleanup in QQuickImage.
Saves us a few lines..
Change-Id: I572f6fc44ede3b923208ce3563116d8fcc9bb922
Reviewed-by: Laszlo Agocs <laszlo.agocs@digia.com>
Gunnar Sletta [Sat, 23 Aug 2014 12:13:53 +0000 (14:13 +0200)]
Make Canvas a texture provider.
Change-Id: I8b5c9d8a5ed9ef9079eafb30ef0cb73786204ee6
Reviewed-by: Laszlo Agocs <laszlo.agocs@digia.com>
Gunnar Sletta [Fri, 22 Aug 2014 14:52:05 +0000 (16:52 +0200)]
Added an example that shows how to consume texture providers from C++.
And how to use use two textures in the same material.
Change-Id: Idcc618ed359422c2a104eeed105b7c4f5086ee4e
Reviewed-by: Laszlo Agocs <laszlo.agocs@digia.com>
Gunnar Sletta [Fri, 22 Aug 2014 06:59:15 +0000 (08:59 +0200)]
Clamp QQuickItem::opacity to [0,1].
This was an oversight the the implementation of
setOpacity. QSGOpacityNode already does the right thing.
[ChangeLog][QtQuick][Item] When Item.opacity is set to a value outside
the range of 0 to 1, it will be clamped.
Change-Id: Ib7f23c5d8860c76e009a25e5ab2c36db20301faf
Reviewed-by: Raine Mäkeläinen <raine.makelainen@gmail.com>
Reviewed-by: Alan Alpert (Personal) <416365416c@gmail.com>
Lars Knoll [Thu, 12 Jun 2014 08:11:09 +0000 (10:11 +0200)]
Don't use d->instanceModel after free'ing it
prevModel points to d->instanceModel and is being
used further down in the code. So reset the pointer
to 0 after freeing the old instanceModel.
Change-Id: I8854ae3e09c8b2fe50ad311f3dbc7b8ed26805e1
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
Tasuku Suzuki [Sat, 16 Aug 2014 13:15:32 +0000 (22:15 +0900)]
Mark custom node in textureinthread dirty after rendering texture
Change-Id: I4401a6db18b1fcc69403062f3f4775d3b62dfd3e
Reviewed-by: Gunnar Sletta <gunnar@sletta.org>
Pelle Johnsen [Wed, 20 Aug 2014 10:06:10 +0000 (12:06 +0200)]
Fix QML2 hang on gcc 4.6.3 armhf
With gcc 4.6.3 armhf (defualt for Ubuntu 12.04) some optimization bug
results in QML2 v4 compiler hang during type inference.
Task-number: QTBUG-40364
Change-Id: Iea1a8be3b5a7d9410304110d89dae3735339cb72
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
Reviewed-by: Erik Verbruggen <erik.verbruggen@digia.com>
Sebastian Sauer [Tue, 12 Aug 2014 11:53:00 +0000 (18:53 +0700)]
QSM: Reintroduce guard argument evaluation
Implements the suggestion from Simon Hausmann (codereview 89716
from 08-05 14:46) to use QQmlScriptString rather then the previous
used MetaObject-manipulation.
This also introduces comparison operators for QQmlScriptString
to be able to determinate if a QQmlScriptString changed what
is needed cause there is otherwise no way to access (all) the
needed details within QQmlScriptStringPrivate.
Change-Id: I198479eac8fd37cbdd98a99aacdd8eebf7b75d21
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
Simon Hausmann [Thu, 21 Aug 2014 11:10:33 +0000 (13:10 +0200)]
Fix crash with early QObject property access
In the reported bug, it can happen that we try to access the compile-time resolved
QObject property of an object that is referenced by id. The binding that uses this is
triggered when the property changes but _also_ when the id referenced object gets either
created or deleted. The first time the binding is evaluated is very early on, when the
id referenced object is not created yet, so the binding evaluation fails. However the
dependency is set up, and so later then the id referenced object is created and the id
property is set on the context, the notification triggers and the binding is re-evaluated.
During that binding evaluation a QObject property access happens by index on an object that
doesn't have its VME meta-object set up yet. Therefore the property access fails and a
crash occurs or the Q_ASSERT(property) assertion fails.
The fix is to set register the id named object in the context _after_ the VME meta-object is
setup.
Task-number: QTBUG-40018
Change-Id: Ic2d7b4a0c49635efe68e93f2f6c316eb65f0c309
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
Albert Astals Cid [Thu, 21 Aug 2014 13:39:56 +0000 (15:39 +0200)]
Fix typo in DelegateModelGroup documentation
Change-Id: Ic01f0935c469f85f32699aebaeb1fc6f8b2279fb
Reviewed-by: Mitch Curtis <mitch.curtis@digia.com>
Mitch Curtis [Fri, 22 Aug 2014 07:52:59 +0000 (09:52 +0200)]
Remove references transforms have to items in QQuickItem's destructor.
In case they try to remove themselves from our list of transforms when
that list has already been destroyed after ~QQuickItem() has run.
Task-number: QTBUG-40877
Change-Id: Ie57f5dd1e8b791846f08629183974c771553c4bf
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
Reviewed-by: Alan Alpert <aalpert@blackberry.com>
Lars Knoll [Mon, 18 Aug 2014 10:38:24 +0000 (12:38 +0200)]
Protect some members in QQmlObjectCreator
Avoid dangling pointers when nested incubators are being used.
Task-number: QTBUG-40437
Change-Id: I73922d2f373b2efbc00983305cdea9e8d60f0c41
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
Jani Heikkinen [Fri, 22 Aug 2014 06:13:59 +0000 (09:13 +0300)]
Update license headers and add new licenses
- Renamed LICENSE.LGPL to LICENSE.LGPLv21
- Added LICENSE.LGPLv3 & LICENSE.GPLv2
- Removed LICENSE.GPL
Change-Id: I84a565e2e0caa3b76bf291a7d188a57a4b00e1b0
Reviewed-by: Jani Heikkinen <jani.heikkinen@digia.com>
Lars Knoll [Thu, 12 Jun 2014 08:19:12 +0000 (10:19 +0200)]
Initialize variable
Change-Id: Ia54dc43d22b8edaa49634c6a364f87b4a06d659d
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
Lars Knoll [Thu, 12 Jun 2014 08:52:32 +0000 (10:52 +0200)]
Don't abuse new to do a reinterpret_cast
Using new to do a reinterpret_cast is rather confusing.
Also protect the list model case against self-assignment
which could lead to memory corruption.
Change-Id: I10b81644d0004d4a50a5a74e5b8c58e27cbe6934
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
Albert Astals Cid [Thu, 21 Aug 2014 13:36:30 +0000 (15:36 +0200)]
Add const & to arguments
Change-Id: I1bcf69638fee32b6e6565b8ea828c0adcff48a67
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
Gunnar Sletta [Fri, 15 Aug 2014 12:15:14 +0000 (14:15 +0200)]
Mark QQuickFBO's node dirty after rendering the texture.
It is impossible to use in a shader effect otherwise.
Change-Id: I489e6ae43cdc3fe8f54efa6d86ead4d21831b84d
Task-number: QTBUG-40809
Reviewed-by: Laszlo Agocs <laszlo.agocs@digia.com>
Gunnar Sletta [Sat, 23 Aug 2014 12:13:05 +0000 (14:13 +0200)]
Introduce QQuickWindowQObjectCleanupJob.
Convenience for cleaning up texture providers. Private class for now,
we can maybe make it public in 5.5.
Change-Id: I3489fde2a268bc988634a16f87ee558b9ac5dba2
Reviewed-by: Laszlo Agocs <laszlo.agocs@digia.com>
Simon Hausmann [Wed, 13 Aug 2014 08:17:53 +0000 (10:17 +0200)]
Improve the internal NodeVisitorEx API
Allow the implementation of visit to control whether the children should be
processed afterwards or not. This is modelled after the JS AST visitor in
Qml.
Change-Id: I5b1adf5e1aefd8899bf444e993ddfbf2c5c125c9
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
Gunnar Sletta [Fri, 15 Aug 2014 07:26:16 +0000 (09:26 +0200)]
Downscale textures which exceed the GL texture limit
This way they will at least render.
[ChangeLog][QtQuick] Images exceeding GL_MAX_TEXTURE_SIZE will be
downscaled to fit so they will still show.
Change-Id: I169ecac768036812b8e14265ec1a0a8902655666
Reviewed-by: Laszlo Agocs <laszlo.agocs@digia.com>
Gunnar Sletta [Thu, 21 Aug 2014 09:59:03 +0000 (11:59 +0200)]
Protect incubation against its creator being deleted.
Change-Id: Ica7ed02c9b67243310ddce3feaf91935b699086d
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
Simon Hausmann [Mon, 11 Aug 2014 11:21:11 +0000 (13:21 +0200)]
Cleanup: Separate the sub-tree layering out of QtQuick into the scene graph
This basically renames QQuickShaderEffectTexture to QSGDefaultLayer and
introduces QSGLayer as interface to be used. QQuickShaderEffectTexture is
generic for the scene graph and has no QtQuick dependencies. The interface
separation allows scene graph backends to customize layers.
Change-Id: I9a7f37addaa4b80a34ff9a1456b0cb9b16d4e9f3
Reviewed-by: Gunnar Sletta <gunnar.sletta@jollamobile.com>
Gatis Paeglis [Tue, 12 Aug 2014 12:46:05 +0000 (14:46 +0200)]
Introspect qrc files in FolderListModel.
And don't use "file watchers" for resource file paths,
otherwise it generates the following warning:
QInotifyFileSystemWatcherEngine::addPaths: inotify_add_watch failed: No
such file or directory
Change-Id: I6b75c9195fb2b2ba7b3e0bb7d146fc5cd343927e
Task-number: QTBUG-40307
Reviewed-by: Shawn Rutledge <shawn.rutledge@digia.com>
Laszlo Agocs [Wed, 20 Aug 2014 14:52:38 +0000 (16:52 +0200)]
Avoid creating fbo with zero size in QQuickWidget
Get rid of incomplete attachment warnings on Android.
Change-Id: I7da546861b1814677b0c8ae110416f69bbbb7edc
Reviewed-by: Paul Olav Tvete <paul.tvete@digia.com>
Alan Alpert [Wed, 20 Aug 2014 18:02:54 +0000 (11:02 -0700)]
Add 5.3.2 changelog for qtdeclarative
Change-Id: I33e8149ec9e2f7ecfebb7f55de0dbb291805be93
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
Simon Hausmann [Tue, 24 Jun 2014 08:35:42 +0000 (10:35 +0200)]
Fix crash with recursively loading cached compilation units
When a cached compilation unit depends on an import that is implemented as a
Qml C++ plugin and that plugin in turn loads an asynchronous component that is
cached, we would get a crash in the typeloader and a failing assertion
(ASSERT: "d->m_mainThreadWaiting == false" in file qml/ftw/qqmlthread.cpp, line 300)
This is because we did not implement the asynchronous loading within the loader
thread for cached compilation units. This is simply done using a posted event,
using the same mechanism used for other async load methods.
Change-Id: Iefce67ab634ce26122c348dcdfc8e66b00fec671
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
Simon Hausmann [Fri, 8 Aug 2014 14:33:58 +0000 (16:33 +0200)]
Cleanup: Remove ShaderEffectSourceNode
We can simply use a standard image node and do the dirty marking also
directly in the texture (both live in the same thread).
Change-Id: I7345c702613782adec3c6a36a7705a2a54ed82ec
Reviewed-by: Gunnar Sletta <gunnar.sletta@jollamobile.com>
Sebastian Sauer [Tue, 12 Aug 2014 11:52:50 +0000 (18:52 +0700)]
v4: Enable primitive conversation to QQmlScriptString in javascript
This makes following QML-code proper working:
ParentChange {
x: 0
Component.onCompleted: x = 10
}
where x is a QQmlScriptString.
Before this patch an error-message would be thrown that the
bool/int/string/etc cannot be converted to a QQmlScriptString.
With the patch primitive types including null and undefined are
proper converted to a QQmlScriptString. The patch ignores (as
in not implements) function/binding assignment.
Unfortunately since commit
aa25ad8d5f4 its not possible any
longer to instanciate QQmlScriptString what means there is
otherwise no (easy) way to inject a QQmlScriptString from
within Javascript.
Change-Id: I18aac6a6e9a57f3b7d0a2d66cdab2be6c3c153c5
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
Gunnar Sletta [Mon, 18 Aug 2014 07:31:08 +0000 (09:31 +0200)]
Fix memory corruption in shader materials.
Change
ee616b3905106a3eedef9ee964ab283ef45c7dbc accidentally
removed the member variable used to refcount the attribute
names. This resulted in the names being deleted and the
stored const char *'s to become invalid. Add it back.
Change-Id: Ie33f75cd76085283a5ee685602e023bb3c42c896
Reviewed-by: Robin Burchell <robin.burchell@viroteck.net>
Mitch Curtis [Mon, 18 Aug 2014 16:30:35 +0000 (18:30 +0200)]
Fix typo in StateChangeScript documentation.
Change-Id: Iec72331c183ea02680bad01f04eae82ebd815cdb
Reviewed-by: Gunnar Sletta <gunnar.sletta@jollamobile.com>
Erik Verbruggen [Wed, 23 Jul 2014 10:22:11 +0000 (12:22 +0200)]
V4 IR: Add loop peeling.
By peeling the first iteration off of a loop and putting it in front of
the loop, type inference can deduce more type information for esp. loop
induction variables. To prevent increasing the code size too much, only
the inner-most loops are peeled.
This gives a 10% speed-up on crypto.js.
Change-Id: I57f9611695bc8defc0bff84e440b8a20b2c8a34e
Reviewed-by: Fawzi Mohamed <fawzi.mohamed@digia.com>
Erik Verbruggen [Wed, 23 Jul 2014 10:17:28 +0000 (12:17 +0200)]
V4 IR: add immediate dominator re-calculation.
When removing edges, the control-flow graph changes, so some immediate
dominators might need to be updated. This change collects all candidates
and processes them in a single batch.
Change-Id: I928f42232427a84bcb9658e314dadd0bd021b12f
Reviewed-by: Fawzi Mohamed <fawzi.mohamed@digia.com>
Topi Reinio [Fri, 15 Aug 2014 11:10:55 +0000 (13:10 +0200)]
Doc: Removing url variable from qdocconf file.
-url inherited from the url variable set in qtbase/doc/global
Change-Id: I94a0da7aa98af1fdd6140168fe9feb27b11c0bdb
Reviewed-by: Leena Miettinen <riitta-leena.miettinen@digia.com>
Reviewed-by: Jerome Pasion <jerome.pasion@digia.com>
Alex Montgomery [Fri, 15 Aug 2014 16:41:56 +0000 (09:41 -0700)]
Fix setContextObject to re-evaluate bindings
Fix QQmlContext::setContextObject to reevaluate bindings as the
documentation says that it should.
Task-number: QTBUG-40798
Change-Id: Ifbd97c7a07a5432f4948937da863370b05705206
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
Laszlo Agocs [Thu, 14 Aug 2014 11:34:30 +0000 (13:34 +0200)]
Fix cursorShape with QQuickWidget
Task-number: QTBUG-40729
Change-Id: If3b2f8ca8795da1ac7c626db9c872f735d1e7b5d
Reviewed-by: Paul Olav Tvete <paul.tvete@digia.com>
Venu [Wed, 13 Aug 2014 14:26:32 +0000 (16:26 +0200)]
Added the QtSQL dependency info. to the project file
Without this information the app fails to find the plugin
required to load the QtQuick.LocalStorage module on Android.
Task-number: QTBUG-37203
Change-Id: I245012e78ab8d1fe3205e08939f4baec58c20759
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@digia.com>
Simon Hausmann [Wed, 6 Aug 2014 12:59:34 +0000 (14:59 +0200)]
Cleanup
Merge QV4::CompiledData::QmlUnit into QV4::CompiledData::Unit. For pure JS
units it means a slight increase of memory usage by a few bytes, but overall it
makes the code a lot simpler.
Change-Id: Ib48927749720b056f004aac0fe22cb8ec729e3f6
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
Robin Burchell [Mon, 11 Aug 2014 09:23:42 +0000 (11:23 +0200)]
tst_dialogs: verify that rootObject is valid
if there's an error during loading, it's much easier to spot if this fails
rather than crashes.
Change-Id: If0106729e18768819da8a877959a095398af8547
Reviewed-by: Shawn Rutledge <shawn.rutledge@digia.com>
Robin Burchell [Mon, 11 Aug 2014 09:23:47 +0000 (11:23 +0200)]
tst_dialogs: QTRY_ on the expression (spyVisibilityChanged.count) not the variable.
We only assign to the variable once, so the value may not change in time.
Change-Id: I54ac7faad60d3984bfde4606aaf7e30a2340ba3e
Reviewed-by: Shawn Rutledge <shawn.rutledge@digia.com>
Gunnar Sletta [Thu, 14 Aug 2014 11:53:11 +0000 (13:53 +0200)]
The cached objects can be deleted, so keep them in a QPointer.
Change-Id: Ieaebd2e7b9823cbe22efc331e42ceab8fbbda0e8
Task-number: QTBUG-40201
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
Laszlo Agocs [Thu, 14 Aug 2014 10:58:55 +0000 (12:58 +0200)]
Fix flicker when showing QQuickWidget
This also reintroduces the change from commit
14b4747b17d522fe57f3a5f21738c5a89323b5e2.
Due to some bizarre merge issue that change has disappeared from qquickwidget.cpp
and its history. It is there in the main log, though.
The new fix depends on this older one, so the combined one fixes the following
three issues:
1. Polish and sync cannot be skipped when we are rendering for the first time.
2. Recreating the fbo twice when the widget is shown. Calling
createFramebufferObject() is not necessary in this case since createContext()
will trigger this anyhow due to scenegraphInitialized().
3. Avoid recreating the fbo when the size is the same as before. Some platforms
are keen on sending resize events with the same size. These should be ignored.
What's worse, some platforms (cocoa) generate a resize on exitting (Cmd-Q)
and not ignoring the resize at that stage is dangerous since the scenegraph
is already invalidated.
Task-number: QTBUG-40710
Task-number: QTBUG-40505
Change-Id: I2e897acc68fa68233563a1db63ffb6c5d0baad73
Reviewed-by: Gunnar Sletta <gunnar.sletta@jollamobile.com>
Erik Verbruggen [Thu, 14 Aug 2014 08:56:54 +0000 (10:56 +0200)]
V4 JIT: fix int32 to double conversion code
Missing else: two (nearly identical) conversions would get generated.
Change-Id: I745120f81d42bf28fbce7ab6a62da909a8e14458
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
Erik Verbruggen [Fri, 8 Aug 2014 13:36:37 +0000 (15:36 +0200)]
V4 JIT: add d8-d15 as available FP registers on ARM.
VFP3-d16 is the minimum implementation available on ARMv7, so these
registers are also always available. The big added bonus is that they
are callee saved, so using them will result in less loads/stores for
doubles.
Change-Id: I0cab3fe24d8677315b4c7d9449d8619cbf9a2919
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
Erik Verbruggen [Tue, 12 Aug 2014 14:28:49 +0000 (16:28 +0200)]
V4 JIT: support saving used callee saved FP registers.
This is not used yet by any platform/abi we support, because we do not
define any callee-saved FP registers. Yet.
Change-Id: I5857a452456175398c5e9681ff33800b9431b9da
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
Erik Verbruggen [Tue, 12 Aug 2014 12:30:42 +0000 (14:30 +0200)]
V4 JIT: calculate used registers and only save those.
Instead of saving all possibly used ones. Note that floating point
registers are not saved yet, as we don't support callee-saved FP
registers yet.
Change-Id: I1db2ba2513f7b466c64ec103eda0c464269247b0
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
Erik Verbruggen [Tue, 12 Aug 2014 07:40:11 +0000 (09:40 +0200)]
V4 JIT: parameterize the prologue and epilogue generation
... with the regular (non-FP) registers that need to be saved. This
patch shouldn't change any of the JIT generated code, because all
regular callee saved registers are passed in.
Change-Id: Id11b8f37f06d80e8015ac6f0d0ccefdfa3342cbe
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
Laszlo Agocs [Thu, 14 Aug 2014 12:08:34 +0000 (14:08 +0200)]
Propagate the accepted flag back in QQuickWidget mouse handlers
Task-number: QTBUG-40784
Change-Id: Ieff4b38358f241aebeb16ec877e05179b01cc004
Reviewed-by: Gunnar Sletta <gunnar.sletta@jollamobile.com>
Laszlo Agocs [Tue, 12 Aug 2014 09:58:58 +0000 (11:58 +0200)]
QQuickWidget: resolve samples also when rendering is triggered from resize
The normal update path did the resolving properly. However when we re-render
due to a resize, it was not done at all.
Change-Id: I3d55be111a4338e8f3dbb1081972f47daca53b35
Reviewed-by: Gunnar Sletta <gunnar.sletta@jollamobile.com>
Frederik Gladhorn [Thu, 14 Aug 2014 09:37:06 +0000 (11:37 +0200)]
Merge "Merge remote-tracking branch 'origin/5.3' into 5.4" into refs/staging/5.4
Frederik Gladhorn [Thu, 14 Aug 2014 09:35:11 +0000 (11:35 +0200)]
Merge remote-tracking branch 'origin/5.3' into 5.4
Change-Id: I2e06c2fcd8aa9d5d090f0568be75272ec82f7b20
Gunnar Sletta [Thu, 14 Aug 2014 06:38:12 +0000 (06:38 +0000)]
Fix potential deadlook in threaded renderloop.
Change-Id: I415e632aa4e584c8fca745581f25a676db0eae42
Reviewed-by: Giulio Camuffo <giulio.camuffo@jollamobile.com>
Reviewed-by: Robin Burchell <robin.burchell@viroteck.net>
Laszlo Agocs [Tue, 12 Aug 2014 08:10:30 +0000 (10:10 +0200)]
Reinitialize in QQuickWidget properly after hide and show
hide() followed by a show() results in totally broken QQuickWidgets due
to not initializing scenegraph again.
Task-number: QTBUG-40710
Change-Id: Id3cded2917d20c165b5885f3f2195d5c4566de89
Reviewed-by: Gunnar Sletta <gunnar.sletta@jollamobile.com>
Venu [Wed, 13 Aug 2014 12:35:20 +0000 (14:35 +0200)]
Added a signal handler
Without the onHeightChanged signal handler the transition
of the NumberPad from left to right is incomplete especially
on a mobile device where the window is scaled to fit the view.
So the NumberPad ends up hidden behind the Display.
Task-number: QTBUG-36086
Change-Id: Iab021c9f2572a4ac83bc393dddc24ddd31849cb4
Reviewed-by: Niels Weber <niels.weber@digia.com>
Reviewed-by: Topi Reiniö <topi.reinio@digia.com>
Mitch Curtis [Tue, 12 Aug 2014 13:10:36 +0000 (15:10 +0200)]
Fix typo in Context2D documentation.
Change-Id: Ib6e2436ba383a2caf78ac359883338016c2b7668
Reviewed-by: Topi Reiniö <topi.reinio@digia.com>
Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@digia.com>
Erik Verbruggen [Mon, 4 Aug 2014 11:24:57 +0000 (13:24 +0200)]
Silence unused parameter warning in release builds.
Change-Id: I02e5dd0bf511056c876c4e418334cad96657703e
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
Erik Verbruggen [Tue, 5 Aug 2014 08:51:57 +0000 (10:51 +0200)]
V4 JIT: fix stack use below stack pointer
When storing a double value returned from a function call on platforms
where the value wouldn't fit in a register, we used to store it on the
stack and then load it into a FP register. This stack use was done
without first lowering the stack pointer.
For x86 and ARM, the value is loaded directly into the FP register, and
for other non-64-bit platforms it correctly allocates the stack slot.
Change-Id: Idbc260038958a036ac2a7383d845199626decc8e
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
Mitch Curtis [Mon, 11 Aug 2014 14:41:02 +0000 (16:41 +0200)]
Ignore extra arguments passed to Context2D functions.
This is in line with what Chrome, Firefox and IE do.
This is also how most JavaScript functions in Qt behave by default
(for example, TableView::resizeColumnsToContents()).
Task-number: QTBUG-40703
Change-Id: I087221e305dcb5fd6709ad4a99a5163d641faac6
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
Gunnar Sletta [Tue, 12 Aug 2014 13:06:04 +0000 (15:06 +0200)]
Disable threaded FBO canvas drawing when not supported.
Change-Id: I1e8300c61ba31a5400fc43f85a9c39d2245b4518
Reviewed-by: J-P Nurmi <jpnurmi@digia.com>
Reviewed-by: Laszlo Agocs <laszlo.agocs@digia.com>
Reviewed-by: Alan Alpert <aalpert@blackberry.com>
Lars Knoll [Fri, 8 Aug 2014 18:29:19 +0000 (20:29 +0200)]
Create rectangle nodes in the text editing through the context
Unfortunately we can't re-use the QSGSimpleRectNode, as it doesn't provide us
with virtual methods to move it's creation into the context. But's since it's
only 20 lines of code anyway, this is still a nice cleanup. And it also allows
the re-use of any optimizations in the renderer for QSGRectangleNode.
Change-Id: I957777fbbeb0a994a9c257baf3bfe87fce8cc9e8
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
Laszlo Agocs [Thu, 24 Jul 2014 08:23:12 +0000 (10:23 +0200)]
Add QQuickWidget::setClearColor()
And make qquickviewcomparison able to demonstrate how to create a
partially transparent QQuickWidget.
Avoid also recreating the QQuickView/QQuickWidget multiple times
when switching between the radio buttons.
[ChangeLog] Added QQuickWidget::setClearColor() in order to support
semi-transparent QQuickWidgets.
Change-Id: I319ad4afbe909530274d09f2a7fcff23730d6ebd
Reviewed-by: Jørgen Lind <jorgen.lind@digia.com>
Erik Verbruggen [Tue, 5 Aug 2014 12:11:16 +0000 (14:11 +0200)]
V4 IR: change IR printing to be more readable.
New structure:
- "comments" now start with a semi-colon, and have a list of key: values.
; predecessors: L17 L26 L36, loop_header: yes
; line: 30, column: 3
- when a temporary has a known type, it is written in front of the
teporary when it is being assigned, and not repeated.
var %109 = this
double %42 = 42
- an expression starts with the operation, followed by the operands that
are separated by commas. The type of the operands is the type
mentioned when they are assigned.
int32 %115 = sub %184, %185
if gt %27, 0 goto L40 else goto L41
- conversions do mention the operand type in order to make them easier
to read.
double %178 = convert var to double %60
- phi node operands are prefixed by the from-label to make it easy to
match those operands with the from-block.
double %62 = phi L35: %58, L34: %61
- all names except for "this" and built-ins are prefixed by a dot in
order to make it clear that a lookup will occur, just like member
accesses.
$6 = call .int2char($0)
%7 = this
%8 = %7.toString()
Change-Id: I9f626a91f97ca7c3f27e01a5539f3c4fc10a46b4
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
Erik Verbruggen [Fri, 8 Aug 2014 14:05:54 +0000 (16:05 +0200)]
V4 RegAlloc: fix callee saved register range handling
This makes sure that the index of the fixed(FP)RegisterRanges matches
the indexes for normal-/fpRegisters, because this index is used to check
if a chosen register intersects with a fixed (= caller saved) register
at call sites.
Change-Id: Ie31554dbe8ed99cb38ca6b2506da663be41d82f6
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
Leena Miettinen [Wed, 13 Aug 2014 09:04:41 +0000 (11:04 +0200)]
Doc: fixed a broken table
In "Importing QML Document Directories" by
adding a missing \row command.
Change-Id: Ie98ee34b2f66472b0ca692d2acdea870247448a0
Reviewed-by: Topi Reiniö <topi.reinio@digia.com>
Erik Verbruggen [Tue, 12 Aug 2014 14:56:39 +0000 (16:56 +0200)]
V4 JIT: fix JS stack frame size calculation.
StackLayout::calculateJSStackFrameSize now returns the size in number
of QV4::Value items, instead of bytes. The value is then multiplied in
the assembler by sizeof(Value) to get the number of bytes. Previously,
the return value was number of bytes, which also got multiplied.
A direct effect is that the JS stack size will be ~87% smaller, with
the nice effect that the GC will run faster (less roots on the stack).
It also won't retain objects whose reference accidentally ended up on
the stack below the used portion for the current function, so possibly
freeing (more) objects (earlier) than before.
Change-Id: Idd5a9c173e641c03e6b8a6fe743e403eda34dfe0
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
Laszlo Agocs [Wed, 13 Aug 2014 08:23:04 +0000 (10:23 +0200)]
Avoid qmake warnings about wrong includes
QtQuick: WARNING: qquickwindow.h includes qqml.h
when it should include QtQml/qqml.h
QtQuick: WARNING: qsgabstractrenderer.h includes qsgnode.h
when it should include QtQuick/qsgnode.h
Change-Id: I3b9dc20de54ef775c562b2c6b80184a7b3149586
Reviewed-by: Jocelyn Turcotte <jocelyn.turcotte@digia.com>
Shawn Rutledge [Tue, 12 Aug 2014 11:42:19 +0000 (13:42 +0200)]
ItemView: use categorized logging for delegate lifecycle
It becomes configurable at runtime instead of having to uncomment
and recompile.
Change-Id: I2c6f24c89f7e6fe1a9a77b948cdac6f2994680bf
Reviewed-by: Frederik Gladhorn <frederik.gladhorn@digia.com>
Reviewed-by: Robin Burchell <robin.burchell@viroteck.net>
Erik Verbruggen [Mon, 11 Aug 2014 11:20:07 +0000 (13:20 +0200)]
V4 RegAlloc: fix use position calculation for phi node arguments.
The correct calculation was already done, but the value was discarded.
Change-Id: I600aeb9414736a3b7924a4a607233ab9bf6c02b6
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
Erik Verbruggen [Thu, 7 Aug 2014 12:33:55 +0000 (14:33 +0200)]
V4 JIT: tweak generated int32 to double conversion code
If the target is a FP register, and the source is a memory address, do
not load the int32 ourselves, but leave it to the assembler to decide
what to do. On x86(_64) this is generates a single instruction, while on
ARM the assembler will insert a load on its own.
For the case where the target is not a FP register, use the return value
register as base register for the target address. The advantage is that
the address calculation is now independent of the preceding conversion,
so it can fit in a different pipeline without dependencies.
Change-Id: Ib7cefa636274ba8596e4d11ae0170a091a0def3e
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
J-P Nurmi [Sun, 10 Aug 2014 10:22:56 +0000 (12:22 +0200)]
Remove QQuickWindow::glslVersion & glslIsCoreProfile
Superceded by the OpenGLInfo attached type
=> remove the API before it gets released
Change-Id: I7511fd28eb375eb3cd3cdd4bda6d82c1883e3094
Reviewed-by: Shawn Rutledge <shawn.rutledge@digia.com>
Reviewed-by: Alan Alpert <aalpert@blackberry.com>
Simon Hausmann [Sat, 9 Aug 2014 07:28:10 +0000 (09:28 +0200)]
Fix the nine patch node factory function (part 2)
Change-Id: I9edb6b0052d3b02cc412f56ae73e02652af0c93c
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
Simon Hausmann [Tue, 12 Aug 2014 10:34:35 +0000 (12:34 +0200)]
Merge "Merge remote-tracking branch 'origin/5.3' into 5.4" into refs/staging/5.4
Mitch Curtis [Tue, 12 Aug 2014 09:36:26 +0000 (11:36 +0200)]
Correct strokeRect documentation.
Change-Id: I81c61f3b32819e45e15b2be472e71e48fac0c148
Reviewed-by: Topi Reiniö <topi.reinio@digia.com>
Erik Verbruggen [Tue, 22 Jul 2014 09:56:33 +0000 (11:56 +0200)]
V4 JIT: generate code for int32 comparisons.
Change-Id: I5e88fb3df7b01f4f515ce4d2e451a5a6f5ba92ad
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
Gunnar Sletta [Mon, 11 Aug 2014 12:30:35 +0000 (14:30 +0200)]
Silence harmless compiler warning.
AlignJustify is not a tested value, but the compiler warning
can throw you off, so best to keep it quiet.
Change-Id: I0b3d717dfe2c11fc4367e7eceb5b83009c4e0a30
Reviewed-by: Robin Burchell <robin.burchell@viroteck.net>
Topi Reinio [Tue, 12 Aug 2014 08:52:42 +0000 (10:52 +0200)]
Doc: Add a keyword for XMLHttpRequest
To make the search term 'XMLHttpRequest' return relevant results in
the Assistant, add a keyword for it.
Task-number: QTBUG-40240
Change-Id: I44b0d397cd014d2468e6302d4293c959ec8c8802
Reviewed-by: J-P Nurmi <jpnurmi@digia.com>
Reviewed-by: Leena Miettinen <riitta-leena.miettinen@digia.com>
Robin Burchell [Mon, 11 Aug 2014 10:41:00 +0000 (12:41 +0200)]
benchmarks: Skip compilation of (and mark with FIXME) a few benchmarks that don't build.
Change-Id: I4d2e9bf3a520636c568a6b58e311994693446c97
Reviewed-by: Gunnar Sletta <gunnar.sletta@jollamobile.com>
Robin Burchell [Mon, 11 Aug 2014 10:35:47 +0000 (12:35 +0200)]
benchmarks/particles: fix projects to actually build
Change-Id: I3edb05279119b921b50a0329dfd47f0ff2cdb9bc
Reviewed-by: Gunnar Sletta <gunnar.sletta@jollamobile.com>
Robin Burchell [Mon, 11 Aug 2014 10:13:46 +0000 (12:13 +0200)]
Fix compilation of tst_compilation (:-P) benchmark.
Change-Id: I7bbf24d816a356f100d7e2c5a8e7a81218f0f54d
Reviewed-by: Gunnar Sletta <gunnar.sletta@jollamobile.com>