Enlightenment CVS committal

Author  : lordchaos
Project : e17
Module  : proto

Dir     : e17/proto/entropy/src/plugins


Modified Files:
        action_simple.c etk_list_viewer.c etk_structure_viewer.c 
        ewl_icon_local_viewer.c filesystem.c thumbnail_generic.c 


Log Message:
* Miscellaneous cleanups
* Remove a crash related to entropy_generic_file cloning.

===================================================================
RCS file: /cvsroot/enlightenment/e17/proto/entropy/src/plugins/action_simple.c,v
retrieving revision 1.10
retrieving revision 1.11
diff -u -3 -r1.10 -r1.11
--- action_simple.c     18 Mar 2006 08:04:11 -0000      1.10
+++ action_simple.c     19 Mar 2006 05:41:08 -0000      1.11
@@ -36,18 +36,22 @@
 
                        if ( i +3 <= strlen(currStr) && !strncmp(currStr+i, 
"\%pf", 3)) {
                                printf("Subbing path and filename\n");
-                               
+                       
+                               strcat(str, "\"");
                                strcat(str, file->path);                        
                
                                strcat(str, "/");
                                strcat(str, file->filename);
+                               strcat(str, "\"");
                                ud = 1;
                                i+=3;
                        }
 
                        if ( i +2 <= strlen(currStr) && !strncmp(currStr+i, 
"\%p", 2)) {
                                printf("Subbing path only\n");
-                               
+                       
+                               strcat(str, "\"");
                                strcat(str, file->path);                        
                
+                               strcat(str, "\"");
                                ud = 1;
                                i+=2;
                        }
@@ -56,7 +60,9 @@
                                printf("Subbing uri\n");
                                
                                char* uri = 
entropy_core_generic_file_uri_create(file, 0);
+                               strcat(str,"\"");
                                strcat(str, uri);
+                               strcat(str, "\"");
                                ud = 1;
                                i+=2;
                                free(uri);
===================================================================
RCS file: 
/cvsroot/enlightenment/e17/proto/entropy/src/plugins/etk_list_viewer.c,v
retrieving revision 1.46
retrieving revision 1.47
diff -u -3 -r1.46 -r1.47
--- etk_list_viewer.c   18 Mar 2006 08:04:11 -0000      1.46
+++ etk_list_viewer.c   19 Mar 2006 05:41:08 -0000      1.47
@@ -214,13 +214,7 @@
                                   l = l->next;
                                   i++;
                           }
-
-                         
                  }
-
-               
-
-                  
        }
        
 }
@@ -580,8 +574,8 @@
 
 
 
-   if (!strlen (file->mime_type)) {
-                   entropy_mime_file_identify (instance->core->mime_plugins, 
file);
+  if (!strlen (file->mime_type)) {
+       entropy_mime_file_identify (instance->core->mime_plugins, file);
   }
 
   if (file->mime_type) {
@@ -774,13 +768,8 @@
       /*Check that this file is the current dir we are displaying*/
       entropy_generic_file* parent_folder = 
entropy_core_parent_folder_file_get(file);
 
-      /*printf("At list viewer, Parent folder is: %p : Current folder: %p\n", 
parent_folder, viewer->current_folder);*/
-      /*if (parent_folder) {
-             printf("Parent folder string: %s/%s : Current folder: %s/%s", 
parent_folder->path, parent_folder->filename,
-                             viewer->current_folder->path, 
viewer->current_folder->filename);
-      }*/
-      
       if (parent_folder && parent_folder == viewer->current_folder) {
+             entropy_core_file_cache_add_reference (file->md5);
              list_viewer_add_row (comp, file);                               
       }
      }
===================================================================
RCS file: 
/cvsroot/enlightenment/e17/proto/entropy/src/plugins/etk_structure_viewer.c,v
retrieving revision 1.18
retrieving revision 1.19
diff -u -3 -r1.18 -r1.19
--- etk_structure_viewer.c      4 Mar 2006 08:23:16 -0000       1.18
+++ etk_structure_viewer.c      19 Mar 2006 05:41:08 -0000      1.19
@@ -125,7 +125,7 @@
    if (instance) {
           viewer = instance->data;
           e_event = ecore_hash_get(viewer->row_hash, row);
-       
+
          if (e_event) {
                  gui_event = entropy_malloc (sizeof (entropy_gui_event));
                  gui_event->event_type =
===================================================================
RCS file: 
/cvsroot/enlightenment/e17/proto/entropy/src/plugins/ewl_icon_local_viewer.c,v
retrieving revision 1.61
retrieving revision 1.62
diff -u -3 -r1.61 -r1.62
--- ewl_icon_local_viewer.c     2 Mar 2006 06:10:55 -0000       1.61
+++ ewl_icon_local_viewer.c     19 Mar 2006 05:41:08 -0000      1.62
@@ -199,8 +199,8 @@
 void
 icon_hover_properties_show_cb (Ewl_Widget * w, void *ev_data, void *user_data)
 {
-  entropy_gui_component_instance *instance = user_data;
-  entropy_icon_viewer *viewer = instance->data;
+  /*entropy_gui_component_instance *instance = user_data;
+  entropy_icon_viewer *viewer = instance->data;*/
 }
 
 /*-----------------------------*/
@@ -448,7 +448,6 @@
 
   Ecore_List *new_file_list = ecore_list_new ();
   Ecore_List *icon_list;
-  entropy_generic_file *file;
   gui_file *local_file;
   Ewl_Iconbox_Icon *list_item;
 
@@ -538,9 +537,6 @@
 void
 ewl_icon_local_viewer_key_event_cb (Ewl_Iconbox * ib, void *data, char *key)
 {
-  entropy_icon_viewer *viewer =
-    ((entropy_gui_component_instance *) data)->data;
-
   printf ("Received controlled key: '%s'\n", key);
 
   if (!strcmp (key, "Delete")) {
===================================================================
RCS file: /cvsroot/enlightenment/e17/proto/entropy/src/plugins/filesystem.c,v
retrieving revision 1.56
retrieving revision 1.57
diff -u -3 -r1.56 -r1.57
--- filesystem.c        14 Mar 2006 13:05:43 -0000      1.56
+++ filesystem.c        19 Mar 2006 05:41:08 -0000      1.57
@@ -72,7 +72,7 @@
            file = entropy_generic_file_new ();
            /*For now, just make an entropy_generic_file for this object */
 
-           strncpy (file->path, folder, 255);
+           strncpy (file->path, folder, PATH_MAX);
            strncpy (file->filename, pos + 1, strlen (pos + 1) + 1);
            strncpy (file->uri_base, data->file_monitor.plugin,
                     strlen (data->file_monitor.plugin));
@@ -83,6 +83,8 @@
                    file->filetype = FILE_FOLDER;
            }
 
+           file->thumbnail = NULL;
+
            /*Register a new listener for this file */
            listener = entropy_malloc (sizeof (entropy_file_listener));
            listener->file = file;
===================================================================
RCS file: 
/cvsroot/enlightenment/e17/proto/entropy/src/plugins/thumbnail_generic.c,v
retrieving revision 1.6
retrieving revision 1.7
diff -u -3 -r1.6 -r1.7
--- thumbnail_generic.c 31 Jan 2006 07:17:48 -0000      1.6
+++ thumbnail_generic.c 19 Mar 2006 05:41:08 -0000      1.7
@@ -17,7 +17,7 @@
 entropy_thumbnail *
 entropy_thumbnail_new ()
 {
-  entropy_thumbnail *thumb = malloc (sizeof (entropy_thumbnail));
+  entropy_thumbnail *thumb = calloc (1,sizeof (entropy_thumbnail));
 
   thumb->text = ecore_hash_new (ecore_str_hash, ecore_str_compare);
   thumb->keys = 0;




-------------------------------------------------------
This SF.Net email is sponsored by xPML, a groundbreaking scripting language
that extends applications into web and mobile media. Attend the live webcast
and join the prime developer group breaking into this new coding territory!
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=110944&bid=241720&dat=121642
_______________________________________________
enlightenment-cvs mailing list
enlightenment-cvs@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/enlightenment-cvs

Reply via email to