diff options
author | Eric Guzman | 2012-06-20 19:42:03 -0700 |
---|---|---|
committer | Eric Guzman | 2012-06-20 19:42:03 -0700 |
commit | 3270aac4980c908f305fb53abadda5121ff6b9cb (patch) | |
tree | 6255aaab239fde71b1f4862dd70de7be62f48b85 /js/panels/Materials/materials-library-panel.reel/materials-library-panel.js | |
parent | a5d93daf6fdccbfee160d6a8ba08f6b6d4b9d7cc (diff) | |
parent | 87377c81da06abf6d656017859830a3ab2902f0e (diff) | |
download | ninja-3270aac4980c908f305fb53abadda5121ff6b9cb.tar.gz |
Merge branch 'binding' of github.com:dhg637/ninja-internal into binding
Diffstat (limited to 'js/panels/Materials/materials-library-panel.reel/materials-library-panel.js')
-rwxr-xr-x | js/panels/Materials/materials-library-panel.reel/materials-library-panel.js | 13 |
1 files changed, 8 insertions, 5 deletions
diff --git a/js/panels/Materials/materials-library-panel.reel/materials-library-panel.js b/js/panels/Materials/materials-library-panel.reel/materials-library-panel.js index c600fd0d..cf0d4e93 100755 --- a/js/panels/Materials/materials-library-panel.reel/materials-library-panel.js +++ b/js/panels/Materials/materials-library-panel.reel/materials-library-panel.js | |||
@@ -51,14 +51,15 @@ exports.MaterialsLibraryPanel = Montage.create(Component, { | |||
51 | 51 | ||
52 | handleNodeActivation: { | 52 | handleNodeActivation: { |
53 | value:function(obj) { | 53 | value:function(obj) { |
54 | this._showMaterialPopup(obj.id); | 54 | this._showMaterialPopup({ materialId: obj.id }); |
55 | } | 55 | } |
56 | }, | 56 | }, |
57 | 57 | ||
58 | handleShowMaterialPopup: { | 58 | handleShowMaterialPopup: { |
59 | enumerable: false, | 59 | enumerable: false, |
60 | value: function (event) { | 60 | value: function (event) { |
61 | this._showMaterialPopup(event.detail.materialId); | 61 | //this._showMaterialPopup(event.detail.materialId); |
62 | this._showMaterialPopup(event.detail); | ||
62 | } | 63 | } |
63 | }, | 64 | }, |
64 | 65 | ||
@@ -74,9 +75,9 @@ exports.MaterialsLibraryPanel = Montage.create(Component, { | |||
74 | 75 | ||
75 | _showMaterialPopup: { | 76 | _showMaterialPopup: { |
76 | enumerable: false, | 77 | enumerable: false, |
77 | value: function (materialID) { | 78 | value: function (materialObj) { |
78 | 79 | ||
79 | if(!this._materialPopup) | 80 | if(!this._materialPopup) |
80 | { | 81 | { |
81 | this._materialPopup = Popup.create(); | 82 | this._materialPopup = Popup.create(); |
82 | this._materialPopup.content = this._materialInfo; | 83 | this._materialPopup.content = this._materialInfo; |
@@ -85,7 +86,9 @@ exports.MaterialsLibraryPanel = Montage.create(Component, { | |||
85 | this._materialPopup.addEventListener("show", this, false); | 86 | this._materialPopup.addEventListener("show", this, false); |
86 | } | 87 | } |
87 | this._materialPopup.show(); | 88 | this._materialPopup.show(); |
88 | this._materialInfo.loadMaterials(materialID); | 89 | |
90 | materialID = materialObj.materialId; | ||
91 | this._materialInfo.loadMaterials(materialID, materialObj.useSelection, materialObj.whichMaterial); | ||
89 | } | 92 | } |
90 | }, | 93 | }, |
91 | 94 | ||