aboutsummaryrefslogtreecommitdiff
path: root/js/components/layout/document-bar.reel
diff options
context:
space:
mode:
authorJohn Mayhew2012-07-24 15:46:16 -0700
committerJohn Mayhew2012-07-24 15:46:16 -0700
commit9f240b8b9b1f5fb0f145c343ca5e533e25e81374 (patch)
tree407564eaa6466e8d4cf2eeee0c56dc623243586f /js/components/layout/document-bar.reel
parentd25359c75089215ee48838db081fd3d51cbbd85f (diff)
parent21d74af1e9fc57cc25cea8aa7408beabf79ff2f3 (diff)
downloadninja-9f240b8b9b1f5fb0f145c343ca5e533e25e81374.tar.gz
Merge branch 'master' of github.com:Motorola-Mobility/ninja
Diffstat (limited to 'js/components/layout/document-bar.reel')
-rwxr-xr-xjs/components/layout/document-bar.reel/document-bar.css13
-rwxr-xr-xjs/components/layout/document-bar.reel/document-bar.html23
-rwxr-xr-xjs/components/layout/document-bar.reel/document-bar.js6
3 files changed, 40 insertions, 2 deletions
diff --git a/js/components/layout/document-bar.reel/document-bar.css b/js/components/layout/document-bar.reel/document-bar.css
index b86855b7..5eba72e8 100755
--- a/js/components/layout/document-bar.reel/document-bar.css
+++ b/js/components/layout/document-bar.reel/document-bar.css
@@ -75,7 +75,7 @@ POSSIBILITY OF SUCH DAMAGE.
75 padding: 0; 75 padding: 0;
76 border: none; 76 border: none;
77 color: #FFF; 77 color: #FFF;
78 width: 44px; 78 width: 46px;
79 text-transform: uppercase; 79 text-transform: uppercase;
80 text-align: left; 80 text-align: left;
81 float: left; 81 float: left;
@@ -83,6 +83,10 @@ POSSIBILITY OF SUCH DAMAGE.
83 font-size: 11px; 83 font-size: 11px;
84} 84}
85 85
86.preview:focus {
87 -webkit-box-shadow: none;
88}
89
86.documentBar .viewicon { 90.documentBar .viewicon {
87 background-repeat: no-repeat; 91 background-repeat: no-repeat;
88 background-position: center center; 92 background-position: center center;
@@ -98,10 +102,15 @@ POSSIBILITY OF SUCH DAMAGE.
98} 102}
99 103
100.documentBar .viewdesign { 104.documentBar .viewdesign {
101 background-image: url('../../../../js/panels/Color/colorpanelpopup.reel/img/icon_bitmap.png'); 105 background-image: url('../../../../js/panels/color/colorpanelpopup.reel/img/icon_bitmap.png');
102 background-size: 90%; 106 background-size: 90%;
103} 107}
104 108
109.documentBar .viewPreview {
110 background-image: url('../../../../images/optionsbar/edit_mode.png');
111 background-size: 100%;
112}
113
105.documentBar section.inactive .viewicon{ 114.documentBar section.inactive .viewicon{
106 opacity: .5; 115 opacity: .5;
107} 116}
diff --git a/js/components/layout/document-bar.reel/document-bar.html b/js/components/layout/document-bar.reel/document-bar.html
index 69f8107f..9e5e4eb2 100755
--- a/js/components/layout/document-bar.reel/document-bar.html
+++ b/js/components/layout/document-bar.reel/document-bar.html
@@ -68,6 +68,21 @@ POSSIBILITY OF SUCH DAMAGE.
68 "condition": {"<-": "@owner.disabled"} 68 "condition": {"<-": "@owner.disabled"}
69 } 69 }
70 }, 70 },
71
72 "menuItemButton": {
73 "prototype": "montage/ui/native/button.reel",
74 "properties": {
75 "element": {"#": "previewButton"},
76 "identifier": "preview",
77 "label": "Preview"
78 },
79 "listeners": [
80 {
81 "type": "action",
82 "listener": {"@": "owner"}
83 }
84 ]
85 },
71 86
72 "owner": { 87 "owner": {
73 "prototype": "js/components/layout/document-bar.reel", 88 "prototype": "js/components/layout/document-bar.reel",
@@ -108,6 +123,14 @@ POSSIBILITY OF SUCH DAMAGE.
108 <button class="btn_view">Code</button> 123 <button class="btn_view">Code</button>
109 124
110 </section> 125 </section>
126
127 <section class="inactive">
128
129 <div class="viewicon viewPreview"></div>
130
131 <button data-montage-id="previewButton" class="btn_view preview"></button>
132
133 </section>
111 134
112 <div data-montage-id="disabledCondition" class="panelDisabled"></div> 135 <div data-montage-id="disabledCondition" class="panelDisabled"></div>
113 136
diff --git a/js/components/layout/document-bar.reel/document-bar.js b/js/components/layout/document-bar.reel/document-bar.js
index 248bc8c4..fa0c8788 100755
--- a/js/components/layout/document-bar.reel/document-bar.js
+++ b/js/components/layout/document-bar.reel/document-bar.js
@@ -203,5 +203,11 @@ exports.DocumentBar = Montage.create(Component, {
203 this.currentView = event._event.target.id; 203 this.currentView = event._event.target.id;
204 this.application.ninja.documentController.stage.stageView.switchDesignDocViews(event._event.target.id);//switch between design view 204 this.application.ninja.documentController.stage.stageView.switchDesignDocViews(event._event.target.id);//switch between design view
205 } 205 }
206 },
207
208 handlePreviewAction: {
209 value: function(event) {
210 NJevent("executePreview");
211 }
206 } 212 }
207}); 213});