[Qt-qml] Timer without animation ?

Attila Csipa qt at csipa.in.rs
Mon Jan 10 11:05:26 CET 2011


Is it possible to have a Timer without having a visual item that brings in
the animation timer ? Think

QtObject {
    Component.onCompleted: console.log("hello world");
    Timer {
             interval: 500; running: true; repeat: true;
             onTriggered: console.log("tick");
    }
}

This gives somewhat cryptic Component is not ready error, but does work if I
replace QtObject with Item. Now, you will be asking well, why don't you just
use Item, and the answer is that it feels a bit weird - I'm experimenting
with GUIless QML (think custom structured QtObject creation, textual UIs,
etc).

Best regards,
Attila
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.qt.nokia.com/pipermail/qt-qml/attachments/20110110/105afcb7/attachment.html 


More information about the Qt-qml mailing list