1. new app file examples, 2. app parsing code... etc. etc.

SVN revision: 12333
This commit is contained in:
Carsten Haitzler 2004-12-02 07:00:30 +00:00
parent 5a47862a7e
commit edf76bcece
5 changed files with 26 additions and 18 deletions

View File

@ -1,5 +1,5 @@
MAINTAINERCLEANFILES = Makefile.in MAINTAINERCLEANFILES = Makefile.in
filesdir = $(datadir)/enlightenment/data/other filesdir = $(datadir)/enlightenment/data/other
files_DATA = favorite_apps.tar.gz files_DATA = applications.tar.gz
EXTRA_DIST = $(files_DATA) EXTRA_DIST = $(files_DATA)

Binary file not shown.

Binary file not shown.

View File

@ -79,7 +79,7 @@ E_App *
e_app_new(char *path, int scan_subdirs) e_app_new(char *path, int scan_subdirs)
{ {
E_App *a; E_App *a;
a = evas_hash_find(_e_apps, path); a = evas_hash_find(_e_apps, path);
if (a) if (a)
{ {
@ -479,17 +479,24 @@ _e_app_dir_file_list_get(E_App *a, char *path)
{ {
int ok = 0; int ok = 0;
if (buf[len - 1] == '\n') buf[len - 1] = 0; if (buf[len - 1] == '\n')
for (l = files; l; l = l->next)
{ {
if (!strcmp(buf, l->data)) buf[len - 1] = 0;
{ len--;
free(l->data); }
files = evas_list_remove_list(files, l); if (len > 0)
break; {
} for (l = files; l; l = l->next)
{
if (!strcmp(buf, l->data))
{
free(l->data);
files = evas_list_remove_list(files, l);
break;
}
}
files2 = evas_list_append(files2, strdup(buf));
} }
files2 = evas_list_append(files2, strdup(buf));
} }
} }
fclose(f); fclose(f);

View File

@ -386,16 +386,17 @@ _e_main_dirs_init(void)
return 0; return 0;
} }
} }
/* FIXME: THIS is a hack to get people started!!! */ /* FIXME: THIS is a hack to get people started!!! */
/* snprintf(buf, sizeof(buf), "%s/.e/e/applications/all/eterm.eet", homedir);
snprintf(buf, sizeof(buf), "%s/.e/e/applications/favorite/eterm.eet", homedir);
if (!e_file_exists(buf)) if (!e_file_exists(buf))
snprintf(buf, sizeof(buf), "tar -C %s/.e/e/applications/favorite/ zxvf %s/data/other/favorite_apps.tar.gz", homedir, PACKAGE_DATA_DIR); snprintf(buf, sizeof(buf),
snprintf(buf, sizeof(buf), "%s/.e/e/applications/bar/", homedir); "gzip -d -c < %s/data/other/applications.tar.gz |"
if (!e_file_exists(buf)) "(cd %s/.e/e/ ; tar -xf -)",
snprintf(buf, sizeof(buf), "tar -C %s/.e/e/applications/bar/ zxvf %s/data/other/favorite_apps.tar.gz", homedir, PACKAGE_DATA_DIR); PACKAGE_DATA_DIR,
homedir);
free(homedir); free(homedir);
*/
return 1; return 1;
} }