Freeciv-3.2
Loading...
Searching...
No Matches
Data Structures | Functions
unitselextradlg.c File Reference
#include <gtk/gtk.h>
#include "fcintl.h"
#include "extras.h"
#include "game.h"
#include "movement.h"
#include "nation.h"
#include "unit.h"
#include "control.h"
#include "tilespec.h"
#include "gui_main.h"
#include "gui_stuff.h"
#include "sprite.h"
#include "unitselextradlg.h"

Go to the source code of this file.

Data Structures

struct  unit_sel_extra_cb_data
 

Functions

static const chartgt_extra_descr (const struct extra_type *tgt_extra, const struct tile *tgt_tile)
 
static void unit_sel_extra_toggled (GtkToggleButton *tb, gpointer userdata)
 
static void unit_sel_extra_destroyed (GtkWidget *radio, gpointer userdata)
 
bool select_tgt_extra (struct unit *actor, struct tile *ptile, bv_extras potential_tgt_extras, struct extra_type *suggested_tgt_extra, const gchar *dlg_title, const gchar *actor_label, const gchar *tgt_label, const gchar *do_label, GCallback do_callback)
 

Function Documentation

◆ select_tgt_extra()

bool select_tgt_extra ( struct unit actor,
struct tile ptile,
bv_extras  potential_tgt_extras,
struct extra_type suggested_tgt_extra,
const gchar dlg_title,
const gchar actor_label,
const gchar tgt_label,
const gchar do_label,
GCallback  do_callback 
)

Create a dialog where a unit select what extra to act on.

Definition at line 107 of file unitselextradlg.c.

◆ tgt_extra_descr()

static const char * tgt_extra_descr ( const struct extra_type tgt_extra,
const struct tile tgt_tile 
)
static

Get an extra selection list item suitable description of the specified extra at the specified tile.

Definition at line 50 of file unitselextradlg.c.

◆ unit_sel_extra_destroyed()

static void unit_sel_extra_destroyed ( GtkWidget radio,
gpointer  userdata 
)
static

Callback to handle destruction of one of the target extra buttons.

Definition at line 99 of file unitselextradlg.c.

◆ unit_sel_extra_toggled()

static void unit_sel_extra_toggled ( GtkToggleButton tb,
gpointer  userdata 
)
static

Callback to handle toggling of one of the target extra buttons.

Definition at line 85 of file unitselextradlg.c.