W3C home > Mailing lists > Public > whatwg@whatwg.org > May 2012

Re: [whatwg] Bandwidth media queries

From: Maciej Stachowiak <mjs@apple.com>
Date: Sun, 20 May 2012 15:11:25 -0700
Message-id: <E2B7C476-09DD-4B0A-AE94-0E7533EE9E59@apple.com>
To: Boris Zbarsky <bzbarsky@MIT.EDU>
Cc: whatwg@lists.whatwg.org

On May 20, 2012, at 6:13 AM, Boris Zbarsky <bzbarsky@MIT.EDU> wrote:

> On 5/20/12 9:04 AM, Boris Zbarsky wrote:
>> On 5/20/12 5:45 AM, Paul Irish wrote:
>>> Since no one mentioned it, I just wanted to make sure this thread is
>>> aware
>>> of the Network Information API [1], which provides
>>> navigator.connection.bandwidth
>>> It's been recently implemented (to some degree) in both Mozilla [2] and
>>> Webkit [3].
>> As far as I can tell, the Mozilla implementation always returns Infinity
>> for .bandwidth.
> Oh, and the WebKit implementation you linked to sometimes returns whatever value the embedding set on the object (thus punting the problem of what to return to the embedding), and by default seems to do this, if I read it right:
> 57	unsigned int NetworkInfoClientEfl::bandwidth() const
> 58	{
> 59	    notImplemented();
> 60	    return 10; // MB/s
> 61	}
> (not exactly spec compliant, so much, of course).

Well spotted. That bug is regrettably still in WebKit trunk. <https://bugs.webkit.org/show_bug.cgi?id=86972>

In addition, the feature is implemented only for a single WebKit port which is not one of the most widely used (EFL), and most other functionality of the NetworkInformation interface is likewise unimplemented. We may end up removing this feature from WebKit if it is not made more functional and/or adopted by more ports. It's not clear if the interface is effectively implementable and the feature is kind of an experiment at the moment.

Received on Sunday, 20 May 2012 22:11:57 UTC

This archive was generated by hypermail 2.4.0 : Wednesday, 22 January 2020 16:59:42 UTC