summaryrefslogtreecommitdiff
path: root/main_gui.c
diff options
context:
space:
mode:
authorDarkvater <darkvater@openttd.org>2005-06-06 13:47:06 +0000
committerDarkvater <darkvater@openttd.org>2005-06-06 13:47:06 +0000
commit5fed47964e28c49f7af879700d013f2897341f4e (patch)
treeac935893726bc7005c7c5ad7d411354e5b8cc0f9 /main_gui.c
parent71c2a573e193b0e4530cee49e02148320c84c612 (diff)
downloadopenttd-5fed47964e28c49f7af879700d013f2897341f4e.tar.xz
(svn r2420) - Codechange: magic number elminitation of cursorsprites.
Diffstat (limited to 'main_gui.c')
-rw-r--r--main_gui.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/main_gui.c b/main_gui.c
index 08c790e39..fa8495f64 100644
--- a/main_gui.c
+++ b/main_gui.c
@@ -122,7 +122,7 @@ void HandleOnEditText(WindowEvent *e)
* @return true if the button is clicked, false if it's unclicked
*/
-bool HandlePlacePushButton(Window *w, int widget, uint32 cursor, int mode, PlaceProc *placeproc)
+bool HandlePlacePushButton(Window *w, int widget, CursorID cursor, int mode, PlaceProc *placeproc)
{
uint32 mask = 1 << widget;
@@ -406,10 +406,10 @@ void ShowRenameWaypointWindow(Waypoint *wp)
static void SelectSignTool(void)
{
- if (_cursor.sprite == 0x2D2)
+ if (_cursor.sprite == SPR_CURSOR_SIGN)
ResetObjectToPlace();
else {
- SetObjectToPlace(0x2D2, 1, 1, 0);
+ SetObjectToPlace(SPR_CURSOR_SIGN, 1, 1, 0);
_place_proc = PlaceProc_Sign;
}
}
@@ -1713,7 +1713,7 @@ static void ScenEditIndustryWndProc(Window *w, WindowEvent *e)
}
if ((button=e->click.widget) >= 4) {
- if (HandlePlacePushButton(w, button, 0xFF1, 1, NULL))
+ if (HandlePlacePushButton(w, button, SPR_CURSOR_INDUSTRY, 1, NULL))
_industry_type_to_place = _industry_type_list[_opt.landscape][button - 4];
}
break;