W3C home > Mailing lists > Public > public-device-apis@w3.org > June 2010

Re: Capture API question

From: Thomas Roessler <tlr@w3.org>
Date: Mon, 21 Jun 2010 21:39:05 +0200
Cc: Thomas Roessler <tlr@w3.org>, "Tran, Dzung D" <dzung.d.tran@intel.com>, Dominique Hazael-Massieux <dom@w3.org>, "Ingmar.Kliche" <Ingmar.Kliche@telekom.de>, "Ilkka.Oksanen@nokia.com" <Ilkka.Oksanen@nokia.com>, Robin Berjon <robin@robineko.com>, Andrei Popescu <andreip@google.com>, "public-device-apis@w3.org" <public-device-apis@w3.org>, Brad Lassey <blassey@mozilla.com>, Doug Turner <dougt@mozilla.com>, "khuey@mozilla.com" <khuey@mozilla.com>
Message-Id: <37A4C3FD-2971-45E4-9744-602093BB05DD@w3.org>
To: arun@mozilla.com
On 21 Jun 2010, at 21:22, Arun Ranganathan wrote:

>> While we're on that one, what are the reasons to overload MIME syntax in @accept instead of adding a separate attribute that triggers a relevant sensor, when present?
>>   
> 
> Minimizing attributes is nice; I don't think this is overloading. Rather, by including @accept in the first place, we may have all that we need.

I agree on the minimization goal.  But Andrei's proposal adds a pseudo MIME parameter in order to save an HTML parameter. That sounds weird.

> At the risk of bikeshedding, what is your proposal, and why is it better?

Add "capture" as an attribute to "input" (I thought of 'source', but that's much too close to 'src' for comfort).  Same values as for Andrei's pseudo-attribute.

Better because:
- doesn't add yet another micro syntax (including pseudo-attribute notion) to HTML
- the "capture" parameter is easily available within the DOM
- clean fall-back for user agents that might do something useful with the current accept parameter (does anybody actually use it right now?)

> Currently, it seems we have Andrei's proposal:
> 
> <input type="file" accept="image/*;source=camera">  [1]

<input type="file" accept="image/*" capture="camera">

> Upon reflection, I'm not sure if we even need the extra ";source=camera" part.  Our implementation doesn't use it, and thus we have the existing use of @accept which seems sufficient.  Andrei, do you think we actually need the additional qualifier?  If so, why?


(Good question; I wouldn't mind dropping the qualifier.)
Received on Monday, 21 June 2010 19:39:27 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Wednesday, 9 May 2012 00:14:10 GMT