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
1468dfd6
Commit
1468dfd6
authored
Sep 12, 2016
by
d8ahazard
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add CacheModule display string to title
parent
40e92721
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
13 additions
and
2 deletions
+13
-2
ReposAdapter.java
app/src/main/java/com/topjohnwu/magisk/ReposAdapter.java
+8
-1
Repo.java
app/src/main/java/com/topjohnwu/magisk/module/Repo.java
+5
-1
No files found.
app/src/main/java/com/topjohnwu/magisk/ReposAdapter.java
View file @
1468dfd6
...
...
@@ -93,8 +93,15 @@ public class ReposAdapter extends RecyclerView.Adapter<ReposAdapter.ViewHolder>
private
void
SetupViewElements
()
{
int
mPosition
=
mHolder
.
getAdapterPosition
();
String
titleString
;
if
(
repo
.
getId
()
!=
null
)
{
mHolder
.
title
.
setText
(
repo
.
getName
());
if
(
repo
.
isCacheModule
())
{
titleString
=
"[Cache] "
+
repo
.
getName
();
}
else
{
titleString
=
repo
.
getName
();
}
mHolder
.
title
.
setText
(
titleString
);
mHolder
.
versionName
.
setText
(
repo
.
getmVersion
());
mHolder
.
description
.
setText
(
repo
.
getDescription
());
String
authorString
=
this
.
context
.
getResources
().
getString
(
R
.
string
.
author
)
+
" "
+
repo
.
getmAuthor
();
...
...
app/src/main/java/com/topjohnwu/magisk/module/Repo.java
View file @
1468dfd6
...
...
@@ -31,7 +31,7 @@ public class Repo {
private
String
mDonateUrl
;
private
String
lastUpdate
;
private
Context
appContext
;
private
boolean
mIsInstalled
,
mCanUpdate
;
private
boolean
mIsInstalled
,
mCanUpdate
,
mIsCacheModule
;
public
Repo
(
String
manifestString
,
Context
context
)
{
...
...
@@ -133,6 +133,9 @@ public class Repo {
case
"donate"
:
this
.
mDonateUrl
=
props
[
1
];
break
;
case
"cacheModule"
:
this
.
mIsCacheModule
=
Boolean
.
valueOf
(
props
[
1
]);
break
;
case
"support"
:
this
.
mSupportUrl
=
props
[
1
];
break
;
...
...
@@ -261,5 +264,6 @@ public class Repo {
public
boolean
isInstalled
()
{
return
mIsInstalled
;
}
public
boolean
canUpdate
()
{
return
mCanUpdate
;
}
public
boolean
isCacheModule
()
{
return
mIsCacheModule
;
}
}
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