Changeset - r23489:b6c4411cc19c
[Not reviewed]
master
0 1 0
peter1138 - 5 years ago 2019-03-21 18:03:39
peter1138@openttd.org
Fix 4da83d2f66: Remove measurement tooltips when completed.
1 file changed with 2 insertions and 1 deletions:
0 comments (0 inline, 0 general)
src/viewport.cpp
Show inline comments
 
@@ -2511,13 +2511,13 @@ void UpdateTileSelection()
 
static inline void ShowMeasurementTooltips(StringID str, uint paramcount, const uint64 params[], TooltipCloseCondition close_cond = TCC_NONE)
 
{
 
	if (!_settings_client.gui.measure_tooltip) return;
 
	GuiShowTooltips(_thd.GetCallbackWnd(), str, paramcount, params, close_cond);
 
}
 

	
 
void HideMeasurementTooltips()
 
static void HideMeasurementTooltips()
 
{
 
	DeleteWindowById(WC_TOOLTIPS, 0);
 
}
 

	
 
/** highlighting tiles while only going over them with the mouse */
 
void VpStartPlaceSizing(TileIndex tile, ViewportPlaceMethod method, ViewportDragDropSelectionProcess process)
 
@@ -3189,12 +3189,13 @@ EventState VpHandlePlaceSizingDrag()
 
		_thd.place_mode = (_thd.select_method & ~VPM_RAILDIRS) ? _thd.next_drawstyle : (HT_RAIL | others);
 
	} else {
 
		_thd.place_mode = HT_POINT | others;
 
	}
 
	SetTileSelectSize(1, 1);
 

	
 
	HideMeasurementTooltips();
 
	w->OnPlaceMouseUp(_thd.select_method, _thd.select_proc, _thd.selend, TileVirtXY(_thd.selstart.x, _thd.selstart.y), TileVirtXY(_thd.selend.x, _thd.selend.y));
 

	
 
	return ES_HANDLED;
 
}
 

	
 
/**
0 comments (0 inline, 0 general)