diff --git a/docs/plugins/hotkeys.rst b/docs/plugins/hotkeys.rst index 6b2ef3f0c..561a34382 100644 --- a/docs/plugins/hotkeys.rst +++ b/docs/plugins/hotkeys.rst @@ -19,14 +19,17 @@ Usage Menu overlay widget ------------------- -The in-game hotkeys menu is registered with the `overlay` framework and can be -enabled as a hotspot in the upper-left corner of the screen. You can bring up -the menu by hovering the mouse cursor over the hotspot and can select a command -to run from the list by clicking on it with the mouse or by using the keyboard -to select a command with the arrow keys and hitting :kbd:`Enter`. +The in-game hotkeys menu is registered with the `overlay` framework and appears +as a DFHack logo in the upper-left corner of the screen. You can bring up the +menu by clicking on the logo or by hitting the global :kbd:`Ctrl`:kbd:`Shift`:kbd:`c` hotkey. You can select a command to run from +the list by clicking on it with the mouse or by using the keyboard to select a +command with the arrow keys and hitting :kbd:`Enter`. + +The menu closes automatically when an action is taken or when you click or +right click anywhere else on the screen. A short description of the command will appear in a nearby textbox. If you'd like to see the full help text for the command or edit the command before -running, you can open it for editing in `gui/launcher` by right clicking on the +running, you can open it for editing in `gui/launcher` by shift clicking on the command, left clicking on the arrow to the left of the command, or by pressing the right arrow key while the command is selected. diff --git a/plugins/lua/hotkeys.lua b/plugins/lua/hotkeys.lua index ac62b49e0..fae138353 100644 --- a/plugins/lua/hotkeys.lua +++ b/plugins/lua/hotkeys.lua @@ -297,7 +297,7 @@ function Menu:onRenderFrame(dc, rect) self.initialize() self.initialize = nil end - Menu.super.onRenderFrame(dc, rect) + Menu.super.onRenderFrame(self, dc, rect) end function Menu:getMouseFramePos() @@ -306,7 +306,7 @@ function Menu:getMouseFramePos() end function Menu:onRenderBody(dc) - local panel = self.subviews.list_panel + Menu.super.onRenderBody(self, dc) local list = self.subviews.list local idx = list:getIdxUnderMouse() if idx and idx ~= self.last_mouse_idx then @@ -316,13 +316,6 @@ function Menu:onRenderBody(dc) list:setSelected(idx) self.last_mouse_idx = idx end - if self:getMouseFramePos() then - self.mouseover = true - elseif self.mouseover then - -- once the mouse has entered the list area, leaving the frame should - -- close the menu screen - self.parent_view:dismiss() - end end -- ---------- --