mirror of https://github.com/stella-emu/stella.git
Highlight widgets when they gain and lose focus.
- This allows widgets that are navigated using the keyboard/joystick to look the same as when using the mouse. - For R77 in particular, this really helps when seeing which button is currently selected.
This commit is contained in:
parent
ce989df3e2
commit
fccd62607b
|
@ -140,6 +140,7 @@ void Widget::receivedFocus()
|
||||||
return;
|
return;
|
||||||
|
|
||||||
_hasFocus = true;
|
_hasFocus = true;
|
||||||
|
setFlags(Widget::FLAG_HILITED);
|
||||||
receivedFocusWidget();
|
receivedFocusWidget();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -150,6 +151,7 @@ void Widget::lostFocus()
|
||||||
return;
|
return;
|
||||||
|
|
||||||
_hasFocus = false;
|
_hasFocus = false;
|
||||||
|
clearFlags(Widget::FLAG_HILITED);
|
||||||
lostFocusWidget();
|
lostFocusWidget();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue