X-Git-Url: http://git.maemo.org/git/?a=blobdiff_plain;f=applet%2Fsrc%2Flivewp-home-widget.c;h=393673b9513b949c14647b1504e23f2470724c84;hb=4b34c4587967636017839562db7f919132c7ddd3;hp=e8ede243c6fb2c6965ae0c10c9dba4b4c2d5b678;hpb=03e7b00dad1d90a9728c1dfd4607fb2aced963ee;p=livewp diff --git a/applet/src/livewp-home-widget.c b/applet/src/livewp-home-widget.c index e8ede24..393673b 100644 --- a/applet/src/livewp-home-widget.c +++ b/applet/src/livewp-home-widget.c @@ -755,6 +755,8 @@ change_layer(Actor * actor, AWallpaperPlugin *desktop_plugin) gint y; Actor *a; + if (!desktop_plugin->priv->rich_animation) return; + a = g_ptr_array_index(actor->child, 0); y = a->y + 10; if (y > 480) y = -480; @@ -858,6 +860,15 @@ init_scene2(AWallpaperPlugin *desktop_plugin) Actor *actor; GPtrArray *child; gint now = time(NULL); + gint y1, y2; + + if (desktop_plugin->priv->rich_animation){ + y1 = -480; + y2 = -480-480; + }else { + y1 = 0; + y2 = -480; + } fprintf(stderr, "init scene2 \n"); //scene.daytime = get_daytime(); @@ -878,7 +889,7 @@ init_scene2(AWallpaperPlugin *desktop_plugin) child = g_ptr_array_sized_new(4); actor = init_object(desktop_plugin, "layer1", "layer1_2.png", - 0, -480, 6, 800, 960, + 0, y1, 6, 800, 960, TRUE, TRUE, 100, 255, NULL, NULL, NULL); //actor->time_start_animation = now; @@ -887,7 +898,7 @@ init_scene2(AWallpaperPlugin *desktop_plugin) g_ptr_array_add(child, actor); actor = init_object(desktop_plugin, "layer1", "layer1_1.png", - 0, (-480 - 480), 7, 800, 960, + 0, y2, 7, 800, 960, TRUE, TRUE, 100, 255, NULL, NULL, NULL); //actor->time_start_animation = now; @@ -896,7 +907,7 @@ init_scene2(AWallpaperPlugin *desktop_plugin) g_ptr_array_add(child, actor); actor = init_object(desktop_plugin, "layer2", "layer2_2.png", - 0, -480, 8, 800, 960, + 0, y1, 8, 800, 960, TRUE, TRUE, 100, 255, NULL, NULL, NULL); //actor->time_start_animation = now; @@ -905,7 +916,7 @@ init_scene2(AWallpaperPlugin *desktop_plugin) g_ptr_array_add(child, actor); actor = init_object(desktop_plugin, "layer2", "layer2_1.png", - 0, (-480 - 480), 9, 800, 960, + 0, y2, 9, 800, 960, TRUE, TRUE, 100, 255, NULL, NULL, NULL); //actor->time_start_animation = now; @@ -914,7 +925,7 @@ init_scene2(AWallpaperPlugin *desktop_plugin) g_ptr_array_add(child, actor); actor = init_object(desktop_plugin, "layers", "", - 0, (-480 - 480), 9, 800, 960, + 0, y2, 9, 800, 960, FALSE, FALSE, 100, 255, (gpointer)&change_layer, NULL, child); actor->time_start_animation = now;