mirror of
https://github.com/overleaf/overleaf.git
synced 2024-12-02 11:38:51 -05:00
18 lines
370 B
CoffeeScript
18 lines
370 B
CoffeeScript
|
define [
|
||
|
"file-view/FileView"
|
||
|
], (FileView) ->
|
||
|
class FileViewManager
|
||
|
constructor: (@ide) ->
|
||
|
@view = new FileView()
|
||
|
|
||
|
@ide.mainAreaManager.addArea
|
||
|
identifier: "file"
|
||
|
element: @view.$el
|
||
|
|
||
|
$(window).resize () => @view.onResize()
|
||
|
@ide.layoutManager.on "resize", () => @view.onResize()
|
||
|
@view.onResize()
|
||
|
|
||
|
showFile: (file) ->
|
||
|
@view.setModel(file)
|