15 #define GETTEXT_DOMAIN "wesnoth-lib"
62 team::SHARE_VISION& share_vision,
66 : controller_(controller)
67 , share_vision_(share_vision)
69 std::stringstream side_stream;
71 register_label(
"side_number",
true, side_stream.str(),
true);
73 register_text(
"team_name",
true,
id,
true);
74 register_text(
"user_team_name",
true, name,
true);
76 register_integer(
"gold",
true, gold);
77 register_integer(
"income",
true, income);
79 register_integer(
"village_income",
true, village_income);
80 register_integer(
"village_support",
true, village_support);
82 register_bool(
"fog",
true, fog);
83 register_bool(
"shroud",
true, shroud);
85 register_bool(
"no_leader",
true, no_leader);
86 register_bool(
"hidden",
true, hidden);
96 register_radio_toggle<team::SHARE_VISION>(
"vision_shroud",
vision_group, team::SHARE_VISION::SHROUD,
share_vision_, window);
100 template <
typename T>
103 ttoggle_button&
b = find_widget<ttoggle_button>(&window, toggle_id,
false);
105 b.
set_value(enum_value == current_value);
tgroup< team::SHARE_VISION > vision_group
REGISTER_DIALOG(label_settings)
void post_show(twindow &window)
Actions to be taken after the window has been shown.
Implements some helper classes to ease adding fields to a dialog and hide the synchronization needed...
tgroup< team::CONTROLLER > controller_group
base class of top level items, the only item which needs to store the final canvases to draw on ...
A class inherited from ttext_box that displays its input as stars.
GLdouble GLdouble GLdouble b
This class stores all the data for a single 'side' (in game nomenclature).
void pre_show(twindow &window)
Actions to be taken before showing the window.
team::CONTROLLER & controller_
T get_active_member_value()
Returns the value paired with the currently activiely toggled member of the group.
GLuint const GLchar * name
void register_radio_toggle(const std::string &toggle_id, tgroup< T > &group, const T &enum_value, T ¤t_value, twindow &window)
void add_member(tselectable_ *widget, const T &value)
Adds a widget/value pair to the group vector.
team::SHARE_VISION & share_vision_
GLsizei const GLcharARB ** string