<?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 - button</title>
    <style type='text/css'>
    </style> 
    <xbl xmlns="http://www.w3.org/ns/xbl">
    <binding id="b1" element="#testdouble">
     <handlers>
	<handler id="hand1" event="click" button="0">
		document.getElementById('testdouble').setAttribute("style", "background-color: green");
        </handler>
	<handler id="hand2" event="click" button="1">
         	 document.getElementById('testdouble').setAttribute("style", "background-color: blue");
        </handler>
     </handlers>
    </binding>
    <binding id="b2" element="#testnormal">
     <handlers>
	<handler id="hand3" event="click" button="0">
          document.getElementById('testnormal').setAttribute("style", "background-color: green");
        </handler>
     </handlers>
    </binding>
    <binding id="b3" element="#testerror">
     <handlers>
	<handler id="hand4" event="click" button="x">
          document.getElementById('testerror').setAttribute("style", "background-color: red");
        </handler>
     </handlers>
    </binding>
    <binding id="b4" element="#testlistnormal">
     <handlers>
	<handler id="hand5" event="click" button="0 2">
          document.getElementById('testlistnormal').setAttribute("style", "background-color: green");
        </handler>
     </handlers>
    </binding>
    <binding id="b5" element="#testlistabnormal">
     <handlers>
	<handler id="hand6" event="click" button="x 0">
          document.getElementById('testlistabnormal').setAttribute("style", "background-color: green");
        </handler>
     </handlers>
    </binding>
    </xbl>
  </head>
  <body> 
   <h1 id="testnormal">Click this with button 0 and the background turns green.</h1><br/>
   <h1 id="testdouble">Click this with mouse button 0 and the background should turn green, but if you click this with mouse button 1 the background should turn blue.</h1><br/>
   <h1 id="testerror">Nothing should happen if you click this</h1><br/>
   <h1 id="testlistnormal">Click this with button 1 or 2 and the background should turn green.</h1><br/>
   <h1 id="testlistabnormal">Click this with button 0 and the background should turn green.</h1><br/>
  </body>
</html>
