aboutsummaryrefslogtreecommitdiff
path: root/js
diff options
context:
space:
mode:
Diffstat (limited to 'js')
-rwxr-xr-xjs/components/layout/document-bar.reel/document-bar.html13
-rwxr-xr-xjs/components/layout/document-bar.reel/document-bar.js16
2 files changed, 18 insertions, 11 deletions
diff --git a/js/components/layout/document-bar.reel/document-bar.html b/js/components/layout/document-bar.reel/document-bar.html
index ccf759ef..3e3ac936 100755
--- a/js/components/layout/document-bar.reel/document-bar.html
+++ b/js/components/layout/document-bar.reel/document-bar.html
@@ -75,13 +75,7 @@ POSSIBILITY OF SUCH DAMAGE.
75 "element": {"#": "previewButton"}, 75 "element": {"#": "previewButton"},
76 "identifier": "preview", 76 "identifier": "preview",
77 "label": "Preview" 77 "label": "Preview"
78 }, 78 }
79 "listeners": [
80 {
81 "type": "action",
82 "listener": {"@": "owner"}
83 }
84 ]
85 }, 79 },
86 80
87 "owner": { 81 "owner": {
@@ -90,7 +84,8 @@ POSSIBILITY OF SUCH DAMAGE.
90 "element": {"#": "documentBar"}, 84 "element": {"#": "documentBar"},
91 "zoomControl": {"@": "hottext1"}, 85 "zoomControl": {"@": "hottext1"},
92 "btnDesign": {"#": "buttonDesign"}, 86 "btnDesign": {"#": "buttonDesign"},
93 "btnCode": {"#": "buttonCode"} 87 "btnCode": {"#": "buttonCode"},
88 "btnPreview": {"#": "buttonPreview"}
94 } 89 }
95 } 90 }
96 } 91 }
@@ -126,7 +121,7 @@ POSSIBILITY OF SUCH DAMAGE.
126 121
127 </section> 122 </section>
128 123
129 <section class="inactive"> 124 <section data-montage-id="buttonPreview" class="inactive">
130 125
131 <div class="viewicon viewPreview"></div> 126 <div class="viewicon viewPreview"></div>
132 127
diff --git a/js/components/layout/document-bar.reel/document-bar.js b/js/components/layout/document-bar.reel/document-bar.js
index a9c98507..5623f825 100755
--- a/js/components/layout/document-bar.reel/document-bar.js
+++ b/js/components/layout/document-bar.reel/document-bar.js
@@ -65,6 +65,17 @@ exports.DocumentBar = Montage.create(Component, {
65 }, 65 },
66 //////////////////////////////////////////////////////////////////// 66 ////////////////////////////////////////////////////////////////////
67 // 67 //
68 btnCode: {
69 value: null
70 },
71 btnDesign: {
72 value: null
73 },
74 btnPreview: {
75 value: null
76 },
77 ////////////////////////////////////////////////////////////////////
78 //
68 _visible: { 79 _visible: {
69 value: false 80 value: false
70 }, 81 },
@@ -113,6 +124,7 @@ exports.DocumentBar = Montage.create(Component, {
113 // 124 //
114 this.btnCode.addEventListener('click', this.showViewCode.bind(this), false); 125 this.btnCode.addEventListener('click', this.showViewCode.bind(this), false);
115 this.btnDesign.addEventListener('click', this.showViewDesign.bind(this), false); 126 this.btnDesign.addEventListener('click', this.showViewDesign.bind(this), false);
127 this.btnPreview.addEventListener('click', this, false);
116 } 128 }
117 }, 129 },
118 //////////////////////////////////////////////////////////////////// 130 ////////////////////////////////////////////////////////////////////
@@ -207,8 +219,8 @@ exports.DocumentBar = Montage.create(Component, {
207 } 219 }
208 }, 220 },
209 221
210 handlePreviewAction: { 222 handleClick: {
211 value: function(event) { 223 value: function(evt) {
212 NJevent("executePreview"); 224 NJevent("executePreview");
213 } 225 }
214 } 226 }