title: How to programmatically set Discoverable time without user confirmation?
body: <p>I usually use this</p>
  
  <pre><code>private void ensureDiscoverable() {
      if(D) Log.d(TAG, "ensure discoverable");
      if (mBluetoothAdapter.getScanMode() !=
              BluetoothAdapter.SCAN_MODE_CONNECTABLE_DISCOVERABLE) {
          Intent discoverableIntent = new Intent(BluetoothAdapter.ACTION_REQUEST_DISCOVERABLE);
          discoverableIntent.putExtra(BluetoothAdapter.EXTRA_DISCOVERABLE_DURATION, 300);
          startActivity(discoverableIntent);
      }
  }
  </code></pre>
  
  <p>But that prompts a user confirmation. Is there a way to bypass this programmatically?</p>
  
  <p>Also, I suppose there are no "news" on the "always discoverable <a href="https://stackoverflow.com/questions/6856931/android-bluetooth-discoverable-always">mode</a>" ? </p>