source: Dev/trunk/src/client/dojox/mobile/tests/test_ProgressIndicator-heading.html

Last change on this file was 483, checked in by hendrikvanantwerpen, 11 years ago

Added Dojo 1.9.3 release.

File size: 2.0 KB
Line 
1<!DOCTYPE html>
2<html>
3<head>
4        <meta http-equiv="Content-type" content="text/html; charset=utf-8"/>
5        <meta name="viewport" content="width=device-width,initial-scale=1,maximum-scale=1,minimum-scale=1,user-scalable=no"/>
6        <meta name="apple-mobile-web-app-capable" content="yes"/>
7        <title>Progress Indicator on Heading</title>
8
9        <script type="text/javascript" src="../deviceTheme.js" data-dojo-config="mblThemeFiles: ['base']"></script>
10        <script type="text/javascript" src="../../../dojo/dojo.js" data-dojo-config="async: true, parseOnLoad: true"></script>
11
12        <script type="text/javascript">
13                require([
14                        "dojo/dom-class",
15                        "dojo/ready",
16                        "dijit/registry",
17                        "dojox/mobile/ProgressIndicator",
18                        "dojox/mobile/parser",
19                        "dojox/mobile",
20                        "dojox/mobile/compat"
21                ], function(domClass, ready, registry, ProgressIndicator){
22                        ready(function(){
23                                var prog1 = new ProgressIndicator({size:30, center:false});
24                                prog1.domNode.style.position = "absolute";
25                                prog1.domNode.style.margin = "5px";
26                                domClass.add(prog1.domNode, "mblProgWhite");
27                                var head1 = registry.byId("head1");
28                                prog1.placeAt(head1.domNode);
29                                prog1.start();
30                                setTimeout(function(){ // network latency simulation
31                                        prog1.stop();
32                                        head1.set("label", "Done");
33                                }, 5000);
34
35                                var prog2 = new ProgressIndicator({size:30, center:false});
36                                prog2.domNode.style.position = "absolute";
37                                prog2.domNode.style.margin = "5px";
38                                prog2.domNode.style.right = "0px";
39                                domClass.add(prog2.domNode, "mblProgWhite");
40                                var head2 = registry.byId("head2");
41                                prog2.placeAt(head2.domNode);
42                                prog2.start();
43                                setTimeout(function(){ // network latency simulation
44                                        prog2.stop();
45                                        head2.set("label", "Done");
46                                }, 5000);
47                        });
48                });
49        </script>
50</head>
51<body style="visibility:hidden;">
52        <div id="foo" data-dojo-type="dojox.mobile.View">
53                <h1 id="head1" data-dojo-type="dojox.mobile.Heading">Loading...</h1>
54                <br><br>
55                <h1 id="head2" data-dojo-type="dojox.mobile.Heading">Loading...</h1>
56        </div>
57</body>
58</html>
Note: See TracBrowser for help on using the repository browser.