modify dropdown to trigger on command completion if possible

This commit is contained in:
Nate Stemen 2018-06-15 08:56:03 -04:00
parent 55112dc7dc
commit b8787e6e68

View file

@ -192,6 +192,13 @@ define [
setTimeout () =>
@editor.execCommand("startAutocomplete")
, 0
if (
change.action == "insert" and
change.lines[0] in ["\\begin{}", "\\ref{}", "\\usepackage{}", "\\cite{}"]
)
setTimeout () =>
@editor.execCommand("startAutocomplete")
, 0
monkeyPatchAutocomplete: () ->
Autocomplete = ace.require("ace/autocomplete").Autocomplete