summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSebastian Dransfeld <sd@tango.flipp.net>2006-12-28 13:58:12 +0000
committerSebastian Dransfeld <sd@tango.flipp.net>2006-12-28 13:58:12 +0000
commitd523a62b26b4507d71b53dc45e536ee0b7973ee8 (patch)
treeebc23097456ed999e2ed2d22467844617606d231
parent941564999b4f021ac220e95921d18b624cbcd4f3 (diff)
Remove old stuff.
SVN revision: 27594
Diffstat (limited to '')
-rw-r--r--src/bin/e_apps.c78
-rw-r--r--src/bin/e_path.c34
2 files changed, 9 insertions, 103 deletions
diff --git a/src/bin/e_apps.c b/src/bin/e_apps.c
index 6c63d2c..5c63ffb 100644
--- a/src/bin/e_apps.c
+++ b/src/bin/e_apps.c
@@ -64,8 +64,6 @@ static void _e_app_fields_save_others(E_App *a);
64static void _e_app_save_order (E_App *app); 64static void _e_app_save_order (E_App *app);
65static int _e_app_cb_event_border_add(void *data, int type, void *event); 65static int _e_app_cb_event_border_add(void *data, int type, void *event);
66static int _e_app_cb_expire_timer (void *data); 66static int _e_app_cb_expire_timer (void *data);
67static int _e_app_exe_valid_get (const char *exe);
68static char *_e_app_localized_val_get (Eet_File *ef, const char *lang, const char *field, int *size);
69#if DEBUG 67#if DEBUG
70static void _e_app_print (const char *path, Ecore_File_Event event); 68static void _e_app_print (const char *path, Ecore_File_Event event);
71#endif 69#endif
@@ -1851,39 +1849,6 @@ e_app_fields_fill(E_App *a, const char *path)
1851#endif 1849#endif
1852} 1850}
1853 1851
1854static char *
1855_e_app_localized_val_get(Eet_File *ef, const char *lang, const char *field, int *size)
1856{
1857 E_Locale_Parts *locale_parts;
1858 char *s, *v;
1859 char buf[PATH_MAX];
1860
1861 if (lang)
1862 {
1863 locale_parts = e_intl_locale_parts_get(lang);
1864
1865 if (locale_parts)
1866 {
1867 s = e_intl_locale_parts_combine(locale_parts, E_INTL_LOC_LANG | E_INTL_LOC_REGION);
1868 snprintf(buf, sizeof(buf), "%s[%s]", field, s);
1869 free(s);
1870 v = eet_read(ef, buf, size);
1871 if (v)
1872 return v;
1873
1874 snprintf(buf, sizeof(buf), "%s[%s]", field, locale_parts->lang);
1875 v = eet_read(ef, buf, size);
1876 if (v)
1877 return v;
1878
1879 e_intl_locale_parts_free(locale_parts);
1880 }
1881 }
1882 /* Fall back to default locale */
1883 return eet_read(ef, field, size);
1884}
1885
1886
1887EAPI void 1852EAPI void
1888e_app_fields_save(E_App *a) 1853e_app_fields_save(E_App *a)
1889{ 1854{
@@ -2574,35 +2539,16 @@ _e_app_cb_monitor(void *data, Ecore_File_Monitor *em,
2574 e_app_fields_fill(a, path); 2539 e_app_fields_fill(a, path);
2575 if (a->filled) 2540 if (a->filled)
2576 { 2541 {
2577/* allow invalid apps 2542 _e_app_change(a, E_APP_CHANGE);
2578 if (!_e_app_exe_valid_get(a->exe)) 2543 for (l = a->references; l; l = l->next)
2579 {
2580 a->deleted = 1;
2581 for (l = a->references; l;)
2582 {
2583 E_App *a2;
2584
2585 a2 = l->data;
2586 l = l->next;
2587 if (a2->parent)
2588 _e_app_subdir_rescan(a2->parent);
2589 }
2590 _e_app_subdir_rescan(app);
2591 }
2592 else
2593 */
2594 { 2544 {
2595 _e_app_change(a, E_APP_CHANGE); 2545 E_App *a2;
2596 for (l = a->references; l; l = l->next) 2546
2597 { 2547 a2 = l->data;
2598 E_App *a2; 2548 if (_e_app_copy(a2, a))
2599 2549 _e_app_change(a2, E_APP_CHANGE);
2600 a2 = l->data;
2601 if (_e_app_copy(a2, a))
2602 _e_app_change(a2, E_APP_CHANGE);
2603 }
2604 _e_app_subdir_rescan(app);
2605 } 2550 }
2551 _e_app_subdir_rescan(app);
2606 } 2552 }
2607 } 2553 }
2608 } 2554 }
@@ -2977,14 +2923,6 @@ _e_app_cb_expire_timer(void *data)
2977 return 0; 2923 return 0;
2978} 2924}
2979 2925
2980
2981static int
2982_e_app_exe_valid_get(const char *exe)
2983{
2984 if ((!exe) || (!exe[0])) return 0;
2985 return 1;
2986}
2987
2988#if DEBUG 2926#if DEBUG
2989static void 2927static void
2990_e_app_print(const char *path, Ecore_File_Event event) 2928_e_app_print(const char *path, Ecore_File_Event event)
diff --git a/src/bin/e_path.c b/src/bin/e_path.c
index 8ea1206..35e46f8 100644
--- a/src/bin/e_path.c
+++ b/src/bin/e_path.c
@@ -253,8 +253,7 @@ e_path_find(E_Path *ep, const char *file)
253 for (l = ep->default_dir_list; l; l = l->next) 253 for (l = ep->default_dir_list; l; l = l->next)
254 { 254 {
255 E_Path_Dir *epd; 255 E_Path_Dir *epd;
256// char *rp; 256
257
258 epd = l->data; 257 epd = l->data;
259 if (epd->dir) 258 if (epd->dir)
260 { 259 {
@@ -267,28 +266,12 @@ e_path_find(E_Path *ep, const char *file)
267 evas_stringshare_add(buf)); 266 evas_stringshare_add(buf));
268 return evas_stringshare_add(buf); 267 return evas_stringshare_add(buf);
269 } 268 }
270/*
271 rp = ecore_file_realpath(buf);
272 if ((rp) && (rp[0] != 0))
273 {
274 strncpy(buf, rp, sizeof(buf) - 1);
275 buf[sizeof(buf) - 1] = 0;
276 free(rp);
277 if (evas_hash_size(ep->hash) >= 512)
278 _e_path_cache_free(ep);
279 ep->hash = evas_hash_add(ep->hash, file,
280 evas_stringshare_add(buf));
281 return evas_stringshare_add(buf);
282 }
283 if (rp) free(rp);
284 */
285 } 269 }
286 } 270 }
287 /* Look in the users dir list */ 271 /* Look in the users dir list */
288 for (l = *(ep->user_dir_list); l; l = l->next) 272 for (l = *(ep->user_dir_list); l; l = l->next)
289 { 273 {
290 E_Path_Dir *epd; 274 E_Path_Dir *epd;
291 char *rp;
292 275
293 epd = l->data; 276 epd = l->data;
294 if (epd->dir) 277 if (epd->dir)
@@ -302,21 +285,6 @@ e_path_find(E_Path *ep, const char *file)
302 evas_stringshare_add(buf)); 285 evas_stringshare_add(buf));
303 return evas_stringshare_add(buf); 286 return evas_stringshare_add(buf);
304 } 287 }
305/*
306 rp = ecore_file_realpath(buf);
307 if ((rp) && (rp[0] != 0))
308 {
309 strncpy(buf, rp, sizeof(buf) - 1);
310 buf[sizeof(buf) - 1] = 0;
311 free(rp);
312 if (evas_hash_size(ep->hash) >= 512)
313 _e_path_cache_free(ep);
314 ep->hash = evas_hash_add(ep->hash, file,
315 evas_stringshare_add(buf));
316 return evas_stringshare_add(buf);
317 }
318 if (rp) free(rp);
319 */
320 } 288 }
321 } 289 }
322 return NULL; 290 return NULL;