Changeset - r26390:2357f0b295b0
[Not reviewed]
master
0 1 0
PeterN - 21 months ago 2022-09-21 11:08:11
peter1138@openttd.org
Fix: File list mouse hover behaviour. (#10040)

Hover highlight was visible even if the mouse pointer was in a different
window. Resolved by using OnMouseOver() instead of OnMouseLoop().
1 file changed with 1 insertions and 4 deletions:
0 comments (0 inline, 0 general)
src/fios_gui.cpp
Show inline comments
 
@@ -721,11 +721,8 @@ public:
 
		}
 
	}
 

	
 
	void OnMouseLoop() override
 
	void OnMouseOver(Point pt, int widget) override
 
	{
 
		const Point pt{ _cursor.pos.x - this->left, _cursor.pos.y - this->top };
 
		const int widget = GetWidgetFromPos(this, pt.x, pt.y);
 

	
 
		if (widget == WID_SL_DRIVES_DIRECTORIES_LIST) {
 
			int y = this->vscroll->GetScrolledRowFromWidget(pt.y, this, WID_SL_DRIVES_DIRECTORIES_LIST, WD_FRAMERECT_TOP);
 
			if (y == INT_MAX) return;
0 comments (0 inline, 0 general)