mirror of
https://git.huckle.dev/Huckles-Minecraft-Archive/jpexs-decompiler.git
synced 2026-09-23 09:42:28 +00:00
[#1343] AS 1/2 direct editation critical bug
This commit is contained in:
@@ -9,6 +9,7 @@ All notable changes to this project will be documented in this file.
|
|||||||
|
|
||||||
### Fixed
|
### Fixed
|
||||||
- [#1327] P-code editing: error message and syntax highlighting fixed when instruction name contains upper cased letter
|
- [#1327] P-code editing: error message and syntax highlighting fixed when instruction name contains upper cased letter
|
||||||
|
- [#1343] AS 1/2 direct editation critical bug
|
||||||
|
|
||||||
## [10.0.0] - 2016-12-24
|
## [10.0.0] - 2016-12-24
|
||||||
### Added
|
### Added
|
||||||
|
|||||||
@@ -901,24 +901,22 @@ public class ActionPanel extends JPanel implements SearchListener<ActionSearchRe
|
|||||||
public void setDecompiledEditMode(boolean val) {
|
public void setDecompiledEditMode(boolean val) {
|
||||||
View.checkAccess();
|
View.checkAccess();
|
||||||
|
|
||||||
if (lastASM == null) {
|
if (src != null) {
|
||||||
return;
|
int lastLine = decompiledEditor.getLine();
|
||||||
}
|
int prefLines = src.getPrefixLineCount();
|
||||||
|
if (val) {
|
||||||
int lastLine = decompiledEditor.getLine();
|
String newText = src.removePrefixAndSuffix(lastDecompiled.text);
|
||||||
int prefLines = lastASM.getPrefixLineCount();
|
setDecompiledText(src.getScriptName(), newText);
|
||||||
if (val) {
|
if (lastLine > -1) {
|
||||||
String newText = lastASM.removePrefixAndSuffix(lastDecompiled.text);
|
if (lastLine - prefLines >= 0) {
|
||||||
setDecompiledText(lastASM.getScriptName(), newText);
|
decompiledEditor.gotoLine(lastLine - prefLines + 1);
|
||||||
if (lastLine > -1) {
|
}
|
||||||
if (lastLine - prefLines >= 0) {
|
}
|
||||||
decompiledEditor.gotoLine(lastLine - prefLines + 1);
|
} else {
|
||||||
|
setDecompiledText(src.getScriptName(), lastDecompiled.text);
|
||||||
|
if (lastLine > -1) {
|
||||||
|
decompiledEditor.gotoLine(lastLine + prefLines + 1);
|
||||||
}
|
}
|
||||||
}
|
|
||||||
} else {
|
|
||||||
setDecompiledText(lastASM.getScriptName(), lastDecompiled.text);
|
|
||||||
if (lastLine > -1) {
|
|
||||||
decompiledEditor.gotoLine(lastLine + prefLines + 1);
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user