Marquee can now be paused and restarted.
1.1 --- a/MarqueeText.qml Tue Jun 03 16:11:47 2014 +0200
1.2 +++ b/MarqueeText.qml Tue Jun 03 18:12:10 2014 +0200
1.3 @@ -38,8 +38,8 @@
1.4 NumberAnimation {
1.5 target: scrollingText;
1.6 properties: "x"
1.7 - //from: 0;
1.8 - to: -scrollingText.width-separatorText.width;
1.9 + from: scrollingText.x;
1.10 + to: scrollingText.x-scrollingText.width-separatorText.width;
1.11 duration: (scrollingText.width+separatorText.width)*1000/pixelsPerSeconds
1.12 }
1.13
1.14 @@ -61,13 +61,12 @@
1.15
1.16 }
1.17
1.18 - //Click to start
1.19 + //Click to start/stop
1.20 MouseArea {
1.21 id:mouseArea
1.22 anchors.fill: parent
1.23 onClicked: {
1.24 - animation.running=true;
1.25 + animation.running=!animation.running;
1.26 }
1.27 -
1.28 }
1.29 }
2.1 --- a/MiniDisplay/minidisplay.cpp Tue Jun 03 16:11:47 2014 +0200
2.2 +++ b/MiniDisplay/minidisplay.cpp Tue Jun 03 18:12:10 2014 +0200
2.3 @@ -158,6 +158,8 @@
2.4 */
2.5 void MiniDisplay::renderWindow(QQuickWindow* aWindow)
2.6 {
2.7 + //if (!iDisplay.IsOpen()) return;
2.8 +
2.9 QImage image=aWindow->grabWindow();
2.10 //image.save("window.png");
2.11 renderImage(&image);
2.12 @@ -227,6 +229,7 @@
2.13 renderWindow(iWindow);
2.14 swapBuffers();
2.15
2.16 +
2.17 //Interrestingly rendering will suspend when we stop changing our text field content
2.18 if (frame%8==0)
2.19 {