mirror of
https://github.com/p-ranav/indicators.git
synced 2025-12-15 11:58:52 +08:00
Minor updates
This commit is contained in:
@@ -154,18 +154,9 @@ int main() {
|
|||||||
p5.end_with("🌑");
|
p5.end_with("🌑");
|
||||||
p5.show_percentage(true);
|
p5.show_percentage(true);
|
||||||
p5.color(ProgressBar::Color::WHITE);
|
p5.color(ProgressBar::Color::WHITE);
|
||||||
std::atomic<int> trail_index{0};
|
auto job5 = [&p5]() {
|
||||||
std::vector<std::string> trail {"■", "□", "▪", "▫"};
|
|
||||||
auto job5 = [&p5, &trail, &trail_index]() {
|
|
||||||
while (true) {
|
while (true) {
|
||||||
p5.lead_progress_with(
|
|
||||||
trail[(trail_index - 3) % trail.size()] +
|
|
||||||
trail[(trail_index - 2) % trail.size()] +
|
|
||||||
trail[(trail_index - 1) % trail.size()] +
|
|
||||||
trail[trail_index % trail.size()] +
|
|
||||||
"🛸");
|
|
||||||
p5.tick();
|
p5.tick();
|
||||||
trail_index += 1;
|
|
||||||
if (p5.completed()) {
|
if (p5.completed()) {
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user