Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in
Toggle navigation
J
jadx
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
open-source
jadx
Commits
c416f77e
Commit
c416f77e
authored
Nov 27, 2013
by
Skylot
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
core: fix android specific class handler
parent
fde431d1
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
9 additions
and
16 deletions
+9
-16
InsnGen.java
jadx-core/src/main/java/jadx/core/codegen/InsnGen.java
+9
-6
RegionGen.java
jadx-core/src/main/java/jadx/core/codegen/RegionGen.java
+0
-10
No files found.
jadx-core/src/main/java/jadx/core/codegen/InsnGen.java
View file @
c416f77e
...
...
@@ -144,15 +144,18 @@ public class InsnGen {
return
arg
(
arg
)
+
"."
+
name
;
}
pr
ivate
String
sfield
(
FieldInfo
field
)
{
pr
otected
String
sfield
(
FieldInfo
field
)
{
String
thisClass
=
mth
.
getParentClass
().
getFullName
();
if
(
thisClass
.
startsWith
(
field
.
getDeclClass
().
getFullName
()))
{
ClassInfo
declClass
=
field
.
getDeclClass
();
if
(
thisClass
.
startsWith
(
declClass
.
getFullName
()))
{
return
field
.
getName
();
}
else
if
(
field
.
getDeclClass
().
getFullName
().
startsWith
(
mth
.
getParentClass
().
getPackage
()
+
".R"
))
{
return
field
.
getDeclClass
().
getNameWithoutPackage
()
+
'.'
+
field
.
getName
();
}
else
{
return
useClass
(
field
.
getDeclClass
())
+
'.'
+
field
.
getName
();
}
// Android specific resources class handler
ClassInfo
parentClass
=
declClass
.
getParentClass
();
if
(
parentClass
!=
null
&&
parentClass
.
getShortName
().
equals
(
"R"
))
{
return
useClass
(
parentClass
)
+
"."
+
declClass
.
getShortName
()
+
"."
+
field
.
getName
();
}
return
useClass
(
declClass
)
+
'.'
+
field
.
getName
();
}
private
void
fieldPut
(
IndexInsnNode
insn
)
{
...
...
jadx-core/src/main/java/jadx/core/codegen/RegionGen.java
View file @
c416f77e
...
...
@@ -308,14 +308,4 @@ public class RegionGen extends InsnGen {
makeRegionIndent
(
code
,
region
);
}
}
// FIXME: !!code from InsnGen.sfield
private
String
sfield
(
FieldInfo
field
)
{
String
thisClass
=
mth
.
getParentClass
().
getFullName
();
if
(
thisClass
.
startsWith
(
field
.
getDeclClass
().
getFullName
()))
{
return
field
.
getName
();
}
else
{
return
useClass
(
field
.
getDeclClass
())
+
'.'
+
field
.
getName
();
}
}
}
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment