This commit is contained in:
Jindra Pet��k
2014-04-05 09:17:29 +02:00
4 changed files with 10 additions and 10 deletions
@@ -270,6 +270,7 @@ import java.io.IOException;
import java.io.InputStream;
import java.io.PrintStream;
import java.util.ArrayList;
import java.util.Arrays;
import java.util.List;
import java.util.concurrent.Callable;
import java.util.concurrent.ExecutionException;
@@ -646,11 +647,13 @@ public class SWFInputStream extends InputStream {
return new byte[0];
}
byte[] ret = new byte[count];
int i = 0;
try {
for (int i = 0; i < count; i++) {
for (i = 0; i < count; i++) {
ret[i] = (byte) readEx();
}
} catch (EOFException | EndOfStreamException ex) {
ret = Arrays.copyOf(ret, i); // truncate array
Logger.getLogger(SWFInputStream.class.getName()).log(Level.SEVERE, null, ex);
}
return ret;
@@ -16,6 +16,7 @@
*/
package com.jpexs.decompiler.flash.gui.abc;
import com.jpexs.decompiler.flash.configuration.Configuration;
import java.awt.Color;
import java.awt.FontMetrics;
import java.awt.Graphics;
@@ -59,6 +60,9 @@ public class LineMarkedEditorPane extends UndoFixedEditorPane {
@Override
public void setText(String t) {
lastLine = -1;
if (Configuration.debugMode.get() && t.length() > 4192) {
t = t.substring(0, 4192);
}
super.setText(t);
setCaretPosition(0); //scroll to top
}
@@ -144,13 +144,6 @@ public abstract class GraphTargetItem implements Serializable {
return false;
}
/*public double toNumber() {
return 0;
}
public boolean toBoolean() {
return Double.compare(toNumber(), 0.0) != 0;
}*/
public Object getResult() {
return null;
}
+2 -2
View File
@@ -660,7 +660,7 @@ public class Helper {
}
}*/
int length = data.length;
if (length > limit) {
if (limit != -1 && length > limit) {
length = limit;
}
@@ -717,7 +717,7 @@ public class Helper {
}
writer.newLine();
if (data.length > limit) {
if (limit != -1 && data.length > limit) {
writer.appendNoHilight(AppStrings.translate("binaryData.truncateWarning").replace("%count%", Integer.toString(data.length - limit)));
}