title: check if location setting has been turned off in users browser
body: <p>I would like to hide() or show() a button that allows users to use their current location based on whether or not they are currently allowing location to be used in their browser setting.
  the below code only checks if the browser supports geolocation and not whether or not the particular user is allowing it.</p>
  
  <pre><code>if (navigator.geolocation)  {
     navigator.geolocation.getCurrentPosition(showPosition);
     } else  {
   x.innerHTML="Geolocation is not supported by this browser.";}
   } 
  </code></pre>
  
  <p>Is there a boolean value that I can detect for their browser setting letting me know if location is currently allowed?</p>
  
  <p>thanks for any suggestions.</p>