Enlightenment CVS committal

Author  : raster
Project : e17
Module  : apps/e

Dir     : e17/apps/e/src/bin


Modified Files:
        e_fwin.c 


Log Message:


and now if we find random .desktop files or .sh shellscripts or executables
around - we can execute them directly (as u'd expect).

===================================================================
RCS file: /cvs/e/e17/apps/e/src/bin/e_fwin.c,v
retrieving revision 1.17
retrieving revision 1.18
diff -u -3 -r1.17 -r1.18
--- e_fwin.c    29 Oct 2006 09:31:12 -0000      1.17
+++ e_fwin.c    29 Oct 2006 09:46:19 -0000      1.18
@@ -59,6 +59,9 @@
    return 1;
 }
 
+/* FIXME: this opens a new window - we need a way to inherit a zone as the
+ * "fwin" window
+ */
 EAPI E_Fwin *
 e_fwin_new(E_Container *con, const char *dev, const char *path)
 {
@@ -533,6 +536,9 @@
 static void
 _e_fwin_file_exec(E_Fwin *fwin, E_Fm2_Icon_Info *ici, E_Fwin_Exec_Type ext)
 {
+   char buf[4096];
+   E_App *a;
+   
    /* FIXME: execute file ici with either a temrinal, the shell, or directly
     * or open the .desktop and exec it */
    switch (ext)
@@ -544,12 +550,24 @@
        e_exehist_add("fwin", ici->file);
        break;
       case E_FWIN_EXEC_SH:
+       snprintf(buf, sizeof(buf), "/bin/sh %s", 
e_util_filename_escape(ici->file));
+       e_zone_exec(fwin->win->border->zone, buf);
        break;
       case E_FWIN_EXEC_TERMINAL_DIRECT:
+       snprintf(buf, sizeof(buf), "%s %s", e_config->exebuf_term_cmd, 
e_util_filename_escape(ici->file));
+       e_zone_exec(fwin->win->border->zone, buf);
        break;
       case E_FWIN_EXEC_TERMINAL_SH:
+       snprintf(buf, sizeof(buf), "%s /bin/sh %s", e_config->exebuf_term_cmd, 
e_util_filename_escape(ici->file));
+       e_zone_exec(fwin->win->border->zone, buf);
        break;
       case E_FWIN_EXEC_DESKTOP:
+       a = e_app_new(ici->file, 0);
+       if (a)
+         {
+            e_zone_app_exec(fwin->win->border->zone, a);
+            e_object_unref(E_OBJECT(a));
+         }
        break;
       default:
        break;



-------------------------------------------------------------------------
Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
_______________________________________________
enlightenment-cvs mailing list
enlightenment-cvs@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/enlightenment-cvs

Reply via email to