Author: steven
Date: Fri Feb 23 17:45:39 2018
New Revision: 1825144

URL: http://svn.apache.org/viewvc?rev=1825144&view=rev
Log:
Updated docs

Modified:
    cordova/site/public/docs/en/dev/guide/platforms/android/plugin.html
    cordova/site/public/feed.xml

Modified: cordova/site/public/docs/en/dev/guide/platforms/android/plugin.html
URL: 
http://svn.apache.org/viewvc/cordova/site/public/docs/en/dev/guide/platforms/android/plugin.html?rev=1825144&r1=1825143&r2=1825144&view=diff
==============================================================================
--- cordova/site/public/docs/en/dev/guide/platforms/android/plugin.html 
(original)
+++ cordova/site/public/docs/en/dev/guide/platforms/android/plugin.html Fri Feb 
23 17:45:39 2018
@@ -2949,7 +2949,7 @@ was the focus of the Cordova-Android 5.0
 <p>The permissions that need to be handled at runtime can be found in the 
Android Developer
 documentation <a 
href="http://developer.android.com/guide/topics/security/permissions.html#perm-groups";>here</a>.</p>
 
-<p>As far as a plugin is concerned, the permission can be requested by calling 
the permission method, which signature is as follows:</p>
+<p>As far as a plugin is concerned, the permission can be requested by calling 
the permission method; the signature of which is as follows:</p>
 <div class="highlight"><pre><code class="language-java" data-lang="java"><span 
class="n">cordova</span><span class="o">.</span><span 
class="na">requestPermission</span><span class="o">(</span><span 
class="n">CordovaPlugin</span> <span class="n">plugin</span><span 
class="o">,</span> <span class="kt">int</span> <span 
class="n">requestCode</span><span class="o">,</span> <span 
class="n">String</span> <span class="n">permission</span><span 
class="o">);</span>
 </code></pre></div>
 <p>To cut down on verbosity, it&#39;s standard practice to assign this to a 
local static variable:</p>
@@ -2974,7 +2974,7 @@ documentation <a href="http://developer.
     <span class="n">cordova</span><span class="o">.</span><span 
class="na">requestPermission</span><span class="o">(</span><span 
class="k">this</span><span class="o">,</span> <span 
class="n">requestCode</span><span class="o">,</span> <span 
class="n">READ</span><span class="o">);</span>
 <span class="o">}</span>
 </code></pre></div>
-<p>This will call the activity and cause a prompt to appear asking for the 
permission.  Once the user has the permission, the result must be handled with 
the <code>onRequestPermissionResult</code> method, which
+<p>This will call the activity and cause a prompt to appear, asking for the 
permission.  Once the user has the permission, the result must be handled with 
the <code>onRequestPermissionResult</code> method, which
 every plugin should override.  An example of this can be found below:</p>
 <div class="highlight"><pre><code class="language-java" data-lang="java"><span 
class="kd">public</span> <span class="kt">void</span> <span 
class="nf">onRequestPermissionResult</span><span class="o">(</span><span 
class="kt">int</span> <span class="n">requestCode</span><span 
class="o">,</span> <span class="n">String</span><span class="o">[]</span> <span 
class="n">permissions</span><span class="o">,</span>
                                          <span class="kt">int</span><span 
class="o">[]</span> <span class="n">grantResults</span><span class="o">)</span> 
<span class="kd">throws</span> <span class="n">JSONException</span>
@@ -3001,7 +3001,7 @@ every plugin should override.  An exampl
     <span class="o">}</span>
 <span class="o">}</span>
 </code></pre></div>
-<p>The switch statement above would return from the prompt and depending on 
the requestCode that was passed in, it would call the method.  It should be 
noted that permission prompts may stack if the execution is not handled 
correctly, and that this should be avoided.</p>
+<p>The switch statement above would return from the prompt and, depending on 
the requestCode that was passed in, would call the respective method.  It 
should be noted that permission prompts may stack if the execution is not 
handled correctly, and that this should be avoided.</p>
 
 <p>In addition to asking for permission for a single permission, it is also 
possible to request permissions for an entire group by defining the permissions 
array, as what is done with the Geolocation plugin:</p>
 <div class="highlight"><pre><code class="language-java" data-lang="java"><span 
class="n">String</span> <span class="o">[]</span> <span 
class="n">permissions</span> <span class="o">=</span> <span class="o">{</span> 
<span class="n">Manifest</span><span class="o">.</span><span 
class="na">permission</span><span class="o">.</span><span 
class="na">ACCESS_COARSE_LOCATION</span><span class="o">,</span> <span 
class="n">Manifest</span><span class="o">.</span><span 
class="na">permission</span><span class="o">.</span><span 
class="na">ACCESS_FINE_LOCATION</span> <span class="o">};</span>

Modified: cordova/site/public/feed.xml
URL: 
http://svn.apache.org/viewvc/cordova/site/public/feed.xml?rev=1825144&r1=1825143&r2=1825144&view=diff
==============================================================================
--- cordova/site/public/feed.xml (original)
+++ cordova/site/public/feed.xml Fri Feb 23 17:45:39 2018
@@ -6,8 +6,8 @@
 </description>
     <link>https://cordova.apache.org/</link>
     <atom:link href="https://cordova.apache.org/feed.xml"; rel="self" 
type="application/rss+xml"/>
-    <pubDate>Fri, 23 Feb 2018 17:13:24 +0000</pubDate>
-    <lastBuildDate>Fri, 23 Feb 2018 17:13:24 +0000</lastBuildDate>
+    <pubDate>Fri, 23 Feb 2018 17:20:54 +0000</pubDate>
+    <lastBuildDate>Fri, 23 Feb 2018 17:20:54 +0000</lastBuildDate>
     <generator>Jekyll v2.5.3</generator>
     
       <item>



---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscr...@cordova.apache.org
For additional commands, e-mail: commits-h...@cordova.apache.org

Reply via email to