1
0
Fork 0
mirror of synced 2024-06-30 03:50:52 +12:00
czkawka/krokiet/ui/progress.slint

69 lines
2.3 KiB
Plaintext
Raw Normal View History

2023-10-23 10:18:01 +13:00
import { Button, VerticalBox , HorizontalBox, TabWidget, ListView, StandardListView, StandardTableView, CheckBox} from "std-widgets.slint";
import {SelectableTableView} from "selectable_tree_view.slint";
import {LeftSidePanel} from "left_side_panel.slint";
import {MainList} from "main_lists.slint";
import {CurrentTab, ProgressToSend} from "common.slint";
import { ProgressIndicator } from "std-widgets.slint";
export component Progress {
in-out property <ProgressToSend> progress_datas;
preferred-width: 400px;
preferred-height: 40px;
VerticalLayout {
Text {
text: progress-datas.step-name;
horizontal-alignment: TextHorizontalAlignment.center;
}
2023-11-11 05:11:32 +13:00
2023-10-23 10:18:01 +13:00
HorizontalLayout {
spacing: 5px;
VerticalLayout {
spacing: 5px;
Text {
vertical-alignment: TextVerticalAlignment.center;
text: "Current Stage:";
}
2023-11-11 05:11:32 +13:00
2023-10-23 10:18:01 +13:00
Text {
vertical-alignment: TextVerticalAlignment.center;
text: "All Stages:";
}
}
2023-11-11 05:11:32 +13:00
2023-10-23 10:18:01 +13:00
VerticalLayout {
spacing: 5px;
VerticalLayout {
alignment: LayoutAlignment.center;
ProgressIndicator {
visible: progress_datas.current-progress >= -0.001;
height: 8px;
progress: progress_datas.current-progress / 100.0;
}
}
2023-11-11 05:11:32 +13:00
2023-10-23 10:18:01 +13:00
VerticalLayout {
alignment: LayoutAlignment.center;
ProgressIndicator {
height: 8px;
2023-11-11 05:11:32 +13:00
progress: progress_datas.all-progress / 100.0;
2023-10-23 10:18:01 +13:00
}
}
}
2023-11-11 05:11:32 +13:00
2023-10-23 10:18:01 +13:00
VerticalLayout {
spacing: 5px;
Text {
2023-11-12 07:10:07 +13:00
visible: progress_datas.current-progress >= -0.001;
2023-10-23 10:18:01 +13:00
vertical-alignment: TextVerticalAlignment.center;
2023-11-11 05:11:32 +13:00
text: progress_datas.current-progress + "%";
2023-10-23 10:18:01 +13:00
}
2023-11-11 05:11:32 +13:00
2023-10-23 10:18:01 +13:00
Text {
vertical-alignment: TextVerticalAlignment.center;
2023-11-11 05:11:32 +13:00
text: progress_datas.all-progress + "%";
2023-10-23 10:18:01 +13:00
}
}
}
}
2023-11-11 05:11:32 +13:00
}