Mercurial > hg > openttd
changeset 17505:d68245dc94f0 draft
(svn r22266) -Fix [FS#4558]: In the scenario editor you could build a ship depot using the hotkeys. Removing that depot causes an assertions to trigger.
author | rubidium <rubidium@openttd.org> |
---|---|
date | Sun, 20 Mar 2011 20:51:31 +0000 |
parents | 03d4e751552d |
children | cd0b20f2ac8c |
files | src/dock_gui.cpp |
diffstat | 1 files changed, 2 insertions(+), 2 deletions(-) [+] |
line wrap: on
line diff
--- a/src/dock_gui.cpp +++ b/src/dock_gui.cpp @@ -136,7 +136,6 @@ virtual void OnClick(Point pt, int widget, int click_count) { - this->last_clicked_widget = (DockToolbarWidgets)widget; switch (widget) { case DTW_CANAL: // Build canal button HandlePlacePushButton(this, DTW_CANAL, SPR_CURSOR_CANAL, HT_RECT); @@ -174,8 +173,9 @@ HandlePlacePushButton(this, DTW_BUILD_AQUEDUCT, SPR_CURSOR_AQUEDUCT, HT_SPECIAL); break; - default: break; + default: return; } + this->last_clicked_widget = (DockToolbarWidgets)widget; } virtual EventState OnKeyPress(uint16 key, uint16 keycode)