mirror of
https://git.huckle.dev/Huckles-Minecraft-Archive/jpexs-decompiler.git
synced 2026-05-30 14:57:26 +00:00
Merge origin/master
This commit is contained in:
@@ -16,6 +16,7 @@
|
||||
*/
|
||||
package com.jpexs.decompiler.graph;
|
||||
|
||||
import com.jpexs.decompiler.flash.IdentifiersDeobfuscation;
|
||||
import com.jpexs.decompiler.flash.SourceGeneratorLocalData;
|
||||
import com.jpexs.decompiler.flash.abc.ABC;
|
||||
import com.jpexs.decompiler.flash.abc.types.InstanceInfo;
|
||||
@@ -77,13 +78,13 @@ public class TypeItem extends GraphTargetItem {
|
||||
@Override
|
||||
public GraphTextWriter appendTo(GraphTextWriter writer, LocalData localData) throws InterruptedException {
|
||||
if (localData.fullyQualifiedNames.contains(fullTypeName)) {
|
||||
writer.hilightSpecial(fullTypeName,"typename",fullTypeName);
|
||||
writer.hilightSpecial(IdentifiersDeobfuscation.printNamespace(localData.constantsAvm2!=null, fullTypeName),"typename",fullTypeName);
|
||||
} else {
|
||||
String simpleName = fullTypeName;
|
||||
if (simpleName.contains(".")) {
|
||||
simpleName = simpleName.substring(simpleName.lastIndexOf('.') + 1);
|
||||
}
|
||||
writer.hilightSpecial(simpleName,"typename",fullTypeName);
|
||||
writer.hilightSpecial(IdentifiersDeobfuscation.printNamespace(localData.constantsAvm2!=null, simpleName),"typename",fullTypeName);
|
||||
}
|
||||
|
||||
return writer;
|
||||
|
||||
@@ -90,7 +90,7 @@ public class Cache<K, V> {
|
||||
}
|
||||
}
|
||||
|
||||
public boolean contains(K key) {
|
||||
public synchronized boolean contains(K key) {
|
||||
if (storageType == STORAGE_FILES) {
|
||||
return cacheFiles.containsKey(key);
|
||||
} else if (storageType == STORAGE_MEMORY) {
|
||||
@@ -99,7 +99,7 @@ public class Cache<K, V> {
|
||||
return false;
|
||||
}
|
||||
|
||||
public void clear() {
|
||||
public synchronized void clear() {
|
||||
cacheMemory.clear();
|
||||
for (File f : cacheFiles.values()) {
|
||||
f.delete();
|
||||
@@ -107,7 +107,7 @@ public class Cache<K, V> {
|
||||
cacheFiles.clear();
|
||||
}
|
||||
|
||||
public void remove(K key) {
|
||||
public synchronized void remove(K key) {
|
||||
if (storageType == STORAGE_FILES) {
|
||||
if (cacheFiles.containsKey(key)) {
|
||||
File f = cacheFiles.get(key);
|
||||
@@ -122,7 +122,7 @@ public class Cache<K, V> {
|
||||
|
||||
}
|
||||
|
||||
public V get(K key) {
|
||||
public synchronized V get(K key) {
|
||||
if (storageType == STORAGE_FILES) {
|
||||
if (!cacheFiles.containsKey(key)) {
|
||||
return null;
|
||||
@@ -146,7 +146,7 @@ public class Cache<K, V> {
|
||||
return null;
|
||||
}
|
||||
|
||||
public void put(K key, V value) {
|
||||
public synchronized void put(K key, V value) {
|
||||
if (storageType == STORAGE_FILES) {
|
||||
File temp = null;
|
||||
try {
|
||||
|
||||
Reference in New Issue
Block a user