UNPKG

dojox

Version:

Dojo eXtensions, a rollup of many useful sub-projects and varying states of maturity – from very stable and robust, to alpha and experimental. See individual projects contain README files for details.

70 lines (64 loc) 2.47 kB
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <html> <head> <meta name="viewport" content="width=device-width,initial-scale=1,maximum-scale=1,minimum-scale=1,user-scalable=no"/> <meta name="apple-mobile-web-app-capable" content="yes" /> <title>Round Rect</title> <link href="../../../themes/iphone/iphone.css" rel="stylesheet"/> <script type="text/javascript" src="../../../../../dojo/dojo.js" data-dojo-config="parseOnLoad: true"></script> <script language="JavaScript" type="text/javascript"> //dojo.require("dojo.parser"); // Use the lightweight parser. dojo.require("dojox.mobile.parser"); dojo.require("dojox.mobile"); dojo.requireIf(!dojo.isWebKit, "dojox.mobile.compat"); dojo.require("doh.runner"); dojo.addOnLoad(function(){ doh.register("dojox.mobile.test.doh.RoundRect", [ { name: "RoundRect Verification", timeout: 4000, runTest: function(){ var d = new doh.Deferred(); setTimeout(d.getTestCallback(function(){ var demoWidget = dijit.byId("dojox_mobile_RoundRect_0"); if(dojo.isIE < 10){ doh.assertEqual('mblRoundRect', demoWidget.domNode.className); }else{ doh.assertEqual('mblRoundRect mblShadow', demoWidget.domNode.className); } demoWidget = dijit.byId("dojox_mobile_RoundRect_1"); doh.assertEqual('mblRoundRect', demoWidget.domNode.className); })); return d; } }, { name: "Set", timeout: 4000, runTest: function(){ var demoWidget = dijit.byId("dojox_mobile_RoundRect_0"); demoWidget.set({shadow :false}); demoWidget.set({shadow :false}); // doh.assertFalse(demoWidget.get("shadow")); // doh.assertEqual('mblRoundRect', demoWidget.domNode.className); } } ]); doh.run(); }); </script> </head> <body> <div id="foo" dojoType="dojox.mobile.View" selected="true"> <h2 dojoType="dojox.mobile.RoundRectCategory">Round Rectangle</h2> <div dojoType="dojox.mobile.RoundRect" shadow="true"> This module provides some widgets that can be used to build web-based applications for mobile devices such as iPhone or Android. </div> <div dojoType="dojox.mobile.RoundRect"> This module provides some widgets that can be used to build web-based applications for mobile devices such as iPhone or Android. </div> </div> </body> </html>