Commit 6f510757 authored by Jörn Zaefferer's avatar Jörn Zaefferer

use jquery for dblclick handler to access event.target

parent 03c623c3
...@@ -125,13 +125,13 @@ function test(name, callback, nowait) { ...@@ -125,13 +125,13 @@ function test(name, callback, nowait) {
else else
n.style.display = "none"; n.style.display = "none";
}; };
b.ondblclick = function(event) { $(b).dblclick(function(event) {
var target = jQuery(event.target).filter("strong").clone(); var target = jQuery(event.target).filter("strong").clone();
if ( target.length ) { if ( target.length ) {
target.children().remove(); target.children().remove();
location.href = location.href.match(/^(.+?)(\?.*)?$/)[1] + "?" + encodeURIComponent($.trim(target.text())); location.href = location.href.match(/^(.+?)(\?.*)?$/)[1] + "?" + encodeURIComponent($.trim(target.text()));
} }
}; });
li.appendChild( b ); li.appendChild( b );
li.appendChild( ol ); li.appendChild( ol );
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment