From c51a1317a767dcd5dfded822815305d4330f4892 Mon Sep 17 00:00:00 2001 From: Ananya Sen Date: Mon, 7 May 2012 15:43:24 -0700 Subject: removed incorrect id selector css for code view container since its breaking it. Signed-off-by: Ananya Sen --- js/stage/stage-view.reel/stage-view.css | 29 ++++++++++------------------- 1 file changed, 10 insertions(+), 19 deletions(-) (limited to 'js') diff --git a/js/stage/stage-view.reel/stage-view.css b/js/stage/stage-view.reel/stage-view.css index e2c4bb0e..8afb52a2 100755 --- a/js/stage/stage-view.reel/stage-view.css +++ b/js/stage/stage-view.reel/stage-view.css @@ -17,29 +17,20 @@ cursor:text; } -.codeViewContainer>div{ - width:2500px;/*to prevent scrolling of editor container in the middle of the page for short files*/ +.codeViewContainer .CodeMirror { + width: 100%; + height: 100%; + background: white; } -/* OLD CSS for reference -#mainContent #codeMirror_1 { - height:100%; +.codeViewContainer .CodeMirror-scroll { + height: 100%; + overflow: auto; } -*/ - -/*.CodeMirror {*/ - /*width: 100%;*/ - /*height: 100%;*/ - /*background: white;*/ -/*}*/ - -/*.CodeMirror .CodeMirror-scroll {*/ - /*height: 100%;*/ - /*overflow: scroll;*/ - /*overflow-x: auto;*/ - /*overflow-y: auto;*/ -/*}*/ +.codeViewContainer>div{ + width:2500px;/*to prevent scrolling of editor container in the middle of the page for short files*/ +} span.CodeMirror-matchhighlight { background: #e9e9e9 } .CodeMirror-focused span.CodeMirror-matchhighlight { background: #e7e4ff; !important } -- cgit v1.2.3 From a00be41613cb952470cc952aa63f67e61745379a Mon Sep 17 00:00:00 2001 From: Ananya Sen Date: Mon, 7 May 2012 17:19:19 -0700 Subject: fixed javascript errors Signed-off-by: Ananya Sen --- js/controllers/document-controller.js | 4 ---- js/controllers/styles-controller.js | 2 +- 2 files changed, 1 insertion(+), 5 deletions(-) (limited to 'js') diff --git a/js/controllers/document-controller.js b/js/controllers/document-controller.js index 6d11bd0e..c6bf4c6b 100755 --- a/js/controllers/document-controller.js +++ b/js/controllers/document-controller.js @@ -427,10 +427,6 @@ var DocumentController = exports.DocumentController = Montage.create(Component, closeDocument: { value: function(id) { - if(this.activeDocument.needsSave === true){ - //if file dirty then alert user to save - } - var doc = this._findDocumentByUUID(id); var closeDocumentIndex = this._findIndexByUUID(id); diff --git a/js/controllers/styles-controller.js b/js/controllers/styles-controller.js index ec4314f9..647c0870 100755 --- a/js/controllers/styles-controller.js +++ b/js/controllers/styles-controller.js @@ -1102,7 +1102,7 @@ var stylesController = exports.StylesController = Montage.create(Component, { ///// The dominant rule might not have the style property defined - why? ///// If no rules have the property defined, we can use the ///// most-specific single-target rule as the dominant rule (for setting styles) - return element.ownerDocument.defaultView.getComputedStyle(element).getPropertyValue(property); + return (element.ownerDocument.defaultView ? element.ownerDocument.defaultView.getComputedStyle(element).getPropertyValue(property) : null); } return value; -- cgit v1.2.3 From 157632ce32b4e71e1f08278cf712ff4f2c835226 Mon Sep 17 00:00:00 2001 From: Ananya Sen Date: Tue, 8 May 2012 10:23:51 -0700 Subject: IKNINJA-1603 Uncaught TypeError: Cannot read property 'documentRoot' of null js/components/layout/bread-crumb.reel/bread-crumb.js:26 Signed-off-by: Ananya Sen --- js/components/layout/bread-crumb.reel/bread-crumb.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'js') diff --git a/js/components/layout/bread-crumb.reel/bread-crumb.js b/js/components/layout/bread-crumb.reel/bread-crumb.js index e396bdbf..c1b021a3 100755 --- a/js/components/layout/bread-crumb.reel/bread-crumb.js +++ b/js/components/layout/bread-crumb.reel/bread-crumb.js @@ -23,7 +23,7 @@ exports.Breadcrumb = Montage.create(Component, { value: function(){ if(!this.application.ninja.documentController.activeDocument) { this.disabled = true; - this.application.ninja.currentSelectedContainer = this.application.ninja.currentDocument.documentRoot; + this.application.ninja.currentSelectedContainer = (this.application.ninja.currentDocument ? this.application.ninja.currentDocument.documentRoot : null); } } }, -- cgit v1.2.3