Enlightenment CVS committal

Author  : onefang
Project : e17
Module  : apps/e

Dir     : e17/apps/e/src/bin


Modified Files:
        e_apps.c e_apps.h e_int_config_apps.c 


Log Message:
Since raster added the ability for fm2 to delete from within .order
files that are displayed as a virtual folder, there is no need for the
all apps app deletion buttons and code.

If you are still having issues with deleting apps, take it up with raster.

===================================================================
RCS file: /cvs/e/e17/apps/e/src/bin/e_apps.c,v
retrieving revision 1.160
retrieving revision 1.161
diff -u -3 -r1.160 -r1.161
--- e_apps.c    1 Sep 2006 09:01:52 -0000       1.160
+++ e_apps.c    1 Sep 2006 09:26:55 -0000       1.161
@@ -812,59 +812,6 @@
    e_object_unref(E_OBJECT(a));
 }
 
-
-EAPI void
-e_app_remove_file_from_order(const char *order, const char *file)
-{
-   char buf[4096];
-   Evas_List *list = NULL, *l;
-   int ret = 0;
-   FILE *f;
-
-   snprintf(buf, sizeof(buf), "%s/.order", order);
-   if (!ecore_file_exists(buf)) return;
-   f = fopen(buf, "rb");
-   if (!f) return;
-
-   while (fgets(buf, sizeof(buf), f))
-     {
-       int len;
-
-       len = strlen(buf);
-       if (len > 0)
-         {
-            if (buf[len - 1] == '\n')
-              {
-                 buf[len - 1] = 0;
-                 len--;
-              }
-            if (strcmp(buf, file) != 0)
-                  list = evas_list_append(list, strdup(buf));
-         }
-     }
-   fclose(f);
-
-   snprintf(buf, sizeof(buf), "%s/.order", order);
-   ecore_file_unlink(buf);
-   f = fopen(buf, "wb");
-   if (!f) return;
-   for (l = list; l; l = l->next)
-     {
-        char *text;
-
-        text = l->data;
-       fprintf(f, "%s\n", text);
-       free(text);
-     }
-   fclose(f);
-   evas_list_free(list);
-
-   snprintf(buf, sizeof(buf), "%s/.eap.cache.cfg", order);
-   ecore_file_unlink(buf);
-
-   return;
-}
-
 EAPI void
 e_app_change_callback_add(void (*func) (void *data, E_App *a, E_App_Change 
ch), void *data)
 {
===================================================================
RCS file: /cvs/e/e17/apps/e/src/bin/e_apps.h,v
retrieving revision 1.38
retrieving revision 1.39
diff -u -3 -r1.38 -r1.39
--- e_apps.h    1 Sep 2006 09:01:52 -0000       1.38
+++ e_apps.h    1 Sep 2006 09:26:55 -0000       1.39
@@ -112,7 +112,6 @@
 EAPI void        e_app_files_prepend_relative            (Evas_List *files, 
E_App *before);
 EAPI void        e_app_files_append                      (Evas_List *files, 
E_App *parent);
 EAPI void        e_app_remove                            (E_App *a);
-EAPI void        e_app_remove_file_from_order            (const char *order, 
const char *file);
     
 EAPI void        e_app_change_callback_add               (void (*func) (void 
*data, E_App *a, E_App_Change ch), void *data);
 EAPI void        e_app_change_callback_del               (void (*func) (void 
*data, E_App *a, E_App_Change ch), void *data);
===================================================================
RCS file: /cvs/e/e17/apps/e/src/bin/e_int_config_apps.c,v
retrieving revision 1.12
retrieving revision 1.13
diff -u -3 -r1.12 -r1.13
--- e_int_config_apps.c 31 Aug 2006 02:21:00 -0000      1.12
+++ e_int_config_apps.c 1 Sep 2006 09:26:55 -0000       1.13
@@ -244,91 +244,6 @@
 }
 
 static void
-_cb_button_delete_left(void *data1, void *data2)
-{
-   E_Config_Dialog_Data *cfdata;
-   Evas_List *l;
-   E_Fm2_Icon_Info *ici;
-   const char *realpath;
-   char buf[4096];
-
-   cfdata = data1;
-   if (!cfdata->gui.o_fm_all) return;
-   if (!cfdata->parent_all) return;
-
-   l = e_fm2_selected_list_get(cfdata->gui.o_fm_all);
-   if (!l) return;
-   ici = l->data;
-   evas_list_free(l);
-
-#if 0
-   /* This just isn't working, lets try the crude method instead. */
-   for (l = cfdata->parent_all->subapps; l; l = l->next)
-     {
-       E_App *a2;
-       
-       a2 = l->data;
-       if ((a2->deleted) || ((a2->orig) && (a2->orig->deleted))) continue;
-       if (!strcmp(ecore_file_get_file(a2->path), 
ecore_file_get_file(ici->file)))
-          {
-              e_app_remove(a2);
-              e_fm2_refresh(cfdata->gui.o_fm_all);
-             break;
-          }
-     }
-#else
-   realpath = e_fm2_real_path_get(cfdata->gui.o_fm_all);
-   if (!strcmp(realpath, "/"))
-     snprintf(buf, sizeof(buf), "/%s", ici->file);
-   else
-     snprintf(buf, sizeof(buf), "%s/%s", realpath, ici->file);
-   ecore_file_unlink(buf);
-   snprintf(buf, sizeof(buf), "%s/.eap.cache.cfg", realpath);
-   ecore_file_unlink(buf);
-   e_fm2_refresh(cfdata->gui.o_fm_all);
-#endif
-}
-
-static void
-_cb_button_delete_right(void *data1, void *data2)
-{
-   E_Config_Dialog_Data *cfdata;
-   Evas_List *l;
-   E_Fm2_Icon_Info *ici;
-   const char *realpath;
-
-   cfdata = data1;
-   if (!cfdata->gui.o_fm) return;
-
-   l = e_fm2_selected_list_get(cfdata->gui.o_fm);
-   if (!l) return;
-   ici = l->data;
-   evas_list_free(l);
-
-#if 0
-   /* This just isn't working, lets try the crude method instead. */
-   if (!cfdata->parent) return;
-   for (l = cfdata->parent->subapps; l; l = l->next)
-     {
-       E_App *a2;
-       
-       a2 = l->data;
-       if ((a2->deleted) || ((a2->orig) && (a2->orig->deleted))) continue;
-       if (!strcmp(ecore_file_get_file(a2->path), 
ecore_file_get_file(ici->file)))
-          {
-              e_app_remove_from_order(a2);
-              e_fm2_refresh(cfdata->gui.o_fm);
-             break;
-          }
-     }
-#else
-   realpath = e_fm2_real_path_get(cfdata->gui.o_fm);
-   e_app_remove_file_from_order(realpath, ecore_file_get_file(ici->file));
-   e_fm2_refresh(cfdata->gui.o_fm);
-#endif
-}
-
-static void
 _cb_button_add(void *data1, void *data2)
 {
    E_Config_Dialog_Data *cfdata;
@@ -462,11 +377,6 @@
    cfdata->gui.o_add_button = mt;
    e_widget_framelist_object_append(of, mt);
 
-   mt = e_widget_button_add(evas, _("Delete application"), "enlightenment/e",
-                          _cb_button_delete_left, cfdata, NULL);
-   cfdata->gui.o_delete_left_button = mt;
-   e_widget_framelist_object_append(of, mt);
-
    e_widget_table_object_append(ot, of, 0, 0, 2, 4, 1, 1, 1, 1);
 
    if (!once)
@@ -512,11 +422,6 @@
          cfdata->gui.o_frame = ob;
          e_widget_min_size_set(ob, 150, 220);
          e_widget_framelist_object_append(of, ob);
-
-         mt = e_widget_button_add(evas, _("Remove application"), 
"enlightenment/e",
-                          _cb_button_delete_right, cfdata, NULL);
-         cfdata->gui.o_delete_right_button = mt;
-         e_widget_framelist_object_append(of, mt);
 
          mt = e_widget_button_add(evas, _("Regenerate \"All Applications\" 
Menu"), "enlightenment/e",
                           _cb_button_regen, cfdata, NULL);



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