29 if(vis && !old_visibility) {
32 }
else if(!vis && old_visibility) {
96 return std::unique_ptr<element_base>{};
120 template<
typename T,
typename ...Params>
122 template<
typename T,
typename ...Params>
131 return any_cast<T>(payload);
150 return any_cast<T>(payload);
157 int32_t this_slot = -1, int32_t from_slot = -1);
159 int32_t primary, int32_t this_slot, int32_t from_slot);
161 int32_t primary, int32_t this_slot, int32_t from_slot);
164 dcon::national_modifier_value nmid,
bool header);
166 dcon::provincial_modifier_value nmid,
bool have_header);
virtual message_result impl_set(sys::state &state, Cyto::Any &payload) noexcept
virtual tooltip_behavior has_tooltip(sys::state &state) noexcept
virtual void on_text(sys::state &state, char32_t ch) noexcept
virtual void impl_on_reset_text(sys::state &state) noexcept
virtual message_result test_mouse(sys::state &state, int32_t x, int32_t y, mouse_probe_type type) noexcept
virtual void add_child_to_back(std::unique_ptr< element_base > child) noexcept
static constexpr uint8_t is_invisible_mask
virtual message_result on_lbutton_down(sys::state &state, int32_t x, int32_t y, sys::key_modifiers mods) noexcept
virtual void update_tooltip(sys::state &state, int32_t x, int32_t y, text::columnar_layout &contents) noexcept
virtual void impl_on_drag_finish(sys::state &state) noexcept
friend std::unique_ptr< element_base > make_element_immediate(sys::state &state, dcon::gui_def_id id)
virtual void render(sys::state &state, int32_t x, int32_t y) noexcept
virtual message_result on_lbutton_up(sys::state &state, int32_t x, int32_t y, sys::key_modifiers mods, bool under_mouse) noexcept
virtual message_result impl_on_rbutton_down(sys::state &state, int32_t x, int32_t y, sys::key_modifiers mods) noexcept
virtual message_result get(sys::state &state, Cyto::Any &payload) noexcept
virtual void on_lose_focus(sys::state &state) noexcept
virtual focus_result on_get_focus(sys::state &state) noexcept
virtual message_result impl_on_scroll(sys::state &state, int32_t x, int32_t y, float amount, sys::key_modifiers mods) noexcept
virtual element_base * get_child_by_name(sys::state const &state, std::string_view name) noexcept
virtual message_result set(sys::state &state, Cyto::Any &payload) noexcept
virtual element_base * get_child_by_index(sys::state const &state, int32_t index) noexcept
friend std::unique_ptr< T > make_element_by_type(sys::state &state, dcon::gui_def_id id, Params &&... params)
virtual void on_update(sys::state &state) noexcept
virtual void impl_on_update(sys::state &state) noexcept
virtual void impl_render(sys::state &state, int32_t x, int32_t y) noexcept
virtual void move_child_to_back(element_base *child) noexcept
virtual message_result impl_on_key_down(sys::state &state, sys::virtual_key key, sys::key_modifiers mods) noexcept
virtual message_result impl_on_lbutton_up(sys::state &state, int32_t x, int32_t y, sys::key_modifiers mods, bool under_mouse) noexcept
virtual void add_child_to_front(std::unique_ptr< element_base > child) noexcept
virtual std::unique_ptr< element_base > remove_child(element_base *child) noexcept
virtual message_result on_scroll(sys::state &state, int32_t x, int32_t y, float amount, sys::key_modifiers mods) noexcept
virtual void on_drag_finish(sys::state &state) noexcept
friend std::unique_ptr< element_base > make_element(sys::state &state, std::string_view name)
virtual message_result impl_on_lbutton_down(sys::state &state, int32_t x, int32_t y, sys::key_modifiers mods) noexcept
message_result impl_get(sys::state &state, Cyto::Any &payload) noexcept
virtual void on_visible(sys::state &state) noexcept
virtual message_result on_mouse_move(sys::state &state, int32_t x, int32_t y, sys::key_modifiers mods) noexcept
virtual void on_create(sys::state &state) noexcept
virtual void move_child_to_front(element_base *child) noexcept
virtual void on_reset_text(sys::state &state) noexcept
virtual void on_drag(sys::state &state, int32_t oldx, int32_t oldy, int32_t x, int32_t y, sys::key_modifiers mods) noexcept
void set_visible(sys::state &state, bool vis)
virtual message_result on_key_down(sys::state &state, sys::virtual_key key, sys::key_modifiers mods) noexcept
virtual message_result impl_on_mouse_move(sys::state &state, int32_t x, int32_t y, sys::key_modifiers mods) noexcept
virtual mouse_probe impl_probe_mouse(sys::state &state, int32_t x, int32_t y, mouse_probe_type type) noexcept
virtual message_result on_rbutton_down(sys::state &state, int32_t x, int32_t y, sys::key_modifiers mods) noexcept
virtual void on_hide(sys::state &state) noexcept
void modifier_description(sys::state &state, text::layout_base &layout, dcon::modifier_id mid, int32_t indentation=0)
void reform_description(sys::state &state, text::columnar_layout &contents, dcon::issue_option_id ref)
T retrieve(sys::state &state, element_base *parent)
void multiplicative_value_modifier_description(sys::state &state, text::layout_base &layout, dcon::value_modifier_key modifier, int32_t primary, int32_t this_slot, int32_t from_slot)
void effect_description(sys::state &state, text::layout_base &layout, dcon::effect_key k, int32_t primary_slot, int32_t this_slot, int32_t from_slot, uint32_t r_lo, uint32_t r_hi)
T send_and_retrieve(sys::state &state, element_base *parent, T value)
void additive_value_modifier_description(sys::state &state, text::layout_base &layout, dcon::value_modifier_key modifier, int32_t primary, int32_t this_slot, int32_t from_slot)
void send(sys::state &state, element_base *parent, T value)
void technology_description(sys::state &state, text::layout_base &contents, dcon::technology_id tech_id) noexcept
void trigger_description(sys::state &state, text::layout_base &layout, dcon::trigger_key k, int32_t primary_slot=-1, int32_t this_slot=-1, int32_t from_slot=-1)
void reform_rules_description(sys::state &state, text::columnar_layout &contents, uint32_t rules)
void invention_description(sys::state &state, text::layout_base &contents, dcon::invention_id inv_id, int32_t indent) noexcept
void active_modifiers_description(sys::state &state, text::layout_base &layout, dcon::nation_id n, int32_t identation, dcon::national_modifier_value nmid, bool header)
void on_drag_finished(int32_t x, int32_t y, key_modifiers mod)
void on_mouse_drag(int32_t x, int32_t y, key_modifiers mod)