Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in / Register
Toggle navigation
M
Magisk
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
Administrator
Magisk
Commits
321d11c2
Commit
321d11c2
authored
Oct 28, 2019
by
topjohnwu
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Move Mapping class
parent
ee447bc4
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
12 additions
and
9 deletions
+12
-9
DelegateApplication.java
...c/main/java/com/topjohnwu/magisk/DelegateApplication.java
+1
-0
DelegateComponentFactory.java
...n/java/com/topjohnwu/magisk/DelegateComponentFactory.java
+1
-0
Mapping.java
...src/main/java/com/topjohnwu/magisk/obfuscate/Mapping.java
+10
-9
No files found.
stub/src/main/java/com/topjohnwu/magisk/DelegateApplication.java
View file @
321d11c2
...
...
@@ -9,6 +9,7 @@ import android.content.res.Configuration;
import
android.os.Build
;
import
android.util.Log
;
import
com.topjohnwu.magisk.obfuscate.Mapping
;
import
com.topjohnwu.magisk.utils.DynamicClassLoader
;
import
java.io.File
;
...
...
stub/src/main/java/com/topjohnwu/magisk/DelegateComponentFactory.java
View file @
321d11c2
...
...
@@ -14,6 +14,7 @@ import com.topjohnwu.magisk.dummy.DummyActivity;
import
com.topjohnwu.magisk.dummy.DummyProvider
;
import
com.topjohnwu.magisk.dummy.DummyReceiver
;
import
com.topjohnwu.magisk.dummy.DummyService
;
import
com.topjohnwu.magisk.obfuscate.Mapping
;
import
static
com
.
topjohnwu
.
magisk
.
DownloadActivity
.
TAG
;
...
...
stub/src/main/java/com/topjohnwu/magisk/Mapping.java
→
stub/src/main/java/com/topjohnwu/magisk/
obfuscate/
Mapping.java
View file @
321d11c2
package
com
.
topjohnwu
.
magisk
;
package
com
.
topjohnwu
.
magisk
.
obfuscate
;
import
java.util.HashMap
;
import
java.util.Map
;
import
static
com
.
topjohnwu
.
magisk
.
DynAPK
.*;
import
static
com
.
topjohnwu
.
magisk
.
R
.
drawable
.*;
class
Mapping
{
public
class
Mapping
{
private
static
Map
<
String
,
String
>
map
=
new
HashMap
<>();
// This mapping will be sent into the guest app
static
Data
data
=
new
Data
();
public
static
Data
data
=
new
Data
();
static
{
map
.
put
(
a
.
z
.
class
.
getName
(),
"a.c"
);
...
...
@@ -25,15 +26,15 @@ class Mapping {
data
.
componentMap
.
put
(
e
.
getValue
(),
e
.
getKey
());
}
int
[]
res
=
new
int
[
5
];
res
[
NOTIFICATION
]
=
R
.
drawable
.
ic_magisk_outline
;
res
[
SUPERUSER
]
=
R
.
drawable
.
sc_superuser
;
res
[
MAGISKHIDE
]
=
R
.
drawable
.
sc_magiskhide
;
res
[
DOWNLOAD
]
=
R
.
drawable
.
sc_cloud_download
;
res
[
MODULES
]
=
R
.
drawable
.
sc_extension
;
res
[
NOTIFICATION
]
=
ic_magisk_outline
;
res
[
SUPERUSER
]
=
sc_superuser
;
res
[
MAGISKHIDE
]
=
sc_magiskhide
;
res
[
DOWNLOAD
]
=
sc_cloud_download
;
res
[
MODULES
]
=
sc_extension
;
data
.
resourceMap
=
res
;
}
static
String
get
(
String
name
)
{
public
static
String
get
(
String
name
)
{
String
n
=
map
.
get
(
name
);
return
n
!=
null
?
n
:
name
;
}
...
...
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