aboutsummaryrefslogtreecommitdiff
path: root/js/panels/Panel.reel/Panel.js
diff options
context:
space:
mode:
Diffstat (limited to 'js/panels/Panel.reel/Panel.js')
-rwxr-xr-xjs/panels/Panel.reel/Panel.js29
1 files changed, 29 insertions, 0 deletions
diff --git a/js/panels/Panel.reel/Panel.js b/js/panels/Panel.reel/Panel.js
index bd9b4e2f..3783459e 100755
--- a/js/panels/Panel.reel/Panel.js
+++ b/js/panels/Panel.reel/Panel.js
@@ -104,6 +104,35 @@ exports.Panel = Montage.create(Component, {
104 } 104 }
105 }, 105 },
106 106
107 _currentDocument: {
108 value : null,
109 enumerable : false
110 },
111
112 currentDocument : {
113 get : function() {
114 return this._currentDocument;
115 },
116 set : function(value) {
117 if (value === this._currentDocument) {
118 return;
119 }
120
121 this._currentDocument = value;
122
123 if(typeof this.panelContent.content[0].controller._currentDocument !== "undefined") {
124 this.panelContent.content[0].controller.currentDocument = this._currentDocument;
125 }
126
127 if(!value) {
128 this.disabled = true;
129 } else {
130 this.disabled = this._currentDocument.currentView !== "design";
131 }
132
133 }
134 },
135
107 handleBtnCollapseAction: { 136 handleBtnCollapseAction: {
108 value: function() { 137 value: function() {
109 this.collapsed = !this.collapsed; 138 this.collapsed = !this.collapsed;