MediaGalleryPreviewContract

The contract used to start the MediaGalleryPreviewActivity given a message ID and the position of the clicked attachment.

Parameters

config

The configuration for the media gallery.

Constructors

Link copied to clipboard
constructor(config: MediaGalleryConfig = MediaGalleryConfig())

Types

Link copied to clipboard
class Input(val message: Message, val selectedAttachmentUrl: String? = null, val videoThumbnailsEnabled: Boolean, val streamCdnImageResizing: StreamCdnImageResizing, val skipEnrichUrl: Boolean = false)

Defines the input for the MediaGalleryPreviewContract.

Functions

Link copied to clipboard
open override fun createIntent(context: Context, input: MediaGalleryPreviewContract.Input): Intent

Creates the intent to start the MediaGalleryPreviewActivity.

Link copied to clipboard
open override fun parseResult(resultCode: Int, intent: Intent?): MediaGalleryPreviewResult?

We parse the result as MediaGalleryPreviewResult, which can be null in case there is no result to return.