- From: Johannes Wilm <notifications@github.com>
- Date: Mon, 03 Aug 2015 12:27:47 -0700
- To: w3c/editing <editing@noreply.github.com>
- Message-ID: <w3c/editing/issues/61/127378366@github.com>
@hallvors Some of those who invented the concepts here have left the ship, but the rest of us are trying to build on what has been documented about these ideas. > "The user's intent" is like an event coming from the UA, right? Yes, so basically copying will consist of at least two events: * The device dependent event: user hit CTRL+C. * The device independent event: user wanted to copy the currently selected text. One of the specs here defines the types of device independent events for most things, but not copy/paste/etc. > I'm pretty sure you'd all like to be able to put a "copy" button in a toolbar inside your editor and be able to control what goes on the OS clipboard when the user clicks that button. In general, we have applied a much more limited approach to these "device independent events" than what had been thought of at previous stages. So these events will only be fired through doing right click menu actions, keydown combinations, etc. on the editable text itself. Other UI elements will not have access to creating similar intents, so normal function calls need to be used there. > I'm pretty sure you'd all like to be able to put a "copy" button in a toolbar inside your editor and be able to control what goes on the OS clipboard when the user clicks that button. So: is this a use case you intend to handle, and if so how do you see it working? I see the dilemma. I guess you don't want there to be a JS function to copy new content to the clipboard because this could represent a security issue by having random sites throw trash into the clipboard? I tried doing just that with execCommand in current chrome, and there was apparently no security check preventing me from doing that: http://pastebin.com/fnVGa7wC So unless you have a way to fix that in mind, I would say one has to choose between: * Removing the option to copy by clicking on a custom UI button, due to security concerns. * Not worrying about the security concerns and simply offering the functionality by means of a buitl in function. What do you think? --- Reply to this email directly or view it on GitHub: https://github.com/w3c/editing/issues/61#issuecomment-127378366
Received on Monday, 3 August 2015 19:28:17 UTC