mirror of
https://git.huckle.dev/Huckles-Minecraft-Archive/jpexs-decompiler.git
synced 2026-09-25 03:20:45 +00:00
#827 "Error occurred: Width (0) and height (0) cannot be <= 0" (have to Ignore 100's of times) fixed
This commit is contained in:
@@ -25,11 +25,29 @@ import javax.swing.JOptionPane;
|
||||
*/
|
||||
public class GuiAbortRetryIgnoreHandler implements AbortRetryIgnoreHandler {
|
||||
|
||||
private boolean ignoreAll = false;
|
||||
|
||||
@Override
|
||||
public int handle(Throwable thrown) {
|
||||
synchronized (GuiAbortRetryIgnoreHandler.class) {
|
||||
String[] options = new String[]{AppStrings.translate("button.abort"), AppStrings.translate("button.retry"), AppStrings.translate("button.ignore")};
|
||||
return View.showOptionDialog(null, AppStrings.translate("error.occured").replace("%error%", thrown.getLocalizedMessage()), AppStrings.translate("error"), JOptionPane.YES_NO_OPTION, JOptionPane.ERROR_MESSAGE, null, options, "");
|
||||
String[] options = new String[]{
|
||||
AppStrings.translate("button.abort"),
|
||||
AppStrings.translate("button.retry"),
|
||||
AppStrings.translate("button.ignore"),
|
||||
AppStrings.translate("button.ignoreAll")
|
||||
};
|
||||
|
||||
if (ignoreAll) {
|
||||
return AbortRetryIgnoreHandler.IGNORE;
|
||||
}
|
||||
|
||||
int result = View.showOptionDialog(null, AppStrings.translate("error.occured").replace("%error%", thrown.getLocalizedMessage()), AppStrings.translate("error"), JOptionPane.YES_NO_OPTION, JOptionPane.ERROR_MESSAGE, null, options, "");
|
||||
if (result == AbortRetryIgnoreHandler.IGNORE_ALL) {
|
||||
ignoreAll = true;
|
||||
result = AbortRetryIgnoreHandler.IGNORE;
|
||||
}
|
||||
|
||||
return result;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -279,8 +279,6 @@ public final class MainPanel extends JPanel implements ActionListener, TreeSelec
|
||||
|
||||
private TreePanelMode treePanelMode;
|
||||
|
||||
private AbortRetryIgnoreHandler errorHandler = new GuiAbortRetryIgnoreHandler();
|
||||
|
||||
private CancellableWorker setSourceWorker;
|
||||
|
||||
public TreeItem oldItem;
|
||||
@@ -460,7 +458,7 @@ public final class MainPanel extends JPanel implements ActionListener, TreeSelec
|
||||
|
||||
File ftemp = new File(tempDir);
|
||||
ExportDialog exd = new ExportDialog(null);
|
||||
files = exportSelection(errorHandler, tempDir, exd);
|
||||
files = exportSelection(new GuiAbortRetryIgnoreHandler(), tempDir, exd);
|
||||
files.clear();
|
||||
|
||||
File[] fs = ftemp.listFiles();
|
||||
@@ -1576,6 +1574,7 @@ public final class MainPanel extends JPanel implements ActionListener, TreeSelec
|
||||
protected Void doInBackground() throws Exception {
|
||||
Helper.freeMem();
|
||||
try {
|
||||
AbortRetryIgnoreHandler errorHandler = new GuiAbortRetryIgnoreHandler();
|
||||
if (compressed) {
|
||||
swf.exportFla(errorHandler, selfile.getAbsolutePath(), new File(swf.getFile()).getName(), ApplicationInfo.APPLICATION_NAME, ApplicationInfo.applicationVerName, ApplicationInfo.version, Configuration.parallelSpeedUp.get(), selectedVersion);
|
||||
} else {
|
||||
@@ -1699,6 +1698,7 @@ public final class MainPanel extends JPanel implements ActionListener, TreeSelec
|
||||
@Override
|
||||
public Void doInBackground() throws Exception {
|
||||
try {
|
||||
AbortRetryIgnoreHandler errorHandler = new GuiAbortRetryIgnoreHandler();
|
||||
if (onlySel) {
|
||||
exportSelection(errorHandler, selFile, export);
|
||||
} else {
|
||||
|
||||
@@ -574,3 +574,4 @@ text.align.translatex.decrease = Decrease TranslateX
|
||||
text.align.translatex.increase = Increase TranslateX
|
||||
selectPreviousTag = Select previous tag
|
||||
selectNextTag = Select next tag
|
||||
button.ignoreAll = Ignore All
|
||||
|
||||
@@ -571,3 +571,6 @@ menu.file.export.xml = SWF XML export\u00e1l\u00e1s
|
||||
#after version 4.1.1
|
||||
text.align.translatex.decrease = TranslateX cs\u00f6kkent\u00e9se
|
||||
text.align.translatex.increase = TranslateX n\u00f6vel\u00e9se
|
||||
selectPreviousTag = El\u0151z\u0151 tag kiv\u00e1laszt\u00e1sa
|
||||
selectNextTag = K\u00f6vetkez\u0151 tag kiv\u00e1laszt\u00e1sa
|
||||
button.ignoreAll = Mell\u0151z mindet
|
||||
Reference in New Issue
Block a user