mirror of
https://github.com/recloudstream/cloudstream.git
synced 2024-08-15 01:53:11 +00:00
splash screen
This commit is contained in:
parent
a0ad101605
commit
9455fc528f
4 changed files with 22 additions and 5 deletions
|
@ -176,6 +176,11 @@ class MainActivity : AppCompatActivity(), ColorPickerDialogListener {
|
|||
}
|
||||
|
||||
override fun onCreate(savedInstanceState: Bundle?) {
|
||||
theme.applyStyle(
|
||||
R.style.LoadedStyle,
|
||||
true
|
||||
) // THEME IS SET BEFORE VIEW IS CREATED TO APPLY THE THEME TO THE MAIN VIEW
|
||||
|
||||
super.onCreate(savedInstanceState)
|
||||
|
||||
window.setSoftInputMode(WindowManager.LayoutParams.SOFT_INPUT_STATE_ALWAYS_HIDDEN)
|
||||
|
|
|
@ -148,7 +148,7 @@ class WatchCartoonOnlineProvider : MainAPI() {
|
|||
val start = text.indexOf("itemprop=\"embedURL")
|
||||
val foundJS = Regex("<script>(.*?)</script>").find(text, start)?.groupValues?.get(1)
|
||||
?.replace("document.write", "var returnValue = ")
|
||||
println("JS: $foundJS")
|
||||
|
||||
val rhino = Context.enter()
|
||||
rhino.initStandardObjects()
|
||||
rhino.optimizationLevel = -1
|
||||
|
@ -191,7 +191,7 @@ class WatchCartoonOnlineProvider : MainAPI() {
|
|||
"cookie" to "countrytabs=0"
|
||||
)
|
||||
)
|
||||
println("LINK:" + linkResponse.text)
|
||||
|
||||
val link = mapper.readValue<LinkResponse>(linkResponse.text)
|
||||
|
||||
val hdLink = "${link.server}/getvid?evid=${link.hd}"
|
||||
|
|
8
app/src/main/res/drawable/splash_background.xml
Normal file
8
app/src/main/res/drawable/splash_background.xml
Normal file
|
@ -0,0 +1,8 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<layer-list xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<item>
|
||||
<color android:color="?attr/bitDarkerGrayBackground"/>
|
||||
</item>
|
||||
<item android:width="150dp" android:height="150dp" android:gravity="center" android:drawable="@drawable/ic_launcher_foreground">
|
||||
</item>
|
||||
</layer-list>
|
|
@ -5,9 +5,10 @@
|
|||
<item name="colorPrimary">@color/colorPrimary</item>
|
||||
<item name="colorPrimaryDark">@color/colorPrimaryDark</item>
|
||||
<item name="colorAccent">@color/colorAccent</item>
|
||||
<!-- <item name="android:windowBackground">@drawable/splash_background</item>-->
|
||||
<item name="android:windowBackground">@drawable/splash_background</item>
|
||||
<item name="android:navigationBarColor">?attr/bitDarkerGrayBackground</item>
|
||||
|
||||
<item name="android:navigationBarColor">@color/darkBackground</item>
|
||||
<!--<item name="android:navigationBarColor">@color/darkBackground</item>-->
|
||||
<item name="android:statusBarColor">@color/grayBackground</item>
|
||||
|
||||
<item name="android:textColorHint">@color/searchColor</item>
|
||||
|
@ -45,7 +46,10 @@
|
|||
<item name="iconColor">@color/iconColor</item>
|
||||
<item name="white">#FFF</item>
|
||||
</style>
|
||||
|
||||
<style name="LoadedStyle">
|
||||
<item name="android:navigationBarColor">?attr/darkBackground</item>
|
||||
<item name="android:windowBackground">?attr/bitDarkerGrayBackground</item>
|
||||
</style>
|
||||
<style name="AppSearchViewStyle"
|
||||
parent="Theme.MaterialComponents.NoActionBar">
|
||||
<item name="android:searchIcon">@drawable/search_icon</item>
|
||||
|
|
Loading…
Reference in a new issue