mirror of
https://github.com/OpenTTD/OpenTTD.git
synced 2025-06-20 03:59:32 +01:00
(svn r2535) Tabs
This commit is contained in:
parent
83f72f696a
commit
1b4a0897b6
@ -331,7 +331,7 @@ static void DestructIndustry(Industry *i)
|
|||||||
{
|
{
|
||||||
TileIndex tile;
|
TileIndex tile;
|
||||||
|
|
||||||
for(tile=0; tile != MapSize(); tile++) {
|
for (tile = 0; tile != MapSize(); tile++) {
|
||||||
if (IsTileType(tile, MP_INDUSTRY) && _map2[tile] == i->index) {
|
if (IsTileType(tile, MP_INDUSTRY) && _map2[tile] == i->index) {
|
||||||
_map_owner[tile] = 0;
|
_map_owner[tile] = 0;
|
||||||
MarkTileDirtyByTile(tile);
|
MarkTileDirtyByTile(tile);
|
||||||
|
@ -727,7 +727,7 @@ static const char * const _cached_filenames[4] = {
|
|||||||
|
|
||||||
#define OPENTTD_SPRITES_COUNT 98
|
#define OPENTTD_SPRITES_COUNT 98
|
||||||
static const uint16 _openttd_grf_indexes[] = {
|
static const uint16 _openttd_grf_indexes[] = {
|
||||||
SPR_OPENTTD_BASE+0, SPR_OPENTTD_BASE+7, // icons etc
|
SPR_OPENTTD_BASE + 0, SPR_OPENTTD_BASE + 7, // icons etc
|
||||||
134, 134, // euro symbol medium size
|
134, 134, // euro symbol medium size
|
||||||
582, 582, // euro symbol large size
|
582, 582, // euro symbol large size
|
||||||
358, 358, // euro symbol tiny
|
358, 358, // euro symbol tiny
|
||||||
|
@ -120,8 +120,8 @@ static void MakeSortedStationList(byte owner)
|
|||||||
firstelement = &_station_sort[0];
|
firstelement = &_station_sort[0];
|
||||||
n = _num_station_sort[0];
|
n = _num_station_sort[0];
|
||||||
} else { // nth element starts at the end of the previous one, and has n elements as described above
|
} else { // nth element starts at the end of the previous one, and has n elements as described above
|
||||||
firstelement = &_station_sort[_num_station_sort[owner-1]];
|
firstelement = &_station_sort[_num_station_sort[owner - 1]];
|
||||||
n = _num_station_sort[owner] - _num_station_sort[owner-1];
|
n = _num_station_sort[owner] - _num_station_sort[owner - 1];
|
||||||
}
|
}
|
||||||
|
|
||||||
_last_station_idx = 0; // used for "cache" in namesorting
|
_last_station_idx = 0; // used for "cache" in namesorting
|
||||||
|
@ -434,8 +434,8 @@ static const SaveLoad _waypoint_desc[] = {
|
|||||||
SLE_CONDVAR(Waypoint, xy, SLE_UINT32, 6, 255),
|
SLE_CONDVAR(Waypoint, xy, SLE_UINT32, 6, 255),
|
||||||
SLE_CONDVAR(Waypoint, town_index, SLE_UINT16, 12, 255),
|
SLE_CONDVAR(Waypoint, town_index, SLE_UINT16, 12, 255),
|
||||||
SLE_CONDVAR(Waypoint, town_cn, SLE_UINT8, 12, 255),
|
SLE_CONDVAR(Waypoint, town_cn, SLE_UINT8, 12, 255),
|
||||||
SLE_VAR(Waypoint,string, SLE_UINT16),
|
SLE_VAR(Waypoint, string, SLE_UINT16),
|
||||||
SLE_VAR(Waypoint,deleted, SLE_UINT8),
|
SLE_VAR(Waypoint, deleted, SLE_UINT8),
|
||||||
|
|
||||||
SLE_CONDVAR(Waypoint, build_date, SLE_UINT16, 3, 255),
|
SLE_CONDVAR(Waypoint, build_date, SLE_UINT16, 3, 255),
|
||||||
SLE_CONDVAR(Waypoint, stat_id, SLE_UINT8, 3, 255),
|
SLE_CONDVAR(Waypoint, stat_id, SLE_UINT8, 3, 255),
|
||||||
|
6
widget.c
6
widget.c
@ -160,7 +160,8 @@ void DrawWindowWidgets(Window *w)
|
|||||||
uint32 dparam_backup[20];
|
uint32 dparam_backup[20];
|
||||||
uint32 cur_click, cur_disabled, cur_hidden;
|
uint32 cur_click, cur_disabled, cur_hidden;
|
||||||
|
|
||||||
if (w->desc_flags & WDF_RESTORE_DPARAM) COPY_OUT_DPARAM(dparam_backup, 0, lengthof(dparam_backup));
|
if (w->desc_flags & WDF_RESTORE_DPARAM)
|
||||||
|
COPY_OUT_DPARAM(dparam_backup, 0, lengthof(dparam_backup));
|
||||||
|
|
||||||
wi = w->widget;
|
wi = w->widget;
|
||||||
|
|
||||||
@ -425,7 +426,8 @@ void DrawWindowWidgets(Window *w)
|
|||||||
|
|
||||||
DrawStringCentered( (r.left+r.right+1)>>1, r.top+2, wi->unkA, 0x84);
|
DrawStringCentered( (r.left+r.right+1)>>1, r.top+2, wi->unkA, 0x84);
|
||||||
restore_dparam:;
|
restore_dparam:;
|
||||||
if (w->desc_flags & WDF_RESTORE_DPARAM) COPY_IN_DPARAM(0, dparam_backup, lengthof(dparam_backup));
|
if (w->desc_flags & WDF_RESTORE_DPARAM)
|
||||||
|
COPY_IN_DPARAM(0, dparam_backup, lengthof(dparam_backup));
|
||||||
draw_default:;
|
draw_default:;
|
||||||
if (cur_disabled & 1) {
|
if (cur_disabled & 1) {
|
||||||
GfxFillRect(r.left+1, r.top+1, r.right-1, r.bottom-1, _color_list[wi->color&0xF].unk2 | 0x8000);
|
GfxFillRect(r.left+1, r.top+1, r.right-1, r.bottom-1, _color_list[wi->color&0xF].unk2 | 0x8000);
|
||||||
|
9
win32.c
9
win32.c
@ -148,9 +148,9 @@ static uint MapWindowsKey(uint sym)
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (GetAsyncKeyState(VK_SHIFT)<0) key |= WKC_SHIFT;
|
if (GetAsyncKeyState(VK_SHIFT) < 0) key |= WKC_SHIFT;
|
||||||
if (GetAsyncKeyState(VK_CONTROL)<0) key |= WKC_CTRL;
|
if (GetAsyncKeyState(VK_CONTROL) < 0) key |= WKC_CTRL;
|
||||||
if (GetAsyncKeyState(VK_MENU)<0) key |= WKC_ALT;
|
if (GetAsyncKeyState(VK_MENU) < 0) key |= WKC_ALT;
|
||||||
return key;
|
return key;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -1073,7 +1073,8 @@ static uint32 *_crc_table;
|
|||||||
|
|
||||||
static void MakeCRCTable(uint32 *table) {
|
static void MakeCRCTable(uint32 *table) {
|
||||||
uint32 crc, poly = 0xEDB88320L;
|
uint32 crc, poly = 0xEDB88320L;
|
||||||
int i, j;
|
int i;
|
||||||
|
int j;
|
||||||
|
|
||||||
_crc_table = table;
|
_crc_table = table;
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user