#include <xtd/forms/application>
#include <xtd/forms/loading_indicator>
#include <xtd/forms/form>
#include <xtd/forms/list_box>
#include <xtd/forms/panel>
#include <xtd/drawing/system_colors>
namespace loading_indicator_example {
class form1 :
public form {
public:
form1() {
text(
"Loading indicator example");
client_size({360, 240});
list_box1.parent(*this);
list_box1.bounds({20, 20, 150, 200});
list_box1.items().push_back_range({{
"Standard",
loading_indicator_style::standard}, {
"System",
loading_indicator_style::system}, {
"Bar",
loading_indicator_style::bar}, {
"Circle bars",
loading_indicator_style::circle_bars}, {
"Circle blinks",
loading_indicator_style::circle_blinks}, {
"Five lines",
loading_indicator_style::five_lines}, {
"Five lines center",
loading_indicator_style::five_lines_center}, {
"Five lines chronological",
loading_indicator_style::five_lines_chronological}, {
"Five lines pulse",
loading_indicator_style::five_lines_pulse}, {
"Five lines wave",
loading_indicator_style::five_lines_wave}, {
"Pulse",
loading_indicator_style::pulse}, {
"Pulse outline",
loading_indicator_style::pulse_outline}, {
"Three balls",
loading_indicator_style::three_balls}, {
"Three balls bouncing",
loading_indicator_style::three_balls_bouncing}, {
"Three balls rotation",
loading_indicator_style::three_balls_rotation}});
list_box1.selected_index_changed += [&] {
};
list_box1.selected_item("Standard");
panel1.parent(*this);
panel1.bounds({190, 20, 150, 200});
panel1.click += loading_indicator1.click += [&] {
loading_indicator1.running(!loading_indicator1.running());
};
loading_indicator1.parent(panel1);
loading_indicator1.location({59, 84});
loading_indicator1.running(true);
}
private:
list_box list_box1;
};
}
auto main() -> int {
}
static xtd::drawing::color window()
Gets a xtd::drawing::color structure that is the color of the background in the client area of a wind...
type_t as(any_object &o)
Casts a type into another type.
Definition __as_any_object.hpp:59
Contains classes that represent ASCII and Unicode character encodings; abstract base classes for conv...
Definition basic_string_builder.hpp:16
The xtd namespace contains all fundamental classes to access Hardware, Os, System,...
Definition abstract_object.hpp:8