aboutsummaryrefslogtreecommitdiff
path: root/js/components/layout/document-entry.reel
diff options
context:
space:
mode:
Diffstat (limited to 'js/components/layout/document-entry.reel')
-rwxr-xr-xjs/components/layout/document-entry.reel/document-entry.js8
1 files changed, 5 insertions, 3 deletions
diff --git a/js/components/layout/document-entry.reel/document-entry.js b/js/components/layout/document-entry.reel/document-entry.js
index 81a63c90..ad0236c6 100755
--- a/js/components/layout/document-entry.reel/document-entry.js
+++ b/js/components/layout/document-entry.reel/document-entry.js
@@ -33,8 +33,10 @@ exports.DocumentEntry = Montage.create(Component, {
33 } 33 }
34 34
35 this._document = value; 35 this._document = value;
36 this._uuid = value.uuid; 36
37 //this.needsDraw = true; 37 if(value) {
38 this._uuid = value.uuid;
39 }
38 } 40 }
39 }, 41 },
40 42
@@ -117,7 +119,7 @@ exports.DocumentEntry = Montage.create(Component, {
117 handleClick: { 119 handleClick: {
118 value: function(event) { 120 value: function(event) {
119 if(event._event.target.nodeName === "IMG") { 121 if(event._event.target.nodeName === "IMG") {
120 this.application.ninja.documentController.closeDocument(this._uuid); 122 this.application.ninja.documentController.closeFile(this.application.ninja.documentController._findDocumentByUUID(this._uuid));
121 } else { 123 } else {
122 if(!this._document.isActive) { 124 if(!this._document.isActive) {
123 this.application.ninja.stage.stageView.switchDocument(this.application.ninja.documentController._findDocumentByUUID(this._uuid)); 125 this.application.ninja.stage.stageView.switchDocument(this.application.ninja.documentController._findDocumentByUUID(this._uuid));