Mercurial Hosting > dad
diff src/dad.js @ 20:0b3376e13e22 default tip
add nested example
author | Franklin Schmidt <fschmidt@gmail.com> |
---|---|
date | Tue, 18 Feb 2025 17:23:17 -0700 |
parents | 36c7b187827b |
children |
line wrap: on
line diff
--- a/src/dad.js Sun Sep 15 08:15:23 2024 -0600 +++ b/src/dad.js Tue Feb 18 17:23:17 2025 -0700 @@ -59,9 +59,13 @@ if( dz === dragging ) continue; if( isIn(x,y,dz.getBoundingClientRect()) ) { + let old = dropzone; dropzone = dz; - dad.onEnter(myEvent(event)); - break; + let f = dad.onEnter(myEvent(event)); + if( f === false ) + dropzone = old; + else + break; } } }