static void
lw_applet_realize (GtkWidget *widget)
{
- GdkScreen *screen;
+ GdkScreen *screen;
+ AWallpaperPlugin *desktop_plugin = widget;
- fprintf(stderr,"ddddddddddddd %s\n", hd_plugin_item_get_plugin_id (HD_PLUGIN_ITEM (widget)));
- screen = gtk_widget_get_screen (widget);
- gtk_widget_set_colormap (widget,
+ fprintf(stderr,"ddddddddddddd %s\n", hd_plugin_item_get_plugin_id (HD_PLUGIN_ITEM (widget)));
+ gchar * strid = g_strdup(hd_plugin_item_get_plugin_id (HD_PLUGIN_ITEM (widget)));
+ gint id = strid[strlen(strid)-1] - '0';
+ desktop_plugin->priv->view = id + 1;
+
+ init_scene_theme(desktop_plugin);
+
+ desktop_plugin->priv->long_timer = g_timeout_add(LONG_TIMER, (GtkFunction)long_timeout, desktop_plugin);
+
+ screen = gtk_widget_get_screen (widget);
+ gtk_widget_set_colormap (widget,
gdk_screen_get_rgba_colormap (screen));
- gtk_widget_set_app_paintable (widget,
+ gtk_widget_set_app_paintable (widget,
TRUE);
- GTK_WIDGET_CLASS (animation_wallpaper_plugin_parent_class)->realize (widget);
+ GTK_WIDGET_CLASS (animation_wallpaper_plugin_parent_class)->realize (widget);
}
else if (!strcmp(priv->theme, "Matrix"))
init_scene_Matrix(desktop_plugin);
#endif
- init_scene_theme(desktop_plugin);
+// init_scene_theme(desktop_plugin);
- priv->long_timer = g_timeout_add(LONG_TIMER, (GtkFunction)long_timeout, desktop_plugin);
+// priv->long_timer = g_timeout_add(LONG_TIMER, (GtkFunction)long_timeout, desktop_plugin);
/* TODO Move scene to priv */
//scene.timer_type = LONG_TIMER_TYPE;
g_signal_connect (desktop_plugin, "notify::is-on-current-desktop",