diff options
author | Ananya Sen | 2012-03-06 16:30:33 -0800 |
---|---|---|
committer | Ananya Sen | 2012-03-06 16:30:33 -0800 |
commit | 2364c671ffc2953e3ee8dfdf037244de8fab3920 (patch) | |
tree | dfdcc7d60b5d8627d6b41d0b37e66ad5cc75ba5b /js/stage | |
parent | fbde30a4651d34ac569bf6750db5dd017ccc8d6e (diff) | |
download | ninja-2364c671ffc2953e3ee8dfdf037244de8fab3920.tar.gz |
IKNINJA-1238 fix and fixing other js errors on switching and closing documents
Signed-off-by: Ananya Sen <Ananya.Sen@motorola.com>
Diffstat (limited to 'js/stage')
-rwxr-xr-x | js/stage/stage-view.reel/stage-view.js | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/js/stage/stage-view.reel/stage-view.js b/js/stage/stage-view.reel/stage-view.js index 91047e51..ad67cada 100755 --- a/js/stage/stage-view.reel/stage-view.js +++ b/js/stage/stage-view.reel/stage-view.js | |||
@@ -125,6 +125,10 @@ exports.StageView = Montage.create(Component, { | |||
125 | 125 | ||
126 | this.application.ninja.documentController.activeDocument = doc; | 126 | this.application.ninja.documentController.activeDocument = doc; |
127 | 127 | ||
128 | if(this.application.ninja.documentController.activeDocument.currentView === "design") { | ||
129 | this.application.ninja.currentDocument = this.application.ninja.documentController.activeDocument; | ||
130 | } | ||
131 | |||
128 | this.application.ninja.stage._scrollFlag = false; // TODO HACK to prevent type error on Hide/Show Iframe | 132 | this.application.ninja.stage._scrollFlag = false; // TODO HACK to prevent type error on Hide/Show Iframe |
129 | this.application.ninja.documentController._showCurrentDocument(); | 133 | this.application.ninja.documentController._showCurrentDocument(); |
130 | 134 | ||
@@ -135,7 +139,6 @@ exports.StageView = Montage.create(Component, { | |||
135 | 139 | ||
136 | if(this.application.ninja.documentController.activeDocument.currentView === "design") { | 140 | if(this.application.ninja.documentController.activeDocument.currentView === "design") { |
137 | this.application.ninja.stage._scrollFlag = true; // TODO HACK to prevent type error on Hide/Show Iframe | 141 | this.application.ninja.stage._scrollFlag = true; // TODO HACK to prevent type error on Hide/Show Iframe |
138 | this.application.ninja.currentDocument = this.application.ninja.documentController.activeDocument; | ||
139 | 142 | ||
140 | //reinitialize draw-util, snapmanager and view-util | 143 | //reinitialize draw-util, snapmanager and view-util |
141 | this.application.ninja.stage.stageDeps.reinitializeForSwitchDocument(); | 144 | this.application.ninja.stage.stageDeps.reinitializeForSwitchDocument(); |