aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLiang Qi <liang.qi@qt.io>2016-12-25 14:43:36 +0100
committerLiang Qi <liang.qi@qt.io>2016-12-25 14:43:36 +0100
commitd8a052bc6b0349045db3d43a373b09cb16b41a48 (patch)
treeb39e3bc4dfd071154cdbae4bca53ef31b496f90b
parent0f911e46c5ccff88ade99366d7e15e1436360391 (diff)
parent884d06db09bc6179baa3add42ff4ef5f3cd0e523 (diff)
Merge remote-tracking branch 'origin/5.8.0' into 5.8
-rw-r--r--dist/changes-5.8.0172
-rw-r--r--examples/quick/demos/calqlatr/calqlatr.qml5
-rw-r--r--src/qml/compiler/qv4isel_moth.cpp5
-rw-r--r--src/quick/items/qquickevents.cpp2
-rw-r--r--src/quick/items/qquickevents_p_p.h18
5 files changed, 190 insertions, 12 deletions
diff --git a/dist/changes-5.8.0 b/dist/changes-5.8.0
new file mode 100644
index 0000000000..2fa4173c2e
--- /dev/null
+++ b/dist/changes-5.8.0
@@ -0,0 +1,172 @@
+Qt 5.8 introduces many new features and improvements as well as bugfixes
+over the 5.7.x series. For more details, refer to the online documentation
+included in this distribution. The documentation is also available online:
+
+ http://doc.qt.io/qt-5/index.html
+
+The Qt version 5.8 series is binary compatible with the 5.7.x series.
+Applications compiled for 5.7 will continue to run with 5.8.
+
+Some of the changes listed in this file include issue tracking numbers
+corresponding to tasks in the Qt Bug Tracker:
+
+ https://bugreports.qt.io/
+
+Each of these identifiers can be entered in the bug tracker to obtain more
+information about a particular change.
+
+****************************************************************************
+* General *
+****************************************************************************
+ - [QTBUG-54982] Add qmlRegisterUncreatableMetaObject convenience function
+ needed to register Q_NAMESPACE QMetaObjects.
+
+****************************************************************************
+* Important Behavior Changes *
+****************************************************************************
+
+ - [QTBUG-52012] When the engine looks for QML modules / extension
+ plugins in statically linked applications, the plugins are not
+ instantiated in the qml loader thread anymore. For this to work
+ however it is necessary for plugins to use
+ Q_PLUGIN_METADATA(IID_QQmlExtensionInterface_iid) in their class
+ declaration instead of hardcoding the interface id as a string literal.
+
+ - A JS null value converted to a QVariant now has type
+ QMetaType::Nullptr rather than QMetaType::VoidStar.
+
+ - To improve the start-up time and reduce memory consumption, the QML engine
+ attempts to cache the code and data structures generated during loading of
+ .qml and .js files. Cache files are - if possible - written to disk in the
+ directory next to the source file with the .qmlc/.jsc extension. If that
+ is not possible, they are written to QStandardPaths::CacheLocation.
+
+
+****************************************************************************
+* Library *
+****************************************************************************
+
+QtQml
+-----
+
+ - [QTBUG-53412] Fix mapping of null JS values to null SQL values instead
+ of empty strings.
+ - [QTBUG-53794] Fix crash when using the "with" statement with an
+ expression that throws an exception.
+ - [QTBUG-54589] Fix assertion when deleting properties of JS objects
+ - [QTBUG-54360] Added exit(int retCode) method to the Qt global object. An
+ application can call Qt.exit to specify a return code of the engine.
+ - QQmlXMLHttpRequest:
+ * [QTBUG-38175] QQmlXMLHttpRequest now supports the PATCH method in HTTP
+ requests.
+ - Fix reading of enum properties from gadgets / value types when the
+ enum was registered with qRegisterMetaType().
+ - Fixed support for using namespaces in property types, signal parameter names
+ and list types
+ - Fixed support for declaring default properties of type list<T>
+
+
+QtQuick
+-------
+
+ - QQuickWindow:
+ * The relevant child item is now sent a hover event when the window
+ receives a QEnterEvent, making sure hovering is recognized without
+ waiting for mouse movement.
+ - [QTBUG-50298] Added Qt.application.font property.
+ - QQuickWidget now properly repaints text on high-DPI screen changes.
+ - [QTBUG-54238] qt.scenegraph.info logging category got renamed to
+ qt.scenegraph.general.
+ - ShaderEffect with OpenGL now supports reading GLSL shader sources from
+ local files and from the resource system. Whenever a fragmentShader or
+ vertexShader property is a valid such URL, the value is treated as a
+ file specification instead of actual source code.
+ - The threaded scene graph renderer does not sleep up to one vsync
+ interval before the first frame anymore.
+ - [QTBUG-48723] Added properties to access color values for the HSV and
+ HSL color models to the basic QML color type.
+ - MouseArea no longer thinks it's pressed when it does not accept the
+ press event. When a press event is not accepted, MouseArea also no
+ longer receives a cancel event.
+ - Touch events are now delivered in a well defined order: New touch points
+ are delivered first to items under the finger which was first touching
+ the screen. Then to items that are under the second finger and finally
+ to common ancestors. This means that items that are "on top" will get a
+ chance to grab touch points before any items in the background.
+ - [QTBUG-39888] Fix crash with QQuickItems created via JavaScript being
+ garbage collected sometimes when they're not assigned to a window.
+
+ - Drag:
+ * [QTBUG-37366] Added imageSource property to attached Drag object: this
+ allows drag sources to specify the pixmap to be drawn next to the
+ mouse cursor when starting a drag and drop operation.
+
+ - Important Behavior Changes:
+ * [QTBUG-54133] QQuickWidget now follows the same behavior as
+ QQuickWindow when it comes to the persistent scenegraph setting
+ controlled by QQuickWindow::setPersistentSceneGraph(). In earlier
+ releases the setting was ignored and the scenegraph was torn down on
+ every hide event. This is not the case anymore.
+ * [QTBUG-54133] QQuickWidget now behaves identically to QOpenGLWidget
+ when it comes to handling window changes when reparenting the widget
+ into a hierarchy belonging to another top-level widget. Previously the
+ OpenGL context always got destroyed and recreated in order to ensure
+ texture resource sharing with the new top-level widget. From now on
+ this is only true when when AA_ShareOpenGLContexts it not set.
+
+ - LayoutMirroring:
+ * [QTBUG-55517] Made it possible to attach LayoutMirroring to a Window.
+
+ - MouseArea:
+ * [QTBUG-40475][QTBUG-42194][QTBUG-33982][QTBUG-42578][QTBUG-52537]
+ Hover state is now updated once per frame. This means that
+ MouseArea::containsMouse property will now be correct even if the
+ mouse is not moving, but items move under the cursor. Likewise the
+ mouse position properties and positionChanged signal will act as if
+ the mouse had moved.
+
+ - QQuickItem:
+ * [QTBUG-31861] Fixed issue with mouse button events being sent even
+ when they were disabled by setAcceptedMouseButtons.
+
+ - QQuickWindow:
+ * QQuickWindow::sendEvent() is deprecated. Use
+ QCoreApplication::sendEvent() directly instead.
+
+ - ShaderEffect:
+ * Add new mesh type BorderImageMesh. BorderImageMesh provides an
+ optimized way to use BorderImage-type images with ShaderEffect.
+
+ - Text:
+ * [QTBUG-52389] Fixed clipping of glyphs that extend beyond font's em
+ square.
+ * [QTBUG-54723] Fixed a performance regression when rendering a rich
+ text item with scaled images.
+ * [QTBUG-43133] Fixed placement of flowing text objects in the start of
+ a right-to-left block.
+
+
+
+QML Elements
+------------
+
+ - Added a LoggingCategory type and added support for it to the console
+ object
+
+ - Binding:
+ * Add delayed property to Binding as a way to avoid potentially expensive
+ or unexpected intermediate values.
+
+ - Text, TextEdit, TextInput:
+ * Added "hintingPreference" property
+
+ - Platform Specific Changes:
+ * [Windows][QTBUG-45321] Worked around an issue with fonts that have corrupt
+ cmap tables.
+
+QtTest
+------
+
+ - TestCase:
+ * [QTBUG-19708] Added tryVerify() function to allow verification of
+ asynchronous conditions that can't be tested using tryCompare().
diff --git a/examples/quick/demos/calqlatr/calqlatr.qml b/examples/quick/demos/calqlatr/calqlatr.qml
index 81f95907a6..017d819b01 100644
--- a/examples/quick/demos/calqlatr/calqlatr.qml
+++ b/examples/quick/demos/calqlatr/calqlatr.qml
@@ -128,6 +128,7 @@ Rectangle {
height: parent.height
MouseArea {
+ id: mouseInput
property real startX: 0
property real oldP: 0
property bool rewind: false
@@ -140,7 +141,7 @@ Rectangle {
height: 50
onPositionChanged: {
var reverse = startX > window.width / 2
- var mx = mapToItem(window, mouse.x).x
+ var mx = mapToItem(window, mouseInput.mouseX, mouseInput.mouseY).x
var p = Math.abs((mx - startX) / (window.width - display.width))
if (p < oldP)
rewind = reverse ? false : true
@@ -149,7 +150,7 @@ Rectangle {
controller.progress = reverse ? 1 - p : p
oldP = p
}
- onPressed: startX = mapToItem(window, mouse.x).x
+ onPressed: startX = mapToItem(window, mouseInput.mouseX, mouseInput.mouseY).x
onReleased: {
if (rewind)
controller.completeToBeginning()
diff --git a/src/qml/compiler/qv4isel_moth.cpp b/src/qml/compiler/qv4isel_moth.cpp
index ca6319ef3c..f2bd57ad8f 100644
--- a/src/qml/compiler/qv4isel_moth.cpp
+++ b/src/qml/compiler/qv4isel_moth.cpp
@@ -242,6 +242,11 @@ void InstructionSelection::run(int functionIndex)
addInstruction(set);
}
exceptionHandler = _block->catchBlock;
+ } else if (_block->catchBlock == nullptr && _block->index() != 0 && _block->in.isEmpty()) {
+ exceptionHandler = nullptr;
+ Instruction::SetExceptionHandler set;
+ set.offset = 0;
+ addInstruction(set);
}
for (IR::Stmt *s : _block->statements()) {
diff --git a/src/quick/items/qquickevents.cpp b/src/quick/items/qquickevents.cpp
index 9b49fcdf2a..a5497f4627 100644
--- a/src/quick/items/qquickevents.cpp
+++ b/src/quick/items/qquickevents.cpp
@@ -552,7 +552,7 @@ void QQuickEventTouchPoint::reset(const QTouchEvent::TouchPoint &tp, ulong times
QQuickEventPoint::reset(tp.state(), tp.scenePos(), tp.id(), timestamp);
m_rotation = tp.rotation();
m_pressure = tp.pressure();
-// m_uniqueId = tp.uniqueId();
+ m_uniqueId = tp.uniqueId();
}
/*!
diff --git a/src/quick/items/qquickevents_p_p.h b/src/quick/items/qquickevents_p_p.h
index 6179791413..7b281623fe 100644
--- a/src/quick/items/qquickevents_p_p.h
+++ b/src/quick/items/qquickevents_p_p.h
@@ -302,8 +302,7 @@ class Q_QUICK_PRIVATE_EXPORT QQuickEventTouchPoint : public QQuickEventPoint
Q_OBJECT
Q_PROPERTY(qreal rotation READ rotation)
Q_PROPERTY(qreal pressure READ pressure)
-// TODO rename to QPointingDeviceUniqueId
-// Q_PROPERTY(QPointerUniqueId uniqueId READ uniqueId)
+ Q_PROPERTY(QPointingDeviceUniqueId uniqueId READ uniqueId)
public:
QQuickEventTouchPoint(QQuickPointerTouchEvent *parent);
@@ -312,12 +311,12 @@ public:
qreal rotation() const { return m_rotation; }
qreal pressure() const { return m_pressure; }
-// QPointerUniqueId uniqueId() const { return m_uniqueId; }
+ QPointingDeviceUniqueId uniqueId() const { return m_uniqueId; }
private:
qreal m_rotation;
qreal m_pressure;
-// QPointerUniqueId m_uniqueId;
+ QPointingDeviceUniqueId m_uniqueId;
Q_DISABLE_COPY(QQuickEventTouchPoint)
};
@@ -451,7 +450,7 @@ class Q_QUICK_PRIVATE_EXPORT QQuickPointerDevice : public QObject
Q_PROPERTY(int maximumTouchPoints READ maximumTouchPoints CONSTANT)
Q_PROPERTY(int buttonCount READ buttonCount CONSTANT)
Q_PROPERTY(QString name READ name CONSTANT)
- Q_PROPERTY(qint64 uniqueId READ uniqueId CONSTANT)
+ Q_PROPERTY(QPointingDeviceUniqueId uniqueId READ uniqueId CONSTANT)
public:
enum DeviceType {
@@ -498,7 +497,8 @@ public:
QQuickPointerDevice(DeviceType devType, PointerType pType, Capabilities caps, int maxPoints, int buttonCount, const QString &name, qint64 uniqueId = 0)
: m_deviceType(devType), m_pointerType(pType), m_capabilities(caps)
- , m_maximumTouchPoints(maxPoints), m_buttonCount(buttonCount), m_name(name), m_uniqueId(uniqueId), m_event(nullptr)
+ , m_maximumTouchPoints(maxPoints), m_buttonCount(buttonCount), m_name(name)
+ , m_uniqueId(QPointingDeviceUniqueId::fromNumericId(uniqueId)), m_event(nullptr)
{
if (m_deviceType == Mouse) {
m_event = new QQuickPointerMouseEvent;
@@ -517,7 +517,7 @@ public:
int maximumTouchPoints() const { return m_maximumTouchPoints; }
int buttonCount() const { return m_buttonCount; }
QString name() const { return m_name; }
- qint64 uniqueId() const { return m_uniqueId; }
+ QPointingDeviceUniqueId uniqueId() const { return m_uniqueId; }
QQuickPointerEvent *pointerEvent() const { return m_event; }
static QQuickPointerDevice *touchDevice(QTouchDevice *d);
@@ -532,7 +532,7 @@ private:
int m_maximumTouchPoints;
int m_buttonCount;
QString m_name;
- qint64 m_uniqueId;
+ QPointingDeviceUniqueId m_uniqueId;
// the device-specific event instance which is reused during event delivery
QQuickPointerEvent *m_event;
@@ -555,7 +555,7 @@ QML_DECLARE_TYPE(QQuickMouseEvent)
QML_DECLARE_TYPE(QQuickWheelEvent)
QML_DECLARE_TYPE(QQuickCloseEvent)
QML_DECLARE_TYPE(QQuickPointerDevice)
-//QML_DECLARE_TYPE(QPointerUniqueId)
+QML_DECLARE_TYPE(QPointingDeviceUniqueId)
QML_DECLARE_TYPE(QQuickPointerEvent)
#endif // QQUICKEVENTS_P_P_H