diff options
Diffstat (limited to 'js/panels/properties/content.reel/content.js')
-rwxr-xr-x | js/panels/properties/content.reel/content.js | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/js/panels/properties/content.reel/content.js b/js/panels/properties/content.reel/content.js index 8fa33a75..cc9ec96a 100755 --- a/js/panels/properties/content.reel/content.js +++ b/js/panels/properties/content.reel/content.js | |||
@@ -55,6 +55,7 @@ exports.Content = Montage.create(Component, { | |||
55 | } | 55 | } |
56 | 56 | ||
57 | this.eventManager.addEventListener("openDocument", this, false); | 57 | this.eventManager.addEventListener("openDocument", this, false); |
58 | this.eventManager.addEventListener("switchDocument", this, false); | ||
58 | } | 59 | } |
59 | }, | 60 | }, |
60 | 61 | ||
@@ -74,6 +75,21 @@ exports.Content = Montage.create(Component, { | |||
74 | } | 75 | } |
75 | }, | 76 | }, |
76 | 77 | ||
78 | handleSwitchDocument: { | ||
79 | value: function(){ | ||
80 | // For now always assume that the stage is selected by default | ||
81 | if(this.application.ninja.selectedElements.length === 0) { | ||
82 | this.displayStageProperties(); | ||
83 | }else { | ||
84 | if(this.application.ninja.selectedElements.length === 1) { | ||
85 | this.displayElementProperties(this.application.ninja.selectedElements[0]._element); | ||
86 | } else { | ||
87 | this.displayGroupProperties(this.application.ninja.selectedElements); | ||
88 | } | ||
89 | } | ||
90 | } | ||
91 | }, | ||
92 | |||
77 | /** | 93 | /** |
78 | * Blur and Key up to handle change in the Element ID field. | 94 | * Blur and Key up to handle change in the Element ID field. |
79 | */ | 95 | */ |