core: option to receive file inline up to maximum "offered" size (#1232)

* core: option to receive file inline up to maximum "offered" size

* comment
This commit is contained in:
Evgeny Poberezkin
2022-10-20 14:32:20 +01:00
committed by GitHub
parent 9edb54b45c
commit c4fc8a97b1
3 changed files with 39 additions and 9 deletions
+2 -2
View File
@@ -84,7 +84,7 @@ data InlineFilesConfig = InlineFilesConfig
defaultInlineFilesConfig :: InlineFilesConfig
defaultInlineFilesConfig =
InlineFilesConfig
{ offerChunks = 15, -- max when chunks are offered - limited to 255 on the encoding level
{ offerChunks = 15, -- max when chunks are offered / received with the option - limited to 255 on the encoding level
sendChunks = 0, -- max per file when chunks will be sent inline without acceptance
totalSendChunks = 30, -- max per conversation when chunks will be sent inline without acceptance
receiveChunks = 5 -- max when chunks are accepted
@@ -233,7 +233,7 @@ data ChatCommand
| SendImage ChatName FilePath
| ForwardFile ChatName FileTransferId
| ForwardImage ChatName FileTransferId
| ReceiveFile FileTransferId (Maybe FilePath)
| ReceiveFile {fileId :: FileTransferId, fileInline :: Maybe Bool, filePath :: Maybe FilePath}
| CancelFile FileTransferId
| FileStatus FileTransferId
| ShowProfile