Freeciv-3.2
|
#include <stdlib.h>
#include <gtk/gtk.h>
#include "log.h"
#include "mem.h"
#include "string_vector.h"
#include "options.h"
#include "colors.h"
#include "dialogs.h"
#include "gui_main.h"
#include "gui_stuff.h"
#include "pages.h"
#include "optiondlg.h"
#include "speclist.h"
Go to the source code of this file.
Data Structures | |
struct | option_dialog |
Enumerations | |
enum | { RESPONSE_CANCEL , RESPONSE_OK , RESPONSE_APPLY , RESPONSE_RESET , RESPONSE_REFRESH , RESPONSE_SAVE } |
Variables | |
static int | opt_dlog_width = -1 |
static int | opt_dlog_height = 480 |
static struct option_dialog_list * | option_dialogs = NULL |
#define option_dialogs_iterate | ( | pdialog | ) | TYPED_LIST_ITERATE(struct option_dialog, option_dialogs, pdialog) |
Definition at line 54 of file optiondlg.c.
#define option_dialogs_iterate_end LIST_ITERATE_END |
Definition at line 56 of file optiondlg.c.
#define SPECLIST_TAG option_dialog |
Definition at line 51 of file optiondlg.c.
#define SPECLIST_TYPE struct option_dialog |
Definition at line 52 of file optiondlg.c.
Enumerator | |
---|---|
RESPONSE_CANCEL | |
RESPONSE_OK | |
RESPONSE_APPLY | |
RESPONSE_RESET | |
RESPONSE_REFRESH | |
RESPONSE_SAVE |
Definition at line 61 of file optiondlg.c.
"response" signal callback.
Definition at line 310 of file optiondlg.c.
Referenced by option_color_select_callback().
|
static |
Option apply requested from menu.
Definition at line 180 of file optiondlg.c.
Referenced by option_button_press_callback(), and option_button_press_callback().
|
static |
Called when a button is pressed on an option.
Definition at line 193 of file optiondlg.c.
Referenced by option_dialog_option_add().
GDestroyNotify callback.
Definition at line 247 of file optiondlg.c.
Referenced by option_color_set_button_color().
Called when the user press a color button.
Definition at line 332 of file optiondlg.c.
Referenced by option_dialog_option_add().
Set the color of a button.
Definition at line 259 of file optiondlg.c.
Referenced by color_selector_response_callback(), and option_dialog_option_color_set().
|
static |
Destroys an option dialog.
Definition at line 418 of file optiondlg.c.
Referenced by option_dialog_destroy_callback(), option_dialog_popdown(), and popdown_optiondlg().
Option dialog widget destroyed callback.
Definition at line 130 of file optiondlg.c.
Referenced by option_dialog_new().
|
inlinestatic |
Do an action for all options of the option dialog.
Definition at line 478 of file optiondlg.c.
Referenced by option_dialog_popup(), and option_dialog_reponse_callback().
|
static |
Returns the option dialog which fit the option set.
Definition at line 232 of file optiondlg.c.
Referenced by option_apply_callback(), option_apply_callback(), option_dialog_popdown(), option_dialog_popup(), option_gui_add(), option_gui_remove(), option_gui_update(), option_refresh_callback(), option_refresh_callback(), option_reset_callback(), and option_reset_callback().
|
static |
Creates a new option dialog.
Definition at line 362 of file optiondlg.c.
|
static |
Add an option to the option dialog.
Definition at line 492 of file optiondlg.c.
Referenced by option_dialog_new(), and option_gui_add().
Apply the option change.
Definition at line 892 of file optiondlg.c.
Referenced by option_apply_callback(), option_apply_callback(), and option_dialog_reponse_callback().
|
inlinestatic |
Set the enum value of the option.
Definition at line 759 of file optiondlg.c.
Referenced by option_dialog_option_refresh(), and option_dialog_option_reset().
Set the boolean value of the option.
Definition at line 699 of file optiondlg.c.
Referenced by option_dialog_option_refresh(), and option_dialog_option_reset().
|
inlinestatic |
Set the font value of the option.
Definition at line 785 of file optiondlg.c.
Referenced by option_dialog_option_refresh(), and option_dialog_option_reset().
Set the enum value of the option.
Definition at line 734 of file optiondlg.c.
Referenced by option_dialog_option_refresh(), and option_dialog_option_reset().
|
inlinestatic |
Set the font value of the option.
Definition at line 775 of file optiondlg.c.
Referenced by option_dialog_option_refresh(), and option_dialog_option_reset().
Set the integer value of the option.
Definition at line 710 of file optiondlg.c.
Referenced by option_dialog_option_refresh(), and option_dialog_option_reset().
Update an option in the option dialog.
Definition at line 819 of file optiondlg.c.
Referenced by option_dialog_option_add(), option_dialog_popup(), option_dialog_reponse_callback(), option_gui_update(), option_refresh_callback(), and option_refresh_callback().
|
static |
Remove an option from the option dialog.
Definition at line 677 of file optiondlg.c.
Referenced by option_gui_remove().
Reset the option.
Definition at line 857 of file optiondlg.c.
Referenced by option_dialog_reponse_callback(), option_reset_callback(), and option_reset_callback().
|
inlinestatic |
Set the string value of the option.
Definition at line 720 of file optiondlg.c.
Referenced by option_dialog_option_refresh(), and option_dialog_option_reset().
Utility for sorting the pages of an option dialog.
Definition at line 444 of file optiondlg.c.
Referenced by option_dialog_reorder_notebook().
void option_dialog_popdown | ( | const struct option_set * | poptset | ) |
Popdown the option dialog for the option set.
Definition at line 999 of file optiondlg.c.
Referenced by server_options_free().
Popup the option dialog for the option set.
Definition at line 985 of file optiondlg.c.
Referenced by client_options_callback(), game_options_callback(), local_options_callback(), local_options_callback(), open_settings(), fc_client::popup_client_options(), pregame_options::popup_server_options(), server_options_callback(), server_options_callback(), and server_options_callback().
|
static |
Reorder the pages of the notebook of the option dialog.
Definition at line 456 of file optiondlg.c.
Referenced by option_dialog_new(), and option_dialog_option_add().
|
static |
Option dialog widget response callback.
Definition at line 98 of file optiondlg.c.
Referenced by option_dialog_new().
Add the GUI for the option.
Definition at line 1040 of file optiondlg.c.
Remove the GUI for the option.
Definition at line 1054 of file optiondlg.c.
Referenced by server_option_free().
Update the GUI for the option.
Definition at line 1026 of file optiondlg.c.
Referenced by option_changed().
Pass on updated option values to controls outside the main option dialogs.
Definition at line 1012 of file optiondlg.c.
Referenced by option_gui_add(), and option_gui_update().
|
static |
Option refresh requested from menu.
Definition at line 154 of file optiondlg.c.
Referenced by option_button_press_callback(), and option_button_press_callback().
|
static |
Option reset requested from menu.
Definition at line 167 of file optiondlg.c.
Referenced by option_button_press_callback(), and option_button_press_callback().
|
static |
Definition at line 39 of file optiondlg.c.
Referenced by option_dialog_destroy_callback(), and option_dialog_new().
|
static |
Definition at line 39 of file optiondlg.c.
Referenced by option_dialog_destroy_callback(), and option_dialog_new().
|
static |
Definition at line 59 of file optiondlg.c.
Referenced by option_dialog_destroy(), option_dialog_get(), and option_dialog_new().