Merge pull request #54 from sletta/master

[qtdeclarative] Ensure that ShaderEffectSource's texture has correct parameters.
[qtdeclarative] Don't crash due to KeyRelease on an unloaded Item.

commit cb9672c86d2679bcb0d9e10f76b12eb03f4c515e
Author: Shawn Rutledge <shawn.rutledge@digia.com>
Date:   Tue Aug 27 13:36:36 2013 +0200

Task-number: QTBUG-33127
QQuickTimeLine: add missing time checks

The same check is done in QQuickTimeLine::pause(), move() and moveBy(),
where the time is passed as an argument. QQuickTimeLine::accel() and
accelDistance() calculate the time based on velocity and acceleration
or distance. With tiny values this calculation can result to a negative
time due to integer overflow.

Task-number: QTBUG-35046
Change-Id: I000e73d3f787375946e8f87a5d24153ae919bc8d
Reviewed-by: Michael Brasser <michael.brasser@live.com>
Merge pull request #55 from martinjones/master

[qtdeclarative] Don't crash due to KeyRelease on an unloaded Item.
Merge pull request #57 from mbrasser-jolla/master

QQuickTimeLine: add missing time checks
[qtdeclarative] Fix memory corruption bug

In QQmlData::destroyed(), release the compiledData after
destroying the context instead of before. The context
contains bindings which may contain references to the
compiledData. (At least with V4 bindings)

This might cause heap corruption in QV4Bindings::Binding::disconnect()
because it uses values from 'program' (one of the datas[] values
from a QQmlCompiledData) to possibly modify memory via sub->setActive().

The reads from a freed program are easily reproduced (just start
an app under lipstick and then close it; detected with valgrind).
I haven't witnessed any heap corruption from this but it may be
behind the occasional crashes of lipstick.
Merge pull request #56 from amtep/master

[qtdeclarative] Fix memory corruption bug
[qtdeclarative] Ensure the vertical text alignment is updated when the Text height changes

Upstream change:
https://qt.gitorious.org/qt/qtdeclarative/commit/53bdf7daa1c598082dfde8bfbf40709f37f866e6
Merge pull request #58 from martinjones/text_valign

[qtdeclarative] Ensure the vertical text alignment is updated when the T...
[qtdeclarative] Make sure the visibility state is the same in GUI and Render threads.

show() would add a window to the GUI thread's list of windows.
handleExposure() which is called asynchronously from show() would add
it to the render thread's list. hide() would remove it from both GUI
and render in one go. That meant that for a short while after
win1.show(), win2.hide(), the GUI thread would have an entry in its
list (from show()) while the render thread had none (not yet delivered
through handleExposure()).

This had some side effects. If we entered polishAndSync() at this
time, the GUI thread would enter the sync lock and post an event, but
as the render thread doesn't track any windows, it would never pick it
up and the system would deadlock. Also, if an incubation controller
was awaiting the incubation signal (as told via
interleaveIncubation()) it would never get it.

Also, a separate thing, but related. To make sure nobody is waiting
for an incubation signal when the render thread stops, emit an
incubation signal after the render loop might have stopped, just to be
on the safe side.

Change-Id: I8d88bb149370f053be9c53cede59eb9920456983