Library scanning much quicker
[fanfix.git] / src / be / nikiroo / fanfix / supported / Cbz.java
index 012c0474a95df1a05cae162a9518e322f9099a80..f9eee08d51428cab98f2c3fbe9b6561cd3087f56 100644 (file)
@@ -39,18 +39,18 @@ class Cbz extends Epub {
        protected boolean requireInfo() {
                return false;
        }
-       
-       @Override
-       public boolean isImageDocument(URL source, InputStream in)
-                       throws IOException {
-               return true;
-       }
 
        @Override
        protected boolean getCover() {
                return false;
        }
 
+       @Override
+       protected void preprocess(URL source, InputStream in) throws IOException {
+               super.preprocess(source, in);
+               meta.setImageDocument(true);
+       }
+
        @Override
        public Story process(URL url) throws IOException {
                Story story = processMeta(url, false, true);
@@ -74,9 +74,7 @@ class Cbz extends Epub {
 
                                if (imageEntry) {
                                        try {
-                                               // we assume that we can get the UUID without a stream
-                                               String uuid = getUuid(url, null) + "_"
-                                                               + entry.getName();
+                                               String uuid = meta.getUuid() + "_" + entry.getName();
 
                                                Instance.getCache().addToCache(zipIn, uuid);
                                                chap.getParagraphs().add(