summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCarsten Haitzler <raster@rasterman.com>2001-03-26 07:21:39 +0000
committerCarsten Haitzler <raster@rasterman.com>2001-03-26 07:21:39 +0000
commit3afd37d99834e73f09076ae9c760e79e109b2994 (patch)
tree7df279e7f22789968c686e596f00877c75bb2640
parentd7057ba6a85216e842297fb7c941d71409d662f5 (diff)
"detailed" mimetype fallback now available... :)
SVN revision: 4453
-rw-r--r--data/icons/image/jpeg-jfif-standard.dbbin49152 -> 0 bytes
-rw-r--r--src/view.c38
2 files changed, 30 insertions, 8 deletions
diff --git a/data/icons/image/jpeg-jfif-standard.db b/data/icons/image/jpeg-jfif-standard.db
deleted file mode 100644
index 399e8d99f..000000000
--- a/data/icons/image/jpeg-jfif-standard.db
+++ /dev/null
Binary files differ
diff --git a/src/view.c b/src/view.c
index 73b08f4bf..f7b567329 100644
--- a/src/view.c
+++ b/src/view.c
@@ -587,17 +587,39 @@ e_view_handle_fs(EfsdEvent *ev)
587 icon->info.mime.type); 587 icon->info.mime.type);
588 if (!e_file_exists(m1)) 588 if (!e_file_exists(m1))
589 { 589 {
590 printf("fallback 1\n"); 590 int found;
591 sprintf(m1, "%s/data/icons/%s/default.db",PACKAGE_DATA_DIR, 591
592 icon->info.mime.base); 592 printf("fallback 0\n");
593 if (!e_file_exists(m1)) 593 strcpy(m2, icon->info.mime.type);
594 p = strrchr(m2, '-');
595 found = 0;
596 while (p)
597 {
598 p[0] = 0;
599 sprintf(m1, "%s/data/icons/%s/%s.db",PACKAGE_DATA_DIR,
600 icon->info.mime.base, m2);
601 printf("try %s\n", m1);
602 if (e_file_exists(m1))
603 {
604 found = 1;
605 break;
606 }
607 p = strrchr(m2, '-');
608 }
609 if (!found)
594 { 610 {
595 printf("fallback 2\n"); 611 printf("fallback 1\n");
596 sprintf(m1, "%s/data/icons/unknown/unknown.db",PACKAGE_DATA_DIR); 612 sprintf(m1, "%s/data/icons/%s/default.db",PACKAGE_DATA_DIR,
613 icon->info.mime.base);
597 if (!e_file_exists(m1)) 614 if (!e_file_exists(m1))
598 { 615 {
599 printf("fallback 3\n"); 616 printf("fallback 2\n");
600 sprintf(m1, "%s/data/icons/unknown/default.db",PACKAGE_DATA_DIR); 617 sprintf(m1, "%s/data/icons/unknown/unknown.db",PACKAGE_DATA_DIR);
618 if (!e_file_exists(m1))
619 {
620 printf("fallback 3\n");
621 sprintf(m1, "%s/data/icons/unknown/default.db",PACKAGE_DATA_DIR);
622 }
601 } 623 }
602 } 624 }
603 } 625 }