mirror of
https://github.com/recloudstream/cloudstream.git
synced 2024-08-15 01:53:11 +00:00
Merge remote-tracking branch 'origin/master'
This commit is contained in:
commit
e14b2d24c8
6 changed files with 36 additions and 7 deletions
2
.github/ISSUE_TEMPLATE/application-bug.yml
vendored
2
.github/ISSUE_TEMPLATE/application-bug.yml
vendored
|
@ -75,7 +75,7 @@ body:
|
||||||
required: true
|
required: true
|
||||||
- label: I have written a short but informative title.
|
- label: I have written a short but informative title.
|
||||||
required: true
|
required: true
|
||||||
- label: I have updated the app to pre-release version **[Latest](https://github.com/rereleased/release/releases)**.
|
- label: I have updated the app to pre-release version **[Latest](https://github.com/recloudstream/cloudstream/releases)**.
|
||||||
required: true
|
required: true
|
||||||
- label: If related to a provider, I have checked the site and it works, but not the app.
|
- label: If related to a provider, I have checked the site and it works, but not the app.
|
||||||
required: true
|
required: true
|
||||||
|
|
|
@ -76,6 +76,15 @@
|
||||||
<category android:name="android.intent.category.LEANBACK_LAUNCHER" />
|
<category android:name="android.intent.category.LEANBACK_LAUNCHER" />
|
||||||
</intent-filter>
|
</intent-filter>
|
||||||
|
|
||||||
|
<intent-filter android:exported="true">
|
||||||
|
<action android:name="android.intent.action.VIEW" />
|
||||||
|
|
||||||
|
<category android:name="android.intent.category.BROWSABLE" />
|
||||||
|
<category android:name="android.intent.category.DEFAULT" />
|
||||||
|
|
||||||
|
<data android:scheme="https" android:host="cs.repo" android:pathPrefix="/"/>
|
||||||
|
</intent-filter>
|
||||||
|
|
||||||
<intent-filter>
|
<intent-filter>
|
||||||
<action android:name="android.intent.action.VIEW" />
|
<action android:name="android.intent.action.VIEW" />
|
||||||
|
|
||||||
|
|
|
@ -253,8 +253,6 @@ object APIHolder {
|
||||||
3 = restricted, must donate 30 benenes to use
|
3 = restricted, must donate 30 benenes to use
|
||||||
*/
|
*/
|
||||||
const val PROVIDER_STATUS_KEY = "PROVIDER_STATUS_KEY"
|
const val PROVIDER_STATUS_KEY = "PROVIDER_STATUS_KEY"
|
||||||
const val PROVIDER_STATUS_URL =
|
|
||||||
"https://raw.githubusercontent.com/reduplicated/Cloudstream/master/docs/providers.json"
|
|
||||||
const val PROVIDER_STATUS_BETA_ONLY = 3
|
const val PROVIDER_STATUS_BETA_ONLY = 3
|
||||||
const val PROVIDER_STATUS_SLOW = 2
|
const val PROVIDER_STATUS_SLOW = 2
|
||||||
const val PROVIDER_STATUS_OK = 1
|
const val PROVIDER_STATUS_OK = 1
|
||||||
|
|
|
@ -52,6 +52,7 @@ import com.lagradost.cloudstream3.ui.result.ResultFragment
|
||||||
import com.lagradost.cloudstream3.ui.search.SearchResultBuilder
|
import com.lagradost.cloudstream3.ui.search.SearchResultBuilder
|
||||||
import com.lagradost.cloudstream3.ui.settings.SettingsFragment.Companion.isEmulatorSettings
|
import com.lagradost.cloudstream3.ui.settings.SettingsFragment.Companion.isEmulatorSettings
|
||||||
import com.lagradost.cloudstream3.ui.settings.SettingsFragment.Companion.isTvSettings
|
import com.lagradost.cloudstream3.ui.settings.SettingsFragment.Companion.isTvSettings
|
||||||
|
import com.lagradost.cloudstream3.ui.settings.SettingsGeneral
|
||||||
import com.lagradost.cloudstream3.ui.setup.HAS_DONE_SETUP_KEY
|
import com.lagradost.cloudstream3.ui.setup.HAS_DONE_SETUP_KEY
|
||||||
import com.lagradost.cloudstream3.utils.AppUtils.isCastApiAvailable
|
import com.lagradost.cloudstream3.utils.AppUtils.isCastApiAvailable
|
||||||
import com.lagradost.cloudstream3.utils.AppUtils.loadCache
|
import com.lagradost.cloudstream3.utils.AppUtils.loadCache
|
||||||
|
@ -72,6 +73,7 @@ import com.lagradost.cloudstream3.utils.UIHelper.getResourceColor
|
||||||
import com.lagradost.cloudstream3.utils.UIHelper.hideKeyboard
|
import com.lagradost.cloudstream3.utils.UIHelper.hideKeyboard
|
||||||
import com.lagradost.cloudstream3.utils.UIHelper.navigate
|
import com.lagradost.cloudstream3.utils.UIHelper.navigate
|
||||||
import com.lagradost.cloudstream3.utils.UIHelper.requestRW
|
import com.lagradost.cloudstream3.utils.UIHelper.requestRW
|
||||||
|
import com.lagradost.cloudstream3.utils.USER_PROVIDER_API
|
||||||
import com.lagradost.nicehttp.Requests
|
import com.lagradost.nicehttp.Requests
|
||||||
import com.lagradost.nicehttp.ResponseParser
|
import com.lagradost.nicehttp.ResponseParser
|
||||||
import kotlinx.android.synthetic.main.activity_main.*
|
import kotlinx.android.synthetic.main.activity_main.*
|
||||||
|
@ -456,6 +458,26 @@ class MainActivity : AppCompatActivity(), ColorPickerDialogListener {
|
||||||
initAll()
|
initAll()
|
||||||
apis = allProviders
|
apis = allProviders
|
||||||
|
|
||||||
|
try {
|
||||||
|
getKey<Array<SettingsGeneral.CustomSite>>(USER_PROVIDER_API)?.let { list ->
|
||||||
|
list.forEach { custom ->
|
||||||
|
allProviders.firstOrNull { it.javaClass.simpleName == custom.parentJavaClass }
|
||||||
|
?.let {
|
||||||
|
allProviders.add(it.javaClass.newInstance().apply {
|
||||||
|
name = custom.name
|
||||||
|
lang = custom.lang
|
||||||
|
mainUrl = custom.url.trimEnd('/')
|
||||||
|
canBeOverridden = false
|
||||||
|
})
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
apis = allProviders
|
||||||
|
APIHolder.apiMap = null
|
||||||
|
} catch (e: Exception) {
|
||||||
|
logError(e)
|
||||||
|
}
|
||||||
|
|
||||||
loadThemes(this)
|
loadThemes(this)
|
||||||
updateLocale()
|
updateLocale()
|
||||||
super.onCreate(savedInstanceState)
|
super.onCreate(savedInstanceState)
|
||||||
|
|
|
@ -31,8 +31,8 @@ import kotlin.concurrent.thread
|
||||||
|
|
||||||
class InAppUpdater {
|
class InAppUpdater {
|
||||||
companion object {
|
companion object {
|
||||||
const val GITHUB_USER_NAME = "rereleased"
|
const val GITHUB_USER_NAME = "recloudstream"
|
||||||
const val GITHUB_REPO = "release"
|
const val GITHUB_REPO = "cloudstream"
|
||||||
|
|
||||||
// === IN APP UPDATER ===
|
// === IN APP UPDATER ===
|
||||||
data class GithubAsset(
|
data class GithubAsset(
|
||||||
|
|
|
@ -26,10 +26,10 @@
|
||||||
<Preference
|
<Preference
|
||||||
android:title="@string/github"
|
android:title="@string/github"
|
||||||
android:icon="@drawable/ic_github_logo"
|
android:icon="@drawable/ic_github_logo"
|
||||||
app:summary="https://github.com/rereleased/release/releases">
|
app:summary="https://github.com/recloudstream/cloudstream">
|
||||||
<intent
|
<intent
|
||||||
android:action="android.intent.action.VIEW"
|
android:action="android.intent.action.VIEW"
|
||||||
android:data="https://github.com/rereleased/release/releases" />
|
android:data="https://github.com/recloudstream/cloudstream" />
|
||||||
</Preference>
|
</Preference>
|
||||||
|
|
||||||
<Preference
|
<Preference
|
||||||
|
|
Loading…
Reference in a new issue