diff options
author | Ananya Sen | 2012-07-23 17:01:14 -0700 |
---|---|---|
committer | Ananya Sen | 2012-07-23 17:01:14 -0700 |
commit | 48d9ed19573a07c68da305d14ca6ab3a04d31d64 (patch) | |
tree | b4bf6c48c7fdade2cf531d84cac3359489d38405 /js/components/layout | |
parent | c07a7a9d11bc8299fa9686544b18840cc8e640c2 (diff) | |
parent | afc7ad4f240fdf7890a79c2d4d7f8eb2e7c30a34 (diff) | |
download | ninja-48d9ed19573a07c68da305d14ca6ab3a04d31d64.tar.gz |
Merge branch 'refs/heads/Jose-Document' into Document
Diffstat (limited to 'js/components/layout')
7 files changed, 54 insertions, 186 deletions
diff --git a/js/components/layout/bread-crumb.reel/bread-crumb.html b/js/components/layout/bread-crumb.reel/bread-crumb.html index 2c6d941f..2fff245c 100755 --- a/js/components/layout/bread-crumb.reel/bread-crumb.html +++ b/js/components/layout/bread-crumb.reel/bread-crumb.html | |||
@@ -44,13 +44,17 @@ POSSIBILITY OF SUCH DAMAGE. | |||
44 | } | 44 | } |
45 | }, | 45 | }, |
46 | 46 | ||
47 | "nodeNameConverter": { | ||
48 | "prototype": "js/components/converter/node-name-converter" | ||
49 | }, | ||
50 | |||
47 | "breadcrumbButton": { | 51 | "breadcrumbButton": { |
48 | "prototype": "js/components/layout/bread-crumb-button.reel", | 52 | "prototype": "js/components/layout/bread-crumb-button.reel", |
49 | "properties": { | 53 | "properties": { |
50 | "element": {"#": "breadcrumbButton"} | 54 | "element": {"#": "breadcrumbButton"} |
51 | }, | 55 | }, |
52 | "bindings": { | 56 | "bindings": { |
53 | "label": {"<-": "@buttonsList.objectAtCurrentIteration.label"}, | 57 | "label": {"<-": "@buttonsList.objectAtCurrentIteration.label", "converter": {"@": "nodeNameConverter"}}, |
54 | "value": {"<-": "@buttonsList.objectAtCurrentIteration.nodeUuid"} | 58 | "value": {"<-": "@buttonsList.objectAtCurrentIteration.nodeUuid"} |
55 | } | 59 | } |
56 | }, | 60 | }, |
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 fbd03221..3e3ac936 100755 --- a/js/components/layout/document-bar.reel/document-bar.html +++ b/js/components/layout/document-bar.reel/document-bar.html | |||
@@ -68,6 +68,15 @@ 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 | }, | ||
71 | 80 | ||
72 | "owner": { | 81 | "owner": { |
73 | "prototype": "js/components/layout/document-bar.reel", | 82 | "prototype": "js/components/layout/document-bar.reel", |
@@ -75,7 +84,8 @@ POSSIBILITY OF SUCH DAMAGE. | |||
75 | "element": {"#": "documentBar"}, | 84 | "element": {"#": "documentBar"}, |
76 | "zoomControl": {"@": "hottext1"}, | 85 | "zoomControl": {"@": "hottext1"}, |
77 | "btnDesign": {"#": "buttonDesign"}, | 86 | "btnDesign": {"#": "buttonDesign"}, |
78 | "btnCode": {"#": "buttonCode"} | 87 | "btnCode": {"#": "buttonCode"}, |
88 | "btnPreview": {"#": "buttonPreview"} | ||
79 | } | 89 | } |
80 | } | 90 | } |
81 | } | 91 | } |
@@ -110,6 +120,14 @@ POSSIBILITY OF SUCH DAMAGE. | |||
110 | <button class="btn_view">Code</button> | 120 | <button class="btn_view">Code</button> |
111 | 121 | ||
112 | </section> | 122 | </section> |
123 | |||
124 | <section data-montage-id="buttonPreview" class="inactive"> | ||
125 | |||
126 | <div class="viewicon viewPreview"></div> | ||
127 | |||
128 | <button data-montage-id="previewButton" class="btn_view preview"></button> | ||
129 | |||
130 | </section> | ||
113 | 131 | ||
114 | <div data-montage-id="disabledCondition" class="panelDisabled"></div> | 132 | <div data-montage-id="disabledCondition" class="panelDisabled"></div> |
115 | 133 | ||
diff --git a/js/components/layout/document-bar.reel/document-bar.js b/js/components/layout/document-bar.reel/document-bar.js index 194b9b23..803d2c3a 100755 --- a/js/components/layout/document-bar.reel/document-bar.js +++ b/js/components/layout/document-bar.reel/document-bar.js | |||
@@ -86,6 +86,17 @@ exports.DocumentBar = Montage.create(Component, { | |||
86 | }, | 86 | }, |
87 | //////////////////////////////////////////////////////////////////// | 87 | //////////////////////////////////////////////////////////////////// |
88 | // | 88 | // |
89 | btnCode: { | ||
90 | value: null | ||
91 | }, | ||
92 | btnDesign: { | ||
93 | value: null | ||
94 | }, | ||
95 | btnPreview: { | ||
96 | value: null | ||
97 | }, | ||
98 | //////////////////////////////////////////////////////////////////// | ||
99 | // | ||
89 | _visible: { | 100 | _visible: { |
90 | value: false | 101 | value: false |
91 | }, | 102 | }, |
@@ -139,6 +150,7 @@ exports.DocumentBar = Montage.create(Component, { | |||
139 | // | 150 | // |
140 | this.btnCode.addEventListener('click', this.showViewCode.bind(this), false); | 151 | this.btnCode.addEventListener('click', this.showViewCode.bind(this), false); |
141 | this.btnDesign.addEventListener('click', this.showViewDesign.bind(this), false); | 152 | this.btnDesign.addEventListener('click', this.showViewDesign.bind(this), false); |
153 | this.btnPreview.addEventListener('click', this, false); | ||
142 | } | 154 | } |
143 | }, | 155 | }, |
144 | //////////////////////////////////////////////////////////////////// | 156 | //////////////////////////////////////////////////////////////////// |
@@ -241,9 +253,15 @@ exports.DocumentBar = Montage.create(Component, { | |||
241 | render(); | 253 | render(); |
242 | } | 254 | } |
243 | } | 255 | } |
256 | }, | ||
257 | |||
258 | handleClick: { | ||
259 | value: function(evt) { | ||
260 | NJevent("executePreview"); | ||
261 | } | ||
244 | } | 262 | } |
245 | //////////////////////////////////////////////////////////////////// | 263 | //////////////////////////////////////////////////////////////////// |
246 | //////////////////////////////////////////////////////////////////// | 264 | //////////////////////////////////////////////////////////////////// |
247 | }); | 265 | }); |
248 | //////////////////////////////////////////////////////////////////////// | 266 | //////////////////////////////////////////////////////////////////////// |
249 | //////////////////////////////////////////////////////////////////////// \ No newline at end of file | 267 | //////////////////////////////////////////////////////////////////////// |
diff --git a/js/components/layout/stage-mode.reel/stage-mode.css b/js/components/layout/stage-mode.reel/stage-mode.css deleted file mode 100755 index c50679e8..00000000 --- a/js/components/layout/stage-mode.reel/stage-mode.css +++ /dev/null | |||
@@ -1,49 +0,0 @@ | |||
1 | /* <copyright> | ||
2 | Copyright (c) 2012, Motorola Mobility LLC. | ||
3 | All Rights Reserved. | ||
4 | |||
5 | Redistribution and use in source and binary forms, with or without | ||
6 | modification, are permitted provided that the following conditions are met: | ||
7 | |||
8 | * Redistributions of source code must retain the above copyright notice, | ||
9 | this list of conditions and the following disclaimer. | ||
10 | |||
11 | * Redistributions in binary form must reproduce the above copyright notice, | ||
12 | this list of conditions and the following disclaimer in the documentation | ||
13 | and/or other materials provided with the distribution. | ||
14 | |||
15 | * Neither the name of Motorola Mobility LLC nor the names of its | ||
16 | contributors may be used to endorse or promote products derived from this | ||
17 | software without specific prior written permission. | ||
18 | |||
19 | THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" | ||
20 | AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE | ||