# HG changeset patch # User sl # Date 1401811930 -7200 # Node ID c0f274a21d336d998248612cb28d3b64c4451f1f # Parent a42cc76a2d5ac3a058bd328a23d4aa5d4fb709f5 Marquee can now be paused and restarted. diff -r a42cc76a2d5a -r c0f274a21d33 MarqueeText.qml --- a/MarqueeText.qml Tue Jun 03 16:11:47 2014 +0200 +++ b/MarqueeText.qml Tue Jun 03 18:12:10 2014 +0200 @@ -38,8 +38,8 @@ NumberAnimation { target: scrollingText; properties: "x" - //from: 0; - to: -scrollingText.width-separatorText.width; + from: scrollingText.x; + to: scrollingText.x-scrollingText.width-separatorText.width; duration: (scrollingText.width+separatorText.width)*1000/pixelsPerSeconds } @@ -61,13 +61,12 @@ } - //Click to start + //Click to start/stop MouseArea { id:mouseArea anchors.fill: parent onClicked: { - animation.running=true; + animation.running=!animation.running; } - } } diff -r a42cc76a2d5a -r c0f274a21d33 MiniDisplay/minidisplay.cpp --- a/MiniDisplay/minidisplay.cpp Tue Jun 03 16:11:47 2014 +0200 +++ b/MiniDisplay/minidisplay.cpp Tue Jun 03 18:12:10 2014 +0200 @@ -158,6 +158,8 @@ */ void MiniDisplay::renderWindow(QQuickWindow* aWindow) { + //if (!iDisplay.IsOpen()) return; + QImage image=aWindow->grabWindow(); //image.save("window.png"); renderImage(&image); @@ -227,6 +229,7 @@ renderWindow(iWindow); swapBuffers(); + //Interrestingly rendering will suspend when we stop changing our text field content if (frame%8==0) {