- From: Hallvord R. M. Steen <hsteen@mozilla.com>
- Date: Tue, 20 May 2014 13:42:25 -0700 (PDT)
- To: James Greene <james.m.greene@gmail.com>
- Cc: Ben Peters <Ben.Peters@microsoft.com>, Anne van Kesteren <annevk@annevk.nl>, public-webapps <public-webapps@w3.org>
> Getting back to the question of feature discoverability, if we go with > using `document.execCommand` instead of synthetic event dispatching with > side effects, then I would expect the proper support checks to be conducted > with `document.queryCommandSupported` and `document.queryCommandEnabled`. It would sort of be inconsistent with how queryCommandEnabled works and is typically used today. As far as I can tell it's typically used to enable/disable buttons in a editor UI, while you move through the text. Having queryCommandEnabled('copy') return true only during click event processing would for a typical editor make the "copy" button enabled only while you click in the document.. It would take some special-casing and logic to work around that. What if we extend queryCommandEnabled somewhat and allow document.queryCommandEnabled('copy', {'userTriggered':true}) ? -Hallvord
Received on Tuesday, 20 May 2014 20:42:53 UTC