summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
author Joe Fernandez <joefernandez@google.com> 2014-09-03 23:36:30 +0000
committer Android Git Automerger <android-git-automerger@android.com> 2014-09-03 23:36:30 +0000
commit14a5d2bd4d6568af39f031d45a1621fa3e39fe60 (patch)
tree0af3d248bd2723c264218466cda5d01ad7057bbb
parentdef58cbffc32d12445b60ed1a0d8bb81d8dc6625 (diff)
parenta1a3c8a126032596b722d9faa74c616a4a8974e7 (diff)
am a1a3c8a1: am 9de22952: am ab833be6: Merge "docs: Fix bug with Accessibility Services dev guide" into klp-modular-docs
* commit 'a1a3c8a126032596b722d9faa74c616a4a8974e7': docs: Fix bug with Accessibility Services dev guide
-rw-r--r--docs/html/guide/topics/ui/accessibility/services.jd30
1 files changed, 18 insertions, 12 deletions
diff --git a/docs/html/guide/topics/ui/accessibility/services.jd b/docs/html/guide/topics/ui/accessibility/services.jd
index c8680800da06..d69af9f1ca86 100644
--- a/docs/html/guide/topics/ui/accessibility/services.jd
+++ b/docs/html/guide/topics/ui/accessibility/services.jd
@@ -71,24 +71,30 @@ accessibility service.</p>
<h3 id="service-declaration">Accessibility service declaration</h3>
-<p>In order to be treated as an accessibility service, your application must include the
+<p>In order to be treated as an accessibility service, you must include a
{@code service} element (rather than the {@code activity} element) within the {@code application}
-element in its manifest. In addition, within the {@code service} element, you must also include an
+element in your manifest. In addition, within the {@code service} element, you must also include an
accessibility service intent filter. For compatiblity with Android 4.1 and higher, the manifest
must also request the {@link android.Manifest.permission#BIND_ACCESSIBILITY_SERVICE} permission
as shown in the following sample:</p>
<pre>
-&lt;application&gt;
- &lt;service android:name=&quot;.MyAccessibilityService&quot;
- android:label=&quot;@string/accessibility_service_label&quot;
- android:permission=&quot;android.permission.BIND_ACCESSIBILITY_SERVICE&quot&gt;
- &lt;intent-filter&gt;
- &lt;action android:name=&quot;android.accessibilityservice.AccessibilityService&quot; /&gt;
- &lt;/intent-filter&gt;
- &lt;/service&gt;
- &lt;uses-permission android:name="android.permission.BIND_ACCESSIBILITY_SERVICE" /&gt;
-&lt;/application&gt;
+&lt;manifest&gt;
+ ...
+ &lt;uses-permission ... /&gt;
+ ...
+ &lt;application&gt;
+ ...
+ &lt;service android:name=&quot;.MyAccessibilityService&quot;
+ android:label=&quot;@string/accessibility_service_label&quot;
+ android:permission=&quot;android.permission.BIND_ACCESSIBILITY_SERVICE&quot&gt;
+ &lt;intent-filter&gt;
+ &lt;action android:name=&quot;android.accessibilityservice.AccessibilityService&quot; /&gt;
+ &lt;/intent-filter&gt;
+ &lt;/service&gt;
+ &lt;uses-permission android:name="android.permission.BIND_ACCESSIBILITY_SERVICE" /&gt;
+ &lt;/application&gt;
+&lt;/manifest&gt;
</pre>
<p>These declarations are required for all accessibility services deployed on Android 1.6 (API Level