From f628cda737980d0958f564479c0538b41e3dc04c Mon Sep 17 00:00:00 2001 From: tanya Date: Thu, 12 Aug 2010 12:20:38 +0300 Subject: [PATCH] added view in xml as parameter --- applet/src/livewp-scene.c | 19 +++++++++++++------ 1 file changed, 13 insertions(+), 6 deletions(-) diff --git a/applet/src/livewp-scene.c b/applet/src/livewp-scene.c index 784e469..233000d 100644 --- a/applet/src/livewp-scene.c +++ b/applet/src/livewp-scene.c @@ -183,20 +183,27 @@ init_scene_External(AWallpaperPlugin *desktop_plugin){ char* child_argv[2048]; char *run_string = NULL; gchar *exec_path = NULL, - *window_id = NULL; + *window_id = NULL, + *view = NULL, + *strwin = NULL, + *strview =NULL; if (!desktop_plugin->priv->visible) return; + fprintf(stderr,"init_scene_external 111\n"); exec_path = g_strdup(g_hash_table_lookup(desktop_plugin->priv->hash_theme, "exec_path")); window_id = g_strdup(g_hash_table_lookup(desktop_plugin->priv->hash_theme, "window_id")); + view = g_strdup(g_hash_table_lookup(desktop_plugin->priv->hash_theme, "view")); + fprintf(stderr,"init_scene_external 222\n"); if (!exec_path) return; if (window_id){ - run_string = g_strdup_printf("%s %s %d -view %i", exec_path, window_id, - GDK_WINDOW_XID(desktop_plugin->priv->window->window), desktop_plugin->priv->view); - }else { - run_string = g_strdup_printf("%s", exec_path); - } + strwin = g_strdup_printf(" %s %i", window_id, GDK_WINDOW_XID(desktop_plugin->priv->window->window)); + } + if (view){ + strview = g_strdup_printf(" %s %i", view, desktop_plugin->priv->view); + } + run_string = g_strdup_printf("%s%s%s", exec_path, strwin, strview); fprintf(stderr, "runs string = %s\n", run_string); parsestring(run_string, child_argv); -- 1.7.9.5