diff options
author | Pushkar Joshi | 2012-05-31 17:16:21 -0700 |
---|---|---|
committer | Pushkar Joshi | 2012-05-31 17:16:21 -0700 |
commit | 8915a7109d918a2e69b0999ebaa2deb84811fef8 (patch) | |
tree | 19a8af74c58c9ea261f0842f36efdab959be3256 /js/components/layout/document-entry.reel/document-entry.js | |
parent | eea0a556e44c2b60d3aaf6e46d2432d3e6303812 (diff) | |
parent | 06b609df1ff7833592faddbd8d7abb5b9f15a74d (diff) | |
download | ninja-8915a7109d918a2e69b0999ebaa2deb84811fef8.tar.gz |
Merge branch 'pentool' into brushtool
Diffstat (limited to 'js/components/layout/document-entry.reel/document-entry.js')
-rwxr-xr-x | js/components/layout/document-entry.reel/document-entry.js | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/js/components/layout/document-entry.reel/document-entry.js b/js/components/layout/document-entry.reel/document-entry.js index 9e4110e2..50b3624c 100755 --- a/js/components/layout/document-entry.reel/document-entry.js +++ b/js/components/layout/document-entry.reel/document-entry.js | |||
@@ -7,8 +7,6 @@ No rights, expressed or implied, whatsoever to this software are provided by Mot | |||
7 | var Montage = require("montage/core/core").Montage; | 7 | var Montage = require("montage/core/core").Montage; |
8 | var Component = require("montage/ui/component").Component; | 8 | var Component = require("montage/ui/component").Component; |
9 | 9 | ||
10 | //var documentManagerModule = ("js/document/documentManager"); | ||
11 | |||
12 | exports.DocumentEntry = Montage.create(Component, { | 10 | exports.DocumentEntry = Montage.create(Component, { |
13 | 11 | ||
14 | dirty: { value: null }, | 12 | dirty: { value: null }, |
@@ -35,8 +33,10 @@ exports.DocumentEntry = Montage.create(Component, { | |||
35 | } | 33 | } |
36 | 34 | ||
37 | this._document = value; | 35 | this._document = value; |
38 | this._uuid = value.uuid; | 36 | |
39 | //this.needsDraw = true; | 37 | if(value) { |
38 | this._uuid = value.uuid; | ||
39 | } | ||
40 | } | 40 | } |
41 | }, | 41 | }, |
42 | 42 | ||
@@ -119,10 +119,10 @@ exports.DocumentEntry = Montage.create(Component, { | |||
119 | handleClick: { | 119 | handleClick: { |
120 | value: function(event) { | 120 | value: function(event) { |
121 | if(event._event.target.nodeName === "IMG") { | 121 | if(event._event.target.nodeName === "IMG") { |
122 | this.application.ninja.documentController.closeDocument(this._uuid); | 122 | this.application.ninja.documentController.closeFile(this.application.ninja.documentController._findDocumentByUUID(this._uuid)); |
123 | } else { | 123 | } else { |
124 | if(!this._document.isActive) { | 124 | if(!this.active) { |
125 | this.application.ninja.stage.stageView.switchDocument(this.application.ninja.documentController._findDocumentByUUID(this._uuid)); | 125 | this.application.ninja.documentController.switchDocuments(this.application.ninja.currentDocument, this.application.ninja.documentController._findDocumentByUUID(this._uuid)); |
126 | } | 126 | } |
127 | } | 127 | } |
128 | } | 128 | } |