Clear progress bar text when starting it (#230)
These operations use steps which generate progress bar bytes copied information text: * Partition move or copy using GParted's internal block copy * EXT2/3/4 partition move or copy * XFS partition copy The bytes copied text looks like this (after the copy completes and the time remaining is no longer included): 1.00 GiB of 1.00 GiB copied And these operations use steps which generate progress bar information without text (because the progress bar data only represents a fraction complete): * EXT2/3/4 partition resize * EXT2/3/4 partition create * EXT2/3/4 partition format * EXT2/3/4 partition check * NTFS partition resize * NTFS partition copy In the Applying pending operations dialog, while an operation is being applied there are 2 progress bars. The top progress bar displays either a pulse bar or the progress bar data for the current step. Additionally for the relevant steps the progress bar generates the bytes copied text. This text, when available, is displayed in small grey characters just above the progress bar itself. Copy a FAT partition and apply. Bytes copied text is displayed just above the top progress bar. Copy an NTFS partition and apply. The left behind bytes copied text from the previous operation is displayed, instead of nothing. Restart GParted and copy an NTFS partition and apply. As intended, this time there is no bytes copied text displayed just above the top progress bar. As there is just a single ProgressBar object, single_progressbar, fix this by clearing the progress bar text each time it is started. Closes #230 - Missing progress bar text reset when applying operation
This commit is contained in:
parent
ead39c2446
commit
1718c5d2fb
|
@ -37,6 +37,7 @@ void ProgressBar::start( double target, ProgressBar_Text text_mode )
|
|||
m_target = target;
|
||||
m_progress = 0.0;
|
||||
m_text_mode = text_mode;
|
||||
m_text.clear();
|
||||
m_timer.start();
|
||||
do_update();
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue