Changeset - r15538:080d91997992
[Not reviewed]
master
0 1 0
alberth - 14 years ago 2010-07-23 18:40:39
alberth@openttd.org
(svn r20207) -Codechange: Move variable declaration to first use.
1 file changed with 4 insertions and 5 deletions:
0 comments (0 inline, 0 general)
src/industry_gui.cpp
Show inline comments
 
@@ -759,11 +759,9 @@ public:
 

	
 
	virtual void OnClick(Point pt, int widget, int click_count)
 
	{
 
		Industry *i;
 

	
 
		switch (widget) {
 
			case IVW_INFO: {
 
				i = Industry::Get(this->window_number);
 
				Industry *i = Industry::Get(this->window_number);
 

	
 
				/* We should work if needed.. */
 
				if (!IsProductionAlterable(i)) return;
 
@@ -799,8 +797,8 @@ public:
 
				}
 
			} break;
 

	
 
			case IVW_GOTO:
 
				i = Industry::Get(this->window_number);
 
			case IVW_GOTO: {
 
				Industry *i = Industry::Get(this->window_number);
 
				if (_ctrl_pressed) {
 
					ShowExtraViewPortWindow(i->location.tile + TileDiffXY(1, 1));
 
				} else {
 
@@ -809,6 +807,7 @@ public:
 
				break;
 
		}
 
	}
 
	}
 

	
 
	virtual void OnTimeout()
 
	{
0 comments (0 inline, 0 general)