Address additional PR comments

on_activate is likely to happen first so we shouldn't need to check the
other.
develop
Kelvie Wong 2023-02-22 17:22:04 -08:00
parent d18700c964
commit 3c24e67a9a
2 changed files with 7 additions and 1 deletions

@ -3757,6 +3757,12 @@ Misc
Wraps ``dfhack.screen.getKeyDisplay`` in order to allow using strings for the keycode argument. Wraps ``dfhack.screen.getKeyDisplay`` in order to allow using strings for the keycode argument.
* ``invert_color(color, bold)``
This inverts the brightness of ``color``. If this color is coming from a pen's
foreground color, include ``pen.bold`` in ``bold`` for this to work properly.
ViewRect class ViewRect class
-------------- --------------

@ -1461,7 +1461,7 @@ end
function HotkeyLabel:shouldHover() function HotkeyLabel:shouldHover()
-- When on_activate is set, text should also hover on mouseover -- When on_activate is set, text should also hover on mouseover
return HotkeyLabel.super.shouldHover(self) or self.on_activate return self.on_activate or HotkeyLabel.super.shouldHover(self)
end end
function HotkeyLabel:initializeLabel() function HotkeyLabel:initializeLabel()