+change_cloud(Actor *actor, AWallpaperPlugin *desktop_plugin)
+{
+ gint x0, y0 = 300, scale0 = 100,
+ x1, y1 = -actor->height, scale1 = 150,
+ x, y, scale;
+ struct timeval tvb;
+ suseconds_t ms;
+ long sec;
+ double t;
+
+ gettimeofday(&tvb, NULL);
+
+ ms = tvb.tv_usec;
+ sec = tvb.tv_sec;
+// fprintf(stderr, "1 %f - %d\n", sec+(double)ms/100000, now);
+
+ if (!actor->visible){
+ actor->visible = TRUE;
+ if (scene.daytime == TIME_NIGHT)
+ actor->filename = actor->filename;
+ else
+ actor->filename = actor->filename;
+ create_hildon_actor(actor, desktop_plugin);
+ }
+ t = (double)((double)sec+(double)ms/1000000 - actor->time_start_animation) / actor->duration_animation;
+
+ if (scene.wind_orientation == 1){
+ x0 = -actor->width;
+ x1 = 800;
+ }
+ else {
+ x0 = 800;
+ x1 = -actor->width;
+ }
+
+ x = path_line(x0, x1, t);
+ y = -scene.wind_angle * (x - x0) + actor->y;
+ scale = path_line(scale0, scale1, (double)(y - y0)/(y1 - y0));
+
+ //fprintf(stderr, "change cloud t=%f x=%d y=%d scale=%d\n", t, x, y, scale);
+ actor_set_position_full(actor->widget, x, y, actor->z);
+ hildon_animation_actor_set_scale(HILDON_ANIMATION_ACTOR(actor->widget), (double)scale/100, (double)scale/100);
+ if ((y < y1 || y > y0) || t >= 1){
+ /* stop animation */
+ actor->visible = FALSE;
+ destroy_hildon_actor(actor);
+ actor->time_start_animation = sec + 5*60;
+ }
+
+}
+
+void