<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
     "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html lang="en" xml:lang="en" xmlns="http://www.w3.org/1999/xhtml"
 	xmlns:x2="http://www.w3.org/TR/xhtml2"
	xmlns:role="http://www.w3.org/2005/01/wai-rdf/GUIRoleTaxonomy#"
	xmlns:state="http://www.w3.org/2005/07/aaa">
<head>

<style type="text/css">
@namespace x2    url("http://www.w3.org/TR/xhtml2");
@namespace role  url("http://www.w3.org/2005/01/wai-rdf/GUIRoleTaxonomy#");
@namespace state url("http://www.w3.org/2005/07/aaa");
ul.hlist {
	list-style: none;
	margin: 1em;
	padding: 0;
	display: inline;
}

ul.hlist li	{
	display: inline;
	margin: 1em;
	padding: 0;	
}

p.inline {
	display: inline;
	margin: 1em;	
}

div#content {
	position: absolute;
	top: 0;
	left: 0;
}

.hide {
/*
	visibility: hidden;
	height: 0;
	width: 0;
	padding: 0;
	margin: 0;
	display: inline;
	*/
	display: none;
}

li.testItem {
	margin: 0;
}

iframe.short {
	margin-top: 1em;
	height: 3em;
}

iframe.textfieldShort {
	margin-top: 1em;
	height: 8em;
}

iframe.comboboxShort {
	margin-top: 1em;
	height: 11em;
}

iframe.rdfShort {
	margin-top: 1em;
	height: 14em;	
}

iframe.treeShort {
	margin-top: 1em;
	height: 20em;	
}

iframe.sliderShort {
	margin-top: 1em;
	height: 5em;	
}

h3.info {
	display: inline;
	margin: 0;
	padding: 0;
}

</style>

<title>All Tree Tests</title>
</head>

<body>
<h1>All Tree Tests</h1>

<h2>Test Information Options</h2>
<ul>
	<li><a href="index.php">Display no extended test information</a></li>
	<li><a href="index.php?short=1">Display the goal of the test</a></li>
	<li><a href="index.php?short=1&amp;long=1">Display above and the expected behavior</a></li>
	<li><a href="index.php?short=1&amp;long=1&amp;instructions=1">Display above and test instructions</a></li>
</ul>

<ul>
	<li class="testItem">
		<h2>Reference Implementation</h2>
		<div class="info">

	<h3 class="info">Object</h3>
<p class="short">
The reference implementation for the tree widget, adapted from Mozilla.org's Accessible DHTML Widget Page.
</p>

	<h3 class="info">Behavior</h3>
<p class="long">
This widget is adapted from <a href="http://developer.mozilla.org/en/docs/Accessible_DHTML">Mozilla.org's Accessible DHTML Page</a>.  
There were a few changes made to this excellent widget; all bugs in this version are our own.  
This version also tends to trade efficiency for clarity and generality in some places.
</p>
<ul class="long" title="Changes from mozilla.org version">
	<li>Added comments and styling for pedagogical reasons</li>
	<li>Altered some utility functions for test suite consistency</li>
	<li>"End" key and end wrapping now behave with respect to the last <em>visible</em> treeitem</li>
	<li>Removed some unused code for clarity</li>
	<li>Added styling to indicate incremental find activity</li>
</ul>
<p class="long">
The tree widget supports the expected keyboard and mouse interaction as well as a keyboard incremental find.  
Tabbing to the tree will only focus the current selected option (or the first, if none was previously selected).  
Up/Down navigate to select the previous and next options; if "wrap" is allowed then pressing down when the last visible 
node is selected will cause the first visible node to become selected, and vice-versa.  A single mouse click on a tree item 
will cause it to be selected.
</p>
<p class="long">
Branch nodes are indicated with styling, a "+" for an unexpanded (or "closed") node and a "-" for an 
expanded (or "open") node.  Nodes may be toggled by first selecting them and pressing enter or by double clicking them.  
Additionally, nodes may be expanded by selecting them and pressing the "right" arrow key; they may be collapsed (closed) by 
selecting them and pressing the "left" arrow key.
</p>
<p class="long">
The incremental find allows the user to navigate quickly to some tree items.  
When a user types a non-navigation key (alphanumeric), the incremental find is activated.  The first tree item that matches 
the most typed keys in typed order is selected.  After a pause, the incremental search is deactivated and reset.  This also happens 
when the tree looses focus, the selection is moved through navigation, or nodes are expanded or collapsed.
</p>


	<h3 class="info">Instructions</h3>
<ul class="instructions">
	<li>Tab to tree, verify first treeitem is styled as selected</li>
	<li>Use up/down/home/end arrow keys, verify selection moves accordingly</li>
	<li>Use left/right/enter keys to expand expandable treeitems (and verify their styling status changes)</li>
	<li>Tab away from the tree, tab back, and verify last selected option is still the only one focusable and selected</li>
	<li>Verify tree items are selected when clicked with the mouse</li>
	<li>Verify expandable items are toggled when double clicked with the mouse</li>
	<li>Verify incremental find for various items; selection moves to appropriate item and styling indicates incremental find activity</li>
</ul>

		</div>
		<iframe class="short treeShort" width="100%" src="tree_reference/tree_reference.php?iframe=1"/>
	</li>
</ul>	

</body>
</html>
