From 87e247e74040b5e80ff40003d233d5317881102a Mon Sep 17 00:00:00 2001 From: Ananya Sen Date: Thu, 2 Feb 2012 03:30:54 -0800 Subject: fixed code view container, and switching code view Signed-off-by: Ananya Sen --- js/io/document/text-document.js | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) (limited to 'js/io/document/text-document.js') diff --git a/js/io/document/text-document.js b/js/io/document/text-document.js index a9081cb5..156aaacb 100755 --- a/js/io/document/text-document.js +++ b/js/io/document/text-document.js @@ -17,6 +17,8 @@ var TextDocument = exports.TextDocument = Montage.create(baseDocumentModule.Base } }, + _textArea: {value: null, enumerable: false }, + _source: { value: null, enumerable: false}, source: { @@ -31,6 +33,10 @@ var TextDocument = exports.TextDocument = Montage.create(baseDocumentModule.Base // GETTERS / SETTERS + textArea: { + get: function() { return this._textArea; }, + set: function(value) { this._textArea = value; } + }, editor: { get: function() { return this._codeEditor.editor; }, set: function(value) { this._codeEditor.editor = value} @@ -44,8 +50,8 @@ var TextDocument = exports.TextDocument = Montage.create(baseDocumentModule.Base // PUBLIC METHODS initialize: { - value: function(doc, uuid, textArea, callback) { - this.init(doc.name, doc.uri, doc.type, textArea, uuid, null, doc.externalUri); + value: function(doc, uuid, textArea, container, callback) { + this.init(doc.name, doc.uri, doc.type, container, uuid); this.currentView = "code"; this.textArea = textArea; -- cgit v1.2.3