diff options
| author | Simon Hauser <Simon-Hauser@outlook.de> | 2021-11-22 20:48:37 +0100 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2021-11-22 20:48:37 +0100 |
| commit | 6daf35c88c07dd4b220468968a742cda04889cd3 (patch) | |
| tree | 3f038291a7fda4555bcfb4891b5ea37b4542acc7 /lua/telescope/pickers.lua | |
| parent | 6f82c6630cea83b591beeebdc760705cafa3e426 (diff) | |
fix: action mt so we can again concat actions from two different tables (#1143)
* fix: action mt so we can again concat actions from two different tables
- without actually changing the public interface
- without having a local table that keeps track of all actions
* this should clear actions now
we never actually called this function which is kinda a problem because
we never cleaned up previous mapping stores.
We can also make a better mappings store which has access to the keys
sequences which would help the showing actions part
* bugfix
* that should now clear everything
only tests left i think
* more tests
* cleanup
* hack: make sure all actions get cleared
Diffstat (limited to 'lua/telescope/pickers.lua')
| -rw-r--r-- | lua/telescope/pickers.lua | 8 |
1 files changed, 1 insertions, 7 deletions
diff --git a/lua/telescope/pickers.lua b/lua/telescope/pickers.lua index bda4d53..936f377 100644 --- a/lua/telescope/pickers.lua +++ b/lua/telescope/pickers.lua @@ -8,7 +8,6 @@ local channel = require("plenary.async.control").channel local popup = require "plenary.popup" local actions = require "telescope.actions" -local action_set = require "telescope.actions.set" local config = require "telescope.config" local debounce = require "telescope.debounce" local deprecated = require "telescope.deprecated" @@ -48,12 +47,6 @@ function Picker:new(opts) error "layout_strategy and get_window_options are not compatible keys" end - -- Reset actions for any replaced / enhanced actions. - -- TODO: Think about how we could remember to NOT have to do this... - -- I almost forgot once already, cause I'm not smart enough to always do it. - actions._clear() - action_set._clear() - deprecated.options(opts) local layout_strategy = get_default(opts.layout_strategy, config.values.layout_strategy) @@ -1304,6 +1297,7 @@ function pickers.on_close_prompt(prompt_bufnr) end picker.close_windows(status) + mappings.clear(prompt_bufnr) end function pickers.on_resize_window(prompt_bufnr) |
