Move header definition for unit conversion functions to own header.

pull/8/head
Jonathan G Rennison 8 years ago
parent b5531975da
commit 2c6f74a982

@ -393,6 +393,7 @@ widget_type.h
os/windows/win32.h
music/win32_m.h
sound/win32_s.h
unit_conversion.h
video/win32_v.h
window_func.h
window_gui.h

@ -34,6 +34,7 @@
#include "smallmap_gui.h"
#include "window_func.h"
#include "debug.h"
#include "unit_conversion.h"
#include "game/game_text.hpp"
#include "network/network_content_gui.h"
#include <stack>

@ -36,17 +36,9 @@
#include "cargotype.h"
#include "sortlist_type.h"
#include "group.h"
#include "unit_conversion.h"
#include "table/sprites.h"
extern uint ConvertSpeedToDisplaySpeed(uint speed);
extern uint ConvertDisplaySpeedToSpeed(uint speed);
extern uint ConvertWeightToDisplayWeight(uint weight);
extern uint ConvertDisplayWeightToWeight(uint weight);
extern uint ConvertPowerToDisplayPower(uint power);
extern uint ConvertDisplayPowerToPower(uint power);
extern uint ConvertForceToDisplayForce(uint force);
extern uint ConvertDisplayForceToForce(uint force);
/** Widget IDs */
enum TraceRestrictWindowWidgets {
TR_WIDGET_CAPTION,

@ -0,0 +1,19 @@
/* $Id$ */
/*
* This file is part of OpenTTD.
* OpenTTD is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, version 2.
* OpenTTD is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
* See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with OpenTTD. If not, see <http://www.gnu.org/licenses/>.
*/
/** @file unit_conversion.h Functions related to unit conversion. */
uint ConvertSpeedToDisplaySpeed(uint speed);
uint ConvertDisplaySpeedToSpeed(uint speed);
uint ConvertWeightToDisplayWeight(uint weight);
uint ConvertDisplayWeightToWeight(uint weight);
uint ConvertPowerToDisplayPower(uint power);
uint ConvertDisplayPowerToPower(uint power);
uint ConvertForceToDisplayForce(uint force);
uint ConvertDisplayForceToForce(uint force);
Loading…
Cancel
Save