W3C home > Mailing lists > Public > public-webapps@w3.org > January to March 2012

Re: Elements and Blob

From: Charles Pritchard <chuck@jumis.com>
Date: Tue, 14 Feb 2012 12:58:17 -0800
Message-Id: <FF4C8968-EDB5-4E63-8848-7E61E11AB68C@jumis.com>
Cc: "public-webapps@w3.org" <public-webapps@w3.org>
To: Bronislav Klučka <Bronislav.Klucka@bauglir.com>
This was covered and dismissed in earlier form with element.saveData semantics in IE.

It's really unnecessary. We an cover the desired cases without this level of change.



On Feb 14, 2012, at 12:08 PM, Bronislav Klučka <Bronislav.Klucka@bauglir.com> wrote:

> Hi,
> regarding current discussion about Blobs, URL, etc. I'd like to have following proposition:
> every element would have following additional methods/fields:
> 
> Blob function saveToBlob();
> that would return a blob containing element data  (e.g. for img element that would be image data, for p element that would be basically innerHTML, for input it would be current value, for script it would be either script element content [if exists], or it would be empty blob [if src is used]). With CORS applied here. There are progress events needed.
> 
> void function loadFromBlob(Blob blob);
> that would load the blob content as element content (e.g. for img element it would display image data in that blob [no changes to src attribute], for p element that would be basically innerHTML, for input it serve as value, for script this would load data as script (and element content) and execute it [no changes to src attribute]). Function should create no reference between element and blob, just load blob data. There are progress events needed.
> 
> attribute Blob blob;
> that would do the same as loadFromBlob, but it would also create reference between element and blob
> 
> 
> and why that:
> 1/ saveToBlob - would create easy access to any element data, we are already talking about media elements (canvas, image), I see no point of limiting it. Do you want blob from image or textarea? Just one function.
> 
> 2/ loadFromBlob, blob - could solve current issue with createObjectUrl (that functionality would remain as it is): no reference issues, intuitive usage
> 
> 
> 
> Brona
> 
> 
> 
> 
> 
> 
Received on Tuesday, 14 February 2012 20:58:45 GMT

This archive was generated by hypermail 2.3.1 : Tuesday, 26 March 2013 18:49:50 GMT