|
@@ -1,5 +1,6 @@
|
|
|
package io.nexilis.alpha.ui.components
|
|
|
|
|
|
+import android.util.Log
|
|
|
import androidx.compose.foundation.Image
|
|
|
import androidx.compose.foundation.background
|
|
|
import androidx.compose.foundation.layout.Column
|
|
@@ -32,13 +33,14 @@ import io.nexilis.alpha.BuildConfig
|
|
|
import io.nexilis.service.core.DarkLimeGreen
|
|
|
import io.nexilis.service.core.Orange
|
|
|
import io.nexilis.service.data.entities.Message
|
|
|
+import java.io.File
|
|
|
|
|
|
@Composable
|
|
|
fun ContentChat(message: Message) {
|
|
|
val context = LocalContext.current
|
|
|
if (message.image_id.isNotEmpty()) {
|
|
|
Column(modifier = Modifier.padding(2.dp)) {
|
|
|
- val file = context.getFileStreamPath(message.image_id)
|
|
|
+ val file = File(context.filesDir, message.image_id)
|
|
|
val uri = FileProvider.getUriForFile(
|
|
|
context, BuildConfig.APPLICATION_ID + ".provider", file
|
|
|
)
|