added video download started toast

This commit is contained in:
David Kaspar 2024-12-30 13:56:39 +01:00
parent 1231a1483f
commit ee20508e4b
2 changed files with 13 additions and 4 deletions

View File

@ -28,6 +28,7 @@ import android.net.Uri
import android.os.Build
import android.util.Log
import android.view.View
import android.widget.Toast
import androidx.annotation.OptIn
import androidx.compose.animation.AnimatedVisibility
import androidx.compose.animation.core.LinearEasing
@ -1189,9 +1190,18 @@ fun SaveButton(onSaveClick: (localContext: Context) -> Unit) {
onSaveClick(localContext)
}
}
val scope = rememberCoroutineScope()
IconButton(
onClick = {
scope.launch {
Toast
.makeText(
localContext,
// stringRes(context, R.string.secret_key_copied_to_clipboard),
"Video download has started...",
Toast.LENGTH_SHORT,
).show()
}
if (
Build.VERSION.SDK_INT >= Build.VERSION_CODES.Q ||
writeStoragePermissionState.status.isGranted

View File

@ -238,7 +238,6 @@ private fun DialogContent(
val localContext = LocalContext.current
val scope = rememberCoroutineScope()
val context = LocalContext.current
val writeStoragePermissionState =
rememberPermissionState(Manifest.permission.WRITE_EXTERNAL_STORAGE) { isGranted ->
@ -247,7 +246,7 @@ private fun DialogContent(
scope.launch {
Toast
.makeText(
context,
localContext,
// stringRes(context, R.string.secret_key_copied_to_clipboard),
"Media download has started...",
Toast.LENGTH_SHORT,
@ -266,7 +265,7 @@ private fun DialogContent(
scope.launch {
Toast
.makeText(
context,
localContext,
// stringRes(context, R.string.secret_key_copied_to_clipboard),
"Media download has started...",
Toast.LENGTH_SHORT,