~ubuntu-branches/debian/squeeze/openttd/squeeze

« back to all changes in this revision

Viewing changes to src/aircraft_gui.cpp

  • Committer: Bazaar Package Importer
  • Author(s): Jordi Mallach, Matthijs Kooijman, Jordi Mallach
  • Date: 2009-04-15 18:22:10 UTC
  • mfrom: (1.1.6 upstream) (2.1.3 squeeze)
  • Revision ID: james.westby@ubuntu.com-20090415182210-22ktb8kdbp2tf3bm
[ Matthijs Kooijman ]
* New upstream release.
* Remove Debian specific desktop file, upstream provides one now. 
* Add debian/watch file.

[ Jordi Mallach ]
* Bump Standards-Version to 3.8.1, with no changes required.
* Move to debhelper compat 7. Bump Build-Depends accordingly.
* Use dh_prep.
* Add "set -e" to config script.
* Remove a few extra doc files that get installed by upstream Makefile.
* Add more complete copyright information.

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
/* $Id: aircraft_gui.cpp 14267 2008-09-07 21:41:47Z rubidium $ */
 
1
/* $Id: aircraft_gui.cpp 15711 2009-03-14 18:16:29Z rubidium $ */
2
2
 
3
 
/** @file aircraft_gui.cpp */
 
3
/** @file aircraft_gui.cpp The GUI of aircraft. */
4
4
 
5
5
#include "stdafx.h"
6
 
#include "openttd.h"
7
6
#include "aircraft.h"
8
 
#include "debug.h"
9
 
#include "gui.h"
10
 
#include "engine.h"
11
 
#include "depot.h"
12
7
#include "vehicle_gui.h"
13
8
#include "newgrf_engine.h"
14
9
#include "strings_func.h"
15
10
#include "vehicle_func.h"
16
11
#include "gfx_func.h"
 
12
#include "window_gui.h"
17
13
 
18
14
#include "table/sprites.h"
19
15
#include "table/strings.h"
20
16
 
21
17
/**
22
 
* Draw the details for the given vehicle at the position (x,y)
23
 
*
24
 
* @param v current vehicle
25
 
* @param x The x coordinate
26
 
* @param y The y coordinate
27
 
*/
 
18
 * Draw the details for the given vehicle at the position (x, y)
 
19
 *
 
20
 * @param v current vehicle
 
21
 * @param x The x coordinate
 
22
 * @param y The y coordinate
 
23
 */
28
24
void DrawAircraftDetails(const Vehicle *v, int x, int y)
29
25
{
30
26
        int y_offset = (v->Next()->cargo_cap != 0) ? -11 : 0;
41
37
                        SetDParam(1, u->cargo_cap);
42
38
                        SetDParam(2, u->Next()->cargo_type);
43
39
                        SetDParam(3, u->Next()->cargo_cap);
 
40
                        SetDParam(4, GetCargoSubtypeText(u));
44
41
                        DrawString(x, y + 10, (u->Next()->cargo_cap != 0) ? STR_A019_CAPACITY : STR_A01A_CAPACITY, TC_FROMSTRING);
45
42
                }
46
43
 
74
71
                DrawSprite(rotor_sprite, PAL_NONE, x + 25, y + 5);
75
72
        }
76
73
        if (v->index == selection) {
77
 
                DrawFrameRect(x - 1, y - 1, x + 58, y + 21, 0xF, FR_BORDERONLY);
 
74
                DrawFrameRect(x - 1, y - 1, x + 58, y + 21, COLOUR_WHITE, FR_BORDERONLY);
78
75
        }
79
76
}
80
77