Enlightenment CVS committal

Author  : dj2
Project : e17
Module  : libs/ewl

Dir     : e17/libs/ewl/src/lib


Modified Files:
        ewl_io_manager.c 


Log Message:
- add an io image plugin
- yes i know the extenstion to mime type is a hack. it'll get fixed later
- the io manager test can now do text or png/jpg (without having to change
  the test code

===================================================================
RCS file: /cvs/e/e17/libs/ewl/src/lib/ewl_io_manager.c,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -3 -r1.2 -r1.3
--- ewl_io_manager.c    14 Sep 2006 14:33:53 -0000      1.2
+++ ewl_io_manager.c    14 Sep 2006 15:10:24 -0000      1.3
@@ -149,17 +149,26 @@
        ptr = strrchr(uri, '.');
        if (!ptr) DRETURN_PTR(NULL, DLEVEL_STABLE);
 
-       if (!strcmp(ptr, ".txt") || !strcmp(ptr, ".c") || !strcmp(ptr, ".h"))
+       if (!strcasecmp(ptr, ".txt") || !strcasecmp(ptr, ".c") 
+                       || !strcasecmp(ptr, ".h"))
        {
                DRETURN_PTR("text/plain", DLEVEL_STABLE);
        }
-       else if (!strcmp(ptr, ".rtf"))
+       else if (!strcasecmp(ptr, ".rtf"))
        {
                DRETURN_PTR("application/rtf", DLEVEL_STABLE);
        }
-       else if (!strcmp(ptr, ".html"))
+       else if (!strcasecmp(ptr, ".html"))
        {
                DRETURN_PTR("text/html", DLEVEL_STABLE);
+       }
+       else if (!strcasecmp(ptr, ".png"))
+       {
+               DRETURN_PTR("image/png", DLEVEL_STABLE);
+       }
+       else if (!strcasecmp(ptr, ".jpeg") || !strcasecmp(ptr, ".jpg"))
+       {
+               DRETURN_PTR("image/jpeg", DLEVEL_STABLE);
        }
 
        DRETURN_PTR(NULL, DLEVEL_STABLE);



-------------------------------------------------------------------------
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