mirror of
https://github.com/atom/atom.git
synced 2026-02-16 01:25:13 -05:00
Just use the already existing change grammar event.
This commit is contained in:
@@ -550,7 +550,7 @@ class Workspace extends Model
|
||||
@project.bufferForPath(filePath, options).then (buffer) =>
|
||||
editor = @buildTextEditor(_.extend({buffer, largeFileMode}, options))
|
||||
disposable = atom.textEditors.add(editor)
|
||||
grammarSubscription = editor.onDidUseGrammar(@activateGrammar.bind(this))
|
||||
grammarSubscription = editor.onDidChangeGrammar(@activateGrammar.bind(this))
|
||||
editor.onDidDestroy ->
|
||||
grammarSubscription.dispose()
|
||||
disposable.dispose()
|
||||
|
||||
Reference in New Issue
Block a user