mirror of
https://github.com/permissionlesstech/bitchat-android.git
synced 2026-07-25 16:45:20 +00:00
enable file transfer
This commit is contained in:
@@ -158,7 +158,7 @@ class BluetoothPacketBroadcaster(
|
||||
if (transferId != null && transferJobs[transferId]?.isCancelled == true) return@launch
|
||||
broadcastSinglePacket(RoutedPacket(fragment, transferId = transferId), gattServer, characteristic)
|
||||
// 20ms delay between fragments
|
||||
delay(20)
|
||||
delay(50)
|
||||
if (transferId != null) {
|
||||
sent += 1
|
||||
TransferProgressManager.progress(transferId, sent, fragments.size)
|
||||
|
||||
@@ -266,12 +266,11 @@ fun MessageInput(
|
||||
if (!isRecording) {
|
||||
// Revert to original separate buttons: round File button (left) and the old Image plus button (right)
|
||||
Row(horizontalArrangement = Arrangement.spacedBy(6.dp), verticalAlignment = Alignment.CenterVertically) {
|
||||
// DISABLE FILE PICKER
|
||||
//FilePickerButton(
|
||||
// onFileReady = { path ->
|
||||
// onSendFileNote(latestSelectedPeer.value, latestChannel.value, path)
|
||||
// }
|
||||
//)
|
||||
FilePickerButton(
|
||||
onFileReady = { path ->
|
||||
onSendFileNote(latestSelectedPeer.value, latestChannel.value, path)
|
||||
}
|
||||
)
|
||||
ImagePickerButton(
|
||||
onImageReady = { outPath ->
|
||||
onSendImageNote(latestSelectedPeer.value, latestChannel.value, outPath)
|
||||
|
||||
Reference in New Issue
Block a user