aboutsummaryrefslogtreecommitdiff
path: root/modules/textadept/command_entry.lua
diff options
context:
space:
mode:
authormitchell <70453897+667e-11@users.noreply.github.com>2020-08-22 16:34:47 -0400
committermitchell <70453897+667e-11@users.noreply.github.com>2020-08-22 16:34:47 -0400
commit2835799ac0581f667c9ef9b66fe2b155a5348ae5 (patch)
tree7405670a30895c5a81c64c315fbe5040b7d4e147 /modules/textadept/command_entry.lua
parentd9ae118774a156b5d8ed2f1f2747c65bca0ce76a (diff)
downloadtextadept-2835799ac0581f667c9ef9b66fe2b155a5348ae5.tar.gz
textadept-2835799ac0581f667c9ef9b66fe2b155a5348ae5.zip
Added `ui.command_entry.active` and fixed bugs in `events.KEYPRESS` handlers.
Diffstat (limited to 'modules/textadept/command_entry.lua')
-rw-r--r--modules/textadept/command_entry.lua3
1 files changed, 3 insertions, 0 deletions
diff --git a/modules/textadept/command_entry.lua b/modules/textadept/command_entry.lua
index db26b8f2..8033b48c 100644
--- a/modules/textadept/command_entry.lua
+++ b/modules/textadept/command_entry.lua
@@ -10,6 +10,8 @@ local M = ui.command_entry
-- running Lua code and filtering text through shell commands) and history.
-- @field height (number)
-- The height in pixels of the command entry.
+-- @field active (boolean)
+-- Whether or not the command entry is active.
module('ui.command_entry')]]
-- Command history per mode.
@@ -237,6 +239,7 @@ end
local orig_focus = M.focus
M.focus = function()
keys.mode = prev_key_mode
+ M.active = not M.active
orig_focus()
end