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
1ffe9bd8
Commit
1ffe9bd8
authored
Nov 30, 2020
by
vvb2060
Committed by
topjohnwu
Dec 09, 2020
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix update channel without description on release build
parent
0c28b232
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
5 deletions
+7
-5
SettingsItems.kt
...in/java/com/topjohnwu/magisk/ui/settings/SettingsItems.kt
+7
-5
No files found.
app/src/main/java/com/topjohnwu/magisk/ui/settings/SettingsItems.kt
View file @
1ffe9bd8
...
...
@@ -20,6 +20,7 @@ import com.topjohnwu.magisk.databinding.DialogSettingsAppNameBinding
import
com.topjohnwu.magisk.databinding.DialogSettingsDownloadPathBinding
import
com.topjohnwu.magisk.databinding.DialogSettingsUpdateChannelBinding
import
com.topjohnwu.magisk.ktx.get
import
com.topjohnwu.magisk.utils.TransitiveText
import
com.topjohnwu.magisk.utils.Utils
import
com.topjohnwu.magisk.utils.asTransitive
import
com.topjohnwu.magisk.utils.set
...
...
@@ -143,11 +144,12 @@ object UpdateChannel : BaseSettingsItem.Selector() {
set
(
value
)
=
setV
(
value
,
field
,
{
field
=
it
})
{
Config
.
updateChannel
=
it
}
override
val
title
=
R
.
string
.
settings_update_channel_title
.
asTransitive
()
override
val
entries
get
()
=
resources
.
getStringArray
(
R
.
array
.
update_channel
).
let
{
override
val
entries
:
Array
<
String
>
=
resources
.
getStringArray
(
R
.
array
.
update_channel
).
let
{
if
(
BuildConfig
.
DEBUG
)
it
.
toMutableList
().
apply
{
add
(
"Canary"
)
}.
toTypedArray
()
else
it
}
override
val
entryValRes
=
R
.
array
.
value_array
override
val
description
get
()
=
entries
.
getOrNull
(
value
)
?.
asTransitive
()
?:
TransitiveText
.
String
(
if
(
value
==
-
1
)
entries
[
0
]
else
"Canary"
)
}
object
UpdateChannelUrl
:
BaseSettingsItem
.
Input
()
{
...
...
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