Merge lp:~richardw/jarmon/auto-apidocumentation into lp:jarmon
- auto-apidocumentation
- Merge into trunk
Proposed by
Richard Wall
Status: | Merged |
---|---|
Approved by: | Richard Wall |
Approved revision: | 86 |
Merge reported by: | Richard Wall |
Merged at revision: | not available |
Proposed branch: | lp:~richardw/jarmon/auto-apidocumentation |
Merge into: | lp:jarmon |
Diff against target: |
1985 lines (+1591/-107) 14 files modified
README (+19/-5) bin/build (+10/-0) docs/examples/index.html (+2/-2) docs/examples/nginx.conf.example (+2/-1) docs/index.html (+15/-0) jarmon/jarmon.js (+142/-99) jarmonbuild/commands.py (+239/-0) jarmonbuild/yuidoc_template/assets/ac-js (+162/-0) jarmonbuild/yuidoc_template/assets/api-js (+42/-0) jarmonbuild/yuidoc_template/assets/api.css (+242/-0) jarmonbuild/yuidoc_template/assets/reset-fonts-grids-min.css (+7/-0) jarmonbuild/yuidoc_template/classmap.tmpl (+15/-0) jarmonbuild/yuidoc_template/index.tmpl (+9/-0) jarmonbuild/yuidoc_template/main.tmpl (+685/-0) |
To merge this branch: | bzr merge lp:~richardw/jarmon/auto-apidocumentation |
Related bugs: | |
Related blueprints: |
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
Richard Wall | Approve | ||
Review via email: mp+33343@code.launchpad.net |
Commit message
* Cleanup and add further doc strings for compatibility with yuidoc
* Add a tool to automatically download and run yuidoc on the source tree
* Add a tool to automatically create a releasable source archive containing apidocs
* Add documentation of the apidoc and release tools.
* Rearrange the source tree - moving all examples into the docs/examplesfolder
Description of the change
* Cleanup and add further doc strings for compatibility with yuidoc
* Add a tool to automatically download and run yuidoc on the source tree
* Add a tool to automatically create a releasable source archive containing apidocs
* Add documentation of the apidoc and release tools.
* Rearrange the source tree - moving all examples into the docs/examplesfolder
To post a comment you must log in.
Preview Diff
[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1 | === modified file 'README' | |||
2 | --- README 2010-06-23 22:24:21 +0000 | |||
3 | +++ README 2010-08-22 21:23:38 +0000 | |||
4 | @@ -1,15 +1,19 @@ | |||
6 | 1 | Jarmon 0.0.1 | 1 | Jarmon 10.7 |
7 | 2 | 2 | ||
8 | 3 | 3 | ||
9 | 4 | What is this? | 4 | What is this? |
10 | 5 | ============= | 5 | ============= |
13 | 6 | Wrappers and convenience fuctions for working with the javascriptRRD, Flot and | 6 | jarmon.js contains various wrappers and convenience fuctions for working with |
14 | 7 | Collectd. | 7 | the javascriptRRD, Flot and RRD files generated by eg Collectd. |
15 | 8 | Additionally, there is a fully working example which demonstrates how to use | ||
16 | 9 | jarmon.js and how to integrate it with other javascript components - such as | ||
17 | 10 | calendar date pickers etc. | ||
18 | 8 | 11 | ||
19 | 9 | 12 | ||
20 | 10 | Debian / Ubuntu Quick Start | 13 | Debian / Ubuntu Quick Start |
21 | 11 | =========================== | 14 | =========================== |
23 | 12 | To get this demo working, you will need to serve this page from a | 15 | There is a demo html page in the docs/examples folder. |
24 | 16 | To get this demo working, you will need to serve that page from a | ||
25 | 13 | local webserver and serve the folder that contains your RRD files. | 17 | local webserver and serve the folder that contains your RRD files. |
26 | 14 | 18 | ||
27 | 15 | This demo is designed to work with the RRD files generated by | 19 | This demo is designed to work with the RRD files generated by |
28 | @@ -25,10 +29,20 @@ | |||
29 | 25 | $ cd trunk | 29 | $ cd trunk |
30 | 26 | 30 | ||
31 | 27 | # Link to the collectd rrd folder | 31 | # Link to the collectd rrd folder |
33 | 28 | $ ln -s /var/lib/collectd/rrd/localhost data | 32 | $ ln -s /var/lib/collectd/rrd/localhost docs/examples/data |
34 | 29 | 33 | ||
35 | 30 | # Start a local webserver - here we use Twisted, but there are other web server | 34 | # Start a local webserver - here we use Twisted, but there are other web server |
36 | 31 | # config examples in docs/ | 35 | # config examples in docs/ |
37 | 32 | $ aptitude install twisted | 36 | $ aptitude install twisted |
38 | 33 | $ twistd -n web --port 8080 --path . | 37 | $ twistd -n web --port 8080 --path . |
39 | 34 | 38 | ||
40 | 39 | $ firefox http://localhost:8080/docs/examples/index.html | ||
41 | 40 | |||
42 | 41 | |||
43 | 42 | Next Steps | ||
44 | 43 | ========== | ||
45 | 44 | Examine: | ||
46 | 45 | * docs/examples/index.html | ||
47 | 46 | * docs/examples/jarmon_example_recipes.js | ||
48 | 47 | |||
49 | 48 | ...for examples of how to use jarmon.js then add your own chart recipes. | ||
50 | 35 | 49 | ||
51 | === added directory 'bin' | |||
52 | === added file 'bin/build' | |||
53 | --- bin/build 1970-01-01 00:00:00 +0000 | |||
54 | +++ bin/build 2010-08-22 21:23:38 +0000 | |||
55 | @@ -0,0 +1,10 @@ | |||
56 | 1 | #!/usr/bin/env python | ||
57 | 2 | import os | ||
58 | 3 | import sys | ||
59 | 4 | |||
60 | 5 | # Add the current branch to the python path | ||
61 | 6 | sys.path.append(os.path.join(os.path.dirname(__file__), '..')) | ||
62 | 7 | |||
63 | 8 | from jarmonbuild.commands import main | ||
64 | 9 | |||
65 | 10 | raise SystemExit(main()) | ||
66 | 0 | 11 | ||
67 | === added directory 'docs/apidocs' | |||
68 | === added directory 'docs/examples' | |||
69 | === renamed directory 'assets' => 'docs/examples/assets' | |||
70 | === renamed file 'index.html' => 'docs/examples/index.html' | |||
71 | --- index.html 2010-08-01 11:12:55 +0000 | |||
72 | +++ docs/examples/index.html 2010-08-22 21:23:38 +0000 | |||
73 | @@ -13,8 +13,8 @@ | |||
74 | 13 | 13 | ||
75 | 14 | <script type="text/javascript" src="assets/js/dependencies.js"></script> | 14 | <script type="text/javascript" src="assets/js/dependencies.js"></script> |
76 | 15 | 15 | ||
79 | 16 | <script type="text/javascript" src="jarmon.js"></script> | 16 | <script type="text/javascript" src="../../jarmon/jarmon.js"></script> |
80 | 17 | <script type="text/javascript" src="docs/jarmon_example_recipes.js"></script> | 17 | <script type="text/javascript" src="jarmon_example_recipes.js"></script> |
81 | 18 | <script type="text/javascript"> | 18 | <script type="text/javascript"> |
82 | 19 | // Recipes for the charts on this page | 19 | // Recipes for the charts on this page |
83 | 20 | 20 | ||
84 | 21 | 21 | ||
85 | === renamed file 'docs/jarmon_example_recipes.js' => 'docs/examples/jarmon_example_recipes.js' | |||
86 | === renamed file 'docs/nginx.conf.example' => 'docs/examples/nginx.conf.example' | |||
87 | --- docs/nginx.conf.example 2010-06-23 22:24:21 +0000 | |||
88 | +++ docs/examples/nginx.conf.example 2010-08-22 21:23:38 +0000 | |||
89 | @@ -56,9 +56,10 @@ | |||
90 | 56 | location / { | 56 | location / { |
91 | 57 | root .; | 57 | root .; |
92 | 58 | index index.html; | 58 | index index.html; |
93 | 59 | autoindex on; | ||
94 | 59 | } | 60 | } |
95 | 60 | 61 | ||
97 | 61 | location /data { | 62 | location /docs/examples/data { |
98 | 62 | alias /var/lib/collectd/rrd/aziz; | 63 | alias /var/lib/collectd/rrd/aziz; |
99 | 63 | autoindex on; | 64 | autoindex on; |
100 | 64 | } | 65 | } |
101 | 65 | 66 | ||
102 | === modified file 'docs/index.html' | |||
103 | --- docs/index.html 2010-08-03 23:48:15 +0000 | |||
104 | +++ docs/index.html 2010-08-22 21:23:38 +0000 | |||
105 | @@ -8,6 +8,8 @@ | |||
106 | 8 | <h2>Contents</h2> | 8 | <h2>Contents</h2> |
107 | 9 | <ol> | 9 | <ol> |
108 | 10 | <li><a href="#browser-compatibility">Browser Compatibility</a></li> | 10 | <li><a href="#browser-compatibility">Browser Compatibility</a></li> |
109 | 11 | <li><a href="#api-documentation">API documentation</a></li> | ||
110 | 12 | <li><a href="#release-process">Release process and tools</a></li> | ||
111 | 11 | </ol> | 13 | </ol> |
112 | 12 | <h2 id="browser-compatibility">Browser Compatibility</h2> | 14 | <h2 id="browser-compatibility">Browser Compatibility</h2> |
113 | 13 | <p>Jarmon depends upon the <a href="http://code.google.com/p/flot/">Flot | 15 | <p>Jarmon depends upon the <a href="http://code.google.com/p/flot/">Flot |
114 | @@ -77,3 +79,16 @@ | |||
115 | 77 | </dl> | 79 | </dl> |
116 | 78 | </dl> | 80 | </dl> |
117 | 79 | 81 | ||
118 | 82 | <h2 id="api-documentation">API Documentation</h2> | ||
119 | 83 | <p>Jarmon includes <a href="apidocs/index.html">comprehensive API | ||
120 | 84 | documentation</a> | ||
121 | 85 | <p>This API documentation is generated automatically by the release command, | ||
122 | 86 | but you can also build it yourself by issuing the | ||
123 | 87 | <code>./bin/build apidoc</code> command from within a Jarmon source tree. | ||
124 | 88 | The documentation will be saved in a build subfolder.</p> | ||
125 | 89 | |||
126 | 90 | <h2 id="release-process">Release Process and Tools</h2> | ||
127 | 91 | <p>Jarmon includes tools to automate source archive releases. First check | ||
128 | 92 | out the source code, then issue the | ||
129 | 93 | <code>./bin/build -V 10.8 release</code> command from within the source | ||
130 | 94 | tree.</p> | ||
131 | 80 | 95 | ||
132 | === added directory 'jarmon' | |||
133 | === renamed file 'jarmon.js' => 'jarmon/jarmon.js' | |||
134 | --- jarmon.js 2010-08-01 11:12:55 +0000 | |||
135 | +++ jarmon/jarmon.js 2010-08-22 21:23:38 +0000 | |||
136 | @@ -1,8 +1,9 @@ | |||
138 | 1 | /* Copyright (c) 2010 Richard Wall <richard (at) the-moon.net> | 1 | /** |
139 | 2 | * Copyright (c) 2010 Richard Wall <richard (at) the-moon.net> | ||
140 | 2 | * See LICENSE for details. | 3 | * See LICENSE for details. |
141 | 3 | * | 4 | * |
142 | 4 | * Wrappers and convenience fuctions for working with the javascriptRRD, jQuery, | 5 | * Wrappers and convenience fuctions for working with the javascriptRRD, jQuery, |
144 | 5 | * and flot charting packages. | 6 | * and Flot charting packages. |
145 | 6 | * | 7 | * |
146 | 7 | * Designed to work well with the RRD files generated by Collectd: | 8 | * Designed to work well with the RRD files generated by Collectd: |
147 | 8 | * - http://collectd.org/ | 9 | * - http://collectd.org/ |
148 | @@ -12,20 +13,29 @@ | |||
149 | 12 | * - jQuery: http://jquery.com/ | 13 | * - jQuery: http://jquery.com/ |
150 | 13 | * - Flot: http://code.google.com/p/flot/ | 14 | * - Flot: http://code.google.com/p/flot/ |
151 | 14 | * - MochiKit.Async: http://www.mochikit.com/ | 15 | * - MochiKit.Async: http://www.mochikit.com/ |
152 | 16 | * | ||
153 | 17 | * @module jarmon | ||
154 | 15 | */ | 18 | */ |
155 | 16 | 19 | ||
156 | 20 | /** | ||
157 | 21 | * A namespace for Jarmon | ||
158 | 22 | * | ||
159 | 23 | * @class jarmon | ||
160 | 24 | * @static | ||
161 | 25 | */ | ||
162 | 17 | if(typeof jarmon == 'undefined') { | 26 | if(typeof jarmon == 'undefined') { |
163 | 18 | var jarmon = {}; | 27 | var jarmon = {}; |
164 | 19 | } | 28 | } |
165 | 20 | 29 | ||
166 | 21 | /** | ||
167 | 22 | * Download a binary file asynchronously using the jQuery.ajax function | ||
168 | 23 | * | ||
169 | 24 | * @param url: The url of the object to be downloaded | ||
170 | 25 | * @return: A I{MochiKit.Async.Deferred} which will callback with an instance of | ||
171 | 26 | * I{javascriptrrd.BinaryFile} | ||
172 | 27 | **/ | ||
173 | 28 | jarmon.downloadBinary = function(url) { | 30 | jarmon.downloadBinary = function(url) { |
174 | 31 | /** | ||
175 | 32 | * Download a binary file asynchronously using the jQuery.ajax function | ||
176 | 33 | * | ||
177 | 34 | * @method downloadBinary | ||
178 | 35 | * @param url {String} The url of the object to be downloaded | ||
179 | 36 | * @return {Object} A deferred which will callback with an instance of javascriptrrd.BinaryFile | ||
180 | 37 | */ | ||
181 | 38 | |||
182 | 29 | var d = new MochiKit.Async.Deferred(); | 39 | var d = new MochiKit.Async.Deferred(); |
183 | 30 | 40 | ||
184 | 31 | $.ajax({ | 41 | $.ajax({ |
185 | @@ -61,50 +71,16 @@ | |||
186 | 61 | return d; | 71 | return d; |
187 | 62 | }; | 72 | }; |
188 | 63 | 73 | ||
189 | 64 | /** | ||
190 | 65 | * Limit the number of parallel async calls | ||
191 | 66 | * | ||
192 | 67 | * @param limit: The maximum number of in progress calls | ||
193 | 68 | **/ | ||
194 | 69 | jarmon.Parallimiter = function(limit) { | ||
195 | 70 | this.limit = limit || 1; | ||
196 | 71 | this._callQueue = []; | ||
197 | 72 | this._currentCallCount = 0; | ||
198 | 73 | }; | ||
199 | 74 | |||
200 | 75 | jarmon.Parallimiter.prototype.addCallable = function(callable, args) { | ||
201 | 76 | /** | ||
202 | 77 | * Add a function to be called when the number of in progress calls drops | ||
203 | 78 | * below the configured limit | ||
204 | 79 | * | ||
205 | 80 | * @param callable: A function which returns a Deferred. | ||
206 | 81 | **/ | ||
207 | 82 | var d = new MochiKit.Async.Deferred(); | ||
208 | 83 | this._callQueue.unshift([d, callable, args]); | ||
209 | 84 | this._nextCall(); | ||
210 | 85 | return d; | ||
211 | 86 | }; | ||
212 | 87 | |||
213 | 88 | jarmon.Parallimiter.prototype._nextCall = function() { | ||
214 | 89 | if(this._callQueue.length > 0) { | ||
215 | 90 | if(this._currentCallCount < this.limit) { | ||
216 | 91 | this._currentCallCount++; | ||
217 | 92 | var nextCall = this._callQueue.pop(); | ||
218 | 93 | nextCall[1].apply(null, nextCall[2]).addBoth( | ||
219 | 94 | function(self, d, res) { | ||
220 | 95 | d.callback(res); | ||
221 | 96 | self._currentCallCount--; | ||
222 | 97 | self._nextCall(); | ||
223 | 98 | }, this, nextCall[0]); | ||
224 | 99 | } | ||
225 | 100 | } | ||
226 | 101 | }; | ||
227 | 102 | |||
228 | 103 | 74 | ||
229 | 104 | jarmon.localTimeFormatter = function (v, axis) { | 75 | jarmon.localTimeFormatter = function (v, axis) { |
230 | 105 | /** | 76 | /** |
231 | 106 | * Copied from jquery.flot.js and modified to allow timezone | 77 | * Copied from jquery.flot.js and modified to allow timezone |
232 | 107 | * adjustment. | 78 | * adjustment. |
233 | 79 | * | ||
234 | 80 | * @method localTimeFormatter | ||
235 | 81 | * @param v {Number} The timestamp to be formatted | ||
236 | 82 | * @param axis {Object} A hash containing information about the time axis | ||
237 | 83 | * @return {String} The formatted datetime string | ||
238 | 108 | **/ | 84 | **/ |
239 | 109 | // map of app. size of time units in milliseconds | 85 | // map of app. size of time units in milliseconds |
240 | 110 | var timeUnitSize = { | 86 | var timeUnitSize = { |
241 | @@ -155,14 +131,10 @@ | |||
242 | 155 | * convenient way to query the RRDFile based on time range, RRD data source (DS) | 131 | * convenient way to query the RRDFile based on time range, RRD data source (DS) |
243 | 156 | * and RRD consolidation function (CF). | 132 | * and RRD consolidation function (CF). |
244 | 157 | * | 133 | * |
253 | 158 | * @param startTime: A javascript {Date} instance representing the start of query | 134 | * @class jarmon.RrdQuery |
254 | 159 | * time range, or {null} to return earliest available data. | 135 | * @constructor |
255 | 160 | * @param endTime: A javascript {Date} instance representing the end of query | 136 | * @param rrd {Object} A javascriptrrd.RRDFile |
256 | 161 | * time range, or {null} to return latest available data. | 137 | * @param unit {String} The unit symbol for this data series |
249 | 162 | * @param dsId: A {String} name of an RRD DS or an {Int} DS index number or | ||
250 | 163 | * {null} to return the first available DS. | ||
251 | 164 | * @param cfName: A {String} name of an RRD consolidation function | ||
252 | 165 | * @return: A flot compatible data series object | ||
257 | 166 | **/ | 138 | **/ |
258 | 167 | jarmon.RrdQuery = function(rrd, unit) { | 139 | jarmon.RrdQuery = function(rrd, unit) { |
259 | 168 | this.rrd = rrd; | 140 | this.rrd = rrd; |
260 | @@ -175,14 +147,14 @@ | |||
261 | 175 | * end time. The rows are taken from the first RRA whose data spans the | 147 | * end time. The rows are taken from the first RRA whose data spans the |
262 | 176 | * requested time range. | 148 | * requested time range. |
263 | 177 | * | 149 | * |
272 | 178 | * @param startTime: The I{Date} start time | 150 | * @method getData |
273 | 179 | * @param endTime: The I{Date} end time | 151 | * @param startTime {Number} start timestamp |
274 | 180 | * @param dsId: An index I{Number} or key I{String} identifying the RRD | 152 | * @param endTime {Number} end timestamp |
275 | 181 | * datasource (DS). | 153 | * @param dsId {Variant} identifier of the RRD datasource (string or number) |
276 | 182 | * @param cfName: The name I{String} of an RRD consolidation function (CF) | 154 | * @param cfName {String} The name of an RRD consolidation function (CF) |
277 | 183 | * eg AVERAGE, MIN, MAX | 155 | * eg AVERAGE, MIN, MAX |
278 | 184 | * @return: A Flot compatible data series I{Object} | 156 | * @return {Object} A Flot compatible data series |
279 | 185 | * eg {label:'', data:[], unit: ''} | 157 | * eg label: '', data: [], unit: '' |
280 | 186 | **/ | 158 | **/ |
281 | 187 | var startTimestamp = startTime/1000; | 159 | var startTimestamp = startTime/1000; |
282 | 188 | 160 | ||
283 | @@ -258,8 +230,12 @@ | |||
284 | 258 | * A wrapper around RrdQuery which provides asynchronous access to the data in a | 230 | * A wrapper around RrdQuery which provides asynchronous access to the data in a |
285 | 259 | * remote RRD file. | 231 | * remote RRD file. |
286 | 260 | * | 232 | * |
289 | 261 | * @param url: The url I{String} of a remote RRD file | 233 | * @class jarmon.RrdQueryRemote |
290 | 262 | * @param unit: The unit suffix I{String} of this data eg 'bit/sec' | 234 | * @constructor |
291 | 235 | * @param url {String} The url of a remote RRD file | ||
292 | 236 | * @param unit {String} The unit suffix of this data eg 'bit/sec' | ||
293 | 237 | * @param downloader {Function} A callable which returns a Deferred and calls | ||
294 | 238 | * back with a javascriptrrd.BinaryFile when it has downloaded. | ||
295 | 263 | **/ | 239 | **/ |
296 | 264 | jarmon.RrdQueryRemote = function(url, unit, downloader) { | 240 | jarmon.RrdQueryRemote = function(url, unit, downloader) { |
297 | 265 | this.url = url; | 241 | this.url = url; |
298 | @@ -273,10 +249,11 @@ | |||
299 | 273 | /** | 249 | /** |
300 | 274 | * Return a Flot compatible data series asynchronously. | 250 | * Return a Flot compatible data series asynchronously. |
301 | 275 | * | 251 | * |
306 | 276 | * @param startTime: The start time I{Date} | 252 | * @method getData |
307 | 277 | * @param endTime: The end time I{Date} | 253 | * @param startTime {Number} The start timestamp |
308 | 278 | * @returns: A I{MochiKit.Async.Deferred} which calls back with a flot data | 254 | * @param endTime {Number} The end timestamp |
309 | 279 | * series object I{Object} | 255 | * @param dsId {Variant} identifier of the RRD datasource (string or number) |
310 | 256 | * @return {Object} A Deferred which calls back with a flot data series. | ||
311 | 280 | **/ | 257 | **/ |
312 | 281 | var endTimestamp = endTime/1000; | 258 | var endTimestamp = endTime/1000; |
313 | 282 | 259 | ||
314 | @@ -320,11 +297,13 @@ | |||
315 | 320 | }; | 297 | }; |
316 | 321 | 298 | ||
317 | 322 | /** | 299 | /** |
319 | 323 | * Wraps a I{RrdQueryRemote} to provide access to a different RRD DSs within a | 300 | * Wraps RrdQueryRemote to provide access to a different RRD DSs within a |
320 | 324 | * single RrdDataSource. | 301 | * single RrdDataSource. |
321 | 325 | * | 302 | * |
324 | 326 | * @param rrdQuery: An I{RrdQueryRemote} | 303 | * @class jarmon.RrdQueryDsProxy |
325 | 327 | * @param dsId: An index or keyname of an RRD DS | 304 | * @constructor |
326 | 305 | * @param rrdQuery {Object} An RrdQueryRemote instance | ||
327 | 306 | * @param dsId {Variant} identifier of the RRD datasource (string or number) | ||
328 | 328 | **/ | 307 | **/ |
329 | 329 | jarmon.RrdQueryDsProxy = function(rrdQuery, dsId) { | 308 | jarmon.RrdQueryDsProxy = function(rrdQuery, dsId) { |
330 | 330 | this.rrdQuery = rrdQuery; | 309 | this.rrdQuery = rrdQuery; |
331 | @@ -335,6 +314,11 @@ | |||
332 | 335 | jarmon.RrdQueryDsProxy.prototype.getData = function(startTime, endTime) { | 314 | jarmon.RrdQueryDsProxy.prototype.getData = function(startTime, endTime) { |
333 | 336 | /** | 315 | /** |
334 | 337 | * Call I{RrdQueryRemote.getData} with a particular dsId | 316 | * Call I{RrdQueryRemote.getData} with a particular dsId |
335 | 317 | * | ||
336 | 318 | * @method getData | ||
337 | 319 | * @param startTime {Number} A unix timestamp marking the start time | ||
338 | 320 | * @param endTime {Number} A unix timestamp marking the start time | ||
339 | 321 | * @return {Object} A Deferred which calls back with a flot data series. | ||
340 | 338 | **/ | 322 | **/ |
341 | 339 | return this.rrdQuery.getData(startTime, endTime, this.dsId); | 323 | return this.rrdQuery.getData(startTime, endTime, this.dsId); |
342 | 340 | }; | 324 | }; |
343 | @@ -343,10 +327,12 @@ | |||
344 | 343 | /** | 327 | /** |
345 | 344 | * A class for creating a Flot chart from a series of RRD Queries | 328 | * A class for creating a Flot chart from a series of RRD Queries |
346 | 345 | * | 329 | * |
351 | 346 | * @param template: A I{jQuery} containing a single element into which the chart | 330 | * @class jarmon.Chart |
352 | 347 | * will be drawn | 331 | * @constructor |
353 | 348 | * @param options: An I{Object} containing Flot options which describe how the | 332 | * @param template {Object} A jQuery containing a single element into which the |
354 | 349 | * chart should be drawn. | 333 | * chart will be drawn |
355 | 334 | * @param options {Object} Flot options which control how the chart should be | ||
356 | 335 | * drawn. | ||
357 | 350 | **/ | 336 | **/ |
358 | 351 | jarmon.Chart = function(template, options) { | 337 | jarmon.Chart = function(template, options) { |
359 | 352 | this.template = template; | 338 | this.template = template; |
360 | @@ -366,13 +352,13 @@ | |||
361 | 366 | 352 | ||
362 | 367 | 353 | ||
363 | 368 | this.options['yaxis']['ticks'] = function(axis) { | 354 | this.options['yaxis']['ticks'] = function(axis) { |
365 | 369 | /** | 355 | /* |
366 | 370 | * Choose a suitable SI multiplier based on the min and max values from | 356 | * Choose a suitable SI multiplier based on the min and max values from |
367 | 371 | * the axis and then generate appropriate yaxis tick labels. | 357 | * the axis and then generate appropriate yaxis tick labels. |
368 | 372 | * | 358 | * |
369 | 373 | * @param axis: An I{Object} with min and max properties | 359 | * @param axis: An I{Object} with min and max properties |
370 | 374 | * @return: An array of ~5 tick labels | 360 | * @return: An array of ~5 tick labels |
372 | 375 | **/ | 361 | */ |
373 | 376 | var siPrefixes = { | 362 | var siPrefixes = { |
374 | 377 | 0: '', | 363 | 0: '', |
375 | 378 | 1: 'K', | 364 | 1: 'K', |
376 | @@ -431,11 +417,12 @@ | |||
377 | 431 | * Add details of a remote RRD data source whose data will be added to this | 417 | * Add details of a remote RRD data source whose data will be added to this |
378 | 432 | * chart. | 418 | * chart. |
379 | 433 | * | 419 | * |
381 | 434 | * @param label: A I{String} label for this data which will be shown in the | 420 | * @method addData |
382 | 421 | * @param label {String} The label for this data which will be shown in the | ||
383 | 435 | * chart legend | 422 | * chart legend |
387 | 436 | * @param db: The url of the remote RRD database | 423 | * @param db {String} The url of the remote RRD database |
388 | 437 | * @param enabled: true if you want this data plotted on the chart, false | 424 | * @param enabled {Boolean} true if you want this data plotted on the chart, |
389 | 438 | * if not. | 425 | * false if not. |
390 | 439 | **/ | 426 | **/ |
391 | 440 | if(typeof enabled == 'undefined') { | 427 | if(typeof enabled == 'undefined') { |
392 | 441 | enabled = true; | 428 | enabled = true; |
393 | @@ -447,8 +434,9 @@ | |||
394 | 447 | /** | 434 | /** |
395 | 448 | * Enable / Disable a single data source | 435 | * Enable / Disable a single data source |
396 | 449 | * | 436 | * |
399 | 450 | * @param label: The label I{String} of the data source to be enabled / | 437 | * @method switchDataEnabled |
400 | 451 | * disabled | 438 | * @param label {String} The label of the data source to be enabled / |
401 | 439 | * disabled. | ||
402 | 452 | **/ | 440 | **/ |
403 | 453 | for(var i=0; i<this.data.length; i++) { | 441 | for(var i=0; i<this.data.length; i++) { |
404 | 454 | if(this.data[i][0] == label) { | 442 | if(this.data[i][0] == label) { |
405 | @@ -461,8 +449,9 @@ | |||
406 | 461 | /** | 449 | /** |
407 | 462 | * Alter the time range of this chart and redraw | 450 | * Alter the time range of this chart and redraw |
408 | 463 | * | 451 | * |
411 | 464 | * @param startTime: The start time I{Date} | 452 | * @method setTimeRange |
412 | 465 | * @param endTime: The end time I{Date} | 453 | * @param startTime {Number} The start timestamp |
413 | 454 | * @param endTime {Number} The end timestamp | ||
414 | 466 | **/ | 455 | **/ |
415 | 467 | this.startTime = startTime; | 456 | this.startTime = startTime; |
416 | 468 | this.endTime = endTime; | 457 | this.endTime = endTime; |
417 | @@ -475,8 +464,9 @@ | |||
418 | 475 | * A 'chart_loading' event is triggered before the data is requested | 464 | * A 'chart_loading' event is triggered before the data is requested |
419 | 476 | * A 'chart_loaded' event is triggered when the chart has been drawn | 465 | * A 'chart_loaded' event is triggered when the chart has been drawn |
420 | 477 | * | 466 | * |
423 | 478 | * @return: A I{MochiKit.Async.Deferred} which calls back with the chart | 467 | * @method draw |
424 | 479 | * data when the chart has been rendered. | 468 | * @return {Object} A Deferred which calls back with the chart data when |
425 | 469 | * the chart has been rendered. | ||
426 | 480 | **/ | 470 | **/ |
427 | 481 | this.template.addClass('loading'); | 471 | this.template.addClass('loading'); |
428 | 482 | 472 | ||
429 | @@ -584,13 +574,15 @@ | |||
430 | 584 | 574 | ||
431 | 585 | jarmon.Chart.fromRecipe = function(recipes, templateFactory, downloader) { | 575 | jarmon.Chart.fromRecipe = function(recipes, templateFactory, downloader) { |
432 | 586 | /** | 576 | /** |
435 | 587 | * A factory function to generate a list of I{Chart} from a list of recipes | 577 | * A static factory method to generate a list of I{Chart} from a list of |
436 | 588 | * and a list of available rrd files in collectd path format. | 578 | * recipes and a list of available rrd files in collectd path format. |
437 | 589 | * | 579 | * |
442 | 590 | * @param rrdUrlList: A list of rrd download paths | 580 | * @method fromRecipe |
443 | 591 | * @param recipes: A list of recipe objects | 581 | * @param recipes {Array} A list of recipe objects. |
444 | 592 | * @param templateFactory: A callable which generates an html template for a | 582 | * @param templateFactory {Function} A callable which generates an html |
445 | 593 | * chart. | 583 | * template for a chart. |
446 | 584 | * @param downloader {Function} A download function which returns a Deferred | ||
447 | 585 | * @return {Array} A list of Chart objects | ||
448 | 594 | **/ | 586 | **/ |
449 | 595 | 587 | ||
450 | 596 | var charts = []; | 588 | var charts = []; |
451 | @@ -687,8 +679,10 @@ | |||
452 | 687 | * Presents the user with a form and a timeline with which they can choose a | 679 | * Presents the user with a form and a timeline with which they can choose a |
453 | 688 | * time range and co-ordinates the refreshing of a series of charts. | 680 | * time range and co-ordinates the refreshing of a series of charts. |
454 | 689 | * | 681 | * |
457 | 690 | * @param ui: A one element I{jQuery} containing an input form and placeholders | 682 | * @class jarmon.ChartCoordinator |
458 | 691 | * for the timeline and for the series of charts. | 683 | * @constructor |
459 | 684 | * @param ui {Object} A one element jQuery containing an input form and | ||
460 | 685 | * placeholders for the timeline and for the series of charts. | ||
461 | 692 | **/ | 686 | **/ |
462 | 693 | jarmon.ChartCoordinator = function(ui) { | 687 | jarmon.ChartCoordinator = function(ui) { |
463 | 694 | var self = this; | 688 | var self = this; |
464 | @@ -799,6 +793,8 @@ | |||
465 | 799 | /** | 793 | /** |
466 | 800 | * Grab the start and end time from the ui form, highlight the range on the | 794 | * Grab the start and end time from the ui form, highlight the range on the |
467 | 801 | * range timeline and set the time range of all the charts and redraw. | 795 | * range timeline and set the time range of all the charts and redraw. |
468 | 796 | * | ||
469 | 797 | * @method update | ||
470 | 802 | **/ | 798 | **/ |
471 | 803 | 799 | ||
472 | 804 | var selection = this.ui.find('[name="from_standard"]').val(); | 800 | var selection = this.ui.find('[name="from_standard"]').val(); |
473 | @@ -891,8 +887,9 @@ | |||
474 | 891 | /** | 887 | /** |
475 | 892 | * Set the start and end time fields in the form and trigger an update | 888 | * Set the start and end time fields in the form and trigger an update |
476 | 893 | * | 889 | * |
479 | 894 | * @param startTime: The start time I{Date} | 890 | * @method setTimeRange |
480 | 895 | * @param endTime: The end time I{Date} | 891 | * @param startTime {Number} The start timestamp |
481 | 892 | * @param endTime {Number} The end timestamp | ||
482 | 896 | **/ | 893 | **/ |
483 | 897 | if(from != null) { | 894 | if(from != null) { |
484 | 898 | this.ui.find('[name="from"]').val(from); | 895 | this.ui.find('[name="from"]').val(from); |
485 | @@ -905,7 +902,53 @@ | |||
486 | 905 | jarmon.ChartCoordinator.prototype.init = function() { | 902 | jarmon.ChartCoordinator.prototype.init = function() { |
487 | 906 | /** | 903 | /** |
488 | 907 | * Reset all charts and the input form to the default time range - last hour | 904 | * Reset all charts and the input form to the default time range - last hour |
489 | 905 | * | ||
490 | 906 | * @method init | ||
491 | 908 | **/ | 907 | **/ |
492 | 909 | this.update(); | 908 | this.update(); |
493 | 910 | }; | 909 | }; |
494 | 911 | 910 | ||
495 | 911 | /** | ||
496 | 912 | * Limit the number of parallel async calls | ||
497 | 913 | * | ||
498 | 914 | * @class jarmon.Parallimiter | ||
499 | 915 | * @constructor | ||
500 | 916 | * @param limit {Number} The maximum number of in progress calls | ||
501 | 917 | **/ | ||
502 | 918 | jarmon.Parallimiter = function(limit) { | ||
503 | 919 | this.limit = limit || 1; | ||
504 | 920 | this._callQueue = []; | ||
505 | 921 | this._currentCallCount = 0; | ||
506 | 922 | }; | ||
507 | 923 | |||
508 | 924 | jarmon.Parallimiter.prototype.addCallable = function(callable, args) { | ||
509 | 925 | /** | ||
510 | 926 | * Add a function to be called when the number of in progress calls drops | ||
511 | 927 | * below the configured limit | ||
512 | 928 | * | ||
513 | 929 | * @method addCallable | ||
514 | 930 | * @param callable {Function} A function which returns a Deferred. | ||
515 | 931 | * @param args {Array} A list of arguments to pass to the callable | ||
516 | 932 | * @return {Object} A Deferred which fires with the result of the callable | ||
517 | 933 | * when it is called. | ||
518 | 934 | **/ | ||
519 | 935 | var d = new MochiKit.Async.Deferred(); | ||
520 | 936 | this._callQueue.unshift([d, callable, args]); | ||
521 | 937 | this._nextCall(); | ||
522 | 938 | return d; | ||
523 | 939 | }; | ||
524 | 940 | |||
525 | 941 | jarmon.Parallimiter.prototype._nextCall = function() { | ||
526 | 942 | if(this._callQueue.length > 0) { | ||
527 | 943 | if(this._currentCallCount < this.limit) { | ||
528 | 944 | this._currentCallCount++; | ||
529 | 945 | var nextCall = this._callQueue.pop(); | ||
530 | 946 | nextCall[1].apply(null, nextCall[2]).addBoth( | ||
531 | 947 | function(self, d, res) { | ||
532 | 948 | d.callback(res); | ||
533 | 949 | self._currentCallCount--; | ||
534 | 950 | self._nextCall(); | ||
535 | 951 | }, this, nextCall[0]); | ||
536 | 952 | } | ||
537 | 953 | } | ||
538 | 954 | }; | ||
539 | 912 | 955 | ||
540 | === added directory 'jarmonbuild' | |||
541 | === added file 'jarmonbuild/__init__.py' | |||
542 | === added file 'jarmonbuild/commands.py' | |||
543 | --- jarmonbuild/commands.py 1970-01-01 00:00:00 +0000 | |||
544 | +++ jarmonbuild/commands.py 2010-08-22 21:23:38 +0000 | |||
545 | @@ -0,0 +1,239 @@ | |||
546 | 1 | # Copyright (c) 2010 Richard Wall <richard (at) the-moon.net> | ||
547 | 2 | """ | ||
548 | 3 | Functions and Classes for automating the release of Jarmon | ||
549 | 4 | """ | ||
550 | 5 | |||
551 | 6 | import hashlib | ||
552 | 7 | import logging | ||
553 | 8 | import os | ||
554 | 9 | import shutil | ||
555 | 10 | import sys | ||
556 | 11 | |||
557 | 12 | from optparse import OptionParser | ||
558 | 13 | from subprocess import check_call, PIPE | ||
559 | 14 | from tempfile import gettempdir | ||
560 | 15 | from urllib2 import urlopen | ||
561 | 16 | from zipfile import ZipFile, ZIP_DEFLATED | ||
562 | 17 | |||
563 | 18 | import pkg_resources | ||
564 | 19 | |||
565 | 20 | |||
566 | 21 | JARMON_PROJECT_TITLE='Jarmon' | ||
567 | 22 | JARMON_PROJECT_URL='http://www.launchpad.net/jarmon' | ||
568 | 23 | |||
569 | 24 | YUIDOC_URL = 'http://yuilibrary.com/downloads/yuidoc/yuidoc_1.0.0b1.zip' | ||
570 | 25 | YUIDOC_MD5 = 'cd5545d2dec8f7afe3d18e793538162c' | ||
571 | 26 | YUIDOC_DEPENDENCIES = ['setuptools', 'pygments', 'cheetah'] | ||
572 | 27 | |||
573 | 28 | |||
574 | 29 | class BuildError(Exception): | ||
575 | 30 | """ | ||
576 | 31 | A base Exception for errors in the build system | ||
577 | 32 | """ | ||
578 | 33 | pass | ||
579 | 34 | |||
580 | 35 | |||
581 | 36 | class BuildCommand(object): | ||
582 | 37 | def __init__(self, buildversion, log=None): | ||
583 | 38 | self.buildversion = buildversion | ||
584 | 39 | if log is not None: | ||
585 | 40 | self.log = log | ||
586 | 41 | else: | ||
587 | 42 | self.log = logging.getLogger( | ||
588 | 43 | '%s.%s' % (__name__, self.__class__.__name__)) | ||
589 | 44 | |||
590 | 45 | self.workingbranch_dir = os.path.abspath( | ||
591 | 46 | os.path.join(os.path.dirname(__file__), '..')) | ||
592 | 47 | |||
593 | 48 | # setup working dir | ||
594 | 49 | self.build_dir = os.path.join(self.workingbranch_dir, 'build') | ||
595 | 50 | |||
596 | 51 | if not os.path.isdir(self.build_dir): | ||
597 | 52 | self.log.debug('Creating build dir: %s' % (self.build_dir,)) | ||
598 | 53 | os.mkdir(self.build_dir) | ||
599 | 54 | else: | ||
600 | 55 | self.log.debug('Using build dir: %s' % (self.build_dir,)) | ||
601 | 56 | |||
602 | 57 | |||
603 | 58 | class BuildApidocsCommand(BuildCommand): | ||
604 | 59 | """ | ||
605 | 60 | Download YUI Doc and use it to generate apidocs for jarmon | ||
606 | 61 | """ | ||
607 | 62 | |||
608 | 63 | def main(self, argv): | ||
609 | 64 | """ | ||
610 | 65 | The main entry point for the build-apidocs command | ||
611 | 66 | |||
612 | 67 | @param argv: The list of arguments passed to the build-apidocs command | ||
613 | 68 | """ | ||
614 | 69 | tmpdir = gettempdir() | ||
615 | 70 | workingbranch_dir = self.workingbranch_dir | ||
616 | 71 | build_dir = self.build_dir | ||
617 | 72 | |||
618 | 73 | # Check for yuidoc dependencies | ||
619 | 74 | for r in pkg_resources.parse_requirements(YUIDOC_DEPENDENCIES): | ||
620 | 75 | if not pkg_resources.working_set.find(r): | ||
621 | 76 | raise BuildError('Unsatisfied yuidoc dependency: %r' % (r,)) | ||
622 | 77 | |||
623 | 78 | # download and cache yuidoc | ||
624 | 79 | yuizip_path = os.path.join(tmpdir, os.path.basename(YUIDOC_URL)) | ||
625 | 80 | if os.path.exists(yuizip_path): | ||
626 | 81 | self.log.debug('Using cached YUI doc') | ||
627 | 82 | def producer(): | ||
628 | 83 | yield open(yuizip_path).read() | ||
629 | 84 | else: | ||
630 | 85 | self.log.debug('Downloading YUI Doc') | ||
631 | 86 | def producer(): | ||
632 | 87 | with open(yuizip_path, 'w') as yuizip: | ||
633 | 88 | download = urlopen(YUIDOC_URL) | ||
634 | 89 | while True: | ||
635 | 90 | bytes = download.read(1024*10) | ||
636 | 91 | if not bytes: | ||
637 | 92 | break | ||
638 | 93 | else: | ||
639 | 94 | yuizip.write(bytes) | ||
640 | 95 | yield bytes | ||
641 | 96 | |||
642 | 97 | checksum = hashlib.md5() | ||
643 | 98 | for bytes in producer(): | ||
644 | 99 | checksum.update(bytes) | ||
645 | 100 | |||
646 | 101 | actual_md5 = checksum.hexdigest() | ||
647 | 102 | if actual_md5 != YUIDOC_MD5: | ||
648 | 103 | raise BuildError( | ||
649 | 104 | 'YUI Doc checksum error. File: %s, ' | ||
650 | 105 | 'Expected: %s, Got: %s' % (yuizip_path, YUIDOC_MD5, actual_md5)) | ||
651 | 106 | else: | ||
652 | 107 | self.log.debug('YUI Doc checksum verified') | ||
653 | 108 | |||
654 | 109 | # Remove any existing apidocs so that we can track removed files | ||
655 | 110 | shutil.rmtree(os.path.join(build_dir, 'docs', 'apidocs'), True) | ||
656 | 111 | |||
657 | 112 | yuidoc_dir = os.path.join(build_dir, 'yuidoc') | ||
658 | 113 | |||
659 | 114 | # extract yuidoc folder from the downloaded zip file | ||
660 | 115 | self.log.debug( | ||
661 | 116 | 'Extracting YUI Doc from %s to %s' % (yuizip_path, yuidoc_dir)) | ||
662 | 117 | zip = ZipFile(yuizip_path) | ||
663 | 118 | zip.extractall( | ||
664 | 119 | build_dir, (m for m in zip.namelist() if m.startswith('yuidoc'))) | ||
665 | 120 | |||
666 | 121 | # Use the yuidoc script that we just extracted to generate new docs | ||
667 | 122 | self.log.debug('Running YUI Doc') | ||
668 | 123 | check_call(( | ||
669 | 124 | sys.executable, | ||
670 | 125 | os.path.join(yuidoc_dir, 'bin', 'yuidoc.py'), | ||
671 | 126 | os.path.join(workingbranch_dir, 'jarmon'), | ||
672 | 127 | '--parseroutdir=%s' % ( | ||
673 | 128 | os.path.join(build_dir, 'docs', 'apidocs'),), | ||
674 | 129 | '--outputdir=%s' % ( | ||
675 | 130 | os.path.join(build_dir, 'docs', 'apidocs'),), | ||
676 | 131 | '--template=%s' % ( | ||
677 | 132 | os.path.join( | ||
678 | 133 | workingbranch_dir, 'jarmonbuild', 'yuidoc_template'),), | ||
679 | 134 | '--version=%s' % (self.buildversion,), | ||
680 | 135 | '--project=%s' % (JARMON_PROJECT_TITLE,), | ||
681 | 136 | '--projecturl=%s' % (JARMON_PROJECT_URL,) | ||
682 | 137 | ), stdout=PIPE, stderr=PIPE,) | ||
683 | 138 | |||
684 | 139 | shutil.rmtree(yuidoc_dir) | ||
685 | 140 | |||
686 | 141 | |||
687 | 142 | class BuildReleaseCommand(BuildCommand): | ||
688 | 143 | """ | ||
689 | 144 | Export all source files, generate apidocs and create a zip archive for | ||
690 | 145 | upload to Launchpad. | ||
691 | 146 | """ | ||
692 | 147 | |||
693 | 148 | def main(self, argv): | ||
694 | 149 | workingbranch_dir = self.workingbranch_dir | ||
695 | 150 | build_dir = self.build_dir | ||
696 | 151 | |||
697 | 152 | self.log.debug('Export versioned files to a build folder') | ||
698 | 153 | from bzrlib.commands import main as bzr_main | ||
699 | 154 | status = bzr_main(['bzr', 'export', build_dir, workingbranch_dir]) | ||
700 | 155 | if status != 0: | ||
701 | 156 | raise BuildError('bzr export failure. Status: %r' % (status,)) | ||
702 | 157 | |||
703 | 158 | |||
704 | 159 | self.log.debug('Record the branch version') | ||
705 | 160 | from bzrlib.branch import Branch | ||
706 | 161 | from bzrlib.version_info_formats import format_python | ||
707 | 162 | v = format_python.PythonVersionInfoBuilder( | ||
708 | 163 | Branch.open(workingbranch_dir)) | ||
709 | 164 | versionfile_path = os.path.join(build_dir, 'jarmonbuild', '_version.py') | ||
710 | 165 | with open(versionfile_path, 'w') as f: | ||
711 | 166 | v.generate(f) | ||
712 | 167 | |||
713 | 168 | |||
714 | 169 | self.log.debug('Generate apidocs') | ||
715 | 170 | BuildApidocsCommand(buildversion=self.buildversion).main(argv) | ||
716 | 171 | |||
717 | 172 | |||
718 | 173 | self.log.debug('Generate archive') | ||
719 | 174 | archive_root = 'jarmon-%s' % (self.buildversion,) | ||
720 | 175 | prefix_len = len(build_dir) + 1 | ||
721 | 176 | z = ZipFile('%s.zip' % (archive_root,), 'w', ZIP_DEFLATED) | ||
722 | 177 | try: | ||
723 | 178 | for root, dirs, files in os.walk(build_dir): | ||
724 | 179 | for file in files: | ||
725 | 180 | z.write( | ||
726 | 181 | os.path.join(root, file), | ||
727 | 182 | os.path.join(archive_root, root[prefix_len:], file) | ||
728 | 183 | ) | ||
729 | 184 | finally: | ||
730 | 185 | z.close() | ||
731 | 186 | |||
732 | 187 | |||
733 | 188 | # The available sub commands | ||
734 | 189 | build_commands = { | ||
735 | 190 | 'apidocs': BuildApidocsCommand, | ||
736 | 191 | 'release': BuildReleaseCommand, | ||
737 | 192 | } | ||
738 | 193 | |||
739 | 194 | |||
740 | 195 | def main(argv=sys.argv[1:]): | ||
741 | 196 | """ | ||
742 | 197 | The root build command which dispatches to various subcommands for eg | ||
743 | 198 | building apidocs and release zip files. | ||
744 | 199 | """ | ||
745 | 200 | parser = OptionParser(usage='%prog [options] SUBCOMMAND [options]') | ||
746 | 201 | parser.add_option( | ||
747 | 202 | '-V', '--build-version', dest='buildversion', default='0', | ||
748 | 203 | metavar='BUILDVERSION', help='Specify the build version') | ||
749 | 204 | parser.add_option( | ||
750 | 205 | '-d', '--debug', action='store_true', default=False, dest='debug', | ||
751 | 206 | help='Print verbose debug log to stderr') | ||
752 | 207 | |||
753 | 208 | parser.disable_interspersed_args() | ||
754 | 209 | |||
755 | 210 | options, args = parser.parse_args(argv) | ||
756 | 211 | |||
757 | 212 | if len(args) < 1: | ||
758 | 213 | parser.error('Please specify a sub command. ' | ||
759 | 214 | 'Available commands: %r' % (build_commands.keys())) | ||
760 | 215 | |||
761 | 216 | # First argument is the name of a subcommand | ||
762 | 217 | command_name = args.pop(0) | ||
763 | 218 | command_factory = build_commands.get(command_name) | ||
764 | 219 | if not command_factory: | ||
765 | 220 | parser.error('Unrecognised subcommand: %r' % (command_name,)) | ||
766 | 221 | |||
767 | 222 | # Setup logging | ||
768 | 223 | log = logging.getLogger(__name__) | ||
769 | 224 | log.setLevel(logging.INFO) | ||
770 | 225 | # create console handler and set level to debug | ||
771 | 226 | ch = logging.StreamHandler() | ||
772 | 227 | ch.setLevel(logging.INFO) | ||
773 | 228 | # create formatter | ||
774 | 229 | formatter = logging.Formatter( | ||
775 | 230 | '%(asctime)s - %(name)s - %(levelname)s - %(message)s') | ||
776 | 231 | # add formatter to ch | ||
777 | 232 | ch.setFormatter(formatter) | ||
778 | 233 | log.addHandler(ch) | ||
779 | 234 | |||
780 | 235 | if options.debug: | ||
781 | 236 | log.setLevel(logging.DEBUG) | ||
782 | 237 | ch.setLevel(logging.DEBUG) | ||
783 | 238 | |||
784 | 239 | command_factory(buildversion=options.buildversion).main(argv=args) | ||
785 | 0 | 240 | ||
786 | === added directory 'jarmonbuild/yuidoc_template' | |||
787 | === added directory 'jarmonbuild/yuidoc_template/assets' | |||
788 | === added file 'jarmonbuild/yuidoc_template/assets/ac-js' | |||
789 | --- jarmonbuild/yuidoc_template/assets/ac-js 1970-01-01 00:00:00 +0000 | |||
790 | +++ jarmonbuild/yuidoc_template/assets/ac-js 2010-08-22 21:23:38 +0000 | |||
791 | @@ -0,0 +1,162 @@ | |||
792 | 1 | (function() { | ||
793 | 2 | var Event=YAHOO.util.Event, | ||
794 | 3 | Dom=YAHOO.util.Dom, | ||
795 | 4 | oACDS, oAutoComp, | ||
796 | 5 | show = { | ||
797 | 6 | 'private': false, | ||
798 | 7 | 'protected': false, | ||
799 | 8 | 'deprecated': false | ||
800 | 9 | }; | ||
801 | 10 | |||
802 | 11 | Event.onAvailable('yui-classopts-form', function() { | ||
803 | 12 | //Checkboxes are available.. | ||
804 | 13 | var handleClick = function(e) { | ||
805 | 14 | var id, checked = false; | ||
806 | 15 | if (YAHOO.lang.isString(e)) { | ||
807 | 16 | id = e; | ||
808 | 17 | } else { | ||
809 | 18 | var tar = Event.getTarget(e); | ||
810 | 19 | id = tar.id; | ||
811 | 20 | } | ||
812 | 21 | var el = Dom.get(id); | ||
813 | 22 | checked = el.checked; | ||
814 | 23 | |||
815 | 24 | var className = id; | ||
816 | 25 | if (checked) { | ||
817 | 26 | show[id.replace('show_', '')] = true; | ||
818 | 27 | Dom.addClass(document.body, className); | ||
819 | 28 | YAHOO.util.Cookie.setSub('yuidoc', id, 'checked'); | ||
820 | 29 | } else { | ||
821 | 30 | show[id.replace('show_', '')] = false; | ||
822 | 31 | Dom.removeClass(document.body, className); | ||
823 | 32 | YAHOO.util.Cookie.setSub('yuidoc', id, ''); | ||
824 | 33 | } | ||
825 | 34 | }; | ||
826 | 35 | |||
827 | 36 | var checkCookie = function(id) { | ||
828 | 37 | var value = YAHOO.util.Cookie.getSub('yuidoc', id), | ||
829 | 38 | el = Dom.get(id), checked = (value === 'checked');; | ||
830 | 39 | |||
831 | 40 | /* | ||
832 | 41 | if (value === 'checked') { | ||
833 | 42 | el.checked = true; | ||
834 | 43 | } else { | ||
835 | 44 | el.checked = false; | ||
836 | 45 | } | ||
837 | 46 | */ | ||
838 | 47 | |||
839 | 48 | el.checked = checked; | ||
840 | 49 | return checked; | ||
841 | 50 | }; | ||
842 | 51 | |||
843 | 52 | var els = ['show_deprecated', 'show_protected', 'show_private'], | ||
844 | 53 | reapplyHash = false; | ||
845 | 54 | |||
846 | 55 | for (var i = 0; i < els.length; i++) { | ||
847 | 56 | Event.on(els[i], 'click', handleClick); | ||
848 | 57 | reapplyHash = checkCookie(els[i]) || reapplyHash; | ||
849 | 58 | handleClick(els[i]); | ||
850 | 59 | } | ||
851 | 60 | |||
852 | 61 | // If we dynamically show private/protected/etc items during | ||
853 | 62 | // load, we need to reapply anchors so that the search feature | ||
854 | 63 | // works correctly for items that are initially hidden. | ||
855 | 64 | if (reapplyHash) { | ||
856 | 65 | var dl = document.location, hash = dl.hash; | ||
857 | 66 | if (hash) { | ||
858 | 67 | dl.hash = hash; | ||
859 | 68 | } | ||
860 | 69 | } | ||
861 | 70 | |||
862 | 71 | }); | ||
863 | 72 | |||
864 | 73 | //Starting the AutoComplete code | ||
865 | 74 | var getResults = function(query) { | ||
866 | 75 | var results = []; | ||
867 | 76 | if(query && query.length > 0) { | ||
868 | 77 | |||
869 | 78 | var q = query.toLowerCase(); | ||
870 | 79 | |||
871 | 80 | for (var i=0, len=ALL_YUI_PROPS.length; i<len; ++i) { | ||
872 | 81 | |||
873 | 82 | var prop = ALL_YUI_PROPS[i]; | ||
874 | 83 | |||
875 | 84 | if (!show['protected'] && prop.access == "protected") { | ||
876 | 85 | // skip | ||
877 | 86 | } else if (!show['private'] && prop.access == "private") { | ||
878 | 87 | // skip | ||
879 | 88 | } else if (!show['deprecated'] && prop.deprecated) { | ||
880 | 89 | // skip | ||
881 | 90 | } else { | ||
882 | 91 | var s = (prop.host + "." + prop.name).toLowerCase(); | ||
883 | 92 | if (s.indexOf(q) > -1 ) { | ||
884 | 93 | results.push([query, prop]); | ||
885 | 94 | } | ||
886 | 95 | } | ||
887 | 96 | } | ||
888 | 97 | } | ||
889 | 98 | |||
890 | 99 | return results; | ||
891 | 100 | }; | ||
892 | 101 | |||
893 | 102 | // Define Custom Event handlers | ||
894 | 103 | var myOnDataReturn = function(sType, aArgs) { | ||
895 | 104 | var oAutoComp = aArgs[0]; | ||
896 | 105 | var query = aArgs[1]; | ||
897 | 106 | var aResults = aArgs[2]; | ||
898 | 107 | |||
899 | 108 | if(aResults.length == 0) { | ||
900 | 109 | if (query.length > 0) { | ||
901 | 110 | oAutoComp.setBody("<div id=\"resultsdefault\">Not found</div>"); | ||
902 | 111 | } | ||
903 | 112 | } | ||
904 | 113 | }; | ||
905 | 114 | |||
906 | 115 | var myOnItemSelect = function(sType, aArgs) { | ||
907 | 116 | var ac = aArgs[0]; | ||
908 | 117 | var item = aArgs[2]; | ||
909 | 118 | location.href = item[1].url; | ||
910 | 119 | }; | ||
911 | 120 | |||
912 | 121 | |||
913 | 122 | Event.onAvailable("searchresults", function() { | ||
914 | 123 | |||
915 | 124 | // Instantiate JS Function DataSource | ||
916 | 125 | oACDS = new YAHOO.widget.DS_JSFunction(getResults); | ||
917 | 126 | oACDS.maxCacheEntries = 30; | ||
918 | 127 | |||
919 | 128 | // Instantiate AutoComplete | ||
920 | 129 | oAutoComp = new YAHOO.widget.AutoComplete('searchinput','searchresults', oACDS); | ||
921 | 130 | //oAutoComp.alwaysShowContainer = true; | ||
922 | 131 | oAutoComp.queryDelay = 0.2; | ||
923 | 132 | oAutoComp.maxResultsDisplayed = 200; | ||
924 | 133 | oAutoComp.minQueryLength = 0; | ||
925 | 134 | oAutoComp.formatResult = function(oResultItem, query) { | ||
926 | 135 | var sMarkup = "<em>" + oResultItem[1].host + '</em> <span>' + oResultItem[1].name + '</span>'; | ||
927 | 136 | return sMarkup; | ||
928 | 137 | }; | ||
929 | 138 | |||
930 | 139 | // Subscribe to Custom Events | ||
931 | 140 | oAutoComp.dataReturnEvent.subscribe(myOnDataReturn); | ||
932 | 141 | oAutoComp.itemSelectEvent.subscribe(myOnItemSelect); | ||
933 | 142 | |||
934 | 143 | // Set initial content in the container | ||
935 | 144 | oAutoComp.sendQuery(Dom.get("searchinput").value); | ||
936 | 145 | |||
937 | 146 | }); | ||
938 | 147 | |||
939 | 148 | var validateForm = function() { | ||
940 | 149 | return false; | ||
941 | 150 | }; | ||
942 | 151 | |||
943 | 152 | YAHOO.util.Event.onAvailable('classTab', function() { | ||
944 | 153 | var tabs = new YAHOO.widget.TabView('classTab'); | ||
945 | 154 | }); | ||
946 | 155 | /* | ||
947 | 156 | YAHOO.util.Event.onAvailable('codeTree', function() { | ||
948 | 157 | var tree1 = new YAHOO.widget.TreeView('codeTree'); | ||
949 | 158 | tree1.render(); | ||
950 | 159 | }); | ||
951 | 160 | */ | ||
952 | 161 | |||
953 | 162 | })(); | ||
954 | 0 | 163 | ||
955 | === added file 'jarmonbuild/yuidoc_template/assets/api-js' | |||
956 | --- jarmonbuild/yuidoc_template/assets/api-js 1970-01-01 00:00:00 +0000 | |||
957 | +++ jarmonbuild/yuidoc_template/assets/api-js 2010-08-22 21:23:38 +0000 | |||
958 | @@ -0,0 +1,42 @@ | |||
959 | 1 | /* | ||
960 | 2 | Copyright (c) 2008, Yahoo! Inc. All rights reserved. | ||
961 | 3 | Code licensed under the BSD License: | ||
962 | 4 | http://developer.yahoo.net/yui/license.txt | ||
963 | 5 | version: 2.6.0 | ||
964 | 6 | */ | ||
965 | 7 | if(typeof YAHOO=="undefined"||!YAHOO){var YAHOO={};}YAHOO.namespace=function(){var A=arguments,E=null,C,B,D;for(C=0;C<A.length;C=C+1){D=A[C].split(".");E=YAHOO;for(B=(D[0]=="YAHOO")?1:0;B<D.length;B=B+1){E[D[B]]=E[D[B]]||{};E=E[D[B]];}}return E;};YAHOO.log=function(D,A,C){var B=YAHOO.widget.Logger;if(B&&B.log){return B.log(D,A,C);}else{return false;}};YAHOO.register=function(A,E,D){var I=YAHOO.env.modules;if(!I[A]){I[A]={versions:[],builds:[]};}var B=I[A],H=D.version,G=D.build,F=YAHOO.env.listeners;B.name=A;B.version=H;B.build=G;B.versions.push(H);B.builds.push(G);B.mainClass=E;for(var C=0;C<F.length;C=C+1){F[C](B);}if(E){E.VERSION=H;E.BUILD=G;}else{YAHOO.log("mainClass is undefined for module "+A,"warn");}};YAHOO.env=YAHOO.env||{modules:[],listeners:[]};YAHOO.env.getVersion=function(A){return YAHOO.env.modules[A]||null;};YAHOO.env.ua=function(){var C={ie:0,opera:0,gecko:0,webkit:0,mobile:null,air:0};var B=navigator.userAgent,A;if((/KHTML/).test(B)){C.webkit=1;}A=B.match(/AppleWebKit\/([^\s]*)/);if(A&&A[1]){C.webkit=parseFloat(A[1]);if(/ Mobile\//.test(B)){C.mobile="Apple";}else{A=B.match(/NokiaN[^\/]*/);if(A){C.mobile=A[0];}}A=B.match(/AdobeAIR\/([^\s]*)/);if(A){C.air=A[0];}}if(!C.webkit){A=B.match(/Opera[\s\/]([^\s]*)/);if(A&&A[1]){C.opera=parseFloat(A[1]);A=B.match(/Opera Mini[^;]*/);if(A){C.mobile=A[0];}}else{A=B.match(/MSIE\s([^;]*)/);if(A&&A[1]){C.ie=parseFloat(A[1]);}else{A=B.match(/Gecko\/([^\s]*)/);if(A){C.gecko=1;A=B.match(/rv:([^\s\)]*)/);if(A&&A[1]){C.gecko=parseFloat(A[1]);}}}}}return C;}();(function(){YAHOO.namespace("util","widget","example");if("undefined"!==typeof YAHOO_config){var B=YAHOO_config.listener,A=YAHOO.env.listeners,D=true,C;if(B){for(C=0;C<A.length;C=C+1){if(A[C]==B){D=false;break;}}if(D){A.push(B);}}}})();YAHOO.lang=YAHOO.lang||{};(function(){var A=YAHOO.lang,C=["toString","valueOf"],B={isArray:function(D){if(D){return A.isNumber(D.length)&&A.isFunction(D.splice);}return false;},isBoolean:function(D){return typeof D==="boolean";},isFunction:function(D){return typeof D==="function";},isNull:function(D){return D===null;},isNumber:function(D){return typeof D==="number"&&isFinite(D);},isObject:function(D){return(D&&(typeof D==="object"||A.isFunction(D)))||false;},isString:function(D){return typeof D==="string";},isUndefined:function(D){return typeof D==="undefined";},_IEEnumFix:(YAHOO.env.ua.ie)?function(F,E){for(var D=0;D<C.length;D=D+1){var H=C[D],G=E[H];if(A.isFunction(G)&&G!=Object.prototype[H]){F[H]=G;}}}:function(){},extend:function(H,I,G){if(!I||!H){throw new Error("extend failed, please check that "+"all dependencies are included.");}var E=function(){};E.prototype=I.prototype;H.prototype=new E();H.prototype.constructor=H;H.superclass=I.prototype;if(I.prototype.constructor==Object.prototype.constructor){I.prototype.constructor=I;}if(G){for(var D in G){if(A.hasOwnProperty(G,D)){H.prototype[D]=G[D];}}A._IEEnumFix(H.prototype,G);}},augmentObject:function(H,G){if(!G||!H){throw new Error("Absorb failed, verify dependencies.");}var D=arguments,F,I,E=D[2];if(E&&E!==true){for(F=2;F<D.length;F=F+1){H[D[F]]=G[D[F]];}}else{for(I in G){if(E||!(I in H)){H[I]=G[I];}}A._IEEnumFix(H,G);}},augmentProto:function(G,F){if(!F||!G){throw new Error("Augment failed, verify dependencies.");}var D=[G.prototype,F.prototype];for(var E=2;E<arguments.length;E=E+1){D.push(arguments[E]);}A.augmentObject.apply(this,D);},dump:function(D,I){var F,H,K=[],L="{...}",E="f(){...}",J=", ",G=" => ";if(!A.isObject(D)){return D+"";}else{if(D instanceof Date||("nodeType" in D&&"tagName" in D)){return D;}else{if(A.isFunction(D)){return E;}}}I=(A.isNumber(I))?I:3;if(A.isArray(D)){K.push("[");for(F=0,H=D.length;F<H;F=F+1){if(A.isObject(D[F])){K.push((I>0)?A.dump(D[F],I-1):L);}else{K.push(D[F]);}K.push(J);}if(K.length>1){K.pop();}K.push("]");}else{K.push("{");for(F in D){if(A.hasOwnProperty(D,F)){K.push(F+G);if(A.isObject(D[F])){K.push((I>0)?A.dump(D[F],I-1):L);}else{K.push(D[F]);}K.push(J);}}if(K.length>1){K.pop();}K.push("}");}return K.join("");},substitute:function(S,E,L){var I,H,G,O,P,R,N=[],F,J="dump",M=" ",D="{",Q="}";for(;;){I=S.lastIndexOf(D);if(I<0){break;}H=S.indexOf(Q,I);if(I+1>=H){break;}F=S.substring(I+1,H);O=F;R=null;G=O.indexOf(M);if(G>-1){R=O.substring(G+1);O=O.substring(0,G);}P=E[O];if(L){P=L(O,P,R);}if(A.isObject(P)){if(A.isArray(P)){P=A.dump(P,parseInt(R,10));}else{R=R||"";var K=R.indexOf(J);if(K>-1){R=R.substring(4);}if(P.toString===Object.prototype.toString||K>-1){P=A.dump(P,parseInt(R,10));}else{P=P.toString();}}}else{if(!A.isString(P)&&!A.isNumber(P)){P="~-"+N.length+"-~";N[N.length]=F;}}S=S.substring(0,I)+P+S.substring(H+1);}for(I=N.length-1;I>=0;I=I-1){S=S.replace(new RegExp("~-"+I+"-~"),"{"+N[I]+"}","g");}return S;},trim:function(D){try{return D.replace(/^\s+|\s+$/g,"");}catch(E){return D;}},merge:function(){var G={},E=arguments;for(var F=0,D=E.length;F<D;F=F+1){A.augmentObject(G,E[F],true);}return G;},later:function(K,E,L,G,H){K=K||0;E=E||{};var F=L,J=G,I,D;if(A.isString(L)){F=E[L];}if(!F){throw new TypeError("method undefined");}if(!A.isArray(J)){J=[G];}I=function(){F.apply(E,J);};D=(H)?setInterval(I,K):setTimeout(I,K);return{interval:H,cancel:function(){if(this.interval){clearInterval(D);}else{clearTimeout(D);}}};},isValue:function(D){return(A.isObject(D)||A.isString(D)||A.isNumber(D)||A.isBoolean(D));}};A.hasOwnProperty=(Object.prototype.hasOwnProperty)?function(D,E){return D&&D.hasOwnProperty(E);}:function(D,E){return !A.isUndefined(D[E])&&D.constructor.prototype[E]!==D[E];};B.augmentObject(A,B,true);YAHOO.util.Lang=A;A.augment=A.augmentProto;YAHOO.augment=A.augmentProto;YAHOO.extend=A.extend;})();YAHOO.register("yahoo",YAHOO,{version:"2.6.0",build:"1321"});(function(){var B=YAHOO.util,F=YAHOO.lang,L,J,K={},G={},N=window.document;YAHOO.env._id_counter=YAHOO.env._id_counter||0;var C=YAHOO.env.ua.opera,M=YAHOO.env.ua.webkit,A=YAHOO.env.ua.gecko,H=YAHOO.env.ua.ie;var E={HYPHEN:/(-[a-z])/i,ROOT_TAG:/^body|html$/i,OP_SCROLL:/^(?:inline|table-row)$/i};var O=function(Q){if(!E.HYPHEN.test(Q)){return Q;}if(K[Q]){return K[Q];}var R=Q;while(E.HYPHEN.exec(R)){R=R.replace(RegExp.$1,RegExp.$1.substr(1).toUpperCase());}K[Q]=R;return R;};var P=function(R){var Q=G[R];if(!Q){Q=new RegExp("(?:^|\\s+)"+R+"(?:\\s+|$)");G[R]=Q;}return Q;};if(N.defaultView&&N.defaultView.getComputedStyle){L=function(Q,T){var S=null;if(T=="float"){T="cssFloat";}var R=Q.ownerDocument.defaultView.getComputedStyle(Q,"");if(R){S=R[O(T)];}return Q.style[T]||S;};}else{if(N.documentElement.currentStyle&&H){L=function(Q,S){switch(O(S)){case"opacity":var U=100;try{U=Q.filters["DXImageTransform.Microsoft.Alpha"].opacity;}catch(T){try{U=Q.filters("alpha").opacity;}catch(T){}}return U/100;case"float":S="styleFloat";default:var R=Q.currentStyle?Q.currentStyle[S]:null;return(Q.style[S]||R);}};}else{L=function(Q,R){return Q.style[R];};}}if(H){J=function(Q,R,S){switch(R){case"opacity":if(F.isString(Q.style.filter)){Q.style.filter="alpha(opacity="+S*100+")";if(!Q.currentStyle||!Q.currentStyle.hasLayout){Q.style.zoom=1;}}break;case"float":R="styleFloat";default:Q.style[R]=S;}};}else{J=function(Q,R,S){if(R=="float"){R="cssFloat";}Q.style[R]=S;};}var D=function(Q,R){return Q&&Q.nodeType==1&&(!R||R(Q));};YAHOO.util.Dom={get:function(S){if(S){if(S.nodeType||S.item){return S;}if(typeof S==="string"){return N.getElementById(S);}if("length" in S){var T=[];for(var R=0,Q=S.length;R<Q;++R){T[T.length]=B.Dom.get(S[R]);}return T;}return S;}return null;},getStyle:function(Q,S){S=O(S);var R=function(T){return L(T,S);};return B.Dom.batch(Q,R,B.Dom,true);},setStyle:function(Q,S,T){S=O(S);var R=function(U){J(U,S,T);};B.Dom.batch(Q,R,B.Dom,true);},getXY:function(Q){var R=function(S){if((S.parentNode===null||S.offsetParent===null||this.getStyle(S,"display")=="none")&&S!=S.ownerDocument.body){return false;}return I(S);};return B.Dom.batch(Q,R,B.Dom,true);},getX:function(Q){var R=function(S){return B.Dom.getXY(S)[0];};return B.Dom.batch(Q,R,B.Dom,true);},getY:function(Q){var R=function(S){return B.Dom.getXY(S)[1];};return B.Dom.batch(Q,R,B.Dom,true);},setXY:function(Q,T,S){var R=function(W){var V=this.getStyle(W,"position");if(V=="static"){this.setStyle(W,"position","relative");V="relative";}var Y=this.getXY(W);if(Y===false){return false;}var X=[parseInt(this.getStyle(W,"left"),10),parseInt(this.getStyle(W,"top"),10)];if(isNaN(X[0])){X[0]=(V=="relative")?0:W.offsetLeft;}if(isNaN(X[1])){X[1]=(V=="relative")?0:W.offsetTop;}if(T[0]!==null){W.style.left=T[0]-Y[0]+X[0]+"px";}if(T[1]!==null){W.style.top=T[1]-Y[1]+X[1]+"px";}if(!S){var U=this.getXY(W);if((T[0]!==null&&U[0]!=T[0])||(T[1]!==null&&U[1]!=T[1])){this.setXY(W,T,true);}}};B.Dom.batch(Q,R,B.Dom,true);},setX:function(R,Q){B.Dom.setXY(R,[Q,null]);},setY:function(Q,R){B.Dom.setXY(Q,[null,R]);},getRegion:function(Q){var R=function(S){if((S.parentNode===null||S.offsetParent===null||this.getStyle(S,"display")=="none")&&S!=S.ownerDocument.body){return false;}var T=B.Region.getRegion(S);return T;};return B.Dom.batch(Q,R,B.Dom,true);},getClientWidth:function(){return B.Dom.getViewportWidth();},getClientHeight:function(){return B.Dom.getViewportHeight();},getElementsByClassName:function(U,Y,V,W){U=F.trim(U);Y=Y||"*";V=(V)?B.Dom.get(V):null||N;if(!V){return[];}var R=[],Q=V.getElementsByTagName(Y),X=P(U);for(var S=0,T=Q.length;S<T;++S){if(X.test(Q[S].className)){R[R.length]=Q[S];if(W){W.call(Q[S],Q[S]);}}}return R;},hasClass:function(S,R){var Q=P(R);var T=function(U){return Q.test(U.className);};return B.Dom.batch(S,T,B.Dom,true);},addClass:function(R,Q){var S=function(T){if(this.hasClass(T,Q)){return false;}T.className=F.trim([T.className,Q].join(" "));return true;};return B.Dom.batch(R,S,B.Dom,true);},removeClass:function(S,R){var Q=P(R);var T=function(W){var V=false,X=W.className;if(R&&X&&this.hasClass(W,R)){W.className=X.replace(Q," ");if(this.hasClass(W,R)){this.removeClass(W,R);}W.className=F.trim(W.className);if(W.className===""){var U=(W.hasAttribute)?"class":"className";W.removeAttribute(U);}V=true;}return V;};return B.Dom.batch(S,T,B.Dom,true);},replaceClass:function(T,R,Q){if(!Q||R===Q){return false;}var S=P(R);var U=function(V){if(!this.hasClass(V,R)){this.addClass(V,Q);return true;}V.className=V.className.replace(S," "+Q+" ");if(this.hasClass(V,R)){this.removeClass(V,R);}V.className=F.trim(V.className);return true;};return B.Dom.batch(T,U,B.Dom,true);},generateId:function(Q,S){S=S||"yui-gen";var R=function(T){if(T&&T.id){return T.id;}var U=S+YAHOO.env._id_counter++;if(T){T.id=U;}return U;};return B.Dom.batch(Q,R,B.Dom,true)||R.apply(B.Dom,arguments);},isAncestor:function(R,S){R=B.Dom.get(R);S=B.Dom.get(S);var Q=false;if((R&&S)&&(R.nodeType&&S.nodeType)){if(R.contains&&R!==S){Q=R.contains(S);}else{if(R.compareDocumentPosition){Q=!!(R.compareDocumentPosition(S)&16);}}}else{}return Q;},inDocument:function(Q){return this.isAncestor(N.documentElement,Q);},getElementsBy:function(X,R,S,U){R=R||"*";S=(S)?B.Dom.get(S):null||N;if(!S){return[];}var T=[],W=S.getElementsByTagName(R);for(var V=0,Q=W.length;V<Q;++V){if(X(W[V])){T[T.length]=W[V];if(U){U(W[V]);}}}return T;},batch:function(U,X,W,S){U=(U&&(U.tagName||U.item))?U:B.Dom.get(U);if(!U||!X){return false;}var T=(S)?W:window;if(U.tagName||U.length===undefined){return X.call(T,U,W);}var V=[];for(var R=0,Q=U.length;R<Q;++R){V[V.length]=X.call(T,U[R],W);}return V;},getDocumentHeight:function(){var R=(N.compatMode!="CSS1Compat")?N.body.scrollHeight:N.documentElement.scrollHeight;var Q=Math.max(R,B.Dom.getViewportHeight());return Q;},getDocumentWidth:function(){var R=(N.compatMode!="CSS1Compat")?N.body.scrollWidth:N.documentElement.scrollWidth;var Q=Math.max(R,B.Dom.getViewportWidth());return Q;},getViewportHeight:function(){var Q=self.innerHeight; | ||
966 | 8 | var R=N.compatMode;if((R||H)&&!C){Q=(R=="CSS1Compat")?N.documentElement.clientHeight:N.body.clientHeight;}return Q;},getViewportWidth:function(){var Q=self.innerWidth;var R=N.compatMode;if(R||H){Q=(R=="CSS1Compat")?N.documentElement.clientWidth:N.body.clientWidth;}return Q;},getAncestorBy:function(Q,R){while((Q=Q.parentNode)){if(D(Q,R)){return Q;}}return null;},getAncestorByClassName:function(R,Q){R=B.Dom.get(R);if(!R){return null;}var S=function(T){return B.Dom.hasClass(T,Q);};return B.Dom.getAncestorBy(R,S);},getAncestorByTagName:function(R,Q){R=B.Dom.get(R);if(!R){return null;}var S=function(T){return T.tagName&&T.tagName.toUpperCase()==Q.toUpperCase();};return B.Dom.getAncestorBy(R,S);},getPreviousSiblingBy:function(Q,R){while(Q){Q=Q.previousSibling;if(D(Q,R)){return Q;}}return null;},getPreviousSibling:function(Q){Q=B.Dom.get(Q);if(!Q){return null;}return B.Dom.getPreviousSiblingBy(Q);},getNextSiblingBy:function(Q,R){while(Q){Q=Q.nextSibling;if(D(Q,R)){return Q;}}return null;},getNextSibling:function(Q){Q=B.Dom.get(Q);if(!Q){return null;}return B.Dom.getNextSiblingBy(Q);},getFirstChildBy:function(Q,S){var R=(D(Q.firstChild,S))?Q.firstChild:null;return R||B.Dom.getNextSiblingBy(Q.firstChild,S);},getFirstChild:function(Q,R){Q=B.Dom.get(Q);if(!Q){return null;}return B.Dom.getFirstChildBy(Q);},getLastChildBy:function(Q,S){if(!Q){return null;}var R=(D(Q.lastChild,S))?Q.lastChild:null;return R||B.Dom.getPreviousSiblingBy(Q.lastChild,S);},getLastChild:function(Q){Q=B.Dom.get(Q);return B.Dom.getLastChildBy(Q);},getChildrenBy:function(R,T){var S=B.Dom.getFirstChildBy(R,T);var Q=S?[S]:[];B.Dom.getNextSiblingBy(S,function(U){if(!T||T(U)){Q[Q.length]=U;}return false;});return Q;},getChildren:function(Q){Q=B.Dom.get(Q);if(!Q){}return B.Dom.getChildrenBy(Q);},getDocumentScrollLeft:function(Q){Q=Q||N;return Math.max(Q.documentElement.scrollLeft,Q.body.scrollLeft);},getDocumentScrollTop:function(Q){Q=Q||N;return Math.max(Q.documentElement.scrollTop,Q.body.scrollTop);},insertBefore:function(R,Q){R=B.Dom.get(R);Q=B.Dom.get(Q);if(!R||!Q||!Q.parentNode){return null;}return Q.parentNode.insertBefore(R,Q);},insertAfter:function(R,Q){R=B.Dom.get(R);Q=B.Dom.get(Q);if(!R||!Q||!Q.parentNode){return null;}if(Q.nextSibling){return Q.parentNode.insertBefore(R,Q.nextSibling);}else{return Q.parentNode.appendChild(R);}},getClientRegion:function(){var S=B.Dom.getDocumentScrollTop(),R=B.Dom.getDocumentScrollLeft(),T=B.Dom.getViewportWidth()+R,Q=B.Dom.getViewportHeight()+S;return new B.Region(S,T,Q,R);}};var I=function(){if(N.documentElement.getBoundingClientRect){return function(S){var T=S.getBoundingClientRect(),R=Math.round;var Q=S.ownerDocument;return[R(T.left+B.Dom.getDocumentScrollLeft(Q)),R(T.top+B.Dom.getDocumentScrollTop(Q))];};}else{return function(S){var T=[S.offsetLeft,S.offsetTop];var R=S.offsetParent;var Q=(M&&B.Dom.getStyle(S,"position")=="absolute"&&S.offsetParent==S.ownerDocument.body);if(R!=S){while(R){T[0]+=R.offsetLeft;T[1]+=R.offsetTop;if(!Q&&M&&B.Dom.getStyle(R,"position")=="absolute"){Q=true;}R=R.offsetParent;}}if(Q){T[0]-=S.ownerDocument.body.offsetLeft;T[1]-=S.ownerDocument.body.offsetTop;}R=S.parentNode;while(R.tagName&&!E.ROOT_TAG.test(R.tagName)){if(R.scrollTop||R.scrollLeft){T[0]-=R.scrollLeft;T[1]-=R.scrollTop;}R=R.parentNode;}return T;};}}();})();YAHOO.util.Region=function(C,D,A,B){this.top=C;this[1]=C;this.right=D;this.bottom=A;this.left=B;this[0]=B;};YAHOO.util.Region.prototype.contains=function(A){return(A.left>=this.left&&A.right<=this.right&&A.top>=this.top&&A.bottom<=this.bottom);};YAHOO.util.Region.prototype.getArea=function(){return((this.bottom-this.top)*(this.right-this.left));};YAHOO.util.Region.prototype.intersect=function(E){var C=Math.max(this.top,E.top);var D=Math.min(this.right,E.right);var A=Math.min(this.bottom,E.bottom);var B=Math.max(this.left,E.left);if(A>=C&&D>=B){return new YAHOO.util.Region(C,D,A,B);}else{return null;}};YAHOO.util.Region.prototype.union=function(E){var C=Math.min(this.top,E.top);var D=Math.max(this.right,E.right);var A=Math.max(this.bottom,E.bottom);var B=Math.min(this.left,E.left);return new YAHOO.util.Region(C,D,A,B);};YAHOO.util.Region.prototype.toString=function(){return("Region {"+"top: "+this.top+", right: "+this.right+", bottom: "+this.bottom+", left: "+this.left+"}");};YAHOO.util.Region.getRegion=function(D){var F=YAHOO.util.Dom.getXY(D);var C=F[1];var E=F[0]+D.offsetWidth;var A=F[1]+D.offsetHeight;var B=F[0];return new YAHOO.util.Region(C,E,A,B);};YAHOO.util.Point=function(A,B){if(YAHOO.lang.isArray(A)){B=A[1];A=A[0];}this.x=this.right=this.left=this[0]=A;this.y=this.top=this.bottom=this[1]=B;};YAHOO.util.Point.prototype=new YAHOO.util.Region();YAHOO.register("dom",YAHOO.util.Dom,{version:"2.6.0",build:"1321"});YAHOO.util.CustomEvent=function(D,B,C,A){this.type=D;this.scope=B||window;this.silent=C;this.signature=A||YAHOO.util.CustomEvent.LIST;this.subscribers=[];if(!this.silent){}var E="_YUICEOnSubscribe";if(D!==E){this.subscribeEvent=new YAHOO.util.CustomEvent(E,this,true);}this.lastError=null;};YAHOO.util.CustomEvent.LIST=0;YAHOO.util.CustomEvent.FLAT=1;YAHOO.util.CustomEvent.prototype={subscribe:function(B,C,A){if(!B){throw new Error("Invalid callback for subscriber to '"+this.type+"'");}if(this.subscribeEvent){this.subscribeEvent.fire(B,C,A);}this.subscribers.push(new YAHOO.util.Subscriber(B,C,A));},unsubscribe:function(D,F){if(!D){return this.unsubscribeAll();}var E=false;for(var B=0,A=this.subscribers.length;B<A;++B){var C=this.subscribers[B];if(C&&C.contains(D,F)){this._delete(B);E=true;}}return E;},fire:function(){this.lastError=null;var K=[],E=this.subscribers.length;if(!E&&this.silent){return true;}var I=[].slice.call(arguments,0),G=true,D,J=false;if(!this.silent){}var C=this.subscribers.slice(),A=YAHOO.util.Event.throwErrors;for(D=0;D<E;++D){var M=C[D];if(!M){J=true;}else{if(!this.silent){}var L=M.getScope(this.scope);if(this.signature==YAHOO.util.CustomEvent.FLAT){var B=null;if(I.length>0){B=I[0];}try{G=M.fn.call(L,B,M.obj);}catch(F){this.lastError=F;if(A){throw F;}}}else{try{G=M.fn.call(L,this.type,I,M.obj);}catch(H){this.lastError=H;if(A){throw H;}}}if(false===G){if(!this.silent){}break;}}}return(G!==false);},unsubscribeAll:function(){for(var A=this.subscribers.length-1;A>-1;A--){this._delete(A);}this.subscribers=[];return A;},_delete:function(A){var B=this.subscribers[A];if(B){delete B.fn;delete B.obj;}this.subscribers.splice(A,1);},toString:function(){return"CustomEvent: "+"'"+this.type+"', "+"scope: "+this.scope;}};YAHOO.util.Subscriber=function(B,C,A){this.fn=B;this.obj=YAHOO.lang.isUndefined(C)?null:C;this.override=A;};YAHOO.util.Subscriber.prototype.getScope=function(A){if(this.override){if(this.override===true){return this.obj;}else{return this.override;}}return A;};YAHOO.util.Subscriber.prototype.contains=function(A,B){if(B){return(this.fn==A&&this.obj==B);}else{return(this.fn==A);}};YAHOO.util.Subscriber.prototype.toString=function(){return"Subscriber { obj: "+this.obj+", override: "+(this.override||"no")+" }";};if(!YAHOO.util.Event){YAHOO.util.Event=function(){var H=false;var I=[];var J=[];var G=[];var E=[];var C=0;var F=[];var B=[];var A=0;var D={63232:38,63233:40,63234:37,63235:39,63276:33,63277:34,25:9};var K=YAHOO.env.ua.ie?"focusin":"focus";var L=YAHOO.env.ua.ie?"focusout":"blur";return{POLL_RETRYS:2000,POLL_INTERVAL:20,EL:0,TYPE:1,FN:2,WFN:3,UNLOAD_OBJ:3,ADJ_SCOPE:4,OBJ:5,OVERRIDE:6,CAPTURE:7,lastError:null,isSafari:YAHOO.env.ua.webkit,webkit:YAHOO.env.ua.webkit,isIE:YAHOO.env.ua.ie,_interval:null,_dri:null,DOMReady:false,throwErrors:false,startInterval:function(){if(!this._interval){var M=this;var N=function(){M._tryPreloadAttach();};this._interval=setInterval(N,this.POLL_INTERVAL);}},onAvailable:function(R,O,S,Q,P){var M=(YAHOO.lang.isString(R))?[R]:R;for(var N=0;N<M.length;N=N+1){F.push({id:M[N],fn:O,obj:S,override:Q,checkReady:P});}C=this.POLL_RETRYS;this.startInterval();},onContentReady:function(O,M,P,N){this.onAvailable(O,M,P,N,true);},onDOMReady:function(M,O,N){if(this.DOMReady){setTimeout(function(){var P=window;if(N){if(N===true){P=O;}else{P=N;}}M.call(P,"DOMReady",[],O);},0);}else{this.DOMReadyEvent.subscribe(M,O,N);}},_addListener:function(O,M,X,S,N,a){if(!X||!X.call){return false;}if(this._isValidCollection(O)){var Y=true;for(var T=0,V=O.length;T<V;++T){Y=this._addListener(O[T],M,X,S,N,a)&&Y;}return Y;}else{if(YAHOO.lang.isString(O)){var R=this.getEl(O);if(R){O=R;}else{this.onAvailable(O,function(){YAHOO.util.Event._addListener(O,M,X,S,N,a);});return true;}}}if(!O){return false;}if("unload"==M&&S!==this){J[J.length]=[O,M,X,S,N,a];return true;}var b=O;if(N){if(N===true){b=S;}else{b=N;}}var P=function(c){return X.call(b,YAHOO.util.Event.getEvent(c,O),S);};var Z=[O,M,X,P,b,S,N,a];var U=I.length;I[U]=Z;if(this.useLegacyEvent(O,M)){var Q=this.getLegacyIndex(O,M);if(Q==-1||O!=G[Q][0]){Q=G.length;B[O.id+M]=Q;G[Q]=[O,M,O["on"+M]];E[Q]=[];O["on"+M]=function(c){YAHOO.util.Event.fireLegacyEvent(YAHOO.util.Event.getEvent(c),Q);};}E[Q].push(Z);}else{try{this._simpleAdd(O,M,P,a);}catch(W){this.lastError=W;this._removeListener(O,M,X,a);return false;}}return true;},addListener:function(O,Q,N,P,M){return this._addListener(O,Q,N,P,M,false);},addFocusListener:function(O,N,P,M){return this._addListener(O,K,N,P,M,true);},removeFocusListener:function(N,M){return this._removeListener(N,K,M,true);},addBlurListener:function(O,N,P,M){return this._addListener(O,L,N,P,M,true);},removeBlurListener:function(N,M){return this._removeListener(N,L,M,true);},fireLegacyEvent:function(Q,O){var S=true,M,U,T,V,R;U=E[O].slice();for(var N=0,P=U.length;N<P;++N){T=U[N];if(T&&T[this.WFN]){V=T[this.ADJ_SCOPE];R=T[this.WFN].call(V,Q);S=(S&&R);}}M=G[O];if(M&&M[2]){M[2](Q);}return S;},getLegacyIndex:function(N,O){var M=this.generateId(N)+O;if(typeof B[M]=="undefined"){return -1;}else{return B[M];}},useLegacyEvent:function(M,N){return(this.webkit&&this.webkit<419&&("click"==N||"dblclick"==N));},_removeListener:function(N,M,V,Y){var Q,T,X;if(typeof N=="string"){N=this.getEl(N);}else{if(this._isValidCollection(N)){var W=true;for(Q=N.length-1;Q>-1;Q--){W=(this._removeListener(N[Q],M,V,Y)&&W);}return W;}}if(!V||!V.call){return this.purgeElement(N,false,M);}if("unload"==M){for(Q=J.length-1;Q>-1;Q--){X=J[Q];if(X&&X[0]==N&&X[1]==M&&X[2]==V){J.splice(Q,1);return true;}}return false;}var R=null;var S=arguments[4];if("undefined"===typeof S){S=this._getCacheIndex(N,M,V);}if(S>=0){R=I[S];}if(!N||!R){return false;}if(this.useLegacyEvent(N,M)){var P=this.getLegacyIndex(N,M);var O=E[P];if(O){for(Q=0,T=O.length;Q<T;++Q){X=O[Q];if(X&&X[this.EL]==N&&X[this.TYPE]==M&&X[this.FN]==V){O.splice(Q,1);break;}}}}else{try{this._simpleRemove(N,M,R[this.WFN],Y);}catch(U){this.lastError=U;return false;}}delete I[S][this.WFN];delete I[S][this.FN]; | ||
967 | 9 | I.splice(S,1);return true;},removeListener:function(N,O,M){return this._removeListener(N,O,M,false);},getTarget:function(O,N){var M=O.target||O.srcElement;return this.resolveTextNode(M);},resolveTextNode:function(N){try{if(N&&3==N.nodeType){return N.parentNode;}}catch(M){}return N;},getPageX:function(N){var M=N.pageX;if(!M&&0!==M){M=N.clientX||0;if(this.isIE){M+=this._getScrollLeft();}}return M;},getPageY:function(M){var N=M.pageY;if(!N&&0!==N){N=M.clientY||0;if(this.isIE){N+=this._getScrollTop();}}return N;},getXY:function(M){return[this.getPageX(M),this.getPageY(M)];},getRelatedTarget:function(N){var M=N.relatedTarget;if(!M){if(N.type=="mouseout"){M=N.toElement;}else{if(N.type=="mouseover"){M=N.fromElement;}}}return this.resolveTextNode(M);},getTime:function(O){if(!O.time){var N=new Date().getTime();try{O.time=N;}catch(M){this.lastError=M;return N;}}return O.time;},stopEvent:function(M){this.stopPropagation(M);this.preventDefault(M);},stopPropagation:function(M){if(M.stopPropagation){M.stopPropagation();}else{M.cancelBubble=true;}},preventDefault:function(M){if(M.preventDefault){M.preventDefault();}else{M.returnValue=false;}},getEvent:function(O,M){var N=O||window.event;if(!N){var P=this.getEvent.caller;while(P){N=P.arguments[0];if(N&&Event==N.constructor){break;}P=P.caller;}}return N;},getCharCode:function(N){var M=N.keyCode||N.charCode||0;if(YAHOO.env.ua.webkit&&(M in D)){M=D[M];}return M;},_getCacheIndex:function(Q,R,P){for(var O=0,N=I.length;O<N;O=O+1){var M=I[O];if(M&&M[this.FN]==P&&M[this.EL]==Q&&M[this.TYPE]==R){return O;}}return -1;},generateId:function(M){var N=M.id;if(!N){N="yuievtautoid-"+A;++A;M.id=N;}return N;},_isValidCollection:function(N){try{return(N&&typeof N!=="string"&&N.length&&!N.tagName&&!N.alert&&typeof N[0]!=="undefined");}catch(M){return false;}},elCache:{},getEl:function(M){return(typeof M==="string")?document.getElementById(M):M;},clearCache:function(){},DOMReadyEvent:new YAHOO.util.CustomEvent("DOMReady",this),_load:function(N){if(!H){H=true;var M=YAHOO.util.Event;M._ready();M._tryPreloadAttach();}},_ready:function(N){var M=YAHOO.util.Event;if(!M.DOMReady){M.DOMReady=true;M.DOMReadyEvent.fire();M._simpleRemove(document,"DOMContentLoaded",M._ready);}},_tryPreloadAttach:function(){if(F.length===0){C=0;clearInterval(this._interval);this._interval=null;return ;}if(this.locked){return ;}if(this.isIE){if(!this.DOMReady){this.startInterval();return ;}}this.locked=true;var S=!H;if(!S){S=(C>0&&F.length>0);}var R=[];var T=function(V,W){var U=V;if(W.override){if(W.override===true){U=W.obj;}else{U=W.override;}}W.fn.call(U,W.obj);};var N,M,Q,P,O=[];for(N=0,M=F.length;N<M;N=N+1){Q=F[N];if(Q){P=this.getEl(Q.id);if(P){if(Q.checkReady){if(H||P.nextSibling||!S){O.push(Q);F[N]=null;}}else{T(P,Q);F[N]=null;}}else{R.push(Q);}}}for(N=0,M=O.length;N<M;N=N+1){Q=O[N];T(this.getEl(Q.id),Q);}C--;if(S){for(N=F.length-1;N>-1;N--){Q=F[N];if(!Q||!Q.id){F.splice(N,1);}}this.startInterval();}else{clearInterval(this._interval);this._interval=null;}this.locked=false;},purgeElement:function(Q,R,T){var O=(YAHOO.lang.isString(Q))?this.getEl(Q):Q;var S=this.getListeners(O,T),P,M;if(S){for(P=S.length-1;P>-1;P--){var N=S[P];this._removeListener(O,N.type,N.fn,N.capture);}}if(R&&O&&O.childNodes){for(P=0,M=O.childNodes.length;P<M;++P){this.purgeElement(O.childNodes[P],R,T);}}},getListeners:function(O,M){var R=[],N;if(!M){N=[I,J];}else{if(M==="unload"){N=[J];}else{N=[I];}}var T=(YAHOO.lang.isString(O))?this.getEl(O):O;for(var Q=0;Q<N.length;Q=Q+1){var V=N[Q];if(V){for(var S=0,U=V.length;S<U;++S){var P=V[S];if(P&&P[this.EL]===T&&(!M||M===P[this.TYPE])){R.push({type:P[this.TYPE],fn:P[this.FN],obj:P[this.OBJ],adjust:P[this.OVERRIDE],scope:P[this.ADJ_SCOPE],capture:P[this.CAPTURE],index:S});}}}}return(R.length)?R:null;},_unload:function(S){var M=YAHOO.util.Event,P,O,N,R,Q,T=J.slice();for(P=0,R=J.length;P<R;++P){N=T[P];if(N){var U=window;if(N[M.ADJ_SCOPE]){if(N[M.ADJ_SCOPE]===true){U=N[M.UNLOAD_OBJ];}else{U=N[M.ADJ_SCOPE];}}N[M.FN].call(U,M.getEvent(S,N[M.EL]),N[M.UNLOAD_OBJ]);T[P]=null;N=null;U=null;}}J=null;if(I){for(O=I.length-1;O>-1;O--){N=I[O];if(N){M._removeListener(N[M.EL],N[M.TYPE],N[M.FN],N[M.CAPTURE],O);}}N=null;}G=null;M._simpleRemove(window,"unload",M._unload);},_getScrollLeft:function(){return this._getScroll()[1];},_getScrollTop:function(){return this._getScroll()[0];},_getScroll:function(){var M=document.documentElement,N=document.body;if(M&&(M.scrollTop||M.scrollLeft)){return[M.scrollTop,M.scrollLeft];}else{if(N){return[N.scrollTop,N.scrollLeft];}else{return[0,0];}}},regCE:function(){},_simpleAdd:function(){if(window.addEventListener){return function(O,P,N,M){O.addEventListener(P,N,(M));};}else{if(window.attachEvent){return function(O,P,N,M){O.attachEvent("on"+P,N);};}else{return function(){};}}}(),_simpleRemove:function(){if(window.removeEventListener){return function(O,P,N,M){O.removeEventListener(P,N,(M));};}else{if(window.detachEvent){return function(N,O,M){N.detachEvent("on"+O,M);};}else{return function(){};}}}()};}();(function(){var EU=YAHOO.util.Event;EU.on=EU.addListener;EU.onFocus=EU.addFocusListener;EU.onBlur=EU.addBlurListener; | ||
968 | 10 | /* DOMReady: based on work by: Dean Edwards/John Resig/Matthias Miller */ | ||
969 | 11 | if(EU.isIE){YAHOO.util.Event.onDOMReady(YAHOO.util.Event._tryPreloadAttach,YAHOO.util.Event,true);var n=document.createElement("p");EU._dri=setInterval(function(){try{n.doScroll("left");clearInterval(EU._dri);EU._dri=null;EU._ready();n=null;}catch(ex){}},EU.POLL_INTERVAL);}else{if(EU.webkit&&EU.webkit<525){EU._dri=setInterval(function(){var rs=document.readyState;if("loaded"==rs||"complete"==rs){clearInterval(EU._dri);EU._dri=null;EU._ready();}},EU.POLL_INTERVAL);}else{EU._simpleAdd(document,"DOMContentLoaded",EU._ready);}}EU._simpleAdd(window,"load",EU._load);EU._simpleAdd(window,"unload",EU._unload);EU._tryPreloadAttach();})();}YAHOO.util.EventProvider=function(){};YAHOO.util.EventProvider.prototype={__yui_events:null,__yui_subscribers:null,subscribe:function(A,C,F,E){this.__yui_events=this.__yui_events||{}; | ||
970 | 12 | var D=this.__yui_events[A];if(D){D.subscribe(C,F,E);}else{this.__yui_subscribers=this.__yui_subscribers||{};var B=this.__yui_subscribers;if(!B[A]){B[A]=[];}B[A].push({fn:C,obj:F,override:E});}},unsubscribe:function(C,E,G){this.__yui_events=this.__yui_events||{};var A=this.__yui_events;if(C){var F=A[C];if(F){return F.unsubscribe(E,G);}}else{var B=true;for(var D in A){if(YAHOO.lang.hasOwnProperty(A,D)){B=B&&A[D].unsubscribe(E,G);}}return B;}return false;},unsubscribeAll:function(A){return this.unsubscribe(A);},createEvent:function(G,D){this.__yui_events=this.__yui_events||{};var A=D||{};var I=this.__yui_events;if(I[G]){}else{var H=A.scope||this;var E=(A.silent);var B=new YAHOO.util.CustomEvent(G,H,E,YAHOO.util.CustomEvent.FLAT);I[G]=B;if(A.onSubscribeCallback){B.subscribeEvent.subscribe(A.onSubscribeCallback);}this.__yui_subscribers=this.__yui_subscribers||{};var F=this.__yui_subscribers[G];if(F){for(var C=0;C<F.length;++C){B.subscribe(F[C].fn,F[C].obj,F[C].override);}}}return I[G];},fireEvent:function(E,D,A,C){this.__yui_events=this.__yui_events||{};var G=this.__yui_events[E];if(!G){return null;}var B=[];for(var F=1;F<arguments.length;++F){B.push(arguments[F]);}return G.fire.apply(G,B);},hasEvent:function(A){if(this.__yui_events){if(this.__yui_events[A]){return true;}}return false;}};YAHOO.util.KeyListener=function(A,F,B,C){if(!A){}else{if(!F){}else{if(!B){}}}if(!C){C=YAHOO.util.KeyListener.KEYDOWN;}var D=new YAHOO.util.CustomEvent("keyPressed");this.enabledEvent=new YAHOO.util.CustomEvent("enabled");this.disabledEvent=new YAHOO.util.CustomEvent("disabled");if(typeof A=="string"){A=document.getElementById(A);}if(typeof B=="function"){D.subscribe(B);}else{D.subscribe(B.fn,B.scope,B.correctScope);}function E(J,I){if(!F.shift){F.shift=false;}if(!F.alt){F.alt=false;}if(!F.ctrl){F.ctrl=false;}if(J.shiftKey==F.shift&&J.altKey==F.alt&&J.ctrlKey==F.ctrl){var G;if(F.keys instanceof Array){for(var H=0;H<F.keys.length;H++){G=F.keys[H];if(G==J.charCode){D.fire(J.charCode,J);break;}else{if(G==J.keyCode){D.fire(J.keyCode,J);break;}}}}else{G=F.keys;if(G==J.charCode){D.fire(J.charCode,J);}else{if(G==J.keyCode){D.fire(J.keyCode,J);}}}}}this.enable=function(){if(!this.enabled){YAHOO.util.Event.addListener(A,C,E);this.enabledEvent.fire(F);}this.enabled=true;};this.disable=function(){if(this.enabled){YAHOO.util.Event.removeListener(A,C,E);this.disabledEvent.fire(F);}this.enabled=false;};this.toString=function(){return"KeyListener ["+F.keys+"] "+A.tagName+(A.id?"["+A.id+"]":"");};};YAHOO.util.KeyListener.KEYDOWN="keydown";YAHOO.util.KeyListener.KEYUP="keyup";YAHOO.util.KeyListener.KEY={ALT:18,BACK_SPACE:8,CAPS_LOCK:20,CONTROL:17,DELETE:46,DOWN:40,END:35,ENTER:13,ESCAPE:27,HOME:36,LEFT:37,META:224,NUM_LOCK:144,PAGE_DOWN:34,PAGE_UP:33,PAUSE:19,PRINTSCREEN:44,RIGHT:39,SCROLL_LOCK:145,SHIFT:16,SPACE:32,TAB:9,UP:38};YAHOO.register("event",YAHOO.util.Event,{version:"2.6.0",build:"1321"});YAHOO.register("yahoo-dom-event", YAHOO, {version: "2.6.0", build: "1321"}); | ||
971 | 13 | /* | ||
972 | 14 | Copyright (c) 2008, Yahoo! Inc. All rights reserved. | ||
973 | 15 | Code licensed under the BSD License: | ||
974 | 16 | http://developer.yahoo.net/yui/license.txt | ||
975 | 17 | version: 2.6.0 | ||
976 | 18 | */ | ||
977 | 19 | (function(){var lang=YAHOO.lang,util=YAHOO.util,Ev=util.Event;util.DataSourceBase=function(oLiveData,oConfigs){if(oLiveData===null||oLiveData===undefined){return ;}this.liveData=oLiveData;this._oQueue={interval:null,conn:null,requests:[]};this.responseSchema={};if(oConfigs&&(oConfigs.constructor==Object)){for(var sConfig in oConfigs){if(sConfig){this[sConfig]=oConfigs[sConfig];}}}var maxCacheEntries=this.maxCacheEntries;if(!lang.isNumber(maxCacheEntries)||(maxCacheEntries<0)){maxCacheEntries=0;}this._aIntervals=[];this.createEvent("cacheRequestEvent");this.createEvent("cacheResponseEvent");this.createEvent("requestEvent");this.createEvent("responseEvent");this.createEvent("responseParseEvent");this.createEvent("responseCacheEvent");this.createEvent("dataErrorEvent");this.createEvent("cacheFlushEvent");var DS=util.DataSourceBase;this._sName="DataSource instance"+DS._nIndex;DS._nIndex++;};var DS=util.DataSourceBase;lang.augmentObject(DS,{TYPE_UNKNOWN:-1,TYPE_JSARRAY:0,TYPE_JSFUNCTION:1,TYPE_XHR:2,TYPE_JSON:3,TYPE_XML:4,TYPE_TEXT:5,TYPE_HTMLTABLE:6,TYPE_SCRIPTNODE:7,TYPE_LOCAL:8,ERROR_DATAINVALID:"Invalid data",ERROR_DATANULL:"Null data",_nIndex:0,_nTransactionId:0,issueCallback:function(callback,params,error,scope){if(lang.isFunction(callback)){callback.apply(scope,params);}else{if(lang.isObject(callback)){scope=callback.scope||scope||window;var callbackFunc=callback.success;if(error){callbackFunc=callback.failure;}if(callbackFunc){callbackFunc.apply(scope,params.concat([callback.argument]));}}}},parseString:function(oData){if(!lang.isValue(oData)){return null;}var string=oData+"";if(lang.isString(string)){return string;}else{return null;}},parseNumber:function(oData){var number=oData*1;if(lang.isNumber(number)){return number;}else{return null;}},convertNumber:function(oData){return DS.parseNumber(oData);},parseDate:function(oData){var date=null;if(!(oData instanceof Date)){date=new Date(oData);}else{return oData;}if(date instanceof Date){return date;}else{return null;}},convertDate:function(oData){return DS.parseDate(oData);}});DS.Parser={string:DS.parseString,number:DS.parseNumber,date:DS.parseDate};DS.prototype={_sName:null,_aCache:null,_oQueue:null,_aIntervals:null,maxCacheEntries:0,liveData:null,dataType:DS.TYPE_UNKNOWN,responseType:DS.TYPE_UNKNOWN,responseSchema:null,toString:function(){return this._sName;},getCachedResponse:function(oRequest,oCallback,oCaller){var aCache=this._aCache;if(this.maxCacheEntries>0){if(!aCache){this._aCache=[];}else{var nCacheLength=aCache.length;if(nCacheLength>0){var oResponse=null;this.fireEvent("cacheRequestEvent",{request:oRequest,callback:oCallback,caller:oCaller});for(var i=nCacheLength-1;i>=0;i--){var oCacheElem=aCache[i];if(this.isCacheHit(oRequest,oCacheElem.request)){oResponse=oCacheElem.response;this.fireEvent("cacheResponseEvent",{request:oRequest,response:oResponse,callback:oCallback,caller:oCaller});if(i<nCacheLength-1){aCache.splice(i,1);this.addToCache(oRequest,oResponse);}oResponse.cached=true;break;}}return oResponse;}}}else{if(aCache){this._aCache=null;}}return null;},isCacheHit:function(oRequest,oCachedRequest){return(oRequest===oCachedRequest);},addToCache:function(oRequest,oResponse){var aCache=this._aCache;if(!aCache){return ;}while(aCache.length>=this.maxCacheEntries){aCache.shift();}var oCacheElem={request:oRequest,response:oResponse};aCache[aCache.length]=oCacheElem;this.fireEvent("responseCacheEvent",{request:oRequest,response:oResponse});},flushCache:function(){if(this._aCache){this._aCache=[];this.fireEvent("cacheFlushEvent");}},setInterval:function(nMsec,oRequest,oCallback,oCaller){if(lang.isNumber(nMsec)&&(nMsec>=0)){var oSelf=this;var nId=setInterval(function(){oSelf.makeConnection(oRequest,oCallback,oCaller);},nMsec);this._aIntervals.push(nId);return nId;}else{}},clearInterval:function(nId){var tracker=this._aIntervals||[];for(var i=tracker.length-1;i>-1;i--){if(tracker[i]===nId){tracker.splice(i,1);clearInterval(nId);}}},clearAllIntervals:function(){var tracker=this._aIntervals||[];for(var i=tracker.length-1;i>-1;i--){clearInterval(tracker[i]);}tracker=[];},sendRequest:function(oRequest,oCallback,oCaller){var oCachedResponse=this.getCachedResponse(oRequest,oCallback,oCaller);if(oCachedResponse){DS.issueCallback(oCallback,[oRequest,oCachedResponse],false,oCaller);return null;}return this.makeConnection(oRequest,oCallback,oCaller);},makeConnection:function(oRequest,oCallback,oCaller){var tId=DS._nTransactionId++;this.fireEvent("requestEvent",{tId:tId,request:oRequest,callback:oCallback,caller:oCaller});var oRawResponse=this.liveData;this.handleResponse(oRequest,oRawResponse,oCallback,oCaller,tId);return tId;},handleResponse:function(oRequest,oRawResponse,oCallback,oCaller,tId){this.fireEvent("responseEvent",{tId:tId,request:oRequest,response:oRawResponse,callback:oCallback,caller:oCaller});var xhr=(this.dataType==DS.TYPE_XHR)?true:false;var oParsedResponse=null;var oFullResponse=oRawResponse;if(this.responseType===DS.TYPE_UNKNOWN){var ctype=(oRawResponse&&oRawResponse.getResponseHeader)?oRawResponse.getResponseHeader["Content-Type"]:null;if(ctype){if(ctype.indexOf("text/xml")>-1){this.responseType=DS.TYPE_XML;}else{if(ctype.indexOf("application/json")>-1){this.responseType=DS.TYPE_JSON;}else{if(ctype.indexOf("text/plain")>-1){this.responseType=DS.TYPE_TEXT;}}}}else{if(YAHOO.lang.isArray(oRawResponse)){this.responseType=DS.TYPE_JSARRAY;}else{if(oRawResponse&&oRawResponse.nodeType&&oRawResponse.nodeType==9){this.responseType=DS.TYPE_XML;}else{if(oRawResponse&&oRawResponse.nodeName&&(oRawResponse.nodeName.toLowerCase()=="table")){this.responseType=DS.TYPE_HTMLTABLE;}else{if(YAHOO.lang.isObject(oRawResponse)){this.responseType=DS.TYPE_JSON;}else{if(YAHOO.lang.isString(oRawResponse)){this.responseType=DS.TYPE_TEXT;}}}}}}}switch(this.responseType){case DS.TYPE_JSARRAY:if(xhr&&oRawResponse&&oRawResponse.responseText){oFullResponse=oRawResponse.responseText;}oFullResponse=this.doBeforeParseData(oRequest,oFullResponse,oCallback);oParsedResponse=this.parseArrayData(oRequest,oFullResponse); | ||
978 | 20 | break;case DS.TYPE_JSON:if(xhr&&oRawResponse&&oRawResponse.responseText){oFullResponse=oRawResponse.responseText;}try{if(lang.isString(oFullResponse)){if(lang.JSON){oFullResponse=lang.JSON.parse(oFullResponse);}else{if(window.JSON&&JSON.parse){oFullResponse=JSON.parse(oFullResponse);}else{if(oFullResponse.parseJSON){oFullResponse=oFullResponse.parseJSON();}else{while(oFullResponse.length>0&&(oFullResponse.charAt(0)!="{")&&(oFullResponse.charAt(0)!="[")){oFullResponse=oFullResponse.substring(1,oFullResponse.length);}if(oFullResponse.length>0){var objEnd=Math.max(oFullResponse.lastIndexOf("]"),oFullResponse.lastIndexOf("}"));oFullResponse=oFullResponse.substring(0,objEnd+1);oFullResponse=eval("("+oFullResponse+")");}}}}}}catch(e){}oFullResponse=this.doBeforeParseData(oRequest,oFullResponse,oCallback);oParsedResponse=this.parseJSONData(oRequest,oFullResponse);break;case DS.TYPE_HTMLTABLE:if(xhr&&oRawResponse.responseText){oFullResponse=oRawResponse.responseText;}oFullResponse=this.doBeforeParseData(oRequest,oFullResponse,oCallback);oParsedResponse=this.parseHTMLTableData(oRequest,oFullResponse);break;case DS.TYPE_XML:if(xhr&&oRawResponse.responseXML){oFullResponse=oRawResponse.responseXML;}oFullResponse=this.doBeforeParseData(oRequest,oFullResponse,oCallback);oParsedResponse=this.parseXMLData(oRequest,oFullResponse);break;case DS.TYPE_TEXT:if(xhr&&lang.isString(oRawResponse.responseText)){oFullResponse=oRawResponse.responseText;}oFullResponse=this.doBeforeParseData(oRequest,oFullResponse,oCallback);oParsedResponse=this.parseTextData(oRequest,oFullResponse);break;default:oFullResponse=this.doBeforeParseData(oRequest,oFullResponse,oCallback);oParsedResponse=this.parseData(oRequest,oFullResponse);break;}oParsedResponse=oParsedResponse||{};if(!oParsedResponse.results){oParsedResponse.results=[];}if(!oParsedResponse.meta){oParsedResponse.meta={};}if(oParsedResponse&&!oParsedResponse.error){oParsedResponse=this.doBeforeCallback(oRequest,oFullResponse,oParsedResponse,oCallback);this.fireEvent("responseParseEvent",{request:oRequest,response:oParsedResponse,callback:oCallback,caller:oCaller});this.addToCache(oRequest,oParsedResponse);}else{oParsedResponse.error=true;this.fireEvent("dataErrorEvent",{request:oRequest,response:oRawResponse,callback:oCallback,caller:oCaller,message:DS.ERROR_DATANULL});}oParsedResponse.tId=tId;DS.issueCallback(oCallback,[oRequest,oParsedResponse],oParsedResponse.error,oCaller);},doBeforeParseData:function(oRequest,oFullResponse,oCallback){return oFullResponse;},doBeforeCallback:function(oRequest,oFullResponse,oParsedResponse,oCallback){return oParsedResponse;},parseData:function(oRequest,oFullResponse){if(lang.isValue(oFullResponse)){var oParsedResponse={results:oFullResponse,meta:{}};return oParsedResponse;}return null;},parseArrayData:function(oRequest,oFullResponse){if(lang.isArray(oFullResponse)){var results=[],i,j,rec,field,data;if(lang.isArray(this.responseSchema.fields)){var fields=this.responseSchema.fields;for(i=fields.length-1;i>=0;--i){if(typeof fields[i]!=="object"){fields[i]={key:fields[i]};}}var parsers={},p;for(i=fields.length-1;i>=0;--i){p=(typeof fields[i].parser==="function"?fields[i].parser:DS.Parser[fields[i].parser+""])||fields[i].converter;if(p){parsers[fields[i].key]=p;}}var arrType=lang.isArray(oFullResponse[0]);for(i=oFullResponse.length-1;i>-1;i--){var oResult={};rec=oFullResponse[i];if(typeof rec==="object"){for(j=fields.length-1;j>-1;j--){field=fields[j];data=arrType?rec[j]:rec[field.key];if(parsers[field.key]){data=parsers[field.key].call(this,data);}if(data===undefined){data=null;}oResult[field.key]=data;}}else{if(lang.isString(rec)){for(j=fields.length-1;j>-1;j--){field=fields[j];data=rec;if(parsers[field.key]){data=parsers[field.key].call(this,data);}if(data===undefined){data=null;}oResult[field.key]=data;}}}results[i]=oResult;}}else{results=oFullResponse;}var oParsedResponse={results:results};return oParsedResponse;}return null;},parseTextData:function(oRequest,oFullResponse){if(lang.isString(oFullResponse)){if(lang.isString(this.responseSchema.recordDelim)&&lang.isString(this.responseSchema.fieldDelim)){var oParsedResponse={results:[]};var recDelim=this.responseSchema.recordDelim;var fieldDelim=this.responseSchema.fieldDelim;if(oFullResponse.length>0){var newLength=oFullResponse.length-recDelim.length;if(oFullResponse.substr(newLength)==recDelim){oFullResponse=oFullResponse.substr(0,newLength);}if(oFullResponse.length>0){var recordsarray=oFullResponse.split(recDelim);for(var i=0,len=recordsarray.length,recIdx=0;i<len;++i){var bError=false,sRecord=recordsarray[i];if(lang.isString(sRecord)&&(sRecord.length>0)){var fielddataarray=recordsarray[i].split(fieldDelim);var oResult={};if(lang.isArray(this.responseSchema.fields)){var fields=this.responseSchema.fields;for(var j=fields.length-1;j>-1;j--){try{var data=fielddataarray[j];if(lang.isString(data)){if(data.charAt(0)=='"'){data=data.substr(1);}if(data.charAt(data.length-1)=='"'){data=data.substr(0,data.length-1);}var field=fields[j];var key=(lang.isValue(field.key))?field.key:field;if(!field.parser&&field.converter){field.parser=field.converter;}var parser=(typeof field.parser==="function")?field.parser:DS.Parser[field.parser+""];if(parser){data=parser.call(this,data);}if(data===undefined){data=null;}oResult[key]=data;}else{bError=true;}}catch(e){bError=true;}}}else{oResult=fielddataarray;}if(!bError){oParsedResponse.results[recIdx++]=oResult;}}}}}return oParsedResponse;}}return null;},parseXMLResult:function(result){var oResult={},schema=this.responseSchema;try{for(var m=schema.fields.length-1;m>=0;m--){var field=schema.fields[m];var key=(lang.isValue(field.key))?field.key:field;var data=null;var xmlAttr=result.attributes.getNamedItem(key);if(xmlAttr){data=xmlAttr.value;}else{var xmlNode=result.getElementsByTagName(key);if(xmlNode&&xmlNode.item(0)&&xmlNode.item(0)){data=xmlNode.item(0).firstChild.nodeValue;var item=xmlNode.item(0);data=(item.text)?item.text:(item.textContent)?item.textContent:null; | ||
979 | 21 | if(!data){var datapieces=[];for(var j=0,len=item.childNodes.length;j<len;j++){if(item.childNodes[j].nodeValue){datapieces[datapieces.length]=item.childNodes[j].nodeValue;}}if(datapieces.length>0){data=datapieces.join("");}}}}if(data===null){data="";}if(!field.parser&&field.converter){field.parser=field.converter;}var parser=(typeof field.parser==="function")?field.parser:DS.Parser[field.parser+""];if(parser){data=parser.call(this,data);}if(data===undefined){data=null;}oResult[key]=data;}}catch(e){}return oResult;},parseXMLData:function(oRequest,oFullResponse){var bError=false,schema=this.responseSchema,oParsedResponse={meta:{}},xmlList=null,metaNode=schema.metaNode,metaLocators=schema.metaFields||{},i,k,loc,v;try{xmlList=(schema.resultNode)?oFullResponse.getElementsByTagName(schema.resultNode):null;metaNode=metaNode?oFullResponse.getElementsByTagName(metaNode)[0]:oFullResponse;if(metaNode){for(k in metaLocators){if(lang.hasOwnProperty(metaLocators,k)){loc=metaLocators[k];v=metaNode.getElementsByTagName(loc)[0];if(v){v=v.firstChild.nodeValue;}else{v=metaNode.attributes.getNamedItem(loc);if(v){v=v.value;}}if(lang.isValue(v)){oParsedResponse.meta[k]=v;}}}}}catch(e){}if(!xmlList||!lang.isArray(schema.fields)){bError=true;}else{oParsedResponse.results=[];for(i=xmlList.length-1;i>=0;--i){var oResult=this.parseXMLResult(xmlList.item(i));oParsedResponse.results[i]=oResult;}}if(bError){oParsedResponse.error=true;}else{}return oParsedResponse;},parseJSONData:function(oRequest,oFullResponse){var oParsedResponse={results:[],meta:{}};if(lang.isObject(oFullResponse)&&this.responseSchema.resultsList){var schema=this.responseSchema,fields=schema.fields,resultsList=oFullResponse,results=[],metaFields=schema.metaFields||{},fieldParsers=[],fieldPaths=[],simpleFields=[],bError=false,i,len,j,v,key,parser,path;var buildPath=function(needle){var path=null,keys=[],i=0;if(needle){needle=needle.replace(/\[(['"])(.*?)\1\]/g,function(x,$1,$2){keys[i]=$2;return".@"+(i++);}).replace(/\[(\d+)\]/g,function(x,$1){keys[i]=parseInt($1,10)|0;return".@"+(i++);}).replace(/^\./,"");if(!/[^\w\.\$@]/.test(needle)){path=needle.split(".");for(i=path.length-1;i>=0;--i){if(path[i].charAt(0)==="@"){path[i]=keys[parseInt(path[i].substr(1),10)];}}}else{}}return path;};var walkPath=function(path,origin){var v=origin,i=0,len=path.length;for(;i<len&&v;++i){v=v[path[i]];}return v;};path=buildPath(schema.resultsList);if(path){resultsList=walkPath(path,oFullResponse);if(resultsList===undefined){bError=true;}}else{bError=true;}if(!resultsList){resultsList=[];}if(!lang.isArray(resultsList)){resultsList=[resultsList];}if(!bError){if(schema.fields){var field;for(i=0,len=fields.length;i<len;i++){field=fields[i];key=field.key||field;parser=((typeof field.parser==="function")?field.parser:DS.Parser[field.parser+""])||field.converter;path=buildPath(key);if(parser){fieldParsers[fieldParsers.length]={key:key,parser:parser};}if(path){if(path.length>1){fieldPaths[fieldPaths.length]={key:key,path:path};}else{simpleFields[simpleFields.length]={key:key,path:path[0]};}}else{}}for(i=resultsList.length-1;i>=0;--i){var r=resultsList[i],rec={};for(j=simpleFields.length-1;j>=0;--j){rec[simpleFields[j].key]=(r[simpleFields[j].path]!==undefined)?r[simpleFields[j].path]:r[j];}for(j=fieldPaths.length-1;j>=0;--j){rec[fieldPaths[j].key]=walkPath(fieldPaths[j].path,r);}for(j=fieldParsers.length-1;j>=0;--j){var p=fieldParsers[j].key;rec[p]=fieldParsers[j].parser(rec[p]);if(rec[p]===undefined){rec[p]=null;}}results[i]=rec;}}else{results=resultsList;}for(key in metaFields){if(lang.hasOwnProperty(metaFields,key)){path=buildPath(metaFields[key]);if(path){v=walkPath(path,oFullResponse);oParsedResponse.meta[key]=v;}}}}else{oParsedResponse.error=true;}oParsedResponse.results=results;}else{oParsedResponse.error=true;}return oParsedResponse;},parseHTMLTableData:function(oRequest,oFullResponse){var bError=false;var elTable=oFullResponse;var fields=this.responseSchema.fields;var oParsedResponse={results:[]};for(var i=0;i<elTable.tBodies.length;i++){var elTbody=elTable.tBodies[i];for(var j=elTbody.rows.length-1;j>-1;j--){var elRow=elTbody.rows[j];var oResult={};for(var k=fields.length-1;k>-1;k--){var field=fields[k];var key=(lang.isValue(field.key))?field.key:field;var data=elRow.cells[k].innerHTML;if(!field.parser&&field.converter){field.parser=field.converter;}var parser=(typeof field.parser==="function")?field.parser:DS.Parser[field.parser+""];if(parser){data=parser.call(this,data);}if(data===undefined){data=null;}oResult[key]=data;}oParsedResponse.results[j]=oResult;}}if(bError){oParsedResponse.error=true;}else{}return oParsedResponse;}};lang.augmentProto(DS,util.EventProvider);util.LocalDataSource=function(oLiveData,oConfigs){this.dataType=DS.TYPE_LOCAL;if(oLiveData){if(YAHOO.lang.isArray(oLiveData)){this.responseType=DS.TYPE_JSARRAY;}else{if(oLiveData.nodeType&&oLiveData.nodeType==9){this.responseType=DS.TYPE_XML;}else{if(oLiveData.nodeName&&(oLiveData.nodeName.toLowerCase()=="table")){this.responseType=DS.TYPE_HTMLTABLE;oLiveData=oLiveData.cloneNode(true);}else{if(YAHOO.lang.isString(oLiveData)){this.responseType=DS.TYPE_TEXT;}else{if(YAHOO.lang.isObject(oLiveData)){this.responseType=DS.TYPE_JSON;}}}}}}else{oLiveData=[];this.responseType=DS.TYPE_JSARRAY;}this.constructor.superclass.constructor.call(this,oLiveData,oConfigs);};lang.extend(util.LocalDataSource,DS);lang.augmentObject(util.LocalDataSource,DS);util.FunctionDataSource=function(oLiveData,oConfigs){this.dataType=DS.TYPE_JSFUNCTION;oLiveData=oLiveData||function(){};this.constructor.superclass.constructor.call(this,oLiveData,oConfigs);};lang.extend(util.FunctionDataSource,DS,{makeConnection:function(oRequest,oCallback,oCaller){var tId=DS._nTransactionId++;this.fireEvent("requestEvent",{tId:tId,request:oRequest,callback:oCallback,caller:oCaller});var oRawResponse=this.liveData(oRequest);if(this.responseType===DS.TYPE_UNKNOWN){if(YAHOO.lang.isArray(oRawResponse)){this.responseType=DS.TYPE_JSARRAY;}else{if(oRawResponse&&oRawResponse.nodeType&&oRawResponse.nodeType==9){this.responseType=DS.TYPE_XML; | ||
980 | 22 | }else{if(oRawResponse&&oRawResponse.nodeName&&(oRawResponse.nodeName.toLowerCase()=="table")){this.responseType=DS.TYPE_HTMLTABLE;}else{if(YAHOO.lang.isObject(oRawResponse)){this.responseType=DS.TYPE_JSON;}else{if(YAHOO.lang.isString(oRawResponse)){this.responseType=DS.TYPE_TEXT;}}}}}}this.handleResponse(oRequest,oRawResponse,oCallback,oCaller,tId);return tId;}});lang.augmentObject(util.FunctionDataSource,DS);util.ScriptNodeDataSource=function(oLiveData,oConfigs){this.dataType=DS.TYPE_SCRIPTNODE;oLiveData=oLiveData||"";this.constructor.superclass.constructor.call(this,oLiveData,oConfigs);};lang.extend(util.ScriptNodeDataSource,DS,{getUtility:util.Get,asyncMode:"allowAll",scriptCallbackParam:"callback",generateRequestCallback:function(id){return"&"+this.scriptCallbackParam+"=YAHOO.util.ScriptNodeDataSource.callbacks["+id+"]";},makeConnection:function(oRequest,oCallback,oCaller){var tId=DS._nTransactionId++;this.fireEvent("requestEvent",{tId:tId,request:oRequest,callback:oCallback,caller:oCaller});if(util.ScriptNodeDataSource._nPending===0){util.ScriptNodeDataSource.callbacks=[];util.ScriptNodeDataSource._nId=0;}var id=util.ScriptNodeDataSource._nId;util.ScriptNodeDataSource._nId++;var oSelf=this;util.ScriptNodeDataSource.callbacks[id]=function(oRawResponse){if((oSelf.asyncMode!=="ignoreStaleResponses")||(id===util.ScriptNodeDataSource.callbacks.length-1)){if(oSelf.responseType===DS.TYPE_UNKNOWN){if(YAHOO.lang.isArray(oRawResponse)){oSelf.responseType=DS.TYPE_JSARRAY;}else{if(oRawResponse.nodeType&&oRawResponse.nodeType==9){oSelf.responseType=DS.TYPE_XML;}else{if(oRawResponse.nodeName&&(oRawResponse.nodeName.toLowerCase()=="table")){oSelf.responseType=DS.TYPE_HTMLTABLE;}else{if(YAHOO.lang.isObject(oRawResponse)){oSelf.responseType=DS.TYPE_JSON;}else{if(YAHOO.lang.isString(oRawResponse)){oSelf.responseType=DS.TYPE_TEXT;}}}}}}oSelf.handleResponse(oRequest,oRawResponse,oCallback,oCaller,tId);}else{}delete util.ScriptNodeDataSource.callbacks[id];};util.ScriptNodeDataSource._nPending++;var sUri=this.liveData+oRequest+this.generateRequestCallback(id);this.getUtility.script(sUri,{autopurge:true,onsuccess:util.ScriptNodeDataSource._bumpPendingDown,onfail:util.ScriptNodeDataSource._bumpPendingDown});return tId;}});lang.augmentObject(util.ScriptNodeDataSource,DS);lang.augmentObject(util.ScriptNodeDataSource,{_nId:0,_nPending:0,callbacks:[]});util.XHRDataSource=function(oLiveData,oConfigs){this.dataType=DS.TYPE_XHR;this.connMgr=this.connMgr||util.Connect;oLiveData=oLiveData||"";this.constructor.superclass.constructor.call(this,oLiveData,oConfigs);};lang.extend(util.XHRDataSource,DS,{connMgr:null,connXhrMode:"allowAll",connMethodPost:false,connTimeout:0,makeConnection:function(oRequest,oCallback,oCaller){var oRawResponse=null;var tId=DS._nTransactionId++;this.fireEvent("requestEvent",{tId:tId,request:oRequest,callback:oCallback,caller:oCaller});var oSelf=this;var oConnMgr=this.connMgr;var oQueue=this._oQueue;var _xhrSuccess=function(oResponse){if(oResponse&&(this.asyncMode=="ignoreStaleResponses")&&(oResponse.tId!=oQueue.conn.tId)){return null;}else{if(!oResponse){this.fireEvent("dataErrorEvent",{request:oRequest,callback:oCallback,caller:oCaller,message:DS.ERROR_DATANULL});DS.issueCallback(oCallback,[oRequest,{error:true}],true,oCaller);return null;}else{if(this.responseType===DS.TYPE_UNKNOWN){var ctype=(oResponse.getResponseHeader)?oResponse.getResponseHeader["Content-Type"]:null;if(ctype){if(ctype.indexOf("text/xml")>-1){this.responseType=DS.TYPE_XML;}else{if(ctype.indexOf("application/json")>-1){this.responseType=DS.TYPE_JSON;}else{if(ctype.indexOf("text/plain")>-1){this.responseType=DS.TYPE_TEXT;}}}}}this.handleResponse(oRequest,oResponse,oCallback,oCaller,tId);}}};var _xhrFailure=function(oResponse){this.fireEvent("dataErrorEvent",{request:oRequest,callback:oCallback,caller:oCaller,message:DS.ERROR_DATAINVALID});if(lang.isString(this.liveData)&&lang.isString(oRequest)&&(this.liveData.lastIndexOf("?")!==this.liveData.length-1)&&(oRequest.indexOf("?")!==0)){}oResponse=oResponse||{};oResponse.error=true;DS.issueCallback(oCallback,[oRequest,oResponse],true,oCaller);return null;};var _xhrCallback={success:_xhrSuccess,failure:_xhrFailure,scope:this};if(lang.isNumber(this.connTimeout)){_xhrCallback.timeout=this.connTimeout;}if(this.connXhrMode=="cancelStaleRequests"){if(oQueue.conn){if(oConnMgr.abort){oConnMgr.abort(oQueue.conn);oQueue.conn=null;}else{}}}if(oConnMgr&&oConnMgr.asyncRequest){var sLiveData=this.liveData;var isPost=this.connMethodPost;var sMethod=(isPost)?"POST":"GET";var sUri=(isPost||!lang.isValue(oRequest))?sLiveData:sLiveData+oRequest;var sRequest=(isPost)?oRequest:null;if(this.connXhrMode!="queueRequests"){oQueue.conn=oConnMgr.asyncRequest(sMethod,sUri,_xhrCallback,sRequest);}else{if(oQueue.conn){var allRequests=oQueue.requests;allRequests.push({request:oRequest,callback:_xhrCallback});if(!oQueue.interval){oQueue.interval=setInterval(function(){if(oConnMgr.isCallInProgress(oQueue.conn)){return ;}else{if(allRequests.length>0){sUri=(isPost||!lang.isValue(allRequests[0].request))?sLiveData:sLiveData+allRequests[0].request;sRequest=(isPost)?allRequests[0].request:null;oQueue.conn=oConnMgr.asyncRequest(sMethod,sUri,allRequests[0].callback,sRequest);allRequests.shift();}else{clearInterval(oQueue.interval);oQueue.interval=null;}}},50);}}else{oQueue.conn=oConnMgr.asyncRequest(sMethod,sUri,_xhrCallback,sRequest);}}}else{DS.issueCallback(oCallback,[oRequest,{error:true}],true,oCaller);}return tId;}});lang.augmentObject(util.XHRDataSource,DS);util.DataSource=function(oLiveData,oConfigs){oConfigs=oConfigs||{};var dataType=oConfigs.dataType;if(dataType){if(dataType==DS.TYPE_LOCAL){lang.augmentObject(util.DataSource,util.LocalDataSource);return new util.LocalDataSource(oLiveData,oConfigs);}else{if(dataType==DS.TYPE_XHR){lang.augmentObject(util.DataSource,util.XHRDataSource);return new util.XHRDataSource(oLiveData,oConfigs);}else{if(dataType==DS.TYPE_SCRIPTNODE){lang.augmentObject(util.DataSource,util.ScriptNodeDataSource); | ||
981 | 23 | return new util.ScriptNodeDataSource(oLiveData,oConfigs);}else{if(dataType==DS.TYPE_JSFUNCTION){lang.augmentObject(util.DataSource,util.FunctionDataSource);return new util.FunctionDataSource(oLiveData,oConfigs);}}}}}if(YAHOO.lang.isString(oLiveData)){lang.augmentObject(util.DataSource,util.XHRDataSource);return new util.XHRDataSource(oLiveData,oConfigs);}else{if(YAHOO.lang.isFunction(oLiveData)){lang.augmentObject(util.DataSource,util.FunctionDataSource);return new util.FunctionDataSource(oLiveData,oConfigs);}else{lang.augmentObject(util.DataSource,util.LocalDataSource);return new util.LocalDataSource(oLiveData,oConfigs);}}};lang.augmentObject(util.DataSource,DS);})();YAHOO.util.Number={format:function(B,F){F=F||{};if(!YAHOO.lang.isNumber(B)){B*=1;}if(YAHOO.lang.isNumber(B)){var D=(B<0);var J=B+"";var G=(F.decimalSeparator)?F.decimalSeparator:".";var H;if(YAHOO.lang.isNumber(F.decimalPlaces)){var I=F.decimalPlaces;var C=Math.pow(10,I);J=Math.round(B*C)/C+"";H=J.lastIndexOf(".");if(I>0){if(H<0){J+=G;H=J.length-1;}else{if(G!=="."){J=J.replace(".",G);}}while((J.length-1-H)<I){J+="0";}}}if(F.thousandsSeparator){var L=F.thousandsSeparator;H=J.lastIndexOf(G);H=(H>-1)?H:J.length;var K=J.substring(H);var A=-1;for(var E=H;E>0;E--){A++;if((A%3===0)&&(E!==H)&&(!D||(E>1))){K=L+K;}K=J.charAt(E-1)+K;}J=K;}J=(F.prefix)?F.prefix+J:J;J=(F.suffix)?J+F.suffix:J;return J;}else{return B;}}};(function(){var A=function(C,E,D){if(typeof D==="undefined"){D=10;}for(;parseInt(C,10)<D&&D>1;D/=10){C=E.toString()+C;}return C.toString();};var B={formats:{a:function(D,C){return C.a[D.getDay()];},A:function(D,C){return C.A[D.getDay()];},b:function(D,C){return C.b[D.getMonth()];},B:function(D,C){return C.B[D.getMonth()];},C:function(C){return A(parseInt(C.getFullYear()/100,10),0);},d:["getDate","0"],e:["getDate"," "],g:function(C){return A(parseInt(B.formats.G(C)%100,10),0);},G:function(E){var F=E.getFullYear();var D=parseInt(B.formats.V(E),10);var C=parseInt(B.formats.W(E),10);if(C>D){F++;}else{if(C===0&&D>=52){F--;}}return F;},H:["getHours","0"],I:function(D){var C=D.getHours()%12;return A(C===0?12:C,0);},j:function(G){var F=new Date(""+G.getFullYear()+"/1/1 GMT");var D=new Date(""+G.getFullYear()+"/"+(G.getMonth()+1)+"/"+G.getDate()+" GMT");var C=D-F;var E=parseInt(C/60000/60/24,10)+1;return A(E,0,100);},k:["getHours"," "],l:function(D){var C=D.getHours()%12;return A(C===0?12:C," ");},m:function(C){return A(C.getMonth()+1,0);},M:["getMinutes","0"],p:function(D,C){return C.p[D.getHours()>=12?1:0];},P:function(D,C){return C.P[D.getHours()>=12?1:0];},s:function(D,C){return parseInt(D.getTime()/1000,10);},S:["getSeconds","0"],u:function(C){var D=C.getDay();return D===0?7:D;},U:function(F){var C=parseInt(B.formats.j(F),10);var E=6-F.getDay();var D=parseInt((C+E)/7,10);return A(D,0);},V:function(F){var E=parseInt(B.formats.W(F),10);var C=(new Date(""+F.getFullYear()+"/1/1")).getDay();var D=E+(C>4||C<=1?0:1);if(D===53&&(new Date(""+F.getFullYear()+"/12/31")).getDay()<4){D=1;}else{if(D===0){D=B.formats.V(new Date(""+(F.getFullYear()-1)+"/12/31"));}}return A(D,0);},w:"getDay",W:function(F){var C=parseInt(B.formats.j(F),10);var E=7-B.formats.u(F);var D=parseInt((C+E)/7,10);return A(D,0,10);},y:function(C){return A(C.getFullYear()%100,0);},Y:"getFullYear",z:function(E){var D=E.getTimezoneOffset();var C=A(parseInt(Math.abs(D/60),10),0);var F=A(Math.abs(D%60),0);return(D>0?"-":"+")+C+F;},Z:function(C){var D=C.toString().replace(/^.*:\d\d( GMT[+-]\d+)? \(?([A-Za-z ]+)\)?\d*$/,"$2").replace(/[a-z ]/g,"");if(D.length>4){D=B.formats.z(C);}return D;},"%":function(C){return"%";}},aggregates:{c:"locale",D:"%m/%d/%y",F:"%Y-%m-%d",h:"%b",n:"\n",r:"locale",R:"%H:%M",t:"\t",T:"%H:%M:%S",x:"locale",X:"locale"},format:function(G,F,D){F=F||{};if(!(G instanceof Date)){return YAHOO.lang.isValue(G)?G:"";}var H=F.format||"%m/%d/%Y";if(H==="YYYY/MM/DD"){H="%Y/%m/%d";}else{if(H==="DD/MM/YYYY"){H="%d/%m/%Y";}else{if(H==="MM/DD/YYYY"){H="%m/%d/%Y";}}}D=D||"en";if(!(D in YAHOO.util.DateLocale)){if(D.replace(/-[a-zA-Z]+$/,"") in YAHOO.util.DateLocale){D=D.replace(/-[a-zA-Z]+$/,"");}else{D="en";}}var J=YAHOO.util.DateLocale[D];var C=function(L,K){var M=B.aggregates[K];return(M==="locale"?J[K]:M);};var E=function(L,K){var M=B.formats[K];if(typeof M==="string"){return G[M]();}else{if(typeof M==="function"){return M.call(G,G,J);}else{if(typeof M==="object"&&typeof M[0]==="string"){return A(G[M[0]](),M[1]);}else{return K;}}}};while(H.match(/%[cDFhnrRtTxX]/)){H=H.replace(/%([cDFhnrRtTxX])/g,C);}var I=H.replace(/%([aAbBCdegGHIjklmMpPsSuUVwWyYzZ%])/g,E);C=E=undefined;return I;}};YAHOO.namespace("YAHOO.util");YAHOO.util.Date=B;YAHOO.util.DateLocale={a:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],A:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],b:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],B:["January","February","March","April","May","June","July","August","September","October","November","December"],c:"%a %d %b %Y %T %Z",p:["AM","PM"],P:["am","pm"],r:"%I:%M:%S %p",x:"%d/%m/%y",X:"%T"};YAHOO.util.DateLocale["en"]=YAHOO.lang.merge(YAHOO.util.DateLocale,{});YAHOO.util.DateLocale["en-US"]=YAHOO.lang.merge(YAHOO.util.DateLocale["en"],{c:"%a %d %b %Y %I:%M:%S %p %Z",x:"%m/%d/%Y",X:"%I:%M:%S %p"});YAHOO.util.DateLocale["en-GB"]=YAHOO.lang.merge(YAHOO.util.DateLocale["en"],{r:"%l:%M:%S %P %Z"});YAHOO.util.DateLocale["en-AU"]=YAHOO.lang.merge(YAHOO.util.DateLocale["en"]);})();YAHOO.register("datasource",YAHOO.util.DataSource,{version:"2.6.0",build:"1321"});/* | ||
982 | 24 | Copyright (c) 2008, Yahoo! Inc. All rights reserved. | ||
983 | 25 | Code licensed under the BSD License: | ||
984 | 26 | http://developer.yahoo.net/yui/license.txt | ||
985 | 27 | version: 2.6.0 | ||
986 | 28 | */ | ||
987 | 29 | YAHOO.widget.DS_JSArray=YAHOO.util.LocalDataSource;YAHOO.widget.DS_JSFunction=YAHOO.util.FunctionDataSource;YAHOO.widget.DS_XHR=function(B,A,D){var C=new YAHOO.util.XHRDataSource(B,D);C._aDeprecatedSchema=A;return C;};YAHOO.widget.DS_ScriptNode=function(B,A,D){var C=new YAHOO.util.ScriptNodeDataSource(B,D);C._aDeprecatedSchema=A;return C;};YAHOO.widget.DS_XHR.TYPE_JSON=YAHOO.util.DataSourceBase.TYPE_JSON;YAHOO.widget.DS_XHR.TYPE_XML=YAHOO.util.DataSourceBase.TYPE_XML;YAHOO.widget.DS_XHR.TYPE_FLAT=YAHOO.util.DataSourceBase.TYPE_TEXT;YAHOO.widget.AutoComplete=function(G,B,J,C){if(G&&B&&J){if(J instanceof YAHOO.util.DataSourceBase){this.dataSource=J;}else{return ;}this.key=0;var D=J.responseSchema;if(J._aDeprecatedSchema){var K=J._aDeprecatedSchema;if(YAHOO.lang.isArray(K)){if((J.responseType===YAHOO.util.DataSourceBase.TYPE_JSON)||(J.responseType===YAHOO.util.DataSourceBase.TYPE_UNKNOWN)){D.resultsList=K[0];this.key=K[1];D.fields=(K.length<3)?null:K.slice(1);}else{if(J.responseType===YAHOO.util.DataSourceBase.TYPE_XML){D.resultNode=K[0];this.key=K[1];D.fields=K.slice(1);}else{if(J.responseType===YAHOO.util.DataSourceBase.TYPE_TEXT){D.recordDelim=K[0];D.fieldDelim=K[1];}}}J.responseSchema=D;}}if(YAHOO.util.Dom.inDocument(G)){if(YAHOO.lang.isString(G)){this._sName="instance"+YAHOO.widget.AutoComplete._nIndex+" "+G;this._elTextbox=document.getElementById(G);}else{this._sName=(G.id)?"instance"+YAHOO.widget.AutoComplete._nIndex+" "+G.id:"instance"+YAHOO.widget.AutoComplete._nIndex;this._elTextbox=G;}YAHOO.util.Dom.addClass(this._elTextbox,"yui-ac-input");}else{return ;}if(YAHOO.util.Dom.inDocument(B)){if(YAHOO.lang.isString(B)){this._elContainer=document.getElementById(B);}else{this._elContainer=B;}if(this._elContainer.style.display=="none"){}var E=this._elContainer.parentNode;var A=E.tagName.toLowerCase();if(A=="div"){YAHOO.util.Dom.addClass(E,"yui-ac");}else{}}else{return ;}if(this.dataSource.dataType===YAHOO.util.DataSourceBase.TYPE_LOCAL){this.applyLocalFilter=true;}if(C&&(C.constructor==Object)){for(var I in C){if(I){this[I]=C[I];}}}this._initContainerEl();this._initProps();this._initListEl();this._initContainerHelperEls();var H=this;var F=this._elTextbox;YAHOO.util.Event.addListener(F,"keyup",H._onTextboxKeyUp,H);YAHOO.util.Event.addListener(F,"keydown",H._onTextboxKeyDown,H);YAHOO.util.Event.addListener(F,"focus",H._onTextboxFocus,H);YAHOO.util.Event.addListener(F,"blur",H._onTextboxBlur,H);YAHOO.util.Event.addListener(B,"mouseover",H._onContainerMouseover,H);YAHOO.util.Event.addListener(B,"mouseout",H._onContainerMouseout,H);YAHOO.util.Event.addListener(B,"click",H._onContainerClick,H);YAHOO.util.Event.addListener(B,"scroll",H._onContainerScroll,H);YAHOO.util.Event.addListener(B,"resize",H._onContainerResize,H);YAHOO.util.Event.addListener(F,"keypress",H._onTextboxKeyPress,H);YAHOO.util.Event.addListener(window,"unload",H._onWindowUnload,H);this.textboxFocusEvent=new YAHOO.util.CustomEvent("textboxFocus",this);this.textboxKeyEvent=new YAHOO.util.CustomEvent("textboxKey",this);this.dataRequestEvent=new YAHOO.util.CustomEvent("dataRequest",this);this.dataReturnEvent=new YAHOO.util.CustomEvent("dataReturn",this);this.dataErrorEvent=new YAHOO.util.CustomEvent("dataError",this);this.containerPopulateEvent=new YAHOO.util.CustomEvent("containerPopulate",this);this.containerExpandEvent=new YAHOO.util.CustomEvent("containerExpand",this);this.typeAheadEvent=new YAHOO.util.CustomEvent("typeAhead",this);this.itemMouseOverEvent=new YAHOO.util.CustomEvent("itemMouseOver",this);this.itemMouseOutEvent=new YAHOO.util.CustomEvent("itemMouseOut",this);this.itemArrowToEvent=new YAHOO.util.CustomEvent("itemArrowTo",this);this.itemArrowFromEvent=new YAHOO.util.CustomEvent("itemArrowFrom",this);this.itemSelectEvent=new YAHOO.util.CustomEvent("itemSelect",this);this.unmatchedItemSelectEvent=new YAHOO.util.CustomEvent("unmatchedItemSelect",this);this.selectionEnforceEvent=new YAHOO.util.CustomEvent("selectionEnforce",this);this.containerCollapseEvent=new YAHOO.util.CustomEvent("containerCollapse",this);this.textboxBlurEvent=new YAHOO.util.CustomEvent("textboxBlur",this);this.textboxChangeEvent=new YAHOO.util.CustomEvent("textboxChange",this);F.setAttribute("autocomplete","off");YAHOO.widget.AutoComplete._nIndex++;}else{}};YAHOO.widget.AutoComplete.prototype.dataSource=null;YAHOO.widget.AutoComplete.prototype.applyLocalFilter=null;YAHOO.widget.AutoComplete.prototype.queryMatchCase=false;YAHOO.widget.AutoComplete.prototype.queryMatchContains=false;YAHOO.widget.AutoComplete.prototype.queryMatchSubset=false;YAHOO.widget.AutoComplete.prototype.minQueryLength=1;YAHOO.widget.AutoComplete.prototype.maxResultsDisplayed=10;YAHOO.widget.AutoComplete.prototype.queryDelay=0.2;YAHOO.widget.AutoComplete.prototype.typeAheadDelay=0.5;YAHOO.widget.AutoComplete.prototype.queryInterval=500;YAHOO.widget.AutoComplete.prototype.highlightClassName="yui-ac-highlight";YAHOO.widget.AutoComplete.prototype.prehighlightClassName=null;YAHOO.widget.AutoComplete.prototype.delimChar=null;YAHOO.widget.AutoComplete.prototype.autoHighlight=true;YAHOO.widget.AutoComplete.prototype.typeAhead=false;YAHOO.widget.AutoComplete.prototype.animHoriz=false;YAHOO.widget.AutoComplete.prototype.animVert=true;YAHOO.widget.AutoComplete.prototype.animSpeed=0.3;YAHOO.widget.AutoComplete.prototype.forceSelection=false;YAHOO.widget.AutoComplete.prototype.allowBrowserAutocomplete=true;YAHOO.widget.AutoComplete.prototype.alwaysShowContainer=false;YAHOO.widget.AutoComplete.prototype.useIFrame=false;YAHOO.widget.AutoComplete.prototype.useShadow=false;YAHOO.widget.AutoComplete.prototype.suppressInputUpdate=false;YAHOO.widget.AutoComplete.prototype.resultTypeList=true;YAHOO.widget.AutoComplete.prototype.queryQuestionMark=true;YAHOO.widget.AutoComplete.prototype.toString=function(){return"AutoComplete "+this._sName;};YAHOO.widget.AutoComplete.prototype.getInputEl=function(){return this._elTextbox;};YAHOO.widget.AutoComplete.prototype.getContainerEl=function(){return this._elContainer; | ||
988 | 30 | };YAHOO.widget.AutoComplete.prototype.isFocused=function(){return(this._bFocused===null)?false:this._bFocused;};YAHOO.widget.AutoComplete.prototype.isContainerOpen=function(){return this._bContainerOpen;};YAHOO.widget.AutoComplete.prototype.getListEl=function(){return this._elList;};YAHOO.widget.AutoComplete.prototype.getListItemMatch=function(A){if(A._sResultMatch){return A._sResultMatch;}else{return null;}};YAHOO.widget.AutoComplete.prototype.getListItemData=function(A){if(A._oResultData){return A._oResultData;}else{return null;}};YAHOO.widget.AutoComplete.prototype.getListItemIndex=function(A){if(YAHOO.lang.isNumber(A._nItemIndex)){return A._nItemIndex;}else{return null;}};YAHOO.widget.AutoComplete.prototype.setHeader=function(B){if(this._elHeader){var A=this._elHeader;if(B){A.innerHTML=B;A.style.display="block";}else{A.innerHTML="";A.style.display="none";}}};YAHOO.widget.AutoComplete.prototype.setFooter=function(B){if(this._elFooter){var A=this._elFooter;if(B){A.innerHTML=B;A.style.display="block";}else{A.innerHTML="";A.style.display="none";}}};YAHOO.widget.AutoComplete.prototype.setBody=function(A){if(this._elBody){var B=this._elBody;YAHOO.util.Event.purgeElement(B,true);if(A){B.innerHTML=A;B.style.display="block";}else{B.innerHTML="";B.style.display="none";}this._elList=null;}};YAHOO.widget.AutoComplete.prototype.generateRequest=function(B){var A=this.dataSource.dataType;if(A===YAHOO.util.DataSourceBase.TYPE_XHR){if(!this.dataSource.connMethodPost){B=(this.queryQuestionMark?"?":"")+(this.dataSource.scriptQueryParam||"query")+"="+B+(this.dataSource.scriptQueryAppend?("&"+this.dataSource.scriptQueryAppend):"");}else{B=(this.dataSource.scriptQueryParam||"query")+"="+B+(this.dataSource.scriptQueryAppend?("&"+this.dataSource.scriptQueryAppend):"");}}else{if(A===YAHOO.util.DataSourceBase.TYPE_SCRIPTNODE){B="&"+(this.dataSource.scriptQueryParam||"query")+"="+B+(this.dataSource.scriptQueryAppend?("&"+this.dataSource.scriptQueryAppend):"");}}return B;};YAHOO.widget.AutoComplete.prototype.sendQuery=function(B){var A=(this.delimChar)?this._elTextbox.value+B:B;this._sendQuery(A);};YAHOO.widget.AutoComplete.prototype.collapseContainer=function(){this._toggleContainer(false);};YAHOO.widget.AutoComplete.prototype.getSubsetMatches=function(E){var D,C,A;for(var B=E.length;B>=this.minQueryLength;B--){A=this.generateRequest(E.substr(0,B));this.dataRequestEvent.fire(this,D,A);C=this.dataSource.getCachedResponse(A);if(C){return this.filterResults.apply(this.dataSource,[E,C,C,{scope:this}]);}}return null;};YAHOO.widget.AutoComplete.prototype.preparseRawResponse=function(C,B,A){var D=((this.responseStripAfter!=="")&&(B.indexOf))?B.indexOf(this.responseStripAfter):-1;if(D!=-1){B=B.substring(0,D);}return B;};YAHOO.widget.AutoComplete.prototype.filterResults=function(J,L,P,K){if(J&&J!==""){P=YAHOO.widget.AutoComplete._cloneObject(P);var H=K.scope,O=this,B=P.results,M=[],D=false,I=(O.queryMatchCase||H.queryMatchCase),A=(O.queryMatchContains||H.queryMatchContains);for(var C=B.length-1;C>=0;C--){var F=B[C];var E=null;if(YAHOO.lang.isString(F)){E=F;}else{if(YAHOO.lang.isArray(F)){E=F[0];}else{if(this.responseSchema.fields){var N=this.responseSchema.fields[0].key||this.responseSchema.fields[0];E=F[N];}else{if(this.key){E=F[this.key];}}}}if(YAHOO.lang.isString(E)){var G=(I)?E.indexOf(decodeURIComponent(J)):E.toLowerCase().indexOf(decodeURIComponent(J).toLowerCase());if((!A&&(G===0))||(A&&(G>-1))){M.unshift(F);}}}P.results=M;}else{}return P;};YAHOO.widget.AutoComplete.prototype.handleResponse=function(C,A,B){if((this instanceof YAHOO.widget.AutoComplete)&&this._sName){this._populateList(C,A,B);}};YAHOO.widget.AutoComplete.prototype.doBeforeLoadData=function(C,A,B){return true;};YAHOO.widget.AutoComplete.prototype.formatResult=function(B,D,A){var C=(A)?A:"";return C;};YAHOO.widget.AutoComplete.prototype.doBeforeExpandContainer=function(D,A,C,B){return true;};YAHOO.widget.AutoComplete.prototype.destroy=function(){var B=this.toString();var A=this._elTextbox;var D=this._elContainer;this.textboxFocusEvent.unsubscribeAll();this.textboxKeyEvent.unsubscribeAll();this.dataRequestEvent.unsubscribeAll();this.dataReturnEvent.unsubscribeAll();this.dataErrorEvent.unsubscribeAll();this.containerPopulateEvent.unsubscribeAll();this.containerExpandEvent.unsubscribeAll();this.typeAheadEvent.unsubscribeAll();this.itemMouseOverEvent.unsubscribeAll();this.itemMouseOutEvent.unsubscribeAll();this.itemArrowToEvent.unsubscribeAll();this.itemArrowFromEvent.unsubscribeAll();this.itemSelectEvent.unsubscribeAll();this.unmatchedItemSelectEvent.unsubscribeAll();this.selectionEnforceEvent.unsubscribeAll();this.containerCollapseEvent.unsubscribeAll();this.textboxBlurEvent.unsubscribeAll();this.textboxChangeEvent.unsubscribeAll();YAHOO.util.Event.purgeElement(A,true);YAHOO.util.Event.purgeElement(D,true);D.innerHTML="";for(var C in this){if(YAHOO.lang.hasOwnProperty(this,C)){this[C]=null;}}};YAHOO.widget.AutoComplete.prototype.textboxFocusEvent=null;YAHOO.widget.AutoComplete.prototype.textboxKeyEvent=null;YAHOO.widget.AutoComplete.prototype.dataRequestEvent=null;YAHOO.widget.AutoComplete.prototype.dataReturnEvent=null;YAHOO.widget.AutoComplete.prototype.dataErrorEvent=null;YAHOO.widget.AutoComplete.prototype.containerPopulateEvent=null;YAHOO.widget.AutoComplete.prototype.containerExpandEvent=null;YAHOO.widget.AutoComplete.prototype.typeAheadEvent=null;YAHOO.widget.AutoComplete.prototype.itemMouseOverEvent=null;YAHOO.widget.AutoComplete.prototype.itemMouseOutEvent=null;YAHOO.widget.AutoComplete.prototype.itemArrowToEvent=null;YAHOO.widget.AutoComplete.prototype.itemArrowFromEvent=null;YAHOO.widget.AutoComplete.prototype.itemSelectEvent=null;YAHOO.widget.AutoComplete.prototype.unmatchedItemSelectEvent=null;YAHOO.widget.AutoComplete.prototype.selectionEnforceEvent=null;YAHOO.widget.AutoComplete.prototype.containerCollapseEvent=null;YAHOO.widget.AutoComplete.prototype.textboxBlurEvent=null;YAHOO.widget.AutoComplete.prototype.textboxChangeEvent=null;YAHOO.widget.AutoComplete._nIndex=0; | ||
989 | 31 | YAHOO.widget.AutoComplete.prototype._sName=null;YAHOO.widget.AutoComplete.prototype._elTextbox=null;YAHOO.widget.AutoComplete.prototype._elContainer=null;YAHOO.widget.AutoComplete.prototype._elContent=null;YAHOO.widget.AutoComplete.prototype._elHeader=null;YAHOO.widget.AutoComplete.prototype._elBody=null;YAHOO.widget.AutoComplete.prototype._elFooter=null;YAHOO.widget.AutoComplete.prototype._elShadow=null;YAHOO.widget.AutoComplete.prototype._elIFrame=null;YAHOO.widget.AutoComplete.prototype._bFocused=null;YAHOO.widget.AutoComplete.prototype._oAnim=null;YAHOO.widget.AutoComplete.prototype._bContainerOpen=false;YAHOO.widget.AutoComplete.prototype._bOverContainer=false;YAHOO.widget.AutoComplete.prototype._elList=null;YAHOO.widget.AutoComplete.prototype._nDisplayedItems=0;YAHOO.widget.AutoComplete.prototype._sCurQuery=null;YAHOO.widget.AutoComplete.prototype._sPastSelections="";YAHOO.widget.AutoComplete.prototype._sInitInputValue=null;YAHOO.widget.AutoComplete.prototype._elCurListItem=null;YAHOO.widget.AutoComplete.prototype._bItemSelected=false;YAHOO.widget.AutoComplete.prototype._nKeyCode=null;YAHOO.widget.AutoComplete.prototype._nDelayID=-1;YAHOO.widget.AutoComplete.prototype._nTypeAheadDelayID=-1;YAHOO.widget.AutoComplete.prototype._iFrameSrc="javascript:false;";YAHOO.widget.AutoComplete.prototype._queryInterval=null;YAHOO.widget.AutoComplete.prototype._sLastTextboxValue=null;YAHOO.widget.AutoComplete.prototype._initProps=function(){var B=this.minQueryLength;if(!YAHOO.lang.isNumber(B)){this.minQueryLength=1;}var E=this.maxResultsDisplayed;if(!YAHOO.lang.isNumber(E)||(E<1)){this.maxResultsDisplayed=10;}var F=this.queryDelay;if(!YAHOO.lang.isNumber(F)||(F<0)){this.queryDelay=0.2;}var C=this.typeAheadDelay;if(!YAHOO.lang.isNumber(C)||(C<0)){this.typeAheadDelay=0.2;}var A=this.delimChar;if(YAHOO.lang.isString(A)&&(A.length>0)){this.delimChar=[A];}else{if(!YAHOO.lang.isArray(A)){this.delimChar=null;}}var D=this.animSpeed;if((this.animHoriz||this.animVert)&&YAHOO.util.Anim){if(!YAHOO.lang.isNumber(D)||(D<0)){this.animSpeed=0.3;}if(!this._oAnim){this._oAnim=new YAHOO.util.Anim(this._elContent,{},this.animSpeed);}else{this._oAnim.duration=this.animSpeed;}}if(this.forceSelection&&A){}};YAHOO.widget.AutoComplete.prototype._initContainerHelperEls=function(){if(this.useShadow&&!this._elShadow){var A=document.createElement("div");A.className="yui-ac-shadow";A.style.width=0;A.style.height=0;this._elShadow=this._elContainer.appendChild(A);}if(this.useIFrame&&!this._elIFrame){var B=document.createElement("iframe");B.src=this._iFrameSrc;B.frameBorder=0;B.scrolling="no";B.style.position="absolute";B.style.width=0;B.style.height=0;B.tabIndex=-1;B.style.padding=0;this._elIFrame=this._elContainer.appendChild(B);}};YAHOO.widget.AutoComplete.prototype._initContainerEl=function(){YAHOO.util.Dom.addClass(this._elContainer,"yui-ac-container");if(!this._elContent){var C=document.createElement("div");C.className="yui-ac-content";C.style.display="none";this._elContent=this._elContainer.appendChild(C);var B=document.createElement("div");B.className="yui-ac-hd";B.style.display="none";this._elHeader=this._elContent.appendChild(B);var D=document.createElement("div");D.className="yui-ac-bd";this._elBody=this._elContent.appendChild(D);var A=document.createElement("div");A.className="yui-ac-ft";A.style.display="none";this._elFooter=this._elContent.appendChild(A);}else{}};YAHOO.widget.AutoComplete.prototype._initListEl=function(){var C=this.maxResultsDisplayed;var A=this._elList||document.createElement("ul");var B;while(A.childNodes.length<C){B=document.createElement("li");B.style.display="none";B._nItemIndex=A.childNodes.length;A.appendChild(B);}if(!this._elList){var D=this._elBody;YAHOO.util.Event.purgeElement(D,true);D.innerHTML="";this._elList=D.appendChild(A);}};YAHOO.widget.AutoComplete.prototype._enableIntervalDetection=function(){var A=this;if(!A._queryInterval&&A.queryInterval){A._queryInterval=setInterval(function(){A._onInterval();},A.queryInterval);}};YAHOO.widget.AutoComplete.prototype._onInterval=function(){var A=this._elTextbox.value;var B=this._sLastTextboxValue;if(A!=B){this._sLastTextboxValue=A;this._sendQuery(A);}};YAHOO.widget.AutoComplete.prototype._clearInterval=function(){if(this._queryInterval){clearInterval(this._queryInterval);this._queryInterval=null;}};YAHOO.widget.AutoComplete.prototype._isIgnoreKey=function(A){if((A==9)||(A==13)||(A==16)||(A==17)||(A>=18&&A<=20)||(A==27)||(A>=33&&A<=35)||(A>=36&&A<=40)||(A>=44&&A<=45)||(A==229)){return true;}return false;};YAHOO.widget.AutoComplete.prototype._sendQuery=function(G){if(this.minQueryLength<0){this._toggleContainer(false);return ;}var I=(this.delimChar)?this.delimChar:null;if(I){var B=-1;for(var F=I.length-1;F>=0;F--){var D=G.lastIndexOf(I[F]);if(D>B){B=D;}}if(I[F]==" "){for(var E=I.length-1;E>=0;E--){if(G[B-1]==I[E]){B--;break;}}}if(B>-1){var H=B+1;while(G.charAt(H)==" "){H+=1;}this._sPastSelections=G.substring(0,H);G=G.substr(H);}else{this._sPastSelections="";}}if((G&&(G.length<this.minQueryLength))||(!G&&this.minQueryLength>0)){if(this._nDelayID!=-1){clearTimeout(this._nDelayID);}this._toggleContainer(false);return ;}G=encodeURIComponent(G);this._nDelayID=-1;if(this.dataSource.queryMatchSubset||this.queryMatchSubset){var A=this.getSubsetMatches(G);if(A){this.handleResponse(G,A,{query:G});return ;}}if(this.responseStripAfter){this.dataSource.doBeforeParseData=this.preparseRawResponse;}if(this.applyLocalFilter){this.dataSource.doBeforeCallback=this.filterResults;}var C=this.generateRequest(G);this.dataRequestEvent.fire(this,G,C);this.dataSource.sendRequest(C,{success:this.handleResponse,failure:this.handleResponse,scope:this,argument:{query:G}});};YAHOO.widget.AutoComplete.prototype._populateList=function(K,F,C){if(this._nTypeAheadDelayID!=-1){clearTimeout(this._nTypeAheadDelayID);}K=(C&&C.query)?C.query:K;var H=this.doBeforeLoadData(K,F,C);if(H&&!F.error){this.dataReturnEvent.fire(this,K,F.results);if(this._bFocused||(this._bFocused===null)){var M=decodeURIComponent(K); | ||
990 | 32 | this._sCurQuery=M;this._bItemSelected=false;var R=F.results,A=Math.min(R.length,this.maxResultsDisplayed),J=(this.dataSource.responseSchema.fields)?(this.dataSource.responseSchema.fields[0].key||this.dataSource.responseSchema.fields[0]):0;if(A>0){if(!this._elList||(this._elList.childNodes.length<A)){this._initListEl();}this._initContainerHelperEls();var I=this._elList.childNodes;for(var Q=A-1;Q>=0;Q--){var P=I[Q],E=R[Q];if(this.resultTypeList){var B=[];B[0]=(YAHOO.lang.isString(E))?E:E[J]||E[this.key];var L=this.dataSource.responseSchema.fields;if(YAHOO.lang.isArray(L)&&(L.length>1)){for(var N=1,S=L.length;N<S;N++){B[B.length]=E[L[N].key||L[N]];}}else{if(YAHOO.lang.isArray(E)){B=E;}else{if(YAHOO.lang.isString(E)){B=[E];}else{B[1]=E;}}}E=B;}P._sResultMatch=(YAHOO.lang.isString(E))?E:(YAHOO.lang.isArray(E))?E[0]:(E[J]||"");P._oResultData=E;P.innerHTML=this.formatResult(E,M,P._sResultMatch);P.style.display="";}if(A<I.length){var G;for(var O=I.length-1;O>=A;O--){G=I[O];G.style.display="none";}}this._nDisplayedItems=A;this.containerPopulateEvent.fire(this,K,R);if(this.autoHighlight){var D=this._elList.firstChild;this._toggleHighlight(D,"to");this.itemArrowToEvent.fire(this,D);this._typeAhead(D,K);}else{this._toggleHighlight(this._elCurListItem,"from");}H=this.doBeforeExpandContainer(this._elTextbox,this._elContainer,K,R);this._toggleContainer(H);}else{this._toggleContainer(false);}return ;}}else{this.dataErrorEvent.fire(this,K);}};YAHOO.widget.AutoComplete.prototype._clearSelection=function(){var C=this._elTextbox.value;var B=(this.delimChar)?this.delimChar[0]:null;var A=(B)?C.lastIndexOf(B,C.length-2):-1;if(A>-1){this._elTextbox.value=C.substring(0,A);}else{this._elTextbox.value="";}this._sPastSelections=this._elTextbox.value;this.selectionEnforceEvent.fire(this);};YAHOO.widget.AutoComplete.prototype._textMatchesOption=function(){var A=null;for(var B=this._nDisplayedItems-1;B>=0;B--){var C=this._elList.childNodes[B];var D=(""+C._sResultMatch).toLowerCase();if(D==this._sCurQuery.toLowerCase()){A=C;break;}}return(A);};YAHOO.widget.AutoComplete.prototype._typeAhead=function(B,D){if(!this.typeAhead||(this._nKeyCode==8)){return ;}var A=this,C=this._elTextbox;if(C.setSelectionRange||C.createTextRange){this._nTypeAheadDelayID=setTimeout(function(){var F=C.value.length;A._updateValue(B);var G=C.value.length;A._selectText(C,F,G);var E=C.value.substr(F,G);A.typeAheadEvent.fire(A,D,E);},(this.typeAheadDelay*1000));}};YAHOO.widget.AutoComplete.prototype._selectText=function(D,A,B){if(D.setSelectionRange){D.setSelectionRange(A,B);}else{if(D.createTextRange){var C=D.createTextRange();C.moveStart("character",A);C.moveEnd("character",B-D.value.length);C.select();}else{D.select();}}};YAHOO.widget.AutoComplete.prototype._toggleContainerHelpers=function(D){var E=this._elContent.offsetWidth+"px";var B=this._elContent.offsetHeight+"px";if(this.useIFrame&&this._elIFrame){var C=this._elIFrame;if(D){C.style.width=E;C.style.height=B;C.style.padding="";}else{C.style.width=0;C.style.height=0;C.style.padding=0;}}if(this.useShadow&&this._elShadow){var A=this._elShadow;if(D){A.style.width=E;A.style.height=B;}else{A.style.width=0;A.style.height=0;}}};YAHOO.widget.AutoComplete.prototype._toggleContainer=function(I){var D=this._elContainer;if(this.alwaysShowContainer&&this._bContainerOpen){return ;}if(!I){this._toggleHighlight(this._elCurListItem,"from");this._nDisplayedItems=0;this._sCurQuery=null;if(!this._bContainerOpen){this._elContent.style.display="none";return ;}}var A=this._oAnim;if(A&&A.getEl()&&(this.animHoriz||this.animVert)){if(A.isAnimated()){A.stop(true);}var G=this._elContent.cloneNode(true);D.appendChild(G);G.style.top="-9000px";G.style.width="";G.style.height="";G.style.display="";var F=G.offsetWidth;var C=G.offsetHeight;var B=(this.animHoriz)?0:F;var E=(this.animVert)?0:C;A.attributes=(I)?{width:{to:F},height:{to:C}}:{width:{to:B},height:{to:E}};if(I&&!this._bContainerOpen){this._elContent.style.width=B+"px";this._elContent.style.height=E+"px";}else{this._elContent.style.width=F+"px";this._elContent.style.height=C+"px";}D.removeChild(G);G=null;var H=this;var J=function(){A.onComplete.unsubscribeAll();if(I){H._toggleContainerHelpers(true);H._bContainerOpen=I;H.containerExpandEvent.fire(H);}else{H._elContent.style.display="none";H._bContainerOpen=I;H.containerCollapseEvent.fire(H);}};this._toggleContainerHelpers(false);this._elContent.style.display="";A.onComplete.subscribe(J);A.animate();}else{if(I){this._elContent.style.display="";this._toggleContainerHelpers(true);this._bContainerOpen=I;this.containerExpandEvent.fire(this);}else{this._toggleContainerHelpers(false);this._elContent.style.display="none";this._bContainerOpen=I;this.containerCollapseEvent.fire(this);}}};YAHOO.widget.AutoComplete.prototype._toggleHighlight=function(A,C){if(A){var B=this.highlightClassName;if(this._elCurListItem){YAHOO.util.Dom.removeClass(this._elCurListItem,B);this._elCurListItem=null;}if((C=="to")&&B){YAHOO.util.Dom.addClass(A,B);this._elCurListItem=A;}}};YAHOO.widget.AutoComplete.prototype._togglePrehighlight=function(B,C){if(B==this._elCurListItem){return ;}var A=this.prehighlightClassName;if((C=="mouseover")&&A){YAHOO.util.Dom.addClass(B,A);}else{YAHOO.util.Dom.removeClass(B,A);}};YAHOO.widget.AutoComplete.prototype._updateValue=function(C){if(!this.suppressInputUpdate){var F=this._elTextbox;var E=(this.delimChar)?(this.delimChar[0]||this.delimChar):null;var B=C._sResultMatch;var D="";if(E){D=this._sPastSelections;D+=B+E;if(E!=" "){D+=" ";}}else{D=B;}F.value=D;if(F.type=="textarea"){F.scrollTop=F.scrollHeight;}var A=F.value.length;this._selectText(F,A,A);this._elCurListItem=C;}};YAHOO.widget.AutoComplete.prototype._selectItem=function(A){this._bItemSelected=true;this._updateValue(A);this._sPastSelections=this._elTextbox.value;this._clearInterval();this.itemSelectEvent.fire(this,A,A._oResultData);this._toggleContainer(false);};YAHOO.widget.AutoComplete.prototype._jumpSelection=function(){if(this._elCurListItem){this._selectItem(this._elCurListItem); | ||
991 | 33 | }else{this._toggleContainer(false);}};YAHOO.widget.AutoComplete.prototype._moveSelection=function(G){if(this._bContainerOpen){var F=this._elCurListItem;var E=-1;if(F){E=F._nItemIndex;}var C=(G==40)?(E+1):(E-1);if(C<-2||C>=this._nDisplayedItems){return ;}if(F){this._toggleHighlight(F,"from");this.itemArrowFromEvent.fire(this,F);}if(C==-1){if(this.delimChar){this._elTextbox.value=this._sPastSelections+this._sCurQuery;}else{this._elTextbox.value=this._sCurQuery;}return ;}if(C==-2){this._toggleContainer(false);return ;}var D=this._elList.childNodes[C];var A=this._elContent;var B=((YAHOO.util.Dom.getStyle(A,"overflow")=="auto")||(YAHOO.util.Dom.getStyle(A,"overflowY")=="auto"));if(B&&(C>-1)&&(C<this._nDisplayedItems)){if(G==40){if((D.offsetTop+D.offsetHeight)>(A.scrollTop+A.offsetHeight)){A.scrollTop=(D.offsetTop+D.offsetHeight)-A.offsetHeight;}else{if((D.offsetTop+D.offsetHeight)<A.scrollTop){A.scrollTop=D.offsetTop;}}}else{if(D.offsetTop<A.scrollTop){this._elContent.scrollTop=D.offsetTop;}else{if(D.offsetTop>(A.scrollTop+A.offsetHeight)){this._elContent.scrollTop=(D.offsetTop+D.offsetHeight)-A.offsetHeight;}}}}this._toggleHighlight(D,"to");this.itemArrowToEvent.fire(this,D);if(this.typeAhead){this._updateValue(D);}}};YAHOO.widget.AutoComplete.prototype._onContainerMouseover=function(A,C){var D=YAHOO.util.Event.getTarget(A);var B=D.nodeName.toLowerCase();while(D&&(B!="table")){switch(B){case"body":return ;case"li":if(C.prehighlightClassName){C._togglePrehighlight(D,"mouseover");}else{C._toggleHighlight(D,"to");}C.itemMouseOverEvent.fire(C,D);break;case"div":if(YAHOO.util.Dom.hasClass(D,"yui-ac-container")){C._bOverContainer=true;return ;}break;default:break;}D=D.parentNode;if(D){B=D.nodeName.toLowerCase();}}};YAHOO.widget.AutoComplete.prototype._onContainerMouseout=function(A,C){var D=YAHOO.util.Event.getTarget(A);var B=D.nodeName.toLowerCase();while(D&&(B!="table")){switch(B){case"body":return ;case"li":if(C.prehighlightClassName){C._togglePrehighlight(D,"mouseout");}else{C._toggleHighlight(D,"from");}C.itemMouseOutEvent.fire(C,D);break;case"ul":C._toggleHighlight(C._elCurListItem,"to");break;case"div":if(YAHOO.util.Dom.hasClass(D,"yui-ac-container")){C._bOverContainer=false;return ;}break;default:break;}D=D.parentNode;if(D){B=D.nodeName.toLowerCase();}}};YAHOO.widget.AutoComplete.prototype._onContainerClick=function(A,C){var D=YAHOO.util.Event.getTarget(A);var B=D.nodeName.toLowerCase();while(D&&(B!="table")){switch(B){case"body":return ;case"li":C._toggleHighlight(D,"to");C._selectItem(D);return ;default:break;}D=D.parentNode;if(D){B=D.nodeName.toLowerCase();}}};YAHOO.widget.AutoComplete.prototype._onContainerScroll=function(A,B){B._elTextbox.focus();};YAHOO.widget.AutoComplete.prototype._onContainerResize=function(A,B){B._toggleContainerHelpers(B._bContainerOpen);};YAHOO.widget.AutoComplete.prototype._onTextboxKeyDown=function(A,B){var C=A.keyCode;if(B._nTypeAheadDelayID!=-1){clearTimeout(B._nTypeAheadDelayID);}switch(C){case 9:if(!YAHOO.env.ua.opera&&(navigator.userAgent.toLowerCase().indexOf("mac")==-1)||(YAHOO.env.ua.webkit>420)){if(B._elCurListItem){if(B.delimChar&&(B._nKeyCode!=C)){if(B._bContainerOpen){YAHOO.util.Event.stopEvent(A);}}B._selectItem(B._elCurListItem);}else{B._toggleContainer(false);}}break;case 13:if(!YAHOO.env.ua.opera&&(navigator.userAgent.toLowerCase().indexOf("mac")==-1)||(YAHOO.env.ua.webkit>420)){if(B._elCurListItem){if(B._nKeyCode!=C){if(B._bContainerOpen){YAHOO.util.Event.stopEvent(A);}}B._selectItem(B._elCurListItem);}else{B._toggleContainer(false);}}break;case 27:B._toggleContainer(false);return ;case 39:B._jumpSelection();break;case 38:if(B._bContainerOpen){YAHOO.util.Event.stopEvent(A);B._moveSelection(C);}break;case 40:if(B._bContainerOpen){YAHOO.util.Event.stopEvent(A);B._moveSelection(C);}break;default:B._bItemSelected=false;B._toggleHighlight(B._elCurListItem,"from");B.textboxKeyEvent.fire(B,C);break;}if(C===18){B._enableIntervalDetection();}B._nKeyCode=C;};YAHOO.widget.AutoComplete.prototype._onTextboxKeyPress=function(A,B){var C=A.keyCode;if(YAHOO.env.ua.opera||(navigator.userAgent.toLowerCase().indexOf("mac")!=-1)&&(YAHOO.env.ua.webkit<420)){switch(C){case 9:if(B._bContainerOpen){if(B.delimChar){YAHOO.util.Event.stopEvent(A);}if(B._elCurListItem){B._selectItem(B._elCurListItem);}else{B._toggleContainer(false);}}break;case 13:if(B._bContainerOpen){YAHOO.util.Event.stopEvent(A);if(B._elCurListItem){B._selectItem(B._elCurListItem);}else{B._toggleContainer(false);}}break;default:break;}}else{if(C==229){B._enableIntervalDetection();}}};YAHOO.widget.AutoComplete.prototype._onTextboxKeyUp=function(A,C){var B=this.value;C._initProps();var D=A.keyCode;if(C._isIgnoreKey(D)){return ;}if(C._nDelayID!=-1){clearTimeout(C._nDelayID);}C._nDelayID=setTimeout(function(){C._sendQuery(B);},(C.queryDelay*1000));};YAHOO.widget.AutoComplete.prototype._onTextboxFocus=function(A,B){if(!B._bFocused){B._elTextbox.setAttribute("autocomplete","off");B._bFocused=true;B._sInitInputValue=B._elTextbox.value;B.textboxFocusEvent.fire(B);}};YAHOO.widget.AutoComplete.prototype._onTextboxBlur=function(A,C){if(!C._bOverContainer||(C._nKeyCode==9)){if(!C._bItemSelected){var B=C._textMatchesOption();if(!C._bContainerOpen||(C._bContainerOpen&&(B===null))){if(C.forceSelection){C._clearSelection();}else{C.unmatchedItemSelectEvent.fire(C,C._sCurQuery);}}else{if(C.forceSelection){C._selectItem(B);}}}if(C._bContainerOpen){C._toggleContainer(false);}C._clearInterval();C._bFocused=false;if(C._sInitInputValue!==C._elTextbox.value){C.textboxChangeEvent.fire(C);}C.textboxBlurEvent.fire(C);}};YAHOO.widget.AutoComplete.prototype._onWindowUnload=function(A,B){if(B&&B._elTextbox&&B.allowBrowserAutocomplete){B._elTextbox.setAttribute("autocomplete","on");}};YAHOO.widget.AutoComplete.prototype.doBeforeSendQuery=function(A){return this.generateRequest(A);};YAHOO.widget.AutoComplete.prototype.getListItems=function(){var C=[],B=this._elList.childNodes;for(var A=B.length-1;A>=0;A--){C[A]=B[A];}return C;};YAHOO.widget.AutoComplete._cloneObject=function(D){if(!YAHOO.lang.isValue(D)){return D; | ||
992 | 34 | }var F={};if(YAHOO.lang.isFunction(D)){F=D;}else{if(YAHOO.lang.isArray(D)){var E=[];for(var C=0,B=D.length;C<B;C++){E[C]=YAHOO.widget.AutoComplete._cloneObject(D[C]);}F=E;}else{if(YAHOO.lang.isObject(D)){for(var A in D){if(YAHOO.lang.hasOwnProperty(D,A)){if(YAHOO.lang.isValue(D[A])&&YAHOO.lang.isObject(D[A])||YAHOO.lang.isArray(D[A])){F[A]=YAHOO.widget.AutoComplete._cloneObject(D[A]);}else{F[A]=D[A];}}}}else{F=D;}}}return F;};YAHOO.register("autocomplete",YAHOO.widget.AutoComplete,{version:"2.6.0",build:"1321"});/* | ||
993 | 35 | Copyright (c) 2008, Yahoo! Inc. All rights reserved. | ||
994 | 36 | Code licensed under the BSD License: | ||
995 | 37 | http://developer.yahoo.net/yui/license.txt | ||
996 | 38 | version: 2.6.0 | ||
997 | 39 | */ | ||
998 | 40 | YAHOO.namespace("util");YAHOO.util.Cookie={_createCookieString:function(B,D,C,A){var F=YAHOO.lang;var E=encodeURIComponent(B)+"="+(C?encodeURIComponent(D):D);if(F.isObject(A)){if(A.expires instanceof Date){E+="; expires="+A.expires.toGMTString();}if(F.isString(A.path)&&A.path!=""){E+="; path="+A.path;}if(F.isString(A.domain)&&A.domain!=""){E+="; domain="+A.domain;}if(A.secure===true){E+="; secure";}}return E;},_createCookieHashString:function(B){var D=YAHOO.lang;if(!D.isObject(B)){throw new TypeError("Cookie._createCookieHashString(): Argument must be an object.");}var C=new Array();for(var A in B){if(D.hasOwnProperty(B,A)&&!D.isFunction(B[A])&&!D.isUndefined(B[A])){C.push(encodeURIComponent(A)+"="+encodeURIComponent(String(B[A])));}}return C.join("&");},_parseCookieHash:function(E){var D=E.split("&"),F=null,C=new Object();if(E.length>0){for(var B=0,A=D.length;B<A;B++){F=D[B].split("=");C[decodeURIComponent(F[0])]=decodeURIComponent(F[1]);}}return C;},_parseCookieString:function(I,A){var J=new Object();if(YAHOO.lang.isString(I)&&I.length>0){var B=(A===false?function(K){return K;}:decodeURIComponent);if(/[^=]+=[^=;]?(?:; [^=]+=[^=]?)?/.test(I)){var G=I.split(/;\s/g);var H=null;var C=null;var E=null;for(var D=0,F=G.length;D<F;D++){E=G[D].match(/([^=]+)=/i);if(E instanceof Array){H=decodeURIComponent(E[1]);C=B(G[D].substring(E[1].length+1));}else{H=decodeURIComponent(G[D]);C=H;}J[H]=C;}}}return J;},get:function(A,B){var D=YAHOO.lang;var C=this._parseCookieString(document.cookie);if(!D.isString(A)||A===""){throw new TypeError("Cookie.get(): Cookie name must be a non-empty string.");}if(D.isUndefined(C[A])){return null;}if(!D.isFunction(B)){return C[A];}else{return B(C[A]);}},getSub:function(A,C,B){var E=YAHOO.lang;var D=this.getSubs(A);if(D!==null){if(!E.isString(C)||C===""){throw new TypeError("Cookie.getSub(): Subcookie name must be a non-empty string.");}if(E.isUndefined(D[C])){return null;}if(!E.isFunction(B)){return D[C];}else{return B(D[C]);}}else{return null;}},getSubs:function(A){if(!YAHOO.lang.isString(A)||A===""){throw new TypeError("Cookie.getSubs(): Cookie name must be a non-empty string.");}var B=this._parseCookieString(document.cookie,false);if(YAHOO.lang.isString(B[A])){return this._parseCookieHash(B[A]);}return null;},remove:function(B,A){if(!YAHOO.lang.isString(B)||B===""){throw new TypeError("Cookie.remove(): Cookie name must be a non-empty string.");}A=A||{};A.expires=new Date(0);return this.set(B,"",A);},removeSub:function(B,D,A){if(!YAHOO.lang.isString(B)||B===""){throw new TypeError("Cookie.removeSub(): Cookie name must be a non-empty string.");}if(!YAHOO.lang.isString(D)||D===""){throw new TypeError("Cookie.removeSub(): Subcookie name must be a non-empty string.");}var C=this.getSubs(B);if(YAHOO.lang.isObject(C)&&YAHOO.lang.hasOwnProperty(C,D)){delete C[D];return this.setSubs(B,C,A);}else{return"";}},set:function(B,C,A){var E=YAHOO.lang;if(!E.isString(B)){throw new TypeError("Cookie.set(): Cookie name must be a string.");}if(E.isUndefined(C)){throw new TypeError("Cookie.set(): Value cannot be undefined.");}var D=this._createCookieString(B,C,true,A);document.cookie=D;return D;},setSub:function(B,D,C,A){var F=YAHOO.lang;if(!F.isString(B)||B===""){throw new TypeError("Cookie.setSub(): Cookie name must be a non-empty string.");}if(!F.isString(D)||D===""){throw new TypeError("Cookie.setSub(): Subcookie name must be a non-empty string.");}if(F.isUndefined(C)){throw new TypeError("Cookie.setSub(): Subcookie value cannot be undefined.");}var E=this.getSubs(B);if(!F.isObject(E)){E=new Object();}E[D]=C;return this.setSubs(B,E,A);},setSubs:function(B,C,A){var E=YAHOO.lang;if(!E.isString(B)){throw new TypeError("Cookie.setSubs(): Cookie name must be a string.");}if(!E.isObject(C)){throw new TypeError("Cookie.setSubs(): Cookie value must be an object.");}var D=this._createCookieString(B,this._createCookieHashString(C),false,A);document.cookie=D;return D;}};YAHOO.register("cookie",YAHOO.util.Cookie,{version:"2.6.0",build:"1321"}); | ||
999 | 41 | |||
1000 | 42 | |||
1001 | 0 | 43 | ||
1002 | === added file 'jarmonbuild/yuidoc_template/assets/api.css' | |||
1003 | --- jarmonbuild/yuidoc_template/assets/api.css 1970-01-01 00:00:00 +0000 | |||
1004 | +++ jarmonbuild/yuidoc_template/assets/api.css 2010-08-22 21:23:38 +0000 | |||
1005 | @@ -0,0 +1,242 @@ | |||
1006 | 1 | |||
1007 | 2 | |||
1008 | 3 | body { background-color: #ECF0F6; } | ||
1009 | 4 | |||
1010 | 5 | /* main page */ | ||
1011 | 6 | a:link { color: #003399; } | ||
1012 | 7 | a:visited { color: #003399;} | ||
1013 | 8 | |||
1014 | 9 | #doc3 #hd { margin-bottom:1em; position: relative; zoom: 1; } | ||
1015 | 10 | #doc3 #hd h1 { color: #545454; font-size: 170%; padding: 0; height: 60px; font-weight: bold; text-align: center;} | ||
1016 | 11 | #doc3 #hd h1 a { position: relative; top: 14px; } | ||
1017 | 12 | #doc3 #hd a { text-decoration: none; color: black; } | ||
1018 | 13 | #doc3 #hd h3 { | ||
1019 | 14 | background: #98AAB1; background-image: url(bg_hd.gif); color: #000; font-size: 100%; padding: 4px 10px; margin: 0 0 7px 0; | ||
1020 | 15 | border: 1px solid #98AAB1; | ||
1021 | 16 | } | ||
1022 | 17 | #ft hr { | ||
1023 | 18 | display: none; | ||
1024 | 19 | } | ||
1025 | 20 | #ft { | ||
1026 | 21 | background: #98AAB1; background-image: url(bg_hd.gif); color: #000; font-size: 100%; padding: 4px 10px; margin: 7px 0 0 0; border: 1px solid #98AAB1; | ||
1027 | 22 | } | ||
1028 | 23 | #doc3 #hd h3 A { color: #FFF; text-decoration: none; } | ||
1029 | 24 | #doc3 #hd .breadcrumbs { font-size: 85%; margin-bottom:10px;} | ||
1030 | 25 | #doc3 #hd .subtitle {position: absolute; right:1em; padding: 0px;margin:0px} | ||
1031 | 26 | |||
1032 | 27 | #doc3 dl { margin: 2px 0; } | ||
1033 | 28 | #doc3 dd { margin-left: 20px; } | ||
1034 | 29 | #doc3 .requires dt { font-style: italic; } | ||
1035 | 30 | #doc3 .default { margin-top:6px; } | ||
1036 | 31 | #doc3 .detail .deprecated { margin-top:4px; padding:4px; background-color: #EFECCA } | ||
1037 | 32 | #doc3 .detail .deprecated strong { color:#441054; } | ||
1038 | 33 | #doc3 code, pre {font-size:85%} | ||
1039 | 34 | |||
1040 | 35 | #doc3 #hd h1 { | ||
1041 | 36 | border: 1px solid #98AAB1; | ||
1042 | 37 | background-color: #fff; | ||
1043 | 38 | margin-bottom: .5em; | ||
1044 | 39 | |||
1045 | 40 | } | ||
1046 | 41 | #bd { | ||
1047 | 42 | border: 1px solid #98AAB1; | ||
1048 | 43 | background-color: #fff; | ||
1049 | 44 | } | ||
1050 | 45 | |||
1051 | 46 | .submodules dd { | ||
1052 | 47 | font-size: 93%; | ||
1053 | 48 | font-weight: italic; | ||
1054 | 49 | } | ||
1055 | 50 | |||
1056 | 51 | |||
1057 | 52 | #doc3 .classopts { font-size: 85%; float:right; margin:2px; padding: 2px; background-color:#ECF0F6;border: 1px solid #98AAB1;} | ||
1058 | 53 | #yui-classopts-form fieldset legend { display: none; } | ||
1059 | 54 | |||
1060 | 55 | /* undo reset.css styles for description block formatting */ | ||
1061 | 56 | #doc3 .description ul { padding: 10px 0 10px 28px; font-size: 90%; list-style: disc} | ||
1062 | 57 | #doc3 .description li { list-style: disc} | ||
1063 | 58 | #doc3 .description p { padding-bottom: 10px} | ||
1064 | 59 | #doc3 .description strong { font-weight: bold;} | ||
1065 | 60 | #doc3 .description em {padding: 2px; background-color: #EFECCA} | ||
1066 | 61 | #doc3 pre { padding: 10px;} | ||
1067 | 62 | |||
1068 | 63 | #doc3 .summary { margin: 0px 10px 10px 0; padding:10px; background-color:#ECF0F6; border:1px solid #98AAB1; } | ||
1069 | 64 | #doc3 .extends {font-weight: normal; font-size: 90%} | ||
1070 | 65 | |||
1071 | 66 | #doc3 .nav {min-height: 400px;} | ||
1072 | 67 | #doc3 .nav .module { | ||
1073 | 68 | width:100%; | ||
1074 | 69 | border-right: 1px solid #98AAB1; | ||
1075 | 70 | border-bottom: 1px solid #98AAB1; | ||
1076 | 71 | padding: 0; overflow:hidden; | ||
1077 | 72 | } | ||
1078 | 73 | #doc3 .nav .module h4 { | ||
1079 | 74 | padding: 3px 5px; | ||
1080 | 75 | border-bottom: 1px solid #98AAB1; | ||
1081 | 76 | background-image: url(bg_hd.gif); | ||
1082 | 77 | } | ||
1083 | 78 | #doc3 .nav .module h4 A { color: #000; text-decoration: none; } | ||
1084 | 79 | #doc3 .nav .module .content { padding: 2px; } | ||
1085 | 80 | #doc3 .nav .module UL.content LI { font-size: 90%; } | ||
1086 | 81 | #doc3 .nav .module UL.content A { text-decoration: none; color: black; display: block; padding: 2px 4px 2px 4px; } | ||
1087 | 82 | #doc3 .nav .module LI, | ||
1088 | 83 | #doc3 .nav .module LI A { | ||
1089 | 84 | zoom: 1; | ||
1090 | 85 | } | ||
1091 | 86 | #doc3 .nav .module LI.selected A, | ||
1092 | 87 | #doc3 .nav .module LI A:hover { | ||
1093 | 88 | background-color: #ECF0F6; | ||
1094 | 89 | zoom: 1; | ||
1095 | 90 | } | ||
1096 | 91 | |||
1097 | 92 | #doc3 .section { margin: 0 7px 7px 0; } | ||
1098 | 93 | #doc3 .section strong { font-weight: bold;} | ||
1099 | 94 | #doc3 .section hr { border: none 0; border-top: 1px solid #ccc; } | ||
1100 | 95 | #doc3 .section h4 { font-size:110%;} | ||
1101 | 96 | #doc3 .section h3 { background: #98AAB1; background-image: url(bg_hd.gif); width: 98%; color: #000; padding: 3px; margin: 0 0 7px 0; | ||
1102 | 97 | border: 1px solid #98AAB1; | ||
1103 | 98 | |||
1104 | 99 | } | ||
1105 | 100 | #doc3 .section h3 .top { font-size: 60%; font-weight: normal; width: 100%; font-family: verdana; padding-left: 20px; } | ||
1106 | 101 | #doc3 .section h3 .top A { color: #000; text-decoration: none; } | ||
1107 | 102 | |||
1108 | 103 | #doc3 .section.details .content { padding: 0 0 0 10px; } | ||
1109 | 104 | #doc3 .section.details .description { padding: 10px 0 0 20px; } | ||
1110 | 105 | #doc3 .section.details .description dt { font-weight: bold; } | ||
1111 | 106 | #doc3 .section.details .description td { border:1px solid #ccc; margin:2px;padding:2px;} | ||
1112 | 107 | |||
1113 | 108 | #doc3 .inheritance { padding:10px; background-color:#ECF0F6; border:1px solid #98AAB1; } | ||
1114 | 109 | #doc3 .inheritance h4 { font-size: 100%;} | ||
1115 | 110 | |||
1116 | 111 | /* index page autocomplete */ | ||
1117 | 112 | /* | ||
1118 | 113 | #propertysearch {;position:absolute;margin:1em;width:35em;} | ||
1119 | 114 | #searchinput {position:absolute;width:100%;height:1.4em;} | ||
1120 | 115 | #searchresults {position:absolute;top:1.7em;width:100%;} | ||
1121 | 116 | #searchresults .yui-ac-content {position:absolute;top:4px; left:0px; width:100%;height:20em;border:1px solid #aaa;background:#fff;overflow:auto;overflow-x:hidden;z-index:9050;} | ||
1122 | 117 | #searchresults .yui-ac-shadow {position:absolute;margin:.3em;width:100%;background:#a0a0a0;z-index:9049;}: | ||
1123 | 118 | #searchresults ul {padding:5px 0;width:100%;} | ||
1124 | 119 | #searchresults li {padding:0 5px;cursor:default;white-space:nowrap;} | ||
1125 | 120 | #searchresults li.yui-ac-highlight {background:#D1C6DA;} | ||
1126 | 121 | #searchresults li em { position:absolute; width:44%; overflow:hidden; color:#654D6C;} | ||
1127 | 122 | #searchresults li span { position:relative; left:46% } | ||
1128 | 123 | */ | ||
1129 | 124 | |||
1130 | 125 | #propertysearch { | ||
1131 | 126 | width: 25em; | ||
1132 | 127 | position: absolute; | ||
1133 | 128 | right: 5px; | ||
1134 | 129 | bottom: -4px; | ||
1135 | 130 | } | ||
1136 | 131 | #searchinput { | ||
1137 | 132 | width: 83%; | ||
1138 | 133 | height: 1.4em; | ||
1139 | 134 | } | ||
1140 | 135 | #searchresults { | ||
1141 | 136 | position: absolute; | ||
1142 | 137 | right: 25em; | ||
1143 | 138 | top: 25px; | ||
1144 | 139 | height: 0; | ||
1145 | 140 | } | ||
1146 | 141 | #searchresults .yui-ac-content { | ||
1147 | 142 | position: absolute; | ||
1148 | 143 | top: 0; | ||
1149 | 144 | left: 0; | ||
1150 | 145 | width: 25em; | ||
1151 | 146 | height: 20em; | ||
1152 | 147 | border: 1px solid #98AAB1; | ||
1153 | 148 | background: #fff; | ||
1154 | 149 | overflow: auto; | ||
1155 | 150 | overflow-x: hidden; | ||
1156 | 151 | z-index: 9050; | ||
1157 | 152 | } | ||
1158 | 153 | #searchresults li.yui-ac-highlight { | ||
1159 | 154 | background-color: #ECF0F6; | ||
1160 | 155 | } | ||
1161 | 156 | #searchresults li em { | ||
1162 | 157 | width:44%; | ||
1163 | 158 | overflow: hidden; | ||
1164 | 159 | color: #98AAB1; | ||
1165 | 160 | } | ||
1166 | 161 | |||
1167 | 162 | .deprecated, .private, .protected { | ||
1168 | 163 | display: none; | ||
1169 | 164 | } | ||
1170 | 165 | |||
1171 | 166 | body.show_deprecated .deprecated, | ||
1172 | 167 | body.show_private .private, | ||
1173 | 168 | body.show_protected .protected { | ||
1174 | 169 | display: inherit; | ||
1175 | 170 | } | ||
1176 | 171 | |||
1177 | 172 | #splash_classList ul { | ||
1178 | 173 | margin: 1em; | ||
1179 | 174 | margin-left:2em; | ||
1180 | 175 | } | ||
1181 | 176 | #splash_classList ul li { | ||
1182 | 177 | list-style: disc outside; | ||
1183 | 178 | } | ||
1184 | 179 | |||
1185 | 180 | |||
1186 | 181 | /* source code view */ | ||
1187 | 182 | #srcout {min-width: 580px; } | ||
1188 | 183 | *html #srcout { width: 100%; padding-bottom:1em; overflow-x:auto } | ||
1189 | 184 | |||
1190 | 185 | .highlight .c { color: #60a0b0; font-style: italic } /* Comment */ | ||
1191 | 186 | .highlight .err { border: 1px solid #FF0000 } /* Error */ | ||
1192 | 187 | .highlight .k { color: #007020; font-weight: bold } /* Keyword */ | ||
1193 | 188 | .highlight .o { color: #666666 } /* Operator */ | ||
1194 | 189 | .highlight .cm { color: #60a0b0; font-style: italic } /* Comment.Multiline */ | ||
1195 | 190 | .highlight .cp { color: #007020 } /* Comment.Preproc */ | ||
1196 | 191 | .highlight .c1 { color: #60a0b0; font-style: italic } /* Comment.Single */ | ||
1197 | 192 | .highlight .gd { color: #A00000 } /* Generic.Deleted */ | ||
1198 | 193 | .highlight .ge { font-style: italic } /* Generic.Emph */ | ||
1199 | 194 | .highlight .gr { color: #FF0000 } /* Generic.Error */ | ||
1200 | 195 | .highlight .gh { color: #000080; font-weight: bold } /* Generic.Heading */ | ||
1201 | 196 | .highlight .gi { color: #00A000 } /* Generic.Inserted */ | ||
1202 | 197 | .highlight .go { color: #808080 } /* Generic.Output */ | ||
1203 | 198 | .highlight .gp { color: #c65d09; font-weight: bold } /* Generic.Prompt */ | ||
1204 | 199 | .highlight .gs { font-weight: bold } /* Generic.Strong */ | ||
1205 | 200 | .highlight .gu { color: #800080; font-weight: bold } /* Generic.Subheading */ | ||
1206 | 201 | .highlight .gt { color: #0040D0 } /* Generic.Traceback */ | ||
1207 | 202 | .highlight .kc { color: #007020; font-weight: bold } /* Keyword.Constant */ | ||
1208 | 203 | .highlight .kd { color: #007020; font-weight: bold } /* Keyword.Declaration */ | ||
1209 | 204 | .highlight .kp { color: #007020 } /* Keyword.Pseudo */ | ||
1210 | 205 | .highlight .kr { color: #007020; font-weight: bold } /* Keyword.Reserved */ | ||
1211 | 206 | .highlight .kt { color: #007020; font-weight: bold } /* Keyword.Type */ | ||
1212 | 207 | .highlight .m { color: #40a070 } /* Literal.Number */ | ||
1213 | 208 | .highlight .s { color: #4070a0 } /* Literal.String */ | ||
1214 | 209 | .highlight .na { color: #4070a0 } /* Name.Attribute */ | ||
1215 | 210 | .highlight .nb { color: #007020 } /* Name.Builtin */ | ||
1216 | 211 | .highlight .nc { color: #0e84b5; font-weight: bold } /* Name.Class */ | ||
1217 | 212 | .highlight .no { color: #60add5 } /* Name.Constant */ | ||
1218 | 213 | .highlight .nd { color: #555555; font-weight: bold } /* Name.Decorator */ | ||
1219 | 214 | .highlight .ni { color: #d55537; font-weight: bold } /* Name.Entity */ | ||
1220 | 215 | .highlight .ne { color: #007020 } /* Name.Exception */ | ||
1221 | 216 | .highlight .nf { color: #06287e } /* Name.Function */ | ||
1222 | 217 | .highlight .nl { color: #002070; font-weight: bold } /* Name.Label */ | ||
1223 | 218 | .highlight .nn { color: #0e84b5; font-weight: bold } /* Name.Namespace */ | ||
1224 | 219 | .highlight .nt { color: #062873; font-weight: bold } /* Name.Tag */ | ||
1225 | 220 | .highlight .nv { color: #bb60d5 } /* Name.Variable */ | ||
1226 | 221 | .highlight .ow { color: #007020; font-weight: bold } /* Operator.Word */ | ||
1227 | 222 | .highlight .mf { color: #40a070 } /* Literal.Number.Float */ | ||
1228 | 223 | .highlight .mh { color: #40a070 } /* Literal.Number.Hex */ | ||
1229 | 224 | .highlight .mi { color: #40a070 } /* Literal.Number.Integer */ | ||
1230 | 225 | .highlight .mo { color: #40a070 } /* Literal.Number.Oct */ | ||
1231 | 226 | .highlight .sb { color: #4070a0 } /* Literal.String.Backtick */ | ||
1232 | 227 | .highlight .sc { color: #4070a0 } /* Literal.String.Char */ | ||
1233 | 228 | .highlight .sd { color: #4070a0; font-style: italic } /* Literal.String.Doc */ | ||
1234 | 229 | .highlight .s2 { color: #4070a0 } /* Literal.String.Double */ | ||
1235 | 230 | .highlight .se { color: #4070a0; font-weight: bold } /* Literal.String.Escape */ | ||
1236 | 231 | .highlight .sh { color: #4070a0 } /* Literal.String.Heredoc */ | ||
1237 | 232 | .highlight .si { color: #70a0d0; font-style: italic } /* Literal.String.Interpol */ | ||
1238 | 233 | .highlight .sx { color: #c65d09 } /* Literal.String.Other */ | ||
1239 | 234 | .highlight .sr { color: #235388 } /* Literal.String.Regex */ | ||
1240 | 235 | .highlight .s1 { color: #4070a0 } /* Literal.String.Single */ | ||
1241 | 236 | .highlight .ss { color: #517918 } /* Literal.String.Symbol */ | ||
1242 | 237 | .highlight .bp { color: #007020 } /* Name.Builtin.Pseudo */ | ||
1243 | 238 | .highlight .vc { color: #bb60d5 } /* Name.Variable.Class */ | ||
1244 | 239 | .highlight .vg { color: #bb60d5 } /* Name.Variable.Global */ | ||
1245 | 240 | .highlight .vi { color: #bb60d5 } /* Name.Variable.Instance */ | ||
1246 | 241 | .highlight .il { color: #40a070 } /* Literal.Number.Integer.Long */ | ||
1247 | 242 | |||
1248 | 0 | 243 | ||
1249 | === added file 'jarmonbuild/yuidoc_template/assets/bg_hd.gif' | |||
1250 | 1 | Binary files jarmonbuild/yuidoc_template/assets/bg_hd.gif 1970-01-01 00:00:00 +0000 and jarmonbuild/yuidoc_template/assets/bg_hd.gif 2010-08-22 21:23:38 +0000 differ | 244 | Binary files jarmonbuild/yuidoc_template/assets/bg_hd.gif 1970-01-01 00:00:00 +0000 and jarmonbuild/yuidoc_template/assets/bg_hd.gif 2010-08-22 21:23:38 +0000 differ |
1251 | === added file 'jarmonbuild/yuidoc_template/assets/reset-fonts-grids-min.css' | |||
1252 | --- jarmonbuild/yuidoc_template/assets/reset-fonts-grids-min.css 1970-01-01 00:00:00 +0000 | |||
1253 | +++ jarmonbuild/yuidoc_template/assets/reset-fonts-grids-min.css 2010-08-22 21:23:38 +0000 | |||
1254 | @@ -0,0 +1,7 @@ | |||
1255 | 1 | /* | ||
1256 | 2 | Copyright (c) 2008, Yahoo! Inc. All rights reserved. | ||
1257 | 3 | Code licensed under the BSD License: | ||
1258 | 4 | http://developer.yahoo.net/yui/license.txt | ||
1259 | 5 | version: 2.6.0 | ||
1260 | 6 | */ | ||
1261 | 7 | html{color:#000;background:#FFF;}body,div,dl,dt,dd,ul,ol,li,h1,h2,h3,h4,h5,h6,pre,code,form,fieldset,legend,input,textarea,p,blockquote,th,td{margin:0;padding:0;}table{border-collapse:collapse;border-spacing:0;}fieldset,img{border:0;}address,caption,cite,code,dfn,em,strong,th,var{font-style:normal;font-weight:normal;}li{list-style:none;}caption,th{text-align:left;}h1,h2,h3,h4,h5,h6{font-size:100%;font-weight:normal;}q:before,q:after{content:'';}abbr,acronym{border:0;font-variant:normal;}sup{vertical-align:text-top;}sub{vertical-align:text-bottom;}input,textarea,select{font-family:inherit;font-size:inherit;font-weight:inherit;}input,textarea,select{*font-size:100%;}legend{color:#000;}del,ins{text-decoration:none;}body{font:13px/1.231 arial,helvetica,clean,sans-serif;*font-size:small;*font:x-small;}select,input,button,textarea{font:99% arial,helvetica,clean,sans-serif;}table{font-size:inherit;font:100%;}pre,code,kbd,samp,tt{font-family:monospace;*font-size:108%;line-height:100%;}body{text-align:center;}#ft{clear:both;}#doc,#doc2,#doc3,#doc4,.yui-t1,.yui-t2,.yui-t3,.yui-t4,.yui-t5,.yui-t6,.yui-t7{margin:auto;text-align:left;width:57.69em;*width:56.25em;min-width:750px;}#doc2{width:73.076em;*width:71.25em;}#doc3{margin:auto 10px;width:auto;}#doc4{width:74.923em;*width:73.05em;}.yui-b{position:relative;}.yui-b{_position:static;}#yui-main .yui-b{position:static;}#yui-main,.yui-g .yui-u .yui-g{width:100%;}{width:100%;}.yui-t1 #yui-main,.yui-t2 #yui-main,.yui-t3 #yui-main{float:right;margin-left:-25em;}.yui-t4 #yui-main,.yui-t5 #yui-main,.yui-t6 #yui-main{float:left;margin-right:-25em;}.yui-t1 .yui-b{float:left;width:12.30769em;*width:12.00em;}.yui-t1 #yui-main .yui-b{margin-left:13.30769em;*margin-left:13.05em;}.yui-t2 .yui-b{float:left;width:13.8461em;*width:13.50em;}.yui-t2 #yui-main .yui-b{margin-left:14.8461em;*margin-left:14.55em;}.yui-t3 .yui-b{float:left;width:23.0769em;*width:22.50em;}.yui-t3 #yui-main .yui-b{margin-left:24.0769em;*margin-left:23.62em;}.yui-t4 .yui-b{float:right;width:13.8456em;*width:13.50em;}.yui-t4 #yui-main .yui-b{margin-right:14.8456em;*margin-right:14.55em;}.yui-t5 .yui-b{float:right;width:18.4615em;*width:18.00em;}.yui-t5 #yui-main .yui-b{margin-right:19.4615em;*margin-right:19.125em;}.yui-t6 .yui-b{float:right;width:23.0769em;*width:22.50em;}.yui-t6 #yui-main .yui-b{margin-right:24.0769em;*margin-right:23.62em;}.yui-t7 #yui-main .yui-b{display:block;margin:0 0 1em 0;}#yui-main .yui-b{float:none;width:auto;}.yui-gb .yui-u,.yui-g .yui-gb .yui-u,.yui-gb .yui-g,.yui-gb .yui-gb,.yui-gb .yui-gc,.yui-gb .yui-gd,.yui-gb .yui-ge,.yui-gb .yui-gf,.yui-gc .yui-u,.yui-gc .yui-g,.yui-gd .yui-u{float:left;}.yui-g .yui-u,.yui-g .yui-g,.yui-g .yui-gb,.yui-g .yui-gc,.yui-g .yui-gd,.yui-g .yui-ge,.yui-g .yui-gf,.yui-gc .yui-u,.yui-gd .yui-g,.yui-g .yui-gc .yui-u,.yui-ge .yui-u,.yui-ge .yui-g,.yui-gf .yui-g,.yui-gf .yui-u{float:right;}.yui-g div.first,.yui-gb div.first,.yui-gc div.first,.yui-gd div.first,.yui-ge div.first,.yui-gf div.first,.yui-g .yui-gc div.first,.yui-g .yui-ge div.first,.yui-gc div.first div.first{float:left;}.yui-g .yui-u,.yui-g .yui-g,.yui-g .yui-gb,.yui-g .yui-gc,.yui-g .yui-gd,.yui-g .yui-ge,.yui-g .yui-gf{width:49.1%;}.yui-gb .yui-u,.yui-g .yui-gb .yui-u,.yui-gb .yui-g,.yui-gb .yui-gb,.yui-gb .yui-gc,.yui-gb .yui-gd,.yui-gb .yui-ge,.yui-gb .yui-gf,.yui-gc .yui-u,.yui-gc .yui-g,.yui-gd .yui-u{width:32%;margin-left:1.99%;}.yui-gb .yui-u{*margin-left:1.9%;*width:31.9%;}.yui-gc div.first,.yui-gd .yui-u{width:66%;}.yui-gd div.first{width:32%;}.yui-ge div.first,.yui-gf .yui-u{width:74.2%;}.yui-ge .yui-u,.yui-gf div.first{width:24%;}.yui-g .yui-gb div.first,.yui-gb div.first,.yui-gc div.first,.yui-gd div.first{margin-left:0;}.yui-g .yui-g .yui-u,.yui-gb .yui-g .yui-u,.yui-gc .yui-g .yui-u,.yui-gd .yui-g .yui-u,.yui-ge .yui-g .yui-u,.yui-gf .yui-g .yui-u{width:49%;*width:48.1%;*margin-left:0;}.yui-g .yui-g .yui-u{width:48.1%;}.yui-g .yui-gb div.first,.yui-gb .yui-gb div.first{*margin-right:0;*width:32%;_width:31.7%;}.yui-g .yui-gc div.first,.yui-gd .yui-g{width:66%;}.yui-gb .yui-g div.first{*margin-right:4%;_margin-right:1.3%;}.yui-gb .yui-gc div.first,.yui-gb .yui-gd div.first{*margin-right:0;}.yui-gb .yui-gb .yui-u,.yui-gb .yui-gc .yui-u{*margin-left:1.8%;_margin-left:4%;}.yui-g .yui-gb .yui-u{_margin-left:1.0%;}.yui-gb .yui-gd .yui-u{*width:66%;_width:61.2%;}.yui-gb .yui-gd div.first{*width:31%;_width:29.5%;}.yui-g .yui-gc .yui-u,.yui-gb .yui-gc .yui-u{width:32%;_float:right;margin-right:0;_margin-left:0;}.yui-gb .yui-gc div.first{width:66%;*float:left;*margin-left:0;}.yui-gb .yui-ge .yui-u,.yui-gb .yui-gf .yui-u{margin:0;}.yui-gb .yui-gb .yui-u{_margin-left:.7%;}.yui-gb .yui-g div.first,.yui-gb .yui-gb div.first{*margin-left:0;}.yui-gc .yui-g .yui-u,.yui-gd .yui-g .yui-u{*width:48.1%;*margin-left:0;} .yui-gb .yui-gd div.first{width:32%;}.yui-g .yui-gd div.first{_width:29.9%;}.yui-ge .yui-g{width:24%;}.yui-gf .yui-g{width:74.2%;}.yui-gb .yui-ge div.yui-u,.yui-gb .yui-gf div.yui-u{float:right;}.yui-gb .yui-ge div.first,.yui-gb .yui-gf div.first{float:left;}.yui-gb .yui-ge .yui-u,.yui-gb .yui-gf div.first{*width:24%;_width:20%;}.yui-gb .yui-ge div.first,.yui-gb .yui-gf .yui-u{*width:73.5%;_width:65.5%;}.yui-ge div.first .yui-gd .yui-u{width:65%;}.yui-ge div.first .yui-gd div.first{width:32%;}#bd:after,.yui-g:after,.yui-gb:after,.yui-gc:after,.yui-gd:after,.yui-ge:after,.yui-gf:after{content:".";display:block;height:0;clear:both;visibility:hidden;}#bd,.yui-g,.yui-gb,.yui-gc,.yui-gd,.yui-ge,.yui-gf{zoom:1;} | ||
1262 | 0 | 8 | ||
1263 | === added file 'jarmonbuild/yuidoc_template/classmap.tmpl' | |||
1264 | --- jarmonbuild/yuidoc_template/classmap.tmpl 1970-01-01 00:00:00 +0000 | |||
1265 | +++ jarmonbuild/yuidoc_template/classmap.tmpl 2010-08-22 21:23:38 +0000 | |||
1266 | @@ -0,0 +1,15 @@ | |||
1267 | 1 | YAHOO.env.classMap = ${pkgmap}; | ||
1268 | 2 | |||
1269 | 3 | YAHOO.env.resolveClass = function(className) { | ||
1270 | 4 | var a=className.split('.'), ns=YAHOO.env.classMap; | ||
1271 | 5 | |||
1272 | 6 | for (var i=0; i<a.length; i=i+1) { | ||
1273 | 7 | if (ns[a[i]]) { | ||
1274 | 8 | ns = ns[a[i]]; | ||
1275 | 9 | } else { | ||
1276 | 10 | return null; | ||
1277 | 11 | } | ||
1278 | 12 | } | ||
1279 | 13 | |||
1280 | 14 | return ns; | ||
1281 | 15 | }; | ||
1282 | 0 | 16 | ||
1283 | === added file 'jarmonbuild/yuidoc_template/index.tmpl' | |||
1284 | --- jarmonbuild/yuidoc_template/index.tmpl 1970-01-01 00:00:00 +0000 | |||
1285 | +++ jarmonbuild/yuidoc_template/index.tmpl 2010-08-22 21:23:38 +0000 | |||
1286 | @@ -0,0 +1,9 @@ | |||
1287 | 1 | <html> | ||
1288 | 2 | <head> | ||
1289 | 3 | <script type="text/javascript"> | ||
1290 | 4 | document.location.replace("${cleansedmodulename}.html"); | ||
1291 | 5 | </script> | ||
1292 | 6 | </head> | ||
1293 | 7 | <body> | ||
1294 | 8 | </body> | ||
1295 | 9 | </html> | ||
1296 | 0 | 10 | ||
1297 | === added file 'jarmonbuild/yuidoc_template/main.tmpl' | |||
1298 | --- jarmonbuild/yuidoc_template/main.tmpl 1970-01-01 00:00:00 +0000 | |||
1299 | +++ jarmonbuild/yuidoc_template/main.tmpl 2010-08-22 21:23:38 +0000 | |||
1300 | @@ -0,0 +1,685 @@ | |||
1301 | 1 | #encoding UTF-8 | ||
1302 | 2 | #filter EncodeUnicode | ||
1303 | 3 | <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> | ||
1304 | 4 | <html xmlns:yui="http://yuilibrary.com/rdf/1.0/yui.rdf#"> | ||
1305 | 5 | <head> | ||
1306 | 6 | <meta http-equiv="content-type" content="text/html; charset=UTF-8" /> | ||
1307 | 7 | <title>API: $modulename #if $classname# $classname #end if# #if $filename# $filename #end if#</title> | ||
1308 | 8 | |||
1309 | 9 | <link rel="stylesheet" type="text/css" href="assets/reset-fonts-grids-min.css" /> | ||
1310 | 10 | <link rel="stylesheet" type="text/css" href="assets/api.css" /> | ||
1311 | 11 | |||
1312 | 12 | <script type="text/javascript" src="assets/api-js"></script> | ||
1313 | 13 | <script type="text/javascript" src="assets/ac-js"></script> | ||
1314 | 14 | </head> | ||
1315 | 15 | |||
1316 | 16 | <body id="yahoo-com"> | ||
1317 | 17 | |||
1318 | 18 | <div id="doc3" class="yui-t2"> | ||
1319 | 19 | <div id="hd"> | ||
1320 | 20 | <h1><a href="$projecturl" title="$projectname">$projectname v$version API Documentation</a></h1> | ||
1321 | 21 | <h3>$moduletitle <span class="subtitle">$version</span></h3> | ||
1322 | 22 | <a href="./index.html" title="$projectname">$projectname</a> | ||
1323 | 23 | #if $modulename | ||
1324 | 24 | > <a href="./${cleansedmodulename}.html" title="$modulename">$modulename</a> | ||
1325 | 25 | #if $classname# > $classname #end if# | ||
1326 | 26 | #if $filename# > $filename (source view) #end if# | ||
1327 | 27 | #end if | ||
1328 | 28 | <form onsubmit="return false"> | ||
1329 | 29 | <div id="propertysearch"> | ||
1330 | 30 | Search: <input autocomplete="off" id="searchinput" /> | ||
1331 | 31 | <div id="searchresults"> | ||
1332 | 32 | | ||
1333 | 33 | </div> | ||
1334 | 34 | </div> | ||
1335 | 35 | </form> | ||
1336 | 36 | </div> | ||
1337 | 37 | |||
1338 | 38 | <div id="bd"> | ||
1339 | 39 | <div id="yui-main"> | ||
1340 | 40 | <div class="yui-b"> | ||
1341 | 41 | <form action="#" name="yui-classopts-form" method="get" id="yui-classopts-form"> | ||
1342 | 42 | <fieldset> | ||
1343 | 43 | <legend>Filters</legend> | ||
1344 | 44 | <span class="classopts"><input type="checkbox" name="show_private" id="show_private" /> <label for="show_private">Show Private</label></span> | ||
1345 | 45 | <span class="classopts"><input type="checkbox" name="show_protected" id="show_protected" /> <label for="show_protected">Show Protected</label></span> | ||
1346 | 46 | <span class="classopts"><input type="checkbox" name="show_deprecated" id="show_deprecated" /> <label for="show_deprecated">Show Deprecated</label></span> | ||
1347 | 47 | </fieldset> | ||
1348 | 48 | </form> | ||
1349 | 49 | #if $index | ||
1350 | 50 | |||
1351 | 51 | <div class="summary description"> | ||
1352 | 52 | This is the API documentation for | ||
1353 | 53 | <a href="$projecturl">$projectname</a>. | ||
1354 | 54 | <p>Choose a module name from the list for more information.</p> | ||
1355 | 55 | </div> | ||
1356 | 56 | |||
1357 | 57 | #end if | ||
1358 | 58 | |||
1359 | 59 | #if $filename | ||
1360 | 60 | <div id="srcout"> | ||
1361 | 61 | <style> | ||
1362 | 62 | #doc3 .classopts { display:none; } | ||
1363 | 63 | </style> | ||
1364 | 64 | #include raw $filepath_highlighted | ||
1365 | 65 | </div> | ||
1366 | 66 | #else if $classname | ||
1367 | 67 | <h2> | ||
1368 | 68 | #if $access#<code>$access</code>#end if# | ||
1369 | 69 | |||
1370 | 70 | #if $static#<code>$static</code>#end if# | ||
1371 | 71 | #if $final#<code>$final</code>#end if# | ||
1372 | 72 | Class <b property="yui:name">$classname</b> | ||
1373 | 73 | <span class="extends"> | ||
1374 | 74 | #if $extends | ||
1375 | 75 | - extends <a href="${extends}.html" title="$extends">$extends</a> | ||
1376 | 76 | #end if | ||
1377 | 77 | </span> | ||
1378 | 78 | |||
1379 | 79 | #if $uses | ||
1380 | 80 | <span class="extends" rel="yui:extends"> | ||
1381 | 81 | - uses | ||
1382 | 82 | #set $i=0 | ||
1383 | 83 | #for $provider in $uses##if $i > 0#, #end if# | ||
1384 | 84 | <span rel="extend" resource="${provider}.html"> | ||
1385 | 85 | <a href="${provider}.html" property="yui:name" title="$provider">$provider</a>#set $i=$i+1# | ||
1386 | 86 | </span> | ||
1387 | 87 | #end for# | ||
1388 | 88 | |||
1389 | 89 | </span> | ||
1390 | 90 | #end if | ||
1391 | 91 | </h2> | ||
1392 | 92 | <!-- class tree goes here --> | ||
1393 | 93 | |||
1394 | 94 | #if $subclasses | ||
1395 | 95 | <dl class="subclasses" rel="yui:subclasses"> | ||
1396 | 96 | <dt>Known Subclasses:</dt> | ||
1397 | 97 | <dd> | ||
1398 | 98 | #for $subclass in $subclasses | ||
1399 | 99 | <span rel="yui:subclass" resource="${subclass}.html"> | ||
1400 | 100 | <a href="${subclass}.html" property="yui:name" title="$subclass">$subclass</a> | ||
1401 | 101 | </span> | ||
1402 | 102 | #end for | ||
1403 | 103 | </dd> | ||
1404 | 104 | </dl> | ||
1405 | 105 | #end if | ||
1406 | 106 | |||
1407 | 107 | #if $deprecated | ||
1408 | 108 | <div class="deprecated"><strong>Deprecated:</strong> $deprecated</div> | ||
1409 | 109 | #end if | ||
1410 | 110 | |||
1411 | 111 | #if $see | ||
1412 | 112 | <div class="deprecated"><strong>See also:</strong> $see</div> | ||
1413 | 113 | #end if | ||
1414 | 114 | |||
1415 | 115 | <div class="summary description" property="yui:description"> | ||
1416 | 116 | $description | ||
1417 | 117 | </div> | ||
1418 | 118 | |||
1419 | 119 | #if $constructor | ||
1420 | 120 | <div class="section constructor details" rel="yui:constructor" resource="#constructor"> | ||
1421 | 121 | <h3 id="constructor">Constructor</h3> | ||
1422 | 122 | <div class="content"> | ||
1423 | 123 | <div class="detail"> | ||
1424 | 124 | <strong property="yui:name">$classname</strong> | ||
1425 | 125 | <code> | ||
1426 | 126 | ( | ||
1427 | 127 | #if $constructor.params | ||
1428 | 128 | #set $i=0 | ||
1429 | 129 | #set $current="" | ||
1430 | 130 | |||
1431 | 131 | #for $param in $constructor.params# | ||
1432 | 132 | #if $current != $param.name | ||
1433 | 133 | #if $i > 0#, #end if# | ||
1434 | 134 | #set $i = $i + 1 | ||
1435 | 135 | #set $current = $param.name | ||
1436 | 136 | $param.name | ||
1437 | 137 | #end if | ||
1438 | 138 | #end for | ||
1439 | 139 | #end if | ||
1440 | 140 | ) | ||
1441 | 141 | </code> | ||
1442 | 142 | <div class="description"> | ||
1443 | 143 | #if $constructor.params | ||
1444 | 144 | <dl rel="yui:parameters"> | ||
1445 | 145 | <dt>Parameters:</dt> | ||
1446 | 146 | #for $param in $constructor.params | ||
1447 | 147 | <dd rel="yui:parameter"> | ||
1448 | 148 | <code><span property="yui:name">$param.name</span> | ||
1449 | 149 | <<span property="yui:type">$param.type</span>> | ||
1450 | 150 | </code> | ||
1451 | 151 | <span property="yui:description">$param.description</span> | ||
1452 | 152 | </dd> | ||
1453 | 153 | #end for | ||
1454 | 154 | </dl> | ||
1455 | 155 | #end if | ||
1456 | 156 | |||
1457 | 157 | #if $constructor.return | ||
1458 | 158 | <dl> | ||
1459 | 159 | <dt>Returns:</dt> | ||
1460 | 160 | <dd property="yui:return"> | ||
1461 | 161 | $constructor.return | ||
1462 | 162 | </dd> | ||
1463 | 163 | </dl> | ||
1464 | 164 | #end if | ||
1465 | 165 | |||
1466 | 166 | </div> | ||
1467 | 167 | </div> | ||
1468 | 168 | </div> | ||
1469 | 169 | </div> | ||
1470 | 170 | #end if | ||
1471 | 171 | |||
1472 | 172 | <div rel="yui:properties" resource="#properties"> | ||
1473 | 173 | #if $properties | ||
1474 | 174 | <div class="section field details"> | ||
1475 | 175 | <h3 id="properties">Properties</h3> | ||
1476 | 176 | <div class="content"> | ||
1477 | 177 | #for $property in $properties | ||
1478 | 178 | <div class="$property.access#if $property.deprecated# deprecated#end if#" rel="yui:property" resource="#property_$property.name"> | ||
1479 | 179 | <h4><a name="property_$property.name" property="yui:name">$property.name</a> | ||
1480 | 180 | - <code>#if $property.access#$property.access #end if##if $property.static#$property.static #end if##if $property.final#$property.final #end if#<span property="yui:type">$property.type</span></code> | ||
1481 | 181 | </h4> | ||
1482 | 182 | <div class="detail"> | ||
1483 | 183 | <div class="description" property="yui:description"> | ||
1484 | 184 | $property.description | ||
1485 | 185 | </div> | ||
1486 | 186 | </div> | ||
1487 | 187 | |||
1488 | 188 | |||
1489 | 189 | #if $property.default | ||
1490 | 190 | <div class="default" property="yui:defaultValue"> | ||
1491 | 191 | Default Value: $property.default | ||
1492 | 192 | </div> | ||
1493 | 193 | #end if | ||
1494 | 194 | |||
1495 | 195 | #if $property.deprecated | ||
1496 | 196 | <div class="deprecated" property="yui:deprecated"> | ||
1497 | 197 | <strong>Deprecated:</strong> $property.deprecated | ||
1498 | 198 | </div> | ||
1499 | 199 | #end if | ||
1500 | 200 | |||
1501 | 201 | <hr /> | ||
1502 | 202 | </div> | ||
1503 | 203 | #end for | ||
1504 | 204 | </div> | ||
1505 | 205 | </div> | ||
1506 | 206 | #end if | ||
1507 | 207 | |||
1508 | 208 | #if $inherited.properties | ||
1509 | 209 | <div rel="yui:inheritance"> | ||
1510 | 210 | #for $superclassname in $inherited.properties | ||
1511 | 211 | <div class="section field inheritance" rel="yui:superclass" resource="${superclassname}.html"> | ||
1512 | 212 | <h4>Properties inherited from <a href="${superclassname}.html" property="yui:name" title="$superclassname">$superclassname</a>:</h4> | ||
1513 | 213 | <div class="content" rel="yui:properties"> | ||
1514 | 214 | <code> | ||
1515 | 215 | #set i=0 | ||
1516 | 216 | #set l=len($inherited.properties[$superclassname])-1 | ||
1517 | 217 | #for $prop in $inherited.properties[$superclassname]# | ||
1518 | 218 | <span rel="yui:property" resource="${superclassname}.html#property_$prop.name"> | ||
1519 | 219 | <a class="$prop.access#if $prop.deprecated# deprecated#end if#" href="${superclassname}.html#property_$prop.name" property="yui:name" title="$prop.name">$prop.name</a>#if $i<$l#<span class="$prop.access#if $prop.deprecated# deprecated#end if#">,</span>#end if# | ||
1520 | 220 | </span> | ||
1521 | 221 | #set i=i+1 | ||
1522 | 222 | #end for# | ||
1523 | 223 | </code> | ||
1524 | 224 | </div> | ||
1525 | 225 | </div> | ||
1526 | 226 | #end for | ||
1527 | 227 | </div> | ||
1528 | 228 | #end if | ||
1529 | 229 | </div> | ||
1530 | 230 | |||
1531 | 231 | <div rel="yui:methods" resource="#methods"> | ||
1532 | 232 | #if $methods | ||
1533 | 233 | <div class="section method details"> | ||
1534 | 234 | <h3 id="methods">Methods</h3> | ||
1535 | 235 | <div class="content"> | ||
1536 | 236 | #for $method in $methods | ||
1537 | 237 | <div class="$method.access#if $method.deprecated# deprecated#end if#" rel="yui:method" resource="#method_$method.name"> | ||
1538 | 238 | <h4> | ||
1539 | 239 | <a name="method_$method.name">$method.name</a></h4> | ||
1540 | 240 | <div class="detail" > | ||
1541 | 241 | <code> | ||
1542 | 242 | #if $method.access# $method.access #end if# | ||
1543 | 243 | #if $method.static# $method.static #end if# | ||
1544 | 244 | #if $method.final# $method.final #end if# | ||
1545 | 245 | $method.return.type | ||
1546 | 246 | <strong property="yui:name">$method.name</strong> | ||
1547 | 247 | ( | ||
1548 | 248 | #if $method.params | ||
1549 | 249 | #set $i=0 | ||
1550 | 250 | #set $current = "" | ||
1551 | 251 | #for $param in $method.params# | ||
1552 | 252 | #if $current != $param.name | ||
1553 | 253 | #if $i > 0#, #end if# | ||
1554 | 254 | #set $i = $i + 1 | ||
1555 | 255 | #set $current = $param.name | ||
1556 | 256 | $param.name | ||
1557 | 257 | #end if# | ||
1558 | 258 | #end for# | ||
1559 | 259 | #end if | ||
1560 | 260 | ) | ||
1561 | 261 | </code> | ||
1562 | 262 | |||
1563 | 263 | <div class="description" property="yui:description"> | ||
1564 | 264 | $method.description | ||
1565 | 265 | </div> | ||
1566 | 266 | |||
1567 | 267 | <div class="description"> | ||
1568 | 268 | |||
1569 | 269 | #if $method.params | ||
1570 | 270 | <dl rel="yui:parameters"> | ||
1571 | 271 | <dt>Parameters:</dt> | ||
1572 | 272 | #for $param in $method.params | ||
1573 | 273 | <dd rel="yui:parameter"> | ||
1574 | 274 | <code><span property="yui:name">$param.name</span> | ||
1575 | 275 | <<span property="yui:type">$param.type</span>> | ||
1576 | 276 | </code> | ||
1577 | 277 | <span property="yui:description">$param.description</span> | ||
1578 | 278 | </dd> | ||
1579 | 279 | #end for | ||
1580 | 280 | </dl> | ||
1581 | 281 | #end if | ||
1582 | 282 | |||
1583 | 283 | #if $method.return.type | ||
1584 | 284 | <dl> | ||
1585 | 285 | <dt>Returns: | ||
1586 | 286 | <code property="yui:return"> | ||
1587 | 287 | $method.return.type | ||
1588 | 288 | </code></dt> | ||
1589 | 289 | <dd property="yui:returnInfo">$method.return.description</dd> | ||
1590 | 290 | </dl> | ||
1591 | 291 | #end if | ||
1592 | 292 | |||
1593 | 293 | #if $method.chainable | ||
1594 | 294 | <div class="chainable"> | ||
1595 | 295 | <strong>Chainable:</strong> This method is chainable. | ||
1596 | 296 | </div> | ||
1597 | 297 | #end if | ||
1598 | 298 | |||
1599 | 299 | |||
1600 | 300 | #if $method.deprecated | ||
1601 | 301 | <div class="deprecated"> | ||
1602 | 302 | <strong>Deprecated</strong> $method.deprecated | ||
1603 | 303 | </div> | ||
1604 | 304 | #end if | ||
1605 | 305 | |||
1606 | 306 | </div> | ||
1607 | 307 | |||
1608 | 308 | </div> | ||
1609 | 309 | <hr /> | ||
1610 | 310 | </div> | ||
1611 | 311 | #end for | ||
1612 | 312 | </div> | ||
1613 | 313 | </div> | ||
1614 | 314 | #end if | ||
1615 | 315 | |||
1616 | 316 | #if $inherited.methods | ||
1617 | 317 | <div rel="yui:inheritance"> | ||
1618 | 318 | #for $superclassname in $inherited.methods | ||
1619 | 319 | <div class="section field inheritance" rel="yui:superclass" resource="${superclassname}.html"> | ||
1620 | 320 | <h4>Methods inherited from <a href="${superclassname}.html" property="yui:name" title="$superclassname">$superclassname</a>:</h4> | ||
1621 | 321 | <div class="content" rel="yui:methods"> | ||
1622 | 322 | <code> | ||
1623 | 323 | #set i=0 | ||
1624 | 324 | #set l=len($inherited.methods[$superclassname])-1 | ||
1625 | 325 | #for $method in $inherited.methods[$superclassname] | ||
1626 | 326 | <span rel="yui:method" resource="${superclassname}.html#method_$method.name"> | ||
1627 | 327 | <a class="$method.access#if $method.deprecated# deprecated#end if#" href="${superclassname}.html#method_$method.name" property="yui:name" title="$method.name">$method.name</a>#if $i<$l#<span class="$method.access#if $method.deprecated# deprecated#end if#">,</span>#end if# | ||
1628 | 328 | </span> | ||
1629 | 329 | #set i=i+1 | ||
1630 | 330 | #end for | ||
1631 | 331 | </code> | ||
1632 | 332 | </div> | ||
1633 | 333 | </div> | ||
1634 | 334 | #end for | ||
1635 | 335 | </div> | ||
1636 | 336 | #end if | ||
1637 | 337 | </div> | ||
1638 | 338 | |||
1639 | 339 | <div rel="yui:events" resource="#events"> | ||
1640 | 340 | #if $events | ||
1641 | 341 | <div class="section method details"> | ||
1642 | 342 | <h3 id="events">Events</h3> | ||
1643 | 343 | <div class="content"> | ||
1644 | 344 | #for $event in $events | ||
1645 | 345 | <div class="$event.access#if $event.deprecated# deprecated#end if#" rel="yui:event" resource="#event_$event.name"> | ||
1646 | 346 | <h4> | ||
1647 | 347 | <a name="event_$event.name">$event.name</a></h4> | ||
1648 | 348 | <div class="detail"> | ||
1649 | 349 | <code> | ||
1650 | 350 | #if $event.access# $event.access #end if# | ||
1651 | 351 | #if $event.static# $event.static #end if# | ||
1652 | 352 | #if $event.final# $event.final #end if# | ||
1653 | 353 | <strong property="yui:name">$event.name</strong> | ||
1654 | 354 | |||
1655 | 355 | ( | ||
1656 | 356 | #if $event.params | ||
1657 | 357 | #set $i=0 | ||
1658 | 358 | #set $current = "" | ||
1659 | 359 | #for $param in $event.params# | ||
1660 | 360 | #if $current != $param.name | ||
1661 | 361 | #if $i > 0#, #end if# | ||
1662 | 362 | #set $i = $i + 1 | ||
1663 | 363 | #set $current = $param.name | ||
1664 | 364 | $param.name | ||
1665 | 365 | #end if# | ||
1666 | 366 | #end for# | ||
1667 | 367 | #end if | ||
1668 | 368 | ) | ||
1669 | 369 | |||
1670 | 370 | </code> | ||
1671 | 371 | |||
1672 | 372 | <div class="description" property="yui:description"> | ||
1673 | 373 | $event.description | ||
1674 | 374 | </div> | ||
1675 | 375 | |||
1676 | 376 | <div class="description"> | ||
1677 | 377 | |||
1678 | 378 | |||
1679 | 379 | #if $event.params | ||
1680 | 380 | <dl rel="yui:parameters"> | ||
1681 | 381 | <dt>Parameters:</dt> | ||
1682 | 382 | #for $param in $event.params | ||
1683 | 383 | <dd rel="yui:parameter"> | ||
1684 | 384 | <code><span property="yui:name">$param.name</span> | ||
1685 | 385 | <<span property="yui:type">$param.type</span>> | ||
1686 | 386 | </code> | ||
1687 | 387 | <span property="yui:description">$param.description</span> | ||
1688 | 388 | </dd> | ||
1689 | 389 | |||
1690 | 390 | #end for | ||
1691 | 391 | </dl> | ||
1692 | 392 | #end if | ||
1693 | 393 | |||
1694 | 394 | #if $event.bubbles | ||
1695 | 395 | <div class="bubbles"> | ||
1696 | 396 | <strong>Bubbles:</strong> This event bubbles to <a href="${event.bubbles}.html" title="$event.bubbles">$event.bubbles</a>. | ||
1697 | 397 | </div> | ||
1698 | 398 | #end if | ||
1699 | 399 | #if $event.preventable | ||
1700 | 400 | <div class="preventable"> | ||
1701 | 401 | <strong>Preventable:</strong> This event is preventable by method: $event.preventable. | ||
1702 | 402 | </div> | ||
1703 | 403 | #end if | ||
1704 | 404 | |||
1705 | 405 | #if $event.deprecated | ||
1706 | 406 | <div class="deprecated"> | ||
1707 | 407 | <strong>Deprecated</strong> $event.deprecated | ||
1708 | 408 | </div> | ||
1709 | 409 | #end if | ||
1710 | 410 | </div> | ||
1711 | 411 | |||
1712 | 412 | </div> | ||
1713 | 413 | <hr /> | ||
1714 | 414 | </div> | ||
1715 | 415 | #end for | ||
1716 | 416 | </div> | ||
1717 | 417 | </div> | ||
1718 | 418 | #end if | ||
1719 | 419 | |||
1720 | 420 | |||
1721 | 421 | #if $inherited.events | ||
1722 | 422 | <div rel="yui:inheritance"> | ||
1723 | 423 | #for $superclassname in $inherited.events | ||
1724 | 424 | <div class="section field inheritance" rel="yui:superclass" resource="${superclassname}.html"> | ||
1725 | 425 | <h4>Events inherited from <a href="${superclassname}.html" property="yui:name" title="$superclassname">$superclassname</a>:</h4> | ||
1726 | 426 | <div class="content" rel="yui:events"> | ||
1727 | 427 | <code> | ||
1728 | 428 | #set i=0 | ||
1729 | 429 | #set l=len($inherited.methods[$superclassname])-1 | ||
1730 | 430 | #for $event in $inherited.events[$superclassname] | ||
1731 | 431 | #set i=i+1 | ||
1732 | 432 | <span rel="yui:event" resource="${superclassname}.html#event_$event.name"> | ||
1733 | 433 | <a class="$event.access#if $event.deprecated# deprecated#end if#" href="${superclassname}.html#event_$event.name" property="yui:name" title="$event.name">$event.name</a>#if $i<$l#<span class="$event.access#if $event.deprecated# deprecated#end if#">,</span>#end if##set i=i+1# | ||
1734 | 434 | </span> | ||
1735 | 435 | #end for# | ||
1736 | 436 | </code> | ||
1737 | 437 | </div> | ||
1738 | 438 | </div> | ||
1739 | 439 | #end for | ||
1740 | 440 | </div> | ||
1741 | 441 | #end if | ||
1742 | 442 | </div> | ||
1743 | 443 | |||
1744 | 444 | <div rel="yui:attributes" resource="#configattributes"> | ||
1745 | 445 | #if $configs | ||
1746 | 446 | <div class="section field details"> | ||
1747 | 447 | <h3 id="configattributes">Configuration Attributes</h3> | ||
1748 | 448 | <div class="content"> | ||
1749 | 449 | #for $config in $configs | ||
1750 | 450 | <div class="$config.access#if $config.deprecated# deprecated#end if#" rel="yui:attribute" resource="#config_$config.name"> | ||
1751 | 451 | <h4><a name="config_$config.name">$config.name</a> | ||
1752 | 452 | <code>- #if $config.access#$config.access #end if##if $config.static#$config.static #end if##if $config.writeonce#$config.writeonce #end if##if $config.final#$config.final #end if#<span property="yui:type">$config.type</span></code> | ||
1753 | 453 | </h4> | ||
1754 | 454 | <div class="detail"> | ||
1755 | 455 | <div class="description" property="yui:description"> | ||
1756 | 456 | $config.description | ||
1757 | 457 | </div> | ||
1758 | 458 | </div> | ||
1759 | 459 | |||
1760 | 460 | #if $config.deprecated | ||
1761 | 461 | <div class="deprecated"> | ||
1762 | 462 | <strong>Deprecated</strong> $config.deprecated | ||
1763 | 463 | </div> | ||
1764 | 464 | #end if | ||
1765 | 465 | |||
1766 | 466 | #if $config.default | ||
1767 | 467 | <div class="default"> | ||
1768 | 468 | Default Value: $config.default | ||
1769 | 469 | </div> | ||
1770 | 470 | #end if | ||
1771 | 471 | |||
1772 | 472 | <hr /> | ||
1773 | 473 | </div> | ||
1774 | 474 | #end for | ||
1775 | 475 | |||
1776 | 476 | </div> | ||
1777 | 477 | </div> | ||
1778 | 478 | #end if | ||
1779 | 479 | |||
1780 | 480 | #if $inherited.configs | ||
1781 | 481 | <div rel="yui:inheritance"> | ||
1782 | 482 | #for $superclassname in $inherited.configs | ||
1783 | 483 | <div class="section field inheritance" rel="yui:superclass" resource="${superclassname}.html"> | ||
1784 | 484 | <h4>Configuration attributes inherited from <a href="${superclassname}.html" property="yui:name" title="$superclassname">$superclassname</a>:</h4> | ||
1785 | 485 | <div class="content" rel="yui:attributes"> | ||
1786 | 486 | <code> | ||
1787 | 487 | #set i=0 | ||
1788 | 488 | #set l=len($inherited.methods[$superclassname])-1 | ||
1789 | 489 | #for $config in $inherited.configs[$superclassname] | ||
1790 | 490 | #set i=i+1 | ||
1791 | 491 | <span rel="yui:attribute" resource="${superclassname}.html#config_$config.name"> | ||
1792 | 492 | <a class="$config.access#if $config.deprecated# deprecated#end if#" href="${superclassname}.html#config_$config.name" property="yui:name" title="$config.name">$config.name</a>#if $i<$l#<span class="$config.access#if $config.deprecated# deprecated#end if#">,</span>#end if# | ||
1793 | 493 | </span> | ||
1794 | 494 | #set i=i+1 | ||
1795 | 495 | #end for# | ||
1796 | 496 | </code> | ||
1797 | 497 | </div> | ||
1798 | 498 | </div> | ||
1799 | 499 | #end for | ||
1800 | 500 | </div> | ||
1801 | 501 | #end if | ||
1802 | 502 | </div> | ||
1803 | 503 | |||
1804 | 504 | #else if $modulename | ||
1805 | 505 | |||
1806 | 506 | <h3>Module: $modulename | ||
1807 | 507 | |||
1808 | 508 | #if $beta | ||
1809 | 509 | <span class="description"><em>Beta</em></span> | ||
1810 | 510 | #end if | ||
1811 | 511 | |||
1812 | 512 | #if $experimental | ||
1813 | 513 | <span class="description"><em>Experimental</em></span> | ||
1814 | 514 | #end if | ||
1815 | 515 | |||
1816 | 516 | </h3> | ||
1817 | 517 | <div class="description summary"> | ||
1818 | 518 | $moduledesc | ||
1819 | 519 | </div> | ||
1820 | 520 | |||
1821 | 521 | |||
1822 | 522 | #if $requires | ||
1823 | 523 | <div class="content"> | ||
1824 | 524 | Requires: $requires | ||
1825 | 525 | </div> | ||
1826 | 526 | #end if | ||
1827 | 527 | #if $optional | ||
1828 | 528 | <div class="content"> | ||
1829 | 529 | Optional: $optional | ||
1830 | 530 | </div> | ||
1831 | 531 | #end if | ||
1832 | 532 | |||
1833 | 533 | <div class="yui-gc"> | ||
1834 | 534 | <div class="yui-u first"> | ||
1835 | 535 | |||
1836 | 536 | #if $classnames | ||
1837 | 537 | <p>This module contains the following classes:</p> | ||
1838 | 538 | <script> | ||
1839 | 539 | //var YUI_CLASS_LIST = $classList; | ||
1840 | 540 | </script> | ||
1841 | 541 | <div id="splash_classList"> | ||
1842 | 542 | <ul> | ||
1843 | 543 | #set $counter = 0 | ||
1844 | 544 | #for $classNames in $classList_raw | ||
1845 | 545 | <li><a href="${classNames.name}.html" title="$classNames.name" id="class_${counter}">$classNames.guessedname</a></li> | ||
1846 | 546 | #set $counter = $counter + 1 | ||
1847 | 547 | #end for | ||
1848 | 548 | </ul> | ||
1849 | 549 | </div> | ||
1850 | 550 | #end if | ||
1851 | 551 | </div> | ||
1852 | 552 | <div class="yui-u"> | ||
1853 | 553 | #set count = 0; | ||
1854 | 554 | #for $info in $submodules | ||
1855 | 555 | #set count = count + 1 | ||
1856 | 556 | #end for | ||
1857 | 557 | #if count != 0 | ||
1858 | 558 | <div class="submodules"> | ||
1859 | 559 | <h4>Submodules:</h4> | ||
1860 | 560 | <dl> | ||
1861 | 561 | #for $info in $submodules | ||
1862 | 562 | <dt><code><a href="${$subdata[$info].name}.html" title="$info">$info</a></code></dt> | ||
1863 | 563 | <dd>$subdata[$info].description</dd> | ||
1864 | 564 | #end for | ||
1865 | 565 | </dl> | ||
1866 | 566 | </div> | ||
1867 | 567 | #end if | ||
1868 | 568 | |||
1869 | 569 | </div> | ||
1870 | 570 | </div> | ||
1871 | 571 | |||
1872 | 572 | #end if | ||
1873 | 573 | </div> | ||
1874 | 574 | </div> | ||
1875 | 575 | <div class="yui-b"> | ||
1876 | 576 | <div class="nav"> | ||
1877 | 577 | |||
1878 | 578 | #if $modulenames | ||
1879 | 579 | <div id="moduleList" class="module"> | ||
1880 | 580 | <h4>Modules</h4> | ||
1881 | 581 | <ul class="content"> | ||
1882 | 582 | #for $moduledef in $modulenames | ||
1883 | 583 | #set $css = "" | ||
1884 | 584 | #if $moduledef == $modulename | ||
1885 | 585 | #set $css = "selected" | ||
1886 | 586 | #end if | ||
1887 | 587 | <li class="$css"><a href="module_${moduledef}.html" title="$moduledef">$moduledef</a></li> | ||
1888 | 588 | #end for | ||
1889 | 589 | </ul> | ||
1890 | 590 | </div> | ||
1891 | 591 | #end if | ||
1892 | 592 | |||
1893 | 593 | #if $classnames | ||
1894 | 594 | <div id="classList" class="module"> | ||
1895 | 595 | <h4>Classes</h4> | ||
1896 | 596 | <ul class="content"> | ||
1897 | 597 | #for $classdef in $classnames | ||
1898 | 598 | #set $css = "" | ||
1899 | 599 | #if $classdef == $classname | ||
1900 | 600 | #set $css = "selected" | ||
1901 | 601 | #end if | ||
1902 | 602 | <li class="$css"><a href="${classdef}.html" title="$classdef">$classdef</a></li> | ||
1903 | 603 | #end for | ||
1904 | 604 | </ul> | ||
1905 | 605 | </div> | ||
1906 | 606 | #end if | ||
1907 | 607 | |||
1908 | 608 | #if $filenames | ||
1909 | 609 | <div id="fileList" class="module"> | ||
1910 | 610 | <h4>Files</h4> | ||
1911 | 611 | <ul class="content"> | ||
1912 | 612 | #for $filedef in $filenames | ||
1913 | 613 | #set $css = "" | ||
1914 | 614 | #if $filedef == $filename | ||
1915 | 615 | #set $css = "selected" | ||
1916 | 616 | #end if | ||
1917 | 617 | <li class="$css"><a href="${filedef}.html" title="$filedef">$filedef</a></li> | ||
1918 | 618 | #end for | ||
1919 | 619 | </ul> | ||
1920 | 620 | </div> | ||
1921 | 621 | #end if | ||
1922 | 622 | |||
1923 | 623 | #if $properties | ||
1924 | 624 | <div id="propertyList" class="module"> | ||
1925 | 625 | <h4>Properties</h4> | ||
1926 | 626 | <ul class="content"> | ||
1927 | 627 | #for $prop in $properties | ||
1928 | 628 | <li class="${prop.access}#if $prop.deprecated# deprecated#end if#"><a href="#property_${prop.name}" title="$prop.name">$prop.name</a></li> | ||
1929 | 629 | #end for | ||
1930 | 630 | </ul> | ||
1931 | 631 | </div> | ||
1932 | 632 | #end if | ||
1933 | 633 | |||
1934 | 634 | #if $methods | ||
1935 | 635 | <div id="methodsList" class="module"> | ||
1936 | 636 | <h4>Methods</h4> | ||
1937 | 637 | <ul class="content"> | ||
1938 | 638 | #for $method in $methods | ||
1939 | 639 | <li class="${method.access}#if $method.deprecated# deprecated#end if#"><a href="#method_${method.name}" title="$method.name">$method.name</a></li> | ||
1940 | 640 | #end for | ||
1941 | 641 | </ul> | ||
1942 | 642 | </div> | ||
1943 | 643 | #end if | ||
1944 | 644 | |||
1945 | 645 | #if $events | ||
1946 | 646 | <div id="eventsList" class="module"> | ||
1947 | 647 | <h4>Events</h4> | ||
1948 | 648 | <ul class="content"> | ||
1949 | 649 | #for $event in $events | ||
1950 | 650 | <li class="${event.access}#if $event.deprecated# deprecated#end if#"><a href="#event_${event.name}" title="$event.name">$event.name</a></li> | ||
1951 | 651 | #end for | ||
1952 | 652 | </ul> | ||
1953 | 653 | </div> | ||
1954 | 654 | #end if | ||
1955 | 655 | |||
1956 | 656 | #if $configs | ||
1957 | 657 | <div id="configList" class="module"> | ||
1958 | 658 | <h4>Configuration Attributes</h4> | ||
1959 | 659 | <ul class="content"> | ||
1960 | 660 | #for $config in $configs | ||
1961 | 661 | <li class="${config.access}#if $config.deprecated# deprecated#end if#"><a href="#config_${config.name}" title="$config.name">$config.name</a></li> | ||
1962 | 662 | #end for | ||
1963 | 663 | </ul> | ||
1964 | 664 | </div> | ||
1965 | 665 | #end if | ||
1966 | 666 | |||
1967 | 667 | </div> | ||
1968 | 668 | </div> | ||
1969 | 669 | </div> | ||
1970 | 670 | <div id="ft"> | ||
1971 | 671 | <hr /> | ||
1972 | 672 | Copyright © $year Richard Wall. All rights reserved. | ||
1973 | 673 | </div> | ||
1974 | 674 | </div> | ||
1975 | 675 | <script type="text/javascript"> | ||
1976 | 676 | ALL_YUI_PROPS = $allprops; | ||
1977 | 677 | </script> | ||
1978 | 678 | #if $ydn | ||
1979 | 679 | <!--MyBlogLog instrumentation--> | ||
1980 | 680 | <script type="text/javascript" | ||
1981 | 681 | src="http://track2.mybloglog.com/js/jsserv.php?mblID=2007020704011645"></script> | ||
1982 | 682 | #end if | ||
1983 | 683 | </body> | ||
1984 | 684 | </html> | ||
1985 | 685 | #end filter |
Looks good please merge :)