summaryrefslogtreecommitdiff
path: root/src/main_gui.cpp
diff options
context:
space:
mode:
authorbelugas <belugas@openttd.org>2008-08-20 01:29:05 +0000
committerbelugas <belugas@openttd.org>2008-08-20 01:29:05 +0000
commit77ee09921217eac1540b82978178779eb839d08e (patch)
tree814ce35d6f66a7d5595be82243f5c4ba1bcdef9f /src/main_gui.cpp
parentbd6ef958e7f1073dfe9ea8b15c2877a0f9362251 (diff)
downloadopenttd-77ee09921217eac1540b82978178779eb839d08e.tar.xz
(svn r14104) -Feature: Add a window for waypoints, allowing to view all the trains having the selected waypoint in their orders.
Changing its name is also supported from the same new window. Gui based on work done by Satyap, on FS#2025.
Diffstat (limited to 'src/main_gui.cpp')
-rw-r--r--src/main_gui.cpp21
1 files changed, 0 insertions, 21 deletions
diff --git a/src/main_gui.cpp b/src/main_gui.cpp
index 218705527..39d44d9c6 100644
--- a/src/main_gui.cpp
+++ b/src/main_gui.cpp
@@ -66,10 +66,6 @@ void HandleOnEditText(const char *str)
_cmd_text = str;
switch (_rename_what) {
- case 1: // Rename a waypoint
- if (*str == '\0') return;
- DoCommandP(0, id, 0, NULL, CMD_RENAME_WAYPOINT | CMD_MSG(STR_CANT_CHANGE_WAYPOINT_NAME));
- break;
#ifdef ENABLE_NETWORK
case 3: { // Give money, you can only give money in excess of loan
const Player *p = GetPlayer(_current_player);
@@ -131,23 +127,6 @@ void ShowNetworkGiveMoneyWindow(PlayerID player)
}
#endif /* ENABLE_NETWORK */
-void ShowRenameWaypointWindow(const Waypoint *wp)
-{
- int id = wp->index;
-
- /* Are we allowed to change the name of the waypoint? */
- if (!CheckTileOwnership(wp->xy)) {
- ShowErrorMessage(_error_message, STR_CANT_CHANGE_WAYPOINT_NAME,
- TileX(wp->xy) * TILE_SIZE, TileY(wp->xy) * TILE_SIZE);
- return;
- }
-
- _rename_id = id;
- _rename_what = 1;
- SetDParam(0, id);
- ShowQueryString(STR_WAYPOINT_RAW, STR_EDIT_WAYPOINT_NAME, MAX_LENGTH_WAYPOINT_NAME_BYTES, MAX_LENGTH_WAYPOINT_NAME_PIXELS, NULL, CS_ALPHANUMERAL);
-}
-
/* Zooms a viewport in a window in or out */
/* No button handling or what so ever */