mirror of
https://github.com/OpenTTD/OpenTTD.git
synced 2025-03-06 14:27:16 +00:00
(svn r11713) -Codechange: Move some declarations and definitions in a more logical disposition
This commit is contained in:
parent
e2efaaff87
commit
5087a6cdd7
@ -29,6 +29,7 @@ int _fios_num;
|
|||||||
|
|
||||||
static char *_fios_path;
|
static char *_fios_path;
|
||||||
static FiosItem *_fios_items;
|
static FiosItem *_fios_items;
|
||||||
|
SmallFiosItem _file_to_saveload;
|
||||||
static int _fios_count, _fios_alloc;
|
static int _fios_count, _fios_alloc;
|
||||||
|
|
||||||
/* OS-specific functions are taken from their respective files (win32/unix/os2 .c) */
|
/* OS-specific functions are taken from their respective files (win32/unix/os2 .c) */
|
||||||
|
24
src/fios.h
24
src/fios.h
@ -23,14 +23,6 @@ enum {
|
|||||||
MAX_FILE_SLOTS = 64
|
MAX_FILE_SLOTS = 64
|
||||||
};
|
};
|
||||||
|
|
||||||
/* Deals with finding savegames */
|
|
||||||
struct FiosItem {
|
|
||||||
byte type;
|
|
||||||
uint64 mtime;
|
|
||||||
char title[64];
|
|
||||||
char name[256 - 12 - 64];
|
|
||||||
};
|
|
||||||
|
|
||||||
enum SaveLoadDialogMode{
|
enum SaveLoadDialogMode{
|
||||||
SLD_LOAD_GAME,
|
SLD_LOAD_GAME,
|
||||||
SLD_LOAD_SCENARIO,
|
SLD_LOAD_SCENARIO,
|
||||||
@ -54,9 +46,25 @@ enum {
|
|||||||
FIOS_TYPE_INVALID = 255,
|
FIOS_TYPE_INVALID = 255,
|
||||||
};
|
};
|
||||||
|
|
||||||
|
/* Deals with finding savegames */
|
||||||
|
struct FiosItem {
|
||||||
|
byte type;
|
||||||
|
uint64 mtime;
|
||||||
|
char title[64];
|
||||||
|
char name[256 - 12 - 64];
|
||||||
|
};
|
||||||
|
|
||||||
|
/* Deals with the type of the savegame, independent of extension */
|
||||||
|
struct SmallFiosItem {
|
||||||
|
int mode; ///< savegame/scenario type (old, new)
|
||||||
|
char name[MAX_PATH]; ///< name
|
||||||
|
char title[255]; ///< internal name of the game
|
||||||
|
};
|
||||||
|
|
||||||
/* Variables to display file lists */
|
/* Variables to display file lists */
|
||||||
extern FiosItem *_fios_list; ///< defined in misc_gui.cpp
|
extern FiosItem *_fios_list; ///< defined in misc_gui.cpp
|
||||||
extern int _fios_num; ///< defined in fios.cpp, read_only version of _fios_count
|
extern int _fios_num; ///< defined in fios.cpp, read_only version of _fios_count
|
||||||
|
extern SmallFiosItem _file_to_saveload;
|
||||||
extern SaveLoadDialogMode _saveload_mode; ///< defined in misc_gui.cpp
|
extern SaveLoadDialogMode _saveload_mode; ///< defined in misc_gui.cpp
|
||||||
|
|
||||||
/* Launch save/load dialog */
|
/* Launch save/load dialog */
|
||||||
|
@ -25,6 +25,7 @@
|
|||||||
#include "strings_func.h"
|
#include "strings_func.h"
|
||||||
#include "window_func.h"
|
#include "window_func.h"
|
||||||
#include "date_func.h"
|
#include "date_func.h"
|
||||||
|
#include "fios.h"
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* In what 'mode' the GenerateLandscapeWindowProc is.
|
* In what 'mode' the GenerateLandscapeWindowProc is.
|
||||||
|
@ -15,6 +15,7 @@
|
|||||||
#include "bmp.h"
|
#include "bmp.h"
|
||||||
#include "gfx_func.h"
|
#include "gfx_func.h"
|
||||||
#include "core/alloc_func.hpp"
|
#include "core/alloc_func.hpp"
|
||||||
|
#include "fios.h"
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Convert RGB colors to Grayscale using 29.9% Red, 58.7% Green, 11.4% Blue
|
* Convert RGB colors to Grayscale using 29.9% Red, 58.7% Green, 11.4% Blue
|
||||||
|
@ -19,7 +19,7 @@
|
|||||||
#include "genworld.h"
|
#include "genworld.h"
|
||||||
#include "tile_cmd.h"
|
#include "tile_cmd.h"
|
||||||
#include "core/alloc_func.hpp"
|
#include "core/alloc_func.hpp"
|
||||||
#include "functions.h"
|
#include "fios.h"
|
||||||
#include "window_func.h"
|
#include "window_func.h"
|
||||||
#include "functions.h"
|
#include "functions.h"
|
||||||
#include "date_func.h"
|
#include "date_func.h"
|
||||||
|
@ -32,6 +32,7 @@
|
|||||||
#include "engine.h"
|
#include "engine.h"
|
||||||
#include "sound.h"
|
#include "sound.h"
|
||||||
#include "fileio.h"
|
#include "fileio.h"
|
||||||
|
#include "fios.h"
|
||||||
#include "airport.h"
|
#include "airport.h"
|
||||||
#include "aircraft.h"
|
#include "aircraft.h"
|
||||||
#include "console.h"
|
#include "console.h"
|
||||||
|
@ -297,17 +297,9 @@ VARDEF TileIndex _terraform_err_tile;
|
|||||||
VARDEF TileIndex _build_tunnel_endtile;
|
VARDEF TileIndex _build_tunnel_endtile;
|
||||||
VARDEF bool _generating_world;
|
VARDEF bool _generating_world;
|
||||||
|
|
||||||
/* Deals with the type of the savegame, independent of extension */
|
|
||||||
struct SmallFiosItem {
|
|
||||||
int mode; // savegame/scenario type (old, new)
|
|
||||||
char name[MAX_PATH]; // name
|
|
||||||
char title[255]; // internal name of the game
|
|
||||||
};
|
|
||||||
|
|
||||||
/* Used when switching from the intro menu. */
|
/* Used when switching from the intro menu. */
|
||||||
VARDEF byte _switch_mode;
|
VARDEF byte _switch_mode;
|
||||||
VARDEF StringID _switch_mode_errorstr;
|
VARDEF StringID _switch_mode_errorstr;
|
||||||
VARDEF SmallFiosItem _file_to_saveload;
|
|
||||||
|
|
||||||
VARDEF char _ini_videodriver[32], _ini_musicdriver[32], _ini_sounddriver[32], _ini_blitter[32];
|
VARDEF char _ini_videodriver[32], _ini_musicdriver[32], _ini_sounddriver[32], _ini_blitter[32];
|
||||||
|
|
||||||
|
@ -12,6 +12,7 @@
|
|||||||
#include "../variables.h"
|
#include "../variables.h"
|
||||||
#include "../genworld.h"
|
#include "../genworld.h"
|
||||||
#include "../fileio.h"
|
#include "../fileio.h"
|
||||||
|
#include "../fios.h"
|
||||||
#include "../blitter/factory.hpp"
|
#include "../blitter/factory.hpp"
|
||||||
#include "../core/alloc_func.hpp"
|
#include "../core/alloc_func.hpp"
|
||||||
#include "dedicated_v.h"
|
#include "dedicated_v.h"
|
||||||
|
Loading…
Reference in New Issue
Block a user