Autocomplete bug fix #2233

This commit is contained in:
Aman Kumar 2015-02-14 02:11:00 +05:30
parent 80fb124772
commit 224213ccb0

View file

@ -443,6 +443,7 @@ module.exports = class SpellView extends CocoView
# window.snippetEntries = snippetEntries
lang = SpellView.editModes[e.language].substr 'ace/mode/'.length
@zatanna.addSnippets snippetEntries, lang
@newlang = lang
onMultiplayerChanged: ->
if @session.get('multiplayer')
@ -1091,7 +1092,7 @@ module.exports = class SpellView extends CocoView
@destroyAceEditor(@ace)
@debugView?.destroy()
@toolbarView?.destroy()
@zatanna.addSnippets [], @spell.language
@zatanna.addSnippets [], @newlang if @newlang?
$(window).off 'resize', @onWindowResize
super()