fixed bugs with xscreensavers start/stop
[livewp] / applet / src / livewp-config.c
index 0487672..4f499ce 100644 (file)
@@ -38,6 +38,39 @@ current_active_view(void){
 
     return result;
 }
+
+/*******************************************************************************/
+#ifdef APPLICATION
+void 
+fill_priv(Animation_WallpaperPrivate *priv)
+{
+    /* Load config */
+    read_config(priv);
+    /* Set function */
+    if (!strcmp(priv->theme, "Accel"))
+        priv->scene_func = (gpointer)&init_scene_Accel;
+    if (!strcmp(priv->theme, "Berlin"))
+        priv->scene_func = (gpointer)&init_scene_Berlin;
+    if (!strcmp(priv->theme, "Modern"))
+        priv->scene_func = (gpointer)&init_scene_Modern;
+    if (!strcmp(priv->theme, "Matrix"))
+        priv->scene_func = (gpointer)&init_scene_Matrix;
+    if (!strcmp(priv->theme, "Video"))
+        priv->scene_func = (gpointer)&init_scene_Video;
+    
+    priv->extheme_list = get_list_exthemes();
+    GSList *store = priv->extheme_list;
+    while (store){
+        if (!strcmp(priv->theme, g_hash_table_lookup(store->data, "name"))){
+            priv->scene_func = (gpointer)&init_scene_External;
+            priv->hash_theme = store->data;
+            break;
+        }
+        store = g_slist_next(store);
+    }
+
+}
+#endif
 /*******************************************************************************/
 gint 
 read_config(Animation_WallpaperPrivate *priv) {