On 5/6/15 13:13, Gervase Markham wrote:
On 06/05/15 18:36, Tom Schuster wrote:
I think the ribbon would be really useful if it allowed the user to
restore the previous clipboard content. However this is probably not
possible for all data that can be stored in clipboards, i.e. files.
Which is why we wouldn't overwrite the clipboard until the permission
was granted :-)
Well, that makes it scantly better than a doorhanger, which is what
Martin was objecting to (and I agree with him). The model that we really
want here is "this thing happened, click here to undo it" rather than
"this think is about to happen, but won't unless you take additional
action." I think this position is pretty strongly bolstered by Dave
Graham's message about GitHub behavior: "Although IE 11 supports this
API as well, we have not enabled it yet. The browser displays a popup
dialog asking the user for permission to copy to the clipboard.
Hopefully this popup is removed in Edge so we can start using JS there too."
Basically, requiring the extra step of requiring the user to click on an
"okay, do it" button is high enough friction that the function loses its
value.
In any case, we should have a better technical exploration of the
assertion that restoring a clipboard isn't possible in all cases before
we take it as given. A cursory examination of the OS X clipboard API
leads me to believe that this would be trivially possible (I believe we
can just store the array of pasteboardItems from the NSGeneralPBoard off
somewhere so that they can be moved back if necessary). I'd be a little
surprised if this weren't also true for Linux and Windows.
--
Adam Roach
Principal Platform Engineer
a...@mozilla.com
+1 650 903 0800 x863
_______________________________________________
dev-platform mailing list
dev-platform@lists.mozilla.org
https://lists.mozilla.org/listinfo/dev-platform