![]() |
Freeciv21
Develop your civilization from humble roots to a global empire
|
Table widget to display units view (F2) More...
#include <view_units.h>
Inheritance diagram for units_view:
Collaboration diagram for units_view:Public Member Functions | |
| units_view () | |
| Constructor for units view. More... | |
| ~units_view () | |
| Destructor for units view. More... | |
| void | update_view () |
| Refresh all widgets for units view. More... | |
| void | update_units () |
| Updates the units table. More... | |
| void | init () |
| Initializes place in tab for units view. More... | |
Private Slots | |
| void | disband_units () |
| Disband selected units. More... | |
| void | find_nearest () |
| Find nearest selected unit, closest units view when button is clicked. More... | |
| void | upgrade_units () |
| Upgrade selected units. More... | |
| void | selection_changed (const QItemSelection &sl, const QItemSelection &ds) |
| Action for selection changed in units view. More... | |
Private Member Functions | |
| void | update_waiting () |
| Function to load the units waiting table. More... | |
| void | update_buttons (const QItemSelection &sl) |
| Updates the buttons according to the item selection sl in the units table. More... | |
Private Attributes | |
| int | index |
| int | curr_row {-1} |
| int | max_row {0} |
| cid | uid {0} |
| int | counter {0} |
| Ui::FormUnitsView | ui |
Table widget to display units view (F2)
Definition at line 54 of file view_units.h.
| units_view::units_view | ( | ) |
Constructor for units view.
Definition at line 39 of file view_units.cpp.
| units_view::~units_view | ( | ) |
Destructor for units view.
Definition at line 123 of file view_units.cpp.
|
privateslot |
|
privateslot |
Find nearest selected unit, closest units view when button is clicked.
Definition at line 539 of file view_units.cpp.
Referenced by units_view().
| void units_view::init | ( | ) |
Initializes place in tab for units view.
Definition at line 128 of file view_units.cpp.
Referenced by top_bar_units_view(), and units_view_dialog_popup().
|
privateslot |
Action for selection changed in units view.
Definition at line 451 of file view_units.cpp.
Referenced by units_view().
|
private |
Updates the buttons according to the item selection sl in the units table.
Definition at line 461 of file view_units.cpp.
Referenced by selection_changed(), and update_units().
| void units_view::update_units | ( | ) |
Updates the units table.
Definition at line 146 of file view_units.cpp.
Referenced by top_bar_units_view(), and update_view().
| void units_view::update_view | ( | ) |
Refresh all widgets for units view.
Definition at line 133 of file view_units.cpp.
Referenced by top_bar_units_view(), units_view_dialog_popup(), and units_view_dialog_update().
|
private |
Function to load the units waiting table.
Definition at line 348 of file view_units.cpp.
Referenced by update_view().
|
privateslot |
|
private |
Definition at line 69 of file view_units.h.
Referenced by disband_units(), and update_buttons().
|
private |
Definition at line 66 of file view_units.h.
Referenced by update_buttons().
|
private |
Definition at line 65 of file view_units.h.
Referenced by init(), and units_view().
|
private |
Definition at line 67 of file view_units.h.
Referenced by update_buttons(), update_units(), and update_waiting().
|
private |
Definition at line 70 of file view_units.h.
Referenced by units_view(), update_buttons(), update_units(), and update_waiting().
|
private |
Definition at line 68 of file view_units.h.
Referenced by disband_units(), find_nearest(), update_buttons(), and upgrade_units().