<?xml version="1.0" encoding="iso-8859-1"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
<html xmlns='http://www.w3.org/1999/xhtml'
      xmlns:xbl='http://www.w3.org/ns/xbl'
      xmlns:xhtml="http://www.w3.org/1999/xhtml">
  <head>
    <title>XBL 2.0 Test Suite: Handler test - event</title>
    <style type='text/css'>
    </style> 
    <xbl xmlns="http://www.w3.org/ns/xbl">
    <binding id="b1" element="#missingevent">
     <handlers>
	<handler id="hand1">
		document.getElementById('missignevent').setAttribute("style", "background-color: red");
        </handler>
     </handlers>
    </binding>
    <binding id="b2" element="#emptyevent">
     <handlers>
	<handler id="hand2" event="">
          document.getElementById('emptyevent').setAttribute("style", "background-color: red");
        </handler>
     </handlers>
    </binding>
    <binding id="b3" element="#clickevent">
     <handlers>
	<handler id="hand3" event="click" >
          document.getElementById('clickevent').setAttribute("style", "background-color: green");
        </handler>
     </handlers>
    </binding>
    <binding id="b4" element="#mouseoverevent">
     <handlers>
	<handler id="hand4" event="mouseover">
          document.getElementById('mouseoverevent').setAttribute("style", "background-color: green");
        </handler>
     </handlers>
    </binding>
    <binding id="b5" element="#nosuchevent">
     <handlers>
	<handler id="hand6" event="nosuchevent" >
          document.getElementById('nosuchevent').setAttribute("style", "background-color: red");
        </handler>
     </handlers>
    </binding>
    <binding id="b6" element="#doubleevent">
     <handlers>
	<handler id="hand7" event="mouseover">
          document.getElementById('doubleevent').setAttribute("style", "background-color: green");
        </handler>
     </handlers>
    </binding>
    <binding id="b7" element="#doubleevent">
     <handlers>
	<handler id="hand8" event="click">
          document.getElementById('doubleevent').setAttribute("style", "background-color: blue");
        </handler>
     </handlers>
    </binding>
    </xbl>
  </head>
  <body>  
   <h1 id="missingevent">Nothing should happen to this text</h1><br/>
   <h1 id="emptyevent">Nothing should happen to this text</h1><br/>
   <h1 id="clickevent">Background of this text should turn green if you click it.</h1><br/>
   <h1 id="mouseoverevent">Background of this text should turn green if you move mouse over it.</h1><br/>
   <h1 id="nosuchevent">Nothing should happen to this text</h1><br/>
   <h1 id="doubleevent">Background of this text should turn green if you move mouse over it and turn blue if you click it.</h1><br/>
 </body>
</html>
