xtd 0.2.0
Loading...
Searching...
No Matches
loading_indicator.hpp
Go to the documentation of this file.
1
4#pragma once
5#include "control.hpp"
8
10namespace xtd {
12 namespace forms {
32 struct data;
33
34 public:
36
41
44 loading_indicator(const loading_indicator&) = default;
45 loading_indicator& operator =(const loading_indicator&) = default;
47
49
51 using control::control_appearance;
53
63
66 virtual bool running() const noexcept;
67
70 virtual loading_indicator& running(bool value);
72
74
77 void start();
79 void stop();
81
83
87 static loading_indicator create();
91 static loading_indicator create(const drawing::point& location);
96 static loading_indicator create(const drawing::point& location, const drawing::size& size);
102 static loading_indicator create(const drawing::point& location, const drawing::size& size, const xtd::string& name);
106 static loading_indicator create(const control& parent);
111 static loading_indicator create(const control& parent, const drawing::point& location);
117 static loading_indicator create(const control& parent, const drawing::point& location, const drawing::size& size);
124 static loading_indicator create(const control& parent, const drawing::point& location, const drawing::size& size, const xtd::string& name);
126
127 protected:
129
131 xtd::forms::create_params create_params() const noexcept override;
133
135
141 xtd::uptr<xtd::object> clone() const override;
142
143 xtd::drawing::size measure_control() const noexcept override;
144 void on_handle_created(const event_args& e) override;
145 void on_paint(xtd::forms::paint_event_args& e) override;
147
148 private:
149 void on_timer_tick(object& timer, const xtd::event_args& e);
150
151 xtd::sptr<data> data_;
152 };
153 }
154}
Represents the base class for classes that contain event data, and provides a value to use for events...
Definition event_args.hpp:18
Defines the base class for controls, which are components with visual representation.
Definition control.hpp:81
Encapsulates the information needed when creating a control.
Definition create_params.hpp:29
Represents a loading indicator control.
Definition loading_indicator.hpp:31
control & control_appearance(forms::control_appearance value) override
Sets control appearance.
loading_indicator()
Initialize a new instance of loading_indicator class.
virtual xtd::forms::loading_indicator_style loading_indicator_style() const noexcept
Gets the flat style appearance of the loading_indicator control.
Provides data for the xtd::forms::control::paint event.
Definition paint_event_args.hpp:30
Implements a timer that raises an event at user-defined intervals. This timer is optimized for use in...
Definition timer.hpp:38
Contains xtd::forms::content_alignment enum class.
#define forms_export_
Define shared library export.
Definition forms_export.hpp:13
std::unique_ptr< type_t > uptr
The xtd::uptr object is a unique pointer.
Definition uptr.hpp:25
size_t size
Represents a size of any object in bytes.
Definition size.hpp:23
std::shared_ptr< type_t > sptr
The xtd::sptr object is a shared pointer.
Definition sptr.hpp:25
loading_indicator_style
Specifies the appearance of a loading indicator control.
Definition loading_indicator_style.hpp:22
control_appearance
Specifies the appearance of a control.
Definition control_appearance.hpp:21
Contains xtd::forms::loading_indicator_style enum class.
The xtd::forms namespace contains classes for creating Windows-based applications that take full adva...
Definition xtd_about_box.hpp:12
The xtd namespace contains all fundamental classes to access Hardware, Os, System,...
Definition xtd_about_box.hpp:10
Contains xtd::forms::style_sheets::control class.