mirror of
https://github.com/revanced/smali.git
synced 2025-05-03 16:14:29 +02:00
Rename DexReader.skipBytes to moveRelative, and add setOffset
This commit is contained in:
parent
2e34c4499c
commit
68f69b899f
@ -46,6 +46,7 @@ public class DexReader {
|
||||
|
||||
@Nonnull public DexBuffer getDexBuffer() { return dexBuf; }
|
||||
public int getOffset() { return offset; }
|
||||
public void setOffset(int offset) { this.offset = offset; }
|
||||
|
||||
public int getStringIdItemOffset(int stringIndex) { return dexBuf.getStringIdItemOffset(stringIndex); }
|
||||
public int getTypeIdItemOffset(int typeIndex) { return dexBuf.getTypeIdItemOffset(typeIndex); }
|
||||
@ -229,7 +230,7 @@ public class DexReader {
|
||||
}
|
||||
|
||||
public void skipByte() { offset++; }
|
||||
public void skipBytes(int i) { offset += i; }
|
||||
public void moveRelative(int i) { offset += i; }
|
||||
|
||||
public int readSmallUint(int offset) { return dexBuf.readSmallUint(offset); }
|
||||
public int readUshort(int offset) { return dexBuf.readUshort(offset); }
|
||||
|
@ -131,7 +131,7 @@ public abstract class DexBackedEncodedValue {
|
||||
case ValueType.METHOD:
|
||||
case ValueType.ENUM:
|
||||
int valueArg = b >>> 5;
|
||||
reader.skipBytes(valueArg+1);
|
||||
reader.moveRelative(valueArg+1);
|
||||
break;
|
||||
case ValueType.ARRAY:
|
||||
DexBackedArrayEncodedValue.skipFrom(reader);
|
||||
|
Loading…
x
Reference in New Issue
Block a user