function updateSnow() {
if (userSpeed.currentText == '') { // hack
- //console.log('not initialized yet');
return;
}
}
- //Plasmoid.Plasmoid.preferredRepresentation: Plasmoid.fullRepresentation
- Layout.minimumWidth: units.gridUnit * 13;
+ Layout.minimumWidth: units.gridUnit * 14;
Layout.minimumHeight: units.gridUnit * 10;
GridLayout {
Button { width: 100; text: "Stop"; onClicked: destroySnow(); }
}
-//}
Timer {
if(snow[i].x > screenWidth) {
snow[i].x = 0;
} else if (snow[i].x < 0) {
- snow[i].x = 1440;
+ snow[i].x = screenWidth;
}
snow[i].y += snow[i].fallingSpeed;
property int swirl: getRandomIntInclusive(35,200); /* random falling 'swirl' */
property int disposition: 0;
property alias snowFlakeRotation: snowFlake.rotation;
- //property int rotationSpeed: (Math.random() * 100) % 3 + 1; /* falling rotation */
property int rotationSpeed: getRandomIntInclusive(1,4);
property int rotationDirection: getRandomIntInclusive(0,1);
- //property int fallingSpeed: (Math.random() * 100) % 3 + 2;
property int fallingSpeed: Utils.getFallingSpeed(plasmoid.configuration.userSpeed);
- //width: 80; height: 80;
opacity: 0.5;
color: "transparent";
anchors.fill: parent;
source: setImage();
- //source: "../images/romantic.png";
}
}