Freeciv-3.3
Loading...
Searching...
No Matches
Data Structures | Macros | Functions | Variables
spaceshipdlg.c File Reference
#include <stdio.h>
#include <stdlib.h>
#include <gtk/gtk.h>
#include "fcintl.h"
#include "log.h"
#include "mem.h"
#include "shared.h"
#include "support.h"
#include "game.h"
#include "map.h"
#include "packets.h"
#include "player.h"
#include "spaceship.h"
#include "victory.h"
#include "client_main.h"
#include "climisc.h"
#include "colors.h"
#include "options.h"
#include "text.h"
#include "tilespec.h"
#include "dialogs.h"
#include "graphics.h"
#include "gui_main.h"
#include "gui_stuff.h"
#include "helpdlg.h"
#include "inputdlg.h"
#include "mapctrl.h"
#include "mapview.h"
#include "repodlgs.h"
#include "spaceshipdlg.h"
#include "speclist.h"

Go to the source code of this file.

Data Structures

struct  spaceship_dialog
 

Macros

#define SPECLIST_TAG   dialog
 
#define SPECLIST_TYPE   struct spaceship_dialog
 
#define dialog_list_iterate(dialoglist, pdialog)    TYPED_LIST_ITERATE(struct spaceship_dialog, dialoglist, pdialog)
 
#define dialog_list_iterate_end   LIST_ITERATE_END
 

Functions

static struct spaceship_dialogget_spaceship_dialog (struct player *pplayer)
 
static struct spaceship_dialogcreate_spaceship_dialog (struct player *pplayer)
 
static void spaceship_dialog_update_image (struct spaceship_dialog *pdialog)
 
static void spaceship_dialog_update_info (struct spaceship_dialog *pdialog)
 
void spaceship_dialog_init (void)
 
void spaceship_dialog_done (void)
 
void refresh_spaceship_dialog (struct player *pplayer)
 
void popup_spaceship_dialog (struct player *pplayer)
 
void popdown_spaceship_dialog (struct player *pplayer)
 
static void spaceship_image_canvas_draw (GtkDrawingArea *w, cairo_t *cr, int width, int height, gpointer data)
 
static void spaceship_destroy_callback (GtkWidget *w, gpointer data)
 
static void spaceship_response (struct gui_dialog *dlg, int response, gpointer data)
 

Variables

static struct dialog_list * dialog_list
 

Macro Definition Documentation

◆ dialog_list_iterate

#define dialog_list_iterate (   dialoglist,
  pdialog 
)     TYPED_LIST_ITERATE(struct spaceship_dialog, dialoglist, pdialog)

Definition at line 71 of file spaceshipdlg.c.

◆ dialog_list_iterate_end

#define dialog_list_iterate_end   LIST_ITERATE_END

Definition at line 73 of file spaceshipdlg.c.

◆ SPECLIST_TAG

#define SPECLIST_TAG   dialog

Definition at line 67 of file spaceshipdlg.c.

◆ SPECLIST_TYPE

#define SPECLIST_TYPE   struct spaceship_dialog

Definition at line 68 of file spaceshipdlg.c.

Function Documentation

◆ create_spaceship_dialog()

struct spaceship_dialog * create_spaceship_dialog ( struct player pplayer)
static

Create new spaceship dialog

Definition at line 216 of file spaceshipdlg.c.

◆ get_spaceship_dialog()

struct spaceship_dialog * get_spaceship_dialog ( struct player pplayer)
static

Get spaceship dialog about certain player

Definition at line 103 of file spaceshipdlg.c.

◆ popdown_spaceship_dialog()

void popdown_spaceship_dialog ( struct player pplayer)

Popdown the dialog

Definition at line 160 of file spaceshipdlg.c.

◆ popup_spaceship_dialog()

void popup_spaceship_dialog ( struct player pplayer)

Popup the dialog 10% inside the main-window

Definition at line 146 of file spaceshipdlg.c.

◆ refresh_spaceship_dialog()

void refresh_spaceship_dialog ( struct player pplayer)

Refresh spaceship dialog of certain player

Definition at line 117 of file spaceshipdlg.c.

◆ spaceship_destroy_callback()

static void spaceship_destroy_callback ( GtkWidget w,
gpointer  data 
)
static

Spaceship dialog being destroyed

Definition at line 187 of file spaceshipdlg.c.

◆ spaceship_dialog_done()

void spaceship_dialog_done ( void  )

Free resources allocated for spaceship dialogs

Definition at line 95 of file spaceshipdlg.c.

◆ spaceship_dialog_init()

void spaceship_dialog_init ( void  )

Initialize spaceship dialogs

Definition at line 87 of file spaceshipdlg.c.

◆ spaceship_dialog_update_image()

void spaceship_dialog_update_image ( struct spaceship_dialog pdialog)
static

Should also check connectedness, and show non-connected parts differently.

Definition at line 289 of file spaceshipdlg.c.

◆ spaceship_dialog_update_info()

void spaceship_dialog_update_info ( struct spaceship_dialog pdialog)
static

Update spaceship dialog info label text

Definition at line 279 of file spaceshipdlg.c.

◆ spaceship_image_canvas_draw()

static void spaceship_image_canvas_draw ( GtkDrawingArea w,
cairo_t cr,
int  width,
int  height,
gpointer  data 
)
static

Draw spaceship dialog canvas.

Definition at line 172 of file spaceshipdlg.c.

Referenced by create_spaceship_dialog().

◆ spaceship_response()

static void spaceship_response ( struct gui_dialog dlg,
int  response,
gpointer  data 
)
static

User has responded to spaceship dialog

Definition at line 199 of file spaceshipdlg.c.

Variable Documentation

◆ dialog_list

struct dialog_list* dialog_list
static

Definition at line 75 of file spaceshipdlg.c.