mirror of
https://github.com/atom/atom.git
synced 2026-01-24 06:18:03 -05:00
Remove grammars from TextEditorElement.initialize
This commit is contained in:
@@ -27,7 +27,6 @@ class TextEditorElement extends HTMLElement
|
||||
@assert = atom.assert
|
||||
@views = atom.views
|
||||
@styles = atom.styles
|
||||
@grammars = atom.grammars
|
||||
|
||||
@emitter = new Emitter
|
||||
@subscriptions = new CompositeDisposable
|
||||
@@ -81,13 +80,12 @@ class TextEditorElement extends HTMLElement
|
||||
@subscriptions.add @component.onDidChangeScrollLeft =>
|
||||
@emitter.emit("did-change-scroll-left", arguments...)
|
||||
|
||||
initialize: (model, {@views, @themes, @workspace, @assert, @styles, @grammars}, @autoHeight = true, @scrollPastEnd = true) ->
|
||||
initialize: (model, {@views, @themes, @workspace, @assert, @styles}, @autoHeight = true, @scrollPastEnd = true) ->
|
||||
throw new Error("Must pass a views parameter when initializing TextEditorElements") unless @views?
|
||||
throw new Error("Must pass a themes parameter when initializing TextEditorElements") unless @themes?
|
||||
throw new Error("Must pass a workspace parameter when initializing TextEditorElements") unless @workspace?
|
||||
throw new Error("Must pass an assert parameter when initializing TextEditorElements") unless @assert?
|
||||
throw new Error("Must pass a styles parameter when initializing TextEditorElements") unless @styles?
|
||||
throw new Error("Must pass a grammars parameter when initializing TextEditorElements") unless @grammars?
|
||||
|
||||
@setModel(model)
|
||||
this
|
||||
@@ -134,7 +132,6 @@ class TextEditorElement extends HTMLElement
|
||||
themes: @themes
|
||||
workspace: @workspace
|
||||
assert: @assert
|
||||
grammars: @grammars
|
||||
scrollPastEnd: @scrollPastEnd
|
||||
)
|
||||
@rootElement.appendChild(@component.getDomNode())
|
||||
|
||||
Reference in New Issue
Block a user