Freeciv-3.3
Loading...
Searching...
No Matches
Macros | Functions | Variables
mapctrl.h File Reference
#include <SDL3/SDL.h>
#include "fc_types.h"
#include "gui_main.h"
#include "mapctrl_g.h"

Go to the source code of this file.

Macros

#define BLOCKM_W   52
 
#define BLOCKU_W   28
 
#define DEFAULT_OVERVIEW_W   156
 
#define DEFAULT_OVERVIEW_H   104
 
#define DEFAULT_UNITS_W   (158 + BLOCKU_W)
 
#define DEFAULT_UNITS_H   104
 

Functions

void popdown_newcity_dialog (void)
 
void popup_minimap_window (void)
 
void show_minimap_window_buttons (void)
 
void hide_minimap_window_buttons (void)
 
void disable_minimap_window_buttons (void)
 
void redraw_minimap_window_buttons (void)
 
void popdown_minimap_window (void)
 
void popup_unitinfo_window (void)
 
void show_unitinfo_window_buttons (void)
 
void hide_unitinfo_window_buttons (void)
 
void disable_unitinfo_window_buttons (void)
 
void popdown_unitinfo_window (void)
 
void show_game_page (void)
 
void close_game_page (void)
 
void set_new_unitinfo_window_pos (void)
 
void set_new_minimap_window_pos (void)
 
int resize_minimap (void)
 
int resize_unit_info (void)
 
struct widgetget_unit_info_window_widget (void)
 
struct widgetget_minimap_window_widget (void)
 
struct widgetget_tax_rates_widget (void)
 
struct widgetget_research_widget (void)
 
struct widgetget_revolution_widget (void)
 
void enable_and_redraw_find_city_button (void)
 
void enable_and_redraw_revolution_button (void)
 
void enable_main_widgets (void)
 
void disable_main_widgets (void)
 
bool map_event_handler (SDL_KeyboardEvent *key)
 
void finger_down_on_map (struct finger_behavior *finger_behavior)
 
void finger_up_on_map (struct finger_behavior *finger_behavior)
 
void button_down_on_map (struct mouse_button_behavior *button_behavior)
 
void button_up_on_map (struct mouse_button_behavior *button_behavior)
 

Variables

int overview_w
 
int overview_h
 

Macro Definition Documentation

◆ BLOCKM_W

#define BLOCKM_W   52

Definition at line 47 of file mapctrl.h.

◆ BLOCKU_W

#define BLOCKU_W   28

Definition at line 48 of file mapctrl.h.

◆ DEFAULT_OVERVIEW_H

#define DEFAULT_OVERVIEW_H   104

Definition at line 50 of file mapctrl.h.

◆ DEFAULT_OVERVIEW_W

#define DEFAULT_OVERVIEW_W   156

Definition at line 49 of file mapctrl.h.

◆ DEFAULT_UNITS_H

#define DEFAULT_UNITS_H   104

Definition at line 52 of file mapctrl.h.

◆ DEFAULT_UNITS_W

#define DEFAULT_UNITS_W   (158 + BLOCKU_W)

Definition at line 51 of file mapctrl.h.

Function Documentation

◆ button_down_on_map()

void button_down_on_map ( struct mouse_button_behavior button_behavior)

Mouse click handler

Definition at line 2280 of file mapctrl.c.

Referenced by update_button_hold_state().

◆ button_up_on_map()

void button_up_on_map ( struct mouse_button_behavior button_behavior)

Use released mouse button over map.

Definition at line 2351 of file mapctrl.c.

Referenced by main_mouse_button_up_handler().

◆ close_game_page()

void close_game_page ( void  )

Close game page.

Definition at line 2021 of file mapctrl.c.

Referenced by real_set_client_page().

◆ disable_main_widgets()

void disable_main_widgets ( void  )

Disable game page widgets.

Definition at line 2102 of file mapctrl.c.

Referenced by popup_optiondlg().

◆ disable_minimap_window_buttons()

void disable_minimap_window_buttons ( void  )

Make minimap window buttons disabled.

Definition at line 1911 of file mapctrl.c.

Referenced by real_menus_update().

◆ disable_unitinfo_window_buttons()

void disable_unitinfo_window_buttons ( void  )

Make unitinfo buttons disabled.

Definition at line 1617 of file mapctrl.c.

Referenced by real_menus_update().

◆ enable_and_redraw_find_city_button()

void enable_and_redraw_find_city_button ( void  )

Make Find City button available.

Definition at line 2235 of file mapctrl.c.

Referenced by city_report_dialog_popdown(), and popdown_find_dialog().

◆ enable_and_redraw_revolution_button()

void enable_and_redraw_revolution_button ( void  )

Make Revolution button available.

Definition at line 2245 of file mapctrl.c.

Referenced by popdown_government_dialog().

◆ enable_main_widgets()

void enable_main_widgets ( void  )

Enable game page widgets.

Definition at line 2180 of file mapctrl.c.

Referenced by popdown_optiondlg(), and real_set_client_page().

◆ finger_down_on_map()

void finger_down_on_map ( struct finger_behavior finger_behavior)

Finger down handler

Definition at line 2254 of file mapctrl.c.

◆ finger_up_on_map()

void finger_up_on_map ( struct finger_behavior finger_behavior)

Finger up handler

Definition at line 2267 of file mapctrl.c.

Referenced by main_finger_up_handler().

◆ get_minimap_window_widget()

struct widget * get_minimap_window_widget ( void  )

◆ get_research_widget()

struct widget * get_research_widget ( void  )

◆ get_revolution_widget()

struct widget * get_revolution_widget ( void  )

Get main revolution widget.

Definition at line 2227 of file mapctrl.c.

Referenced by set_indicator_icons().

◆ get_tax_rates_widget()

struct widget * get_tax_rates_widget ( void  )

Get main tax rates widget.

Definition at line 2211 of file mapctrl.c.

Referenced by economy_report_dialog_popdown(), economy_report_dialog_popup(), exit_economy_dialog_callback(), and set_indicator_icons().

◆ get_unit_info_window_widget()

struct widget * get_unit_info_window_widget ( void  )

◆ hide_minimap_window_buttons()

void hide_minimap_window_buttons ( void  )

Make minimap window buttons hidden.

Definition at line 1836 of file mapctrl.c.

Referenced by real_menus_update().

◆ hide_unitinfo_window_buttons()

void hide_unitinfo_window_buttons ( void  )

Make unitinfo buttons hidden.

Definition at line 1593 of file mapctrl.c.

Referenced by real_menus_update().

◆ map_event_handler()

bool map_event_handler ( SDL_KeyboardEvent key)

Toggle map drawing stuff.

Definition at line 2440 of file mapctrl.c.

◆ popdown_minimap_window()

void popdown_minimap_window ( void  )

Close minimap window.

Definition at line 1945 of file mapctrl.c.

Referenced by close_game_page(), and resize_minimap().

◆ popdown_newcity_dialog()

void popdown_newcity_dialog ( void  )

Close new city dialog.

Definition at line 2897 of file mapctrl.c.

Referenced by popdown_all_game_dialogs().

◆ popdown_unitinfo_window()

void popdown_unitinfo_window ( void  )

Close unitinfo window.

Definition at line 1637 of file mapctrl.c.

Referenced by close_game_page().

◆ popup_minimap_window()

void popup_minimap_window ( void  )

Open minimap area.

Definition at line 1650 of file mapctrl.c.

Referenced by resize_minimap(), and show_game_page().

◆ popup_unitinfo_window()

void popup_unitinfo_window ( void  )

Open unitinfo window.

Definition at line 1454 of file mapctrl.c.

Referenced by show_game_page().

◆ redraw_minimap_window_buttons()

void redraw_minimap_window_buttons ( void  )

Redraw minimap window buttons.

Definition at line 1874 of file mapctrl.c.

Referenced by toggle_map_window_callback().

◆ resize_minimap()

int resize_minimap ( void  )

Update the size of the minimap

Definition at line 554 of file mapctrl.c.

Referenced by overview_size_changed().

◆ resize_unit_info()

int resize_unit_info ( void  )

◆ set_new_minimap_window_pos()

void set_new_minimap_window_pos ( void  )

This Function is used when resize main_data.screen. We must set new MiniMap start position.

Definition at line 1386 of file mapctrl.c.

Referenced by popup_minimap_window(), real_resize_window_callback(), and toggle_map_window_callback().

◆ set_new_unitinfo_window_pos()

void set_new_unitinfo_window_pos ( void  )

This Function is used when resize main_data.screen. We must set new Units Info Win. start position.

Definition at line 1332 of file mapctrl.c.

Referenced by popup_unitinfo_window(), real_resize_window_callback(), and toggle_unit_info_window_callback().

◆ show_game_page()

void show_game_page ( void  )

Create and show game page.

Definition at line 1958 of file mapctrl.c.

Referenced by real_set_client_page().

◆ show_minimap_window_buttons()

void show_minimap_window_buttons ( void  )

Make minimap window buttons visible.

Definition at line 1798 of file mapctrl.c.

Referenced by real_menus_update().

◆ show_unitinfo_window_buttons()

void show_unitinfo_window_buttons ( void  )

Make unitinfo buttons visible.

Definition at line 1569 of file mapctrl.c.

Referenced by real_menus_update().

Variable Documentation

◆ overview_h

int overview_h
extern

Definition at line 100 of file mapctrl.c.

Referenced by minimap_window_callback(), popup_minimap_window(), and resize_minimap().

◆ overview_w

int overview_w
extern