Freeciv-3.2
|
#include <citydlg.h>
Public Member Functions | |
unit_item (QWidget *parent, struct unit *punit, bool supp=false, int happy_cost=0) | |
~unit_item () | |
void | init_pix () |
Protected Member Functions | |
void | wheelEvent (QWheelEvent *event) |
void | mousePressEvent (QMouseEvent *event) |
void | leaveEvent (QEvent *event) |
void | enterEvent (QEnterEvent *event) |
Private Slots | |
void | disband () |
void | change_homecity () |
void | activate_unit () |
void | activate_and_close_dialog () |
void | sentry_unit () |
void | fortify_unit () |
void | upgrade_unit () |
void | load_unit () |
void | unload_unit () |
void | unload_all () |
Private Member Functions | |
void | contextMenuEvent (QContextMenuEvent *ev) |
void | create_actions () |
Private Attributes | |
QAction * | disband_action |
QAction * | change_home |
QAction * | activate |
QAction * | activate_and_close |
QAction * | sentry |
QAction * | fortify |
QAction * | load |
QAction * | unload |
QAction * | upgrade |
QAction * | unload_trans |
QMenu * | unit_menu |
struct unit * | qunit |
QImage | unit_img |
int | happy_cost |
bool | supported |
unit_item::unit_item | ( | QWidget * | parent, |
struct unit * | punit, | ||
bool | supp = false , |
||
int | hppy_cost = 0 |
||
) |
Class representing one unit, allows context menu, holds pixmap for it
Definition at line 663 of file citydlg.cpp.
unit_item::~unit_item | ( | ) |
Destructor for unit item
Definition at line 743 of file citydlg.cpp.
|
privateslot |
Activates unit and closes city dialog
Definition at line 946 of file citydlg.cpp.
Referenced by create_actions().
|
privateslot |
Activates unit in city dialog
Definition at line 957 of file citydlg.cpp.
Referenced by create_actions().
|
privateslot |
Changes homecity for given unit
Definition at line 936 of file citydlg.cpp.
Referenced by create_actions().
|
private |
Context menu handler
Definition at line 750 of file citydlg.cpp.
|
private |
|
privateslot |
Popups MessageBox for disbanding unit and disbands it
Definition at line 882 of file citydlg.cpp.
Referenced by create_actions().
|
protected |
Mouse entered widget
Definition at line 978 of file citydlg.cpp.
|
privateslot |
Fortifies unit in city dialog
Definition at line 967 of file citydlg.cpp.
Referenced by create_actions().
void unit_item::init_pix | ( | ) |
Sets pixmap for unit_item class
Definition at line 734 of file citydlg.cpp.
Referenced by leaveEvent(), and city_dialog::update_units().
|
protected |
Mouse left widget
Definition at line 999 of file citydlg.cpp.
|
privateslot |
Loads unit into some transport
Definition at line 900 of file citydlg.cpp.
Referenced by create_actions().
|
protected |
Mouse press event -activates unit and closes dialog
Definition at line 1033 of file citydlg.cpp.
|
privateslot |
Sentries unit in city dialog
Definition at line 1046 of file citydlg.cpp.
Referenced by create_actions().
|
privateslot |
Unloads all units from transporter
Definition at line 916 of file citydlg.cpp.
Referenced by create_actions().
|
privateslot |
|
privateslot |
|
protected |
Mouse wheel event - send it to scrollbar
Definition at line 1007 of file citydlg.cpp.
|
private |
Definition at line 147 of file citydlg.h.
Referenced by contextMenuEvent(), and create_actions().
|
private |
Definition at line 148 of file citydlg.h.
Referenced by contextMenuEvent(), and create_actions().
|
private |
Definition at line 146 of file citydlg.h.
Referenced by contextMenuEvent(), and create_actions().
|
private |
Definition at line 145 of file citydlg.h.
Referenced by contextMenuEvent(), and create_actions().
|
private |
Definition at line 150 of file citydlg.h.
Referenced by contextMenuEvent(), and create_actions().
|
private |
Definition at line 168 of file citydlg.h.
Referenced by unit_item().
|
private |
Definition at line 151 of file citydlg.h.
Referenced by contextMenuEvent(), and create_actions().
Definition at line 164 of file citydlg.h.
Referenced by activate_and_close_dialog(), activate_unit(), change_homecity(), contextMenuEvent(), create_actions(), disband(), fortify_unit(), load_unit(), mousePressEvent(), sentry_unit(), unit_item(), unload_all(), unload_unit(), and upgrade_unit().
|
private |
Definition at line 149 of file citydlg.h.
Referenced by contextMenuEvent(), and create_actions().
|
private |
Definition at line 169 of file citydlg.h.
Referenced by unit_item().
|
private |
Definition at line 165 of file citydlg.h.
Referenced by init_pix(), and unit_item().
|
private |
Definition at line 152 of file citydlg.h.
Referenced by contextMenuEvent(), and create_actions().
|
private |
Definition at line 154 of file citydlg.h.
Referenced by contextMenuEvent(), and create_actions().
|
private |
Definition at line 153 of file citydlg.h.
Referenced by contextMenuEvent(), and create_actions().