mirror of
https://github.com/YTVanced/VancedManager
synced 2024-11-25 20:55:12 +00:00
added checks for dev options unlock
This commit is contained in:
parent
87e038a2e6
commit
dab09b1ce7
3 changed files with 8 additions and 20 deletions
13
.github/workflows/android.yml
vendored
13
.github/workflows/android.yml
vendored
|
@ -4,13 +4,9 @@ on:
|
||||||
push:
|
push:
|
||||||
branches:
|
branches:
|
||||||
- master
|
- master
|
||||||
tags:
|
|
||||||
- '*'
|
|
||||||
pull_request:
|
pull_request:
|
||||||
branches:
|
branches:
|
||||||
- master
|
- master
|
||||||
tags:
|
|
||||||
- '*'
|
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
build:
|
build:
|
||||||
|
@ -46,15 +42,6 @@ jobs:
|
||||||
name: 'Vanced-Manager'
|
name: 'Vanced-Manager'
|
||||||
path: ${{ steps.sign-app.outputs.signedReleaseFile }}
|
path: ${{ steps.sign-app.outputs.signedReleaseFile }}
|
||||||
|
|
||||||
- name: Upload to GitHub releases
|
|
||||||
uses: svenstaro/upload-release-action@v1-release
|
|
||||||
with:
|
|
||||||
repo_token: ${{ secrets.GITHUB_TOKEN }}
|
|
||||||
file: ${{ steps.sign-app.outputs.signedReleaseFile }}
|
|
||||||
asset_name: release.apk
|
|
||||||
tag: ${{ github.ref }}
|
|
||||||
overwrite: true
|
|
||||||
|
|
||||||
- name: Upload to Discord
|
- name: Upload to Discord
|
||||||
uses: sinshutu/upload-to-discord@master
|
uses: sinshutu/upload-to-discord@master
|
||||||
env:
|
env:
|
||||||
|
|
|
@ -32,12 +32,13 @@ open class About : BaseFragment() {
|
||||||
}
|
}
|
||||||
|
|
||||||
if (count == 5) {
|
if (count == 5) {
|
||||||
Toast.makeText(requireContext(), "Dev options unlocked!", Toast.LENGTH_SHORT).show()
|
val prefs = PreferenceManager.getDefaultSharedPreferences(requireContext())
|
||||||
val prefs =
|
val devSettings = prefs.getBoolean("devSettings", false)
|
||||||
PreferenceManager.getDefaultSharedPreferences(
|
if (!devSettings) {
|
||||||
requireContext()
|
Toast.makeText(requireContext(), "Dev options unlocked!", Toast.LENGTH_SHORT).show()
|
||||||
)
|
prefs.edit().putBoolean("devSettings", true).apply()
|
||||||
prefs.edit().putBoolean("devSettings", true).apply()
|
} else Toast.makeText(requireContext(), "Dev options already unlocked", Toast.LENGTH_SHORT).show()
|
||||||
|
|
||||||
}
|
}
|
||||||
return@setOnTouchListener true
|
return@setOnTouchListener true
|
||||||
}
|
}
|
||||||
|
|
|
@ -49,7 +49,7 @@ class UpdateCheckFragment : DialogFragment() {
|
||||||
|
|
||||||
updatebtn.setOnClickListener {
|
updatebtn.setOnClickListener {
|
||||||
val url =
|
val url =
|
||||||
"https://github.com/X1nto/VancedInstaller/releases/latest/download/release.apk"
|
"https://github.com/X1nto/VancedFiles/blob/master/release.apk"
|
||||||
url.download()
|
url.download()
|
||||||
.observeOn(AndroidSchedulers.mainThread())
|
.observeOn(AndroidSchedulers.mainThread())
|
||||||
.subscribeBy(
|
.subscribeBy(
|
||||||
|
|
Loading…
Reference in a new issue