Changed mouse hover events for some controls

This commit is contained in:
Travis Nickles 2018-08-01 04:03:42 -05:00
parent 0fc4cb1e32
commit bd48966c7d

View File

@ -409,13 +409,28 @@ namespace DS4Windows
foreach (Control control in fLPSettings.Controls)
{
string tempst;
if (control.HasChildren)
{
foreach (Control ctrl in control.Controls)
{
if (hoverTextDict.TryGetValue(ctrl, out tempst))
{
ctrl.MouseHover += Items_MouseHover;
}
control.MouseHover += Items_MouseHover;
else
{
ctrl.MouseHover += ClearLastMessage;
}
}
}
else
{
if (hoverTextDict.TryGetValue(control, out tempst))
control.MouseEnter += Items_MouseHover;
else
control.MouseHover += ClearLastMessage;
}
}
}
@ -447,6 +462,12 @@ namespace DS4Windows
g.DrawImage(shield, new Rectangle(0, 0, finalWidth, finalHeight));
}
private void ClearLastMessage(object sender, EventArgs e)
{
lbLastMessage.Text = "";
lbLastMessage.ForeColor = SystemColors.GrayText;
}
private void blankControllerTab()
{
for (int Index = 0, PadsLen = Pads.Length;