From 19f9cf8d2e3d9116aa19b1f988fc5490247add4c Mon Sep 17 00:00:00 2001 From: Venugopal Shivashankar Date: Thu, 8 Dec 2016 13:45:54 +0100 Subject: Calqlatr Example: Pass the third arg to the mapToItem() calls MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Apparently the mapToItem version used in the example requires at least three arguments, for some reason only two were provided, the item and the mouseX coordinate. Without the third argument, mouseY coordinate, the drag operation to move the display fails with warnings on the console. Task-number: QTBUG-57514 Change-Id: If1b16c27539bd90a2d20203dedc26f11ac2a0942 Reviewed-by: Shawn Rutledge Reviewed-by: Topi Reiniƶ Reviewed-by: Mitch Curtis --- examples/quick/demos/calqlatr/calqlatr.qml | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'examples/quick') 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() -- cgit v1.2.3 From ee3e437762eec57edecb1c3f8634076a94ce9d9a Mon Sep 17 00:00:00 2001 From: Nico Vertriest Date: Tue, 20 Dec 2016 13:28:34 +0100 Subject: Example: corrected screenshot of the localstorage app MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Was still displaying a screenshot of the previous example \image --> \borderedimage Change-Id: Ifb23d0ffe1216c7d79170b6bbbd7da1511afe79c Reviewed-by: Topi Reiniƶ --- examples/quick/localstorage/doc/src/localstorage.qdoc | 2 +- .../localstorage/qml-localstorage-example.png | Bin 46168 -> 0 bytes 2 files changed, 1 insertion(+), 1 deletion(-) delete mode 100644 examples/quick/localstorage/localstorage/qml-localstorage-example.png (limited to 'examples/quick') diff --git a/examples/quick/localstorage/doc/src/localstorage.qdoc b/examples/quick/localstorage/doc/src/localstorage.qdoc index 1bfba147e1..8ffcbe9d14 100644 --- a/examples/quick/localstorage/doc/src/localstorage.qdoc +++ b/examples/quick/localstorage/doc/src/localstorage.qdoc @@ -28,7 +28,7 @@ \title Qt Quick Examples - Local Storage \example localstorage \brief A collection of QML local storage examples. - \image qml-localstorage-example.png + \borderedimage qml-localstorage-example.png \e{Local Storage} is a collection of small QML examples relating to Qt Quick's \l{local storage} functionality. diff --git a/examples/quick/localstorage/localstorage/qml-localstorage-example.png b/examples/quick/localstorage/localstorage/qml-localstorage-example.png deleted file mode 100644 index 7d7edafe63..0000000000 Binary files a/examples/quick/localstorage/localstorage/qml-localstorage-example.png and /dev/null differ -- cgit v1.2.3