aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authormitchell <70453897+667e-11@users.noreply.github.com>2011-02-13 14:09:19 -0500
committermitchell <70453897+667e-11@users.noreply.github.com>2011-02-13 14:09:19 -0500
commit04e2c0ee4c69682f263bc0f210832b39820ddd30 (patch)
tree4a4506385c7bad7d7696b06ec88da92e0cc23ebb
parentd6056c9b83a3c90cd406a805f38d25406315ca81 (diff)
downloadtextadept-04e2c0ee4c69682f263bc0f210832b39820ddd30.tar.gz
textadept-04e2c0ee4c69682f263bc0f210832b39820ddd30.zip
Show completions for current context too; modules/textadept/adeptsense.lua
-rw-r--r--modules/textadept/adeptsense.lua3
1 files changed, 3 insertions, 0 deletions
diff --git a/modules/textadept/adeptsense.lua b/modules/textadept/adeptsense.lua
index 4786360d..f8c7dac0 100644
--- a/modules/textadept/adeptsense.lua
+++ b/modules/textadept/adeptsense.lua
@@ -109,6 +109,9 @@ function get_completions(sense, symbol, only_fields, only_functions)
end
if not only_functions then
for _, v in ipairs(compls[class].fields) do c[#c + 1] = v end
+ if include_globals then
+ for _, v in ipairs(compls[''].fields) do c[#c + 1] = v end
+ end
end
for _, inherited in ipairs(sense.class_list[class] or {}) do
if compls[inherited] then