ladybird/Userland/Applications/FileManager/FileOperationProgress.gml
Leandro Pereira 602f98fe67 FileManager: Estimate transfer time
Use the total bytes transferred count to estimate the time left
for the copy operation to finish.  With the estimate label, the
two progress bars were deemed superfluous, so the only remaining
progress bar is the overall copy progress, that is updated more
frequently.  (The same progress is also shown in the task bar,
so you can minimize the window and still be informed of the
progress.)
2021-04-17 09:41:35 +02:00

103 lines
1.9 KiB
Text

@GUI::Widget {
fill_with_background_color: true
layout: @GUI::VerticalBoxLayout {
margins: [4, 4, 4, 4]
}
@GUI::Widget {
fixed_height: 32
layout: @GUI::HorizontalBoxLayout {
}
@GUI::ImageWidget {
name: "source_folder_icon"
}
@GUI::ImageWidget {
name: "file_copy_animation"
}
@GUI::ImageWidget {
name: "destination_folder_icon"
}
}
@GUI::Label {
text: "Copying files..."
text_alignment: "CenterLeft"
font_weight: "Bold"
fixed_height: 32
name: "files_copied_label"
}
@GUI::HorizontalSeparator {
fixed_height: 2
}
@GUI::Widget {
fixed_height: 22
layout: @GUI::HorizontalBoxLayout {
}
@GUI::Label {
text: "Copying: "
font_weight: "Bold"
text_alignment: "CenterLeft"
fixed_width: 80
}
@GUI::Label {
name: "current_file_label"
text: "Placeholder"
text_alignment: "CenterLeft"
}
}
@GUI::Widget {
fixed_height: 22
layout: @GUI::HorizontalBoxLayout {
}
@GUI::Label {
text: "Time left: "
font_weight: "Bold"
text_alignment: "CenterLeft"
fixed_width: 80
}
@GUI::Label {
name: "estimated_time_label"
text: "Estimating..."
text_alignment: "CenterLeft"
}
}
@GUI::Progressbar {
fixed_height: 22
name: "overall_progressbar"
min: 0
}
@GUI::Widget {
fixed_height: 2
}
@GUI::Widget {
shrink_to_fit: true
layout: @GUI::HorizontalBoxLayout {
}
@GUI::Widget {
}
@GUI::Button {
text: "Cancel"
name: "button"
fixed_width: 80
}
}
}