Update of /cvsroot/dynapi/dynapi/tests
In directory usw-pr-cvs1:/tmp/cvs-serv8760

Added Files:
        cancel_navigation.html 
Log Message:
testfile for "return false" + onclick in dragable layer.

--- NEW FILE ---
<html>
<head>
<title>Return false test</title>
<script language="Javascript" src="../src/dynapi.js"></script>
<script language="Javascript">
DynAPI.setLibraryPath('../src/lib/');
DynAPI.include('dynapi.api.*');
DynAPI.include('dynapi.event.*');
DynAPI.include('dynapi.util.debug');
</script>
<script language="Javascript">

DynAPI.onLoad = function() {
        html='<a href="http://www.cnn.com"; onclick="alert(\'hi\');return 
false;">Return false</a><br /><a href="http://www.cnn.com"; 
onclick="alert(\'hi\');return true;">Return true</a>'

        myLayer = new DynLayer(null,50,150,150,150,'lightgrey',null,null,null,html)

        DragEvent.setDragBoundary(myLayer)
        DragEvent.enableDragEvents(myLayer)
        DynAPI.document.addChild(myLayer)
}

</script>
</head>

<body >
<b>Issue</b><br />
In various browsers DynAPI's events system stopped "return false" from cancelling 
navigation.<br />
The two "Return false" links should show an alert only, and not navigate to another 
page.<br />
The others should show an alert, and then go to www.cnn.com<br />
<a href="http://www.cnn.com"; onclick="alert('hi');return false;">Return false</a><br 
/><a href="http://www.cnn.com"; onclick="alert('hi');return true;">Return true</a>
</body>
</html>


_______________________________________________
Dynapi-CVS mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/dynapi-cvs

Reply via email to