Enlightenment CVS committal

Author  : raster
Project : e17
Module  : apps/e

Dir     : e17/apps/e/src/bin


Modified Files:
        e_container.c e_zone.c 


Log Message:


ehack is baaack! :)

===================================================================
RCS file: /cvsroot/enlightenment/e17/apps/e/src/bin/e_container.c,v
retrieving revision 1.62
retrieving revision 1.63
diff -u -3 -r1.62 -r1.63
--- e_container.c       29 May 2005 11:37:18 -0000      1.62
+++ e_container.c       2 Jun 2005 14:56:07 -0000       1.63
@@ -99,7 +99,7 @@
    
    e_pointer_container_set(con);
 
-   con->num = evas_list_count(con->manager->containers);
+   con->num = evas_list_count(con->manager->containers) - 1;
    snprintf(name, sizeof(name), _("Container %d"), con->num);
    con->name = strdup(name);
 
===================================================================
RCS file: /cvsroot/enlightenment/e17/apps/e/src/bin/e_zone.c,v
retrieving revision 1.54
retrieving revision 1.55
diff -u -3 -r1.54 -r1.55
--- e_zone.c    2 Jun 2005 09:49:07 -0000       1.54
+++ e_zone.c    2 Jun 2005 14:56:07 -0000       1.55
@@ -459,13 +459,20 @@
 int
 e_zone_app_exec(E_Zone *zone, E_App *a)
 {
-   int ret;
-   char *penv_display, *p1, *p2;
+   static int launch_id = 1;
+   char *p1, *p2;
+   char *penv_display;
+   char *penv_ld_preload;
+   char *penv_ld_preload_path;
    char buf[4096], buf2[32];
    
    /* save previous env vars we need to save */
    penv_display = getenv("DISPLAY");
    if (penv_display) penv_display = strdup(penv_display);
+   penv_ld_preload = getenv("LD_PRELOAD");
+   if (penv_ld_preload) penv_ld_preload = strdup(penv_ld_preload);
+   penv_ld_preload_path = getenv("LD_PRELOAD_PATH");
+   if (penv_ld_preload_path) penv_ld_preload_path = 
strdup(penv_ld_preload_path);
    
    /* set env vars */
    p1 = strrchr(penv_display, ':');
@@ -490,16 +497,22 @@
      strcpy(buf, penv_display);
    e_util_env_set("DISPLAY", buf);
    snprintf(buf, sizeof(buf), "%i %i", zone->desk_x_current, 
zone->desk_y_current);
-   e_util_env_set("_E_DESK", buf);
+   e_util_env_set("E_DESK", buf);
    snprintf(buf, sizeof(buf), "%i", zone->num);
-   e_util_env_set("_E_ZONE", buf);
+   e_util_env_set("E_ZONE", buf);
    snprintf(buf, sizeof(buf), "%i", zone->container->num);
-   e_util_env_set("_E_CONTAINER", buf);
+   e_util_env_set("E_CONTAINER", buf);
    snprintf(buf, sizeof(buf), "%i", zone->container->manager->num);
-   e_util_env_set("_E_MANAGER", buf);
+   e_util_env_set("E_MANAGER", buf);
+   e_util_env_set("LD_PRELOAD_PATH", PACKAGE_LIB_DIR"/enlightenment/preload");
+   e_util_env_set("LD_PRELOAD", 
PACKAGE_LIB_DIR"/enlightenment/preload/e_hack.so");
    
+   snprintf(buf, sizeof(buf), "%i", launch_id);
+   e_util_env_set("E_LAUNCH_ID", buf);
+   launch_id++;
+   if (launch_id == 0) launch_id = 1;
    /* execute */
-   ret = e_app_exec(a);
+   if (!e_app_exec(a)) return 0;
    
    /* reset env vars */
    if (penv_display)
@@ -507,7 +520,17 @@
        e_util_env_set("DISPLAY", penv_display);
        free(penv_display);
      }
-   return ret;
+   if (penv_ld_preload)
+     {
+       e_util_env_set("LD_PRELOAD", penv_ld_preload);
+       free(penv_ld_preload);
+     }
+   if (penv_ld_preload_path)
+     {
+       e_util_env_set("LD_PRELOAD_PATH", penv_ld_preload_path);
+       free(penv_ld_preload_path);
+     }
+   return launch_id;
 }
 
 /* local subsystem functions */




-------------------------------------------------------
This SF.Net email is sponsored by Yahoo.
Introducing Yahoo! Search Developer Network - Create apps using Yahoo!
Search APIs Find out how you can build Yahoo! directly into your own
Applications - visit http://developer.yahoo.net/?fr=offad-ysdn-ostg-q22005
_______________________________________________
enlightenment-cvs mailing list
enlightenment-cvs@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/enlightenment-cvs

Reply via email to