halt.html revision 1b298c6f0ef597aa4ab0b8bcb25430b6c9a87749
fcf3ce441efd61da9bb2884968af01cb7c1452ccJohn Forte<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
fcf3ce441efd61da9bb2884968af01cb7c1452ccJohn Forte <link rel="stylesheet" type="text/css" href="/yui-dev/build/reset-fonts-grids/reset-fonts-grids.css">
fcf3ce441efd61da9bb2884968af01cb7c1452ccJohn Forte margin: 1em;
fcf3ce441efd61da9bb2884968af01cb7c1452ccJohn Forte background-color: #ccc;
fcf3ce441efd61da9bb2884968af01cb7c1452ccJohn Forte border: 1px solid black;
fcf3ce441efd61da9bb2884968af01cb7c1452ccJohn Forte height: 100px;
fcf3ce441efd61da9bb2884968af01cb7c1452ccJohn Forte width: 100px;
fcf3ce441efd61da9bb2884968af01cb7c1452ccJohn Forte strong { font-weight: bold; }
fcf3ce441efd61da9bb2884968af01cb7c1452ccJohn Forte <p>This test case shows that calling halt on an event will stop all events, not just those associated with the event.</p>
fcf3ce441efd61da9bb2884968af01cb7c1452ccJohn Forte <p>If you click the <strong>[Click Me]</strong> link below, the animation will <strong>NOT</strong> run. It calls <strong>e.halt()</strong> before the animation.</p>
fcf3ce441efd61da9bb2884968af01cb7c1452ccJohn Forte <p><a href="index.php">[Click here to see the working case]</a></p>
fcf3ce441efd61da9bb2884968af01cb7c1452ccJohn Forte I am Animated
fcf3ce441efd61da9bb2884968af01cb7c1452ccJohn Forte<script type="text/javascript" src="/build3x/yui/yui.js?bust=1216406682"></script>
fcf3ce441efd61da9bb2884968af01cb7c1452ccJohn Forte<!-- needed until built into a module -->
fcf3ce441efd61da9bb2884968af01cb7c1452ccJohn Forte<script type="text/javascript" src="/build3x/attribute/attribute.js?bust=1216406682"></script>
fcf3ce441efd61da9bb2884968af01cb7c1452ccJohn Forte<script type="text/javascript" src="/build3x/base/base.js?bust=1216406682"></script>
fcf3ce441efd61da9bb2884968af01cb7c1452ccJohn Forte<!-- needed until new node.js is built into yui.js -->
fcf3ce441efd61da9bb2884968af01cb7c1452ccJohn Forte<script type="text/javascript" src="/build3x/animation/animation.js?bust=1216406682"></script>
fcf3ce441efd61da9bb2884968af01cb7c1452ccJohn Fortevar yConfig = {
fcf3ce441efd61da9bb2884968af01cb7c1452ccJohn Forte logExclude: {
fcf3ce441efd61da9bb2884968af01cb7c1452ccJohn Forte 'YUI': true,
fcf3ce441efd61da9bb2884968af01cb7c1452ccJohn Forte Event: true,
fcf3ce441efd61da9bb2884968af01cb7c1452ccJohn Forte Attribute: true,
fcf3ce441efd61da9bb2884968af01cb7c1452ccJohn Forte augment: true
fcf3ce441efd61da9bb2884968af01cb7c1452ccJohn Forte debug: false
fcf3ce441efd61da9bb2884968af01cb7c1452ccJohn Fortevar Y = new YUI(yConfig).use('nodeextras', 'base', 'animation');
fcf3ce441efd61da9bb2884968af01cb7c1452ccJohn ForteY.on('event:ready', function() {
fcf3ce441efd61da9bb2884968af01cb7c1452ccJohn Forte Y.Node.get('#test').on('click', function(e) {
fcf3ce441efd61da9bb2884968af01cb7c1452ccJohn Forte console.log('#test clicked..');
fcf3ce441efd61da9bb2884968af01cb7c1452ccJohn Forte console.log('calling event.halt() before anim..');
fcf3ce441efd61da9bb2884968af01cb7c1452ccJohn Forte var anim = new Y.Anim({
fcf3ce441efd61da9bb2884968af01cb7c1452ccJohn Forte node: '#anim',
7014882c6a3672fd0e5d60200af8643ae53c5928Richard Lowe height: 200,
fcf3ce441efd61da9bb2884968af01cb7c1452ccJohn Forte height: 100,
fcf3ce441efd61da9bb2884968af01cb7c1452ccJohn Forte duration: 1,
fcf3ce441efd61da9bb2884968af01cb7c1452ccJohn Forte iteration: 1
fcf3ce441efd61da9bb2884968af01cb7c1452ccJohn Forte<!-- lifeagree.corp.yahoo.com compressed/chunked Fri Jul 18 11:44:42 PDT 2008 -->