/[jscoverage]/trunk/doc/example-jsunit/jsunit/app/main-loader.html
ViewVC logotype

Annotation of /trunk/doc/example-jsunit/jsunit/app/main-loader.html

Parent Directory Parent Directory | Revision Log Revision Log


Revision 30 - (hide annotations)
Sun Aug 19 04:45:14 2007 UTC (14 years, 10 months ago) by siliconforks
File MIME type: text/html
File size: 1444 byte(s)
Add jsunit example.

1 siliconforks 30 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
2     <html>
3     <head>
4     <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
5     <title>jsUnit External Data Document loader</title>
6     <script language="JavaScript" type="text/javascript">
7    
8     var loadStatus;
9     var callback = function () {
10     };
11    
12     function buffer() {
13     return window.frames.documentBuffer;
14     }
15    
16     function load(uri) {
17     loadStatus = 'loading';
18     buffer().document.location.href = uri;
19     }
20    
21     function loadComplete() {
22     top.xbDEBUG.dump('main-loader.html:loadComplete(): loadStatus = ' + loadStatus + ' href=' + buffer().document.location.href);
23     if (loadStatus == 'loading') {
24     loadStatus = 'complete';
25     callback();
26     callback = function () {
27     };
28     }
29     }
30    
31     if (top.xbDEBUG.on) {
32     var scopeName = 'main_loader_' + (new Date()).getTime();
33     top[scopeName] = window;
34     top.xbDebugTraceFunction(scopeName, 'buffer');
35     top.xbDebugTraceFunction(scopeName, 'load');
36     top.xbDebugTraceFunction(scopeName, 'loadComplete');
37     }
38    
39     </script>
40     </head>
41    
42     <body>
43     <iframe name="documentBuffer" onload="loadComplete()"></iframe>
44     </body>
45     </html>

  ViewVC Help
Powered by ViewVC 1.1.24