1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17
import QtQml 2.0 QtObject { function something(i) { if (i > 10) { something(i / 4); } else { console.log("done"); } } property int width: 400 property int height: 400 onWidthChanged: something(width); Component.onCompleted: width = 500; }