Skip to content

Commit 3231898

Browse files
committed
fix: File transfer progress bar now shows when sending a file
1 parent cd468b8 commit 3231898

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

src/chat.c

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -593,6 +593,10 @@ static void chat_onFileControl(ToxWindow *self, Toxic *toxic, uint32_t friendnum
593593
line_info_add(self, c_config, false, NULL, NULL, SYS_MSG, 0, 0, "File transfer [%zu] for '%s' accepted.",
594594
ft->index, ft->file_name);
595595
sound_notify(self, toxic, silent, NT_NOFOCUS | c_config->bell_on_filetrans_accept | NT_WNDALERT_2, NULL);
596+
char progline[MAX_STR_SIZE];
597+
init_progress_bar(progline);
598+
line_info_add(self, c_config, false, NULL, NULL, SYS_MSG, 0, 0, "%s", progline);
599+
ft->line_id = self->chatwin->hst->line_end->id + 2;
596600
} else if (ft->state == FILE_TRANSFER_PAUSED) { /* transfer is resumed */
597601
ft->state = FILE_TRANSFER_STARTED;
598602
}

0 commit comments

Comments
 (0)