Skip to content
Snippets Groups Projects
Commit bb03ff31 authored by rswindell's avatar rswindell
Browse files

Center the percentage complete in the transfer progress window.

parent ac8d87b6
No related branches found
No related tags found
No related merge requests found
...@@ -312,7 +312,7 @@ void zmodem_progress(void* cbdata, ulong current_pos) ...@@ -312,7 +312,7 @@ void zmodem_progress(void* cbdata, ulong current_pos)
); );
clreol(); clreol();
cputs("\r\n"); cputs("\r\n");
cprintf("%*s%3d%%\r\n", TRANSFER_WIN_WIDTH/2-2, "" cprintf("%*s%3d%%\r\n", TRANSFER_WIN_WIDTH/2-4, ""
,(long)(((float)current_pos/(float)zm->current_file_size)*100.0)); ,(long)(((float)current_pos/(float)zm->current_file_size)*100.0));
l = 60*((float)current_pos/(float)zm->current_file_size); l = 60*((float)current_pos/(float)zm->current_file_size);
cprintf("[%*.*s%*s]", l, l, cprintf("[%*.*s%*s]", l, l,
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment