fix typo in Enum i18n + fix Import
authorNiki Roo <niki@nikiroo.be>
Thu, 2 May 2019 19:43:44 +0000 (21:43 +0200)
committerNiki Roo <niki@nikiroo.be>
Thu, 2 May 2019 19:43:44 +0000 (21:43 +0200)
libs/nikiroo-utils-4.7.2-dev-sources.jar
src/be/nikiroo/fanfix/bundles/StringIdGui.java
src/be/nikiroo/fanfix/bundles/resources_gui.properties
src/be/nikiroo/fanfix/bundles/resources_gui_fr.properties
src/be/nikiroo/fanfix/supported/Cbz.java
src/be/nikiroo/fanfix/supported/Epub.java
src/be/nikiroo/fanfix/supported/InfoReader.java
src/be/nikiroo/fanfix/supported/Text.java

index 6676e982d0c5a8864652d574fe7af08620453ac7..c4f532dfe98705c805819c33f9d373d787aad704 100644 (file)
Binary files a/libs/nikiroo-utils-4.7.2-dev-sources.jar and b/libs/nikiroo-utils-4.7.2-dev-sources.jar differ
index 0fb83855630944d80918e5a69c51c814cfda12ff..6bb774c1a0bab0e194f1c31da8e6b101f310e6ac 100644 (file)
@@ -150,7 +150,7 @@ public enum StringIdGui {
        @Meta(def = "An error occured when contacting the library", format = Format.STRING, description = "default description if the error is not known")
        ERROR_LIB_STATUS, //
        @Meta(def = "You are not allowed to access this library", format = Format.STRING, description = "library access not allowed")
-       ERROR_LIB_STATUS_UNAUTORIZED, //
+       ERROR_LIB_STATUS_UNAUTHORIZED, //
        @Meta(def = "Library not valid", format = Format.STRING, description = "the library is invalid (not correctly set up)")
        ERROR_LIB_STATUS_INVALID, //
        @Meta(def = "Library currently unavailable", format = Format.STRING, description = "the library is out of commission")
index 9840392639b2f5b50d92313248e2277e2e5cdbcd..de44c18c085b11663cfae8b7b4546f9c2d71dc10 100644 (file)
@@ -165,7 +165,7 @@ PROGRESS_CHANGE_SOURCE = Change the source of the book to %s
 ERROR_LIB_STATUS = An error occured when contacting the library
 # library access not allowed
 # (FORMAT: STRING) 
-ERROR_LIB_STATUS_UNAUTORIZED = You are not allowed to access this library
+ERROR_LIB_STATUS_UNAUTHORIZED = You are not allowed to access this library
 # the library is invalid (not correctly set up)
 # (FORMAT: STRING) 
 ERROR_LIB_STATUS_INVALID = Library not valid
index 453957c8dad1537f12ab3d8920f8716e813df923..2b6d19200b0773404d03ee49e052cc58fe6ee1b2 100644 (file)
@@ -165,7 +165,7 @@ PROGRESS_CHANGE_SOURCE = Change la source du livre en %s
 ERROR_LIB_STATUS = Une erreur est survenue en contactant la librairie
 # library access not allowed
 # (FORMAT: STRING) 
-ERROR_LIB_STATUS_UNAUTORIZED = Vous n'étes pas autorisé à accéder à cette librairie
+ERROR_LIB_STATUS_UNAUTHORIZED = Vous n'étes pas autorisé à accéder à cette librairie
 # the library is invalid (not correctly set up)
 # (FORMAT: STRING) 
 ERROR_LIB_STATUS_INVALID = Librairie invalide
index e1a766e32defd0a1945e3aeba53c0622b7e487a2..dfc1bbb86e90ea4705ca967bd319904484ac49f3 100644 (file)
@@ -21,7 +21,7 @@ import be.nikiroo.fanfix.data.Paragraph.ParagraphType;
 import be.nikiroo.fanfix.data.Story;
 import be.nikiroo.utils.IOUtils;
 import be.nikiroo.utils.Image;
-import be.nikiroo.utils.MarkableFileInputStream;
+import be.nikiroo.utils.streams.MarkableFileInputStream;
 import be.nikiroo.utils.Progress;
 
 /**
@@ -78,8 +78,7 @@ class Cbz extends Epub {
                InputStream cbzIn = null;
                ZipInputStream zipIn = null;
                try {
-                       cbzIn = new MarkableFileInputStream(new FileInputStream(
-                                       getSourceFileOriginal()));
+                       cbzIn = new MarkableFileInputStream(getSourceFileOriginal());
                        zipIn = new ZipInputStream(cbzIn);
                        for (ZipEntry entry = zipIn.getNextEntry(); entry != null; entry = zipIn
                                        .getNextEntry()) {
index c71ba1785ea9db20e6d10bc5b5a72f6612057d53..ae26574340c58cc9e19d54889f70fb77dadf272a 100644 (file)
@@ -17,7 +17,7 @@ import be.nikiroo.fanfix.Instance;
 import be.nikiroo.fanfix.data.MetaData;
 import be.nikiroo.utils.IOUtils;
 import be.nikiroo.utils.Image;
-import be.nikiroo.utils.MarkableFileInputStream;
+import be.nikiroo.utils.streams.MarkableFileInputStream;
 import be.nikiroo.utils.StringUtils;
 
 /**
@@ -174,8 +174,7 @@ class Epub extends InfoText {
                        }
 
                        if (tmp.exists()) {
-                               this.fakeIn = new MarkableFileInputStream(new FileInputStream(
-                                               tmp));
+                               this.fakeIn = new MarkableFileInputStream(tmp);
                        }
 
                        if (tmpInfo.exists()) {
index 817345e028fce27bf6f53f397b3eaeb4a55ca545..57f021f203e68450c9926e372fb02f4d484fde9c 100644 (file)
@@ -14,7 +14,7 @@ import be.nikiroo.fanfix.Instance;
 import be.nikiroo.fanfix.bundles.Config;
 import be.nikiroo.fanfix.data.MetaData;
 import be.nikiroo.utils.Image;
-import be.nikiroo.utils.MarkableFileInputStream;
+import be.nikiroo.utils.streams.MarkableFileInputStream;
 
 // not complete: no "description" tag
 public class InfoReader {
@@ -25,8 +25,7 @@ public class InfoReader {
                }
 
                if (infoFile.exists()) {
-                       InputStream in = new MarkableFileInputStream(new FileInputStream(
-                                       infoFile));
+                       InputStream in = new MarkableFileInputStream(infoFile);
                        try {
                                return createMeta(infoFile.toURI().toURL(), in, withCover);
                        } finally {
index 3518f20f6fce30b9c3751eaaf867c60568919d07..5a4188a2fe6bfa431ccca2cc6eb57904740d42be 100644 (file)
@@ -19,7 +19,7 @@ import be.nikiroo.fanfix.bundles.Config;
 import be.nikiroo.fanfix.data.MetaData;
 import be.nikiroo.utils.Image;
 import be.nikiroo.utils.ImageUtils;
-import be.nikiroo.utils.MarkableFileInputStream;
+import be.nikiroo.utils.streams.MarkableFileInputStream;
 import be.nikiroo.utils.Progress;
 
 /**
@@ -71,7 +71,7 @@ class Text extends BasicSupport {
        protected Document loadDocument(URL source) throws IOException {
                try {
                        sourceFile = new File(source.toURI());
-                       in = new MarkableFileInputStream(new FileInputStream(sourceFile));
+                       in = new MarkableFileInputStream(sourceFile);
                } catch (URISyntaxException e) {
                        throw new IOException("Cannot load the text document: " + source);
                }