stuff (#567)
* Add blur to dialog for devices that support it * More adjustable seek time * Bump exo player
This commit is contained in:
parent
6fa2f11db2
commit
6fd3515d2c
3 changed files with 15 additions and 7 deletions
|
@ -113,7 +113,7 @@ dependencies {
|
||||||
implementation 'jp.wasabeef:glide-transformations:4.3.0'
|
implementation 'jp.wasabeef:glide-transformations:4.3.0'
|
||||||
|
|
||||||
// Exoplayer
|
// Exoplayer
|
||||||
ext.exo_version = '1.5.0'
|
ext.exo_version = '1.5.1'
|
||||||
implementation "androidx.media3:media3-exoplayer:$exo_version"
|
implementation "androidx.media3:media3-exoplayer:$exo_version"
|
||||||
implementation "androidx.media3:media3-ui:$exo_version"
|
implementation "androidx.media3:media3-ui:$exo_version"
|
||||||
implementation "androidx.media3:media3-exoplayer-hls:$exo_version"
|
implementation "androidx.media3:media3-exoplayer-hls:$exo_version"
|
||||||
|
@ -124,7 +124,7 @@ dependencies {
|
||||||
implementation "androidx.media3:media3-cast:$exo_version"
|
implementation "androidx.media3:media3-cast:$exo_version"
|
||||||
implementation "androidx.mediarouter:mediarouter:1.7.0"
|
implementation "androidx.mediarouter:mediarouter:1.7.0"
|
||||||
// Media3 extension
|
// Media3 extension
|
||||||
implementation "com.github.anilbeesetti.nextlib:nextlib-media3ext:0.8.3"
|
implementation "com.github.anilbeesetti.nextlib:nextlib-media3ext:0.8.4"
|
||||||
|
|
||||||
// UI
|
// UI
|
||||||
implementation 'com.google.android.material:material:1.12.0'
|
implementation 'com.google.android.material:material:1.12.0'
|
||||||
|
|
|
@ -3,6 +3,8 @@ package ani.dantotsu.util
|
||||||
import android.app.Activity
|
import android.app.Activity
|
||||||
import android.app.AlertDialog
|
import android.app.AlertDialog
|
||||||
import android.content.Context
|
import android.content.Context
|
||||||
|
import android.os.Build
|
||||||
|
import android.view.WindowManager
|
||||||
import android.view.View
|
import android.view.View
|
||||||
import ani.dantotsu.R
|
import ani.dantotsu.R
|
||||||
|
|
||||||
|
@ -205,8 +207,14 @@ class AlertDialogBuilder(private val context: Context) {
|
||||||
onShow?.invoke()
|
onShow?.invoke()
|
||||||
}
|
}
|
||||||
dialog.window?.apply {
|
dialog.window?.apply {
|
||||||
setDimAmount(0.8f)
|
setDimAmount(0.5f)
|
||||||
attributes.windowAnimations = android.R.style.Animation_Dialog
|
attributes.windowAnimations = android.R.style.Animation_Dialog
|
||||||
|
if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.S) {
|
||||||
|
val params = attributes
|
||||||
|
params.flags = params.flags or WindowManager.LayoutParams.FLAG_BLUR_BEHIND
|
||||||
|
params.setBlurBehindRadius(20)
|
||||||
|
attributes = params
|
||||||
|
}
|
||||||
}
|
}
|
||||||
dialog.show()
|
dialog.show()
|
||||||
}
|
}
|
||||||
|
|
|
@ -1102,10 +1102,10 @@
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:layout_marginHorizontal="32dp"
|
android:layout_marginHorizontal="32dp"
|
||||||
android:stepSize="5.0"
|
android:stepSize="1.0"
|
||||||
android:value="15.0"
|
android:value="10.0"
|
||||||
android:valueFrom="5.0"
|
android:valueFrom="1.0"
|
||||||
android:valueTo="45.0"
|
android:valueTo="50.0"
|
||||||
app:labelBehavior="floating"
|
app:labelBehavior="floating"
|
||||||
app:labelStyle="@style/fontTooltip"
|
app:labelStyle="@style/fontTooltip"
|
||||||
app:thumbColor="?attr/colorSecondary"
|
app:thumbColor="?attr/colorSecondary"
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue