W3C home > Mailing lists > Public > public-web-bluetooth-log@w3.org > January 2016

Re: [web-bluetooth] When a device causes a page to open, the page should be able to find the device

From: François Beaufort via GitHub <sysbot+gh@w3.org>
Date: Wed, 06 Jan 2016 11:18:21 +0000
To: public-web-bluetooth-log@w3.org
Message-ID: <issue_comment.created-169300837-1452079100-sysbot+gh@w3.org>
If we go down the Permissions API road 
 it would be as simple as adding a `referringDevice` key to the 
Permission object.

permissions.query({ name: 'bluetooth' })
.then(permission => {
  if (permission.state != 'granted') {
    console.log('User has forbidden websites to use bluetooth...');
  if (permission.referringDevice) {
    // Let's try to connect to the Physical Web object first. 
    return connectDevice(permission.referringDevice);

GitHub Notification of comment by beaufortfrancois
Please view or discuss this issue at 
 using your GitHub account
Received on Wednesday, 6 January 2016 11:18:24 UTC

This archive was generated by hypermail 2.3.1 : Wednesday, 6 January 2016 11:18:24 UTC