Initial version based on previous work. (Version alpha 7)

This commit is contained in:
Jindra Pet��k
2010-09-04 13:57:22 +02:00
commit a34ee7364c
1147 changed files with 84884 additions and 0 deletions
@@ -0,0 +1,41 @@
/*
* Copyright (c) 2010. JPEXS
*/
package com.jpexs.asdec.abc.avm2.treemodel;
import com.jpexs.asdec.abc.avm2.ConstantPool;
import com.jpexs.asdec.abc.avm2.instructions.AVM2Instruction;
import com.jpexs.asdec.abc.avm2.instructions.InstructionDefinition;
public class LocalRegTreeItem extends TreeItem {
public int regIndex;
public TreeItem computedValue;
public LocalRegTreeItem(AVM2Instruction instruction, int regIndex, TreeItem computedValue) {
super(instruction, PRECEDENCE_PRIMARY);
this.regIndex = regIndex;
if (computedValue == null) {
computedValue = new UndefinedTreeItem(instruction);
}
this.computedValue = computedValue;
}
@Override
public String toString(ConstantPool constants) {
return hilight(InstructionDefinition.localRegName(regIndex));
}
@Override
public boolean isFalse() {
return computedValue.isFalse();
}
@Override
public boolean isTrue() {
return computedValue.isTrue();
}
}