diff options
author | hwc487 | 2012-07-09 16:08:02 -0700 |
---|---|---|
committer | hwc487 | 2012-07-09 16:08:02 -0700 |
commit | 5085d0f67df89a21715308956004164597a6ba79 (patch) | |
tree | 2c896163143a66331205a39b0a3b1b45d51bf12a /js/panels/CSSPanel/ComputedStyleSubPanel.reel | |
parent | 51f1691f792dbda9b740ded8aa0457c9406db156 (diff) | |
parent | 84b3327bd92faafab7954b5eb64c7abe24a3fe13 (diff) | |
download | ninja-5085d0f67df89a21715308956004164597a6ba79.tar.gz |
Merge branch 'master' of github.com:Motorola-Mobility/ninja-internal into GridFixes
Conflicts:
js/helper-classes/3D/StageLine.js
Diffstat (limited to 'js/panels/CSSPanel/ComputedStyleSubPanel.reel')
-rwxr-xr-x | js/panels/CSSPanel/ComputedStyleSubPanel.reel/ComputedStyleSubPanel.html | 46 | ||||
-rwxr-xr-x | js/panels/CSSPanel/ComputedStyleSubPanel.reel/ComputedStyleSubPanel.js | 30 |
2 files changed, 38 insertions, 38 deletions
diff --git a/js/panels/CSSPanel/ComputedStyleSubPanel.reel/ComputedStyleSubPanel.html b/js/panels/CSSPanel/ComputedStyleSubPanel.reel/ComputedStyleSubPanel.html index a65fd32f..28876d29 100755 --- a/js/panels/CSSPanel/ComputedStyleSubPanel.reel/ComputedStyleSubPanel.html +++ b/js/panels/CSSPanel/ComputedStyleSubPanel.reel/ComputedStyleSubPanel.html | |||
@@ -1,4 +1,4 @@ | |||
1 | <!DOCTYPE html> | 1 | <!doctype html> |
2 | <!-- <copyright> | 2 | <!-- <copyright> |
3 | Copyright (c) 2012, Motorola Mobility, Inc | 3 | Copyright (c) 2012, Motorola Mobility, Inc |
4 | All Rights Reserved. | 4 | All Rights Reserved. |
@@ -30,9 +30,9 @@ POSSIBILITY OF SUCH DAMAGE. | |||
30 | </copyright> --> | 30 | </copyright> --> |
31 | <html> | 31 | <html> |
32 | <head> | 32 | <head> |
33 | <meta http-equiv="Content-type" content="text/html; charset=utf-8"> | 33 | <meta http-equiv="Content-type" content="text/html; charset=utf-8"> |
34 | <title>ComputedStyleSubPanel</title> | 34 | <title>ComputedStyleSubPanel</title> |
35 | <link href="computed-style-sub-panel.css" type="text/css" rel="stylesheet"> | 35 | <link href="computed-style-sub-panel.css" type="text/css" rel="stylesheet"> |
36 | <script type="text/montage-serialization"> | 36 | <script type="text/montage-serialization"> |
37 | { | 37 | { |
38 | "owner": { | 38 | "owner": { |
@@ -45,27 +45,27 @@ POSSIBILITY OF SUCH DAMAGE. | |||
45 | } | 45 | } |
46 | } | 46 | } |
47 | 47 | ||
48 | } | 48 | } |
49 | </script> | 49 | </script> |
50 | 50 | ||
51 | </head> | 51 | </head> |
52 | <body> | 52 | <body> |
53 | <div data-montage-id="nj-css-panel-computed" class="nj-css-panel-computed"> | 53 | <div data-montage-id="nj-css-panel-computed" class="nj-css-panel-computed"> |
54 | <div data-montage-id="nj-css-filter-panel" class="nj-css-filter-panel"> | 54 | <div data-montage-id="nj-css-filter-panel" class="nj-css-filter-panel"> |
55 | <input data-montage-id="nj-css-filter" class="nj-skinned nj-css-filter-input" type="search"> | 55 | <input data-montage-id="nj-css-filter" class="nj-skinned nj-css-filter-input" type="search"> |
56 | <select data-montage-id="nj-css-group-select" class="nj-skinned nj-css-group-select"> | 56 | <select data-montage-id="nj-css-group-select" class="nj-skinned nj-css-group-select"> |
57 | <option value="all">All</option> | 57 | <option value="all">All</option> |
58 | <option value="summary" selected>Summary</option> | 58 | <option value="summary" selected>Summary</option> |
59 | <option value="background">Background</option> | 59 | <option value="background">Background</option> |
60 | <option value="dimensions">Dimensions</option> | 60 | <option value="dimensions">Dimensions</option> |
61 | <option value="border">Border</option> | 61 | <option value="border">Border</option> |
62 | <option value="font">Font</option> | 62 | <option value="font">Font</option> |
63 | <option value="layout">Layout</option> | 63 | <option value="layout">Layout</option> |
64 | </select> | 64 | </select> |
65 | </div> | 65 | </div> |
66 | <div class="nj-sub-panel"> | 66 | <div class="nj-sub-panel"> |
67 | <dl data-montage-id="nj-css-computed-list" class="nj-css-style-list nj-css-computed-list"></dl> | 67 | <dl data-montage-id="nj-css-computed-list" class="nj-css-style-list nj-css-computed-list"></dl> |
68 | </div> | 68 | </div> |
69 | </div> | 69 | </div> |
70 | </body> | 70 | </body> |
71 | </html> | 71 | </html> |
diff --git a/js/panels/CSSPanel/ComputedStyleSubPanel.reel/ComputedStyleSubPanel.js b/js/panels/CSSPanel/ComputedStyleSubPanel.reel/ComputedStyleSubPanel.js index e214a49b..a6a655d5 100755 --- a/js/panels/CSSPanel/ComputedStyleSubPanel.reel/ComputedStyleSubPanel.js +++ b/js/panels/CSSPanel/ComputedStyleSubPanel.reel/ComputedStyleSubPanel.js | |||
@@ -49,25 +49,25 @@ exports.ComputedStyleSubPanel = Montage.create(Component, { | |||
49 | }, | 49 | }, |
50 | // prepareForDraw : { | 50 | // prepareForDraw : { |
51 | // value: function() { | 51 | // value: function() { |
52 | // | 52 | // |
53 | // } | 53 | // } |
54 | // }, | 54 | // }, |
55 | willDraw : { | 55 | willDraw : { |
56 | value: function() { | 56 | value: function() { |
57 | if(this._declaration) { | 57 | if(this._declaration) { |
58 | 58 | ||
59 | var group = this.staticGroupingMap[this._group], | 59 | var group = this.staticGroupingMap[this._group], |
60 | matchedInGroup, elementList; | 60 | matchedInGroup, elementList; |
61 | 61 | ||
62 | if(this._group === 'all' && !group) { | 62 | if(this._group === 'all' && !group) { |
63 | group = this.staticGroupingMap['all'] = nj.toArray(this._declaration).sort(); | 63 | group = this.staticGroupingMap['all'] = nj.toArray(this._declaration).sort(); |
64 | } | 64 | } |
65 | 65 | ||
66 | ///// Filter group to show only the styles that match search filter | 66 | ///// Filter group to show only the styles that match search filter |
67 | matchedInGroup = group.filter(function(item) { | 67 | matchedInGroup = group.filter(function(item) { |
68 | return (item.indexOf(this._filter) > -1); | 68 | return (item.indexOf(this._filter) > -1); |
69 | }, this); | 69 | }, this); |
70 | 70 | ||
71 | this._elementList = matchedInGroup.map(function(propName) { | 71 | this._elementList = matchedInGroup.map(function(propName) { |
72 | var propEl = nj.make('dt'), | 72 | var propEl = nj.make('dt'), |
73 | valEl = nj.make('dd'), | 73 | valEl = nj.make('dd'), |
@@ -75,20 +75,20 @@ exports.ComputedStyleSubPanel = Montage.create(Component, { | |||
75 | 75 | ||
76 | propEl.appendChild(nj.textNode(propName)); | 76 | propEl.appendChild(nj.textNode(propName)); |
77 | propEl.title = propName; | 77 | propEl.title = propName; |
78 | 78 | ||
79 | valEl.appendChild(nj.textNode(this._declaration.getPropertyValue(propName))); | 79 | valEl.appendChild(nj.textNode(this._declaration.getPropertyValue(propName))); |
80 | valEl.title = this._declaration.getPropertyValue(propName); | 80 | valEl.title = this._declaration.getPropertyValue(propName); |
81 | 81 | ||
82 | contEl.appendChild(propEl); | 82 | contEl.appendChild(propEl); |
83 | contEl.appendChild(valEl); | 83 | contEl.appendChild(valEl); |
84 | 84 | ||
85 | return contEl; | 85 | return contEl; |
86 | }, this); | 86 | }, this); |
87 | 87 | ||
88 | /*if(matchedInGroup.length) { | 88 | /*if(matchedInGroup.length) { |
89 | 89 | ||
90 | } else { | 90 | } else { |
91 | 91 | ||
92 | }*/ | 92 | }*/ |
93 | } | 93 | } |
94 | } | 94 | } |
@@ -101,7 +101,7 @@ exports.ComputedStyleSubPanel = Montage.create(Component, { | |||
101 | ///// Append style elements to the list container | 101 | ///// Append style elements to the list container |
102 | this._elementList.forEach(function(el) { | 102 | this._elementList.forEach(function(el) { |
103 | this.computedListEl.appendChild(el); | 103 | this.computedListEl.appendChild(el); |
104 | }, this); | 104 | }, this); |
105 | } | 105 | } |
106 | } | 106 | } |
107 | }, | 107 | }, |
@@ -138,7 +138,7 @@ exports.ComputedStyleSubPanel = Montage.create(Component, { | |||
138 | ///// Get computed style of passed in node | 138 | ///// Get computed style of passed in node |
139 | declaration = this._declaration = source.ownerDocument.defaultView.getComputedStyle(source); | 139 | declaration = this._declaration = source.ownerDocument.defaultView.getComputedStyle(source); |
140 | } | 140 | } |
141 | 141 | ||
142 | this.needsDraw = true; | 142 | this.needsDraw = true; |
143 | } | 143 | } |
144 | }, | 144 | }, |
@@ -194,7 +194,7 @@ exports.ComputedStyleSubPanel = Montage.create(Component, { | |||
194 | 'dimensions' : [ | 194 | 'dimensions' : [ |
195 | 'width', 'height', 'top', 'right', 'bottom', 'left', | 195 | 'width', 'height', 'top', 'right', 'bottom', 'left', |
196 | 'padding-top', 'padding-right', 'padding-bottom', 'padding-left', | 196 | 'padding-top', 'padding-right', 'padding-bottom', 'padding-left', |
197 | 'margin-top', 'margin-right', 'margin-bottom', 'margin-left', | 197 | 'margin-top', 'margin-right', 'margin-bottom', 'margin-left', |
198 | 'border-top-width', 'border-right-width', 'border-bottom-width', 'border-left-width' | 198 | 'border-top-width', 'border-right-width', 'border-bottom-width', 'border-left-width' |
199 | ], | 199 | ], |
200 | 'border' : [ | 200 | 'border' : [ |
@@ -203,7 +203,7 @@ exports.ComputedStyleSubPanel = Montage.create(Component, { | |||
203 | 'border-top-style', 'border-right-style', 'border-bottom-style', 'border-left-style' | 203 | 'border-top-style', 'border-right-style', 'border-bottom-style', 'border-left-style' |
204 | ], | 204 | ], |
205 | 'font' : [ | 205 | 'font' : [ |
206 | 'font-family', 'font-size', 'font-weight', 'font-style', 'color', 'text-transform', | 206 | 'font-family', 'font-size', 'font-weight', 'font-style', 'color', 'text-transform', |
207 | 'text-decoration', 'letter-spacing', 'word-spacing', 'line-height', 'text-align', | 207 | 'text-decoration', 'letter-spacing', 'word-spacing', 'line-height', 'text-align', |
208 | 'vertical-align', 'direction' | 208 |