[whatwg] HTML5 cut/copy

Two more questions about implementation details:

Cut/copy:
Does it make sense to fire a drag event at all? The spec says that drag
events should be fired at the source node every 350ms (presumably to allow
the source node to cancel a drag after it started), but a cut/copy takes
place "instantaneously". If drag events should be fired during cut/copy,
should the clipboard be restored to its original state if the drag event is
cancelled? It would make sense, but might make implementations more
complicated.

Paste:
It seems like there is no time a dragleave event would ever fire. A paste
essentially goes through the drag and drop loop once; the only possible
transition is for the current target element to go from null to non-null.

Daniel

On Tue, Jan 12, 2010 at 5:38 PM, Ian Hickson <ian at hixie.ch> wrote:

> On Tue, 12 Jan 2010, Daniel Cheng wrote:
> >
> >
> http://www.whatwg.org/specs/web-apps/current-work/multipage/dnd.html#copy-to-clipboard
> >
> > The current spec says that drop events should be fired while handling
> > copy/cut operations. Is this intended? The clipboard is not a DOM
> > element; it seems like it'd make sense only to fire the drop event for
> > pastes.
>
> Oops. Fixed. It should have been dragstart, drag, and dragend. Thanks.
>
> --
> Ian Hickson               U+1047E                )\._.,--....,'``.    fL
> http://ln.hixie.ch/       U+263A                /,   _.. \   _\  ;`._ ,.
> Things that are impossible just take longer.   `._.-(,_..'--(,_..'`-.;.'
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.whatwg.org/pipermail/whatwg-whatwg.org/attachments/20100122/9474015b/attachment.htm>

Received on Friday, 22 January 2010 13:38:49 UTC