Fix small issues, improve Result.flatMap
This commit is contained in:
parent
698e08573b
commit
87990c425c
7 changed files with 97 additions and 16 deletions
|
|
@ -357,5 +357,11 @@ internal fun MessagesViewDarkPreview(@PreviewParameter(MessagesStateProvider::cl
|
|||
|
||||
@Composable
|
||||
private fun ContentToPreview(state: MessagesState) {
|
||||
MessagesView(state, {}, {}, {}, {})
|
||||
MessagesView(
|
||||
state = state,
|
||||
onBackPressed = {},
|
||||
onRoomDetailsClicked = {},
|
||||
onEventClicked = {},
|
||||
onPreviewAttachments = {}
|
||||
)
|
||||
}
|
||||
|
|
|
|||
|
|
@ -23,14 +23,12 @@ interface LocalMediaFactory {
|
|||
|
||||
/**
|
||||
* This method will create a [LocalMedia] with the given [MediaFile] and [mimeType].
|
||||
*
|
||||
*/
|
||||
fun createFromMediaFile(mediaFile: MediaFile, mimeType: String?): LocalMedia
|
||||
|
||||
/**
|
||||
* This method will create a [LocalMedia] with the given [uri] and [mimeType]
|
||||
* If the [mimeType] is null, it'll try to read it from the content.
|
||||
*
|
||||
*/
|
||||
fun createFromUri(uri: Uri, mimeType: String?): LocalMedia
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue