diff options
| author | John Spurlock <jspurlock@google.com> | 2012-10-01 09:30:49 -0400 |
|---|---|---|
| committer | John Spurlock <jspurlock@google.com> | 2012-10-01 16:57:13 -0400 |
| commit | 3a4d41a654bf00972da9013854ba0e15b2c01fe9 (patch) | |
| tree | de294331dcc0b80affc478427e7990e53e62f056 /core/java/android | |
| parent | 135e5fb71242b1151929e2ea7bf221ff421e6ad2 (diff) | |
| download | frameworks_base-3a4d41a654bf00972da9013854ba0e15b2c01fe9.zip frameworks_base-3a4d41a654bf00972da9013854ba0e15b2c01fe9.tar.gz frameworks_base-3a4d41a654bf00972da9013854ba0e15b2c01fe9.tar.bz2 | |
Update javadocs for DreamService.
Reflect the new intent-filter protocol, and add a bit about <dream>.
Also escape xml so it's visible in generated html.
Bug:7256474
Change-Id: Id270eeb70601b492458834f19216801b428af4cb
Diffstat (limited to 'core/java/android')
| -rw-r--r-- | core/java/android/service/dreams/DreamService.java | 26 |
1 files changed, 16 insertions, 10 deletions
diff --git a/core/java/android/service/dreams/DreamService.java b/core/java/android/service/dreams/DreamService.java index f97354f..03b685b 100644 --- a/core/java/android/service/dreams/DreamService.java +++ b/core/java/android/service/dreams/DreamService.java @@ -47,24 +47,30 @@ import com.android.internal.policy.PolicyManager; * * <p>Dreams should be declared in the manifest as follows:</p> * <pre> - * {@code - * <service + * <service * android:name=".MyDream" * android:exported="true" * android:icon="@drawable/my_icon" * android:label="@string/my_dream_label" > * - * <intent-filter> - * <action android:name="android.intent.action.MAIN" /> - * <category android:name="android.intent.category.DREAM" /> - * </intent-filter> + * <intent-filter> + * <action android:name="android.service.dreams.DreamService" /> + * <category android:name="android.intent.category.DEFAULT" /> + * </intent-filter> * - * <!-- Point to additional information for this dream (optional) --> - * <meta-data + * <!-- Point to additional information for this dream (optional) --> + * <meta-data * android:name="android.service.dream" * android:resource="@xml/my_dream" /> - * </service> - * } + * </service> + * </pre> + * <p>If specified, additional information for the dream is defined using the + * <code><{@link android.R.styleable#Dream dream}></code> element. For example:</p> + * <pre> + * (in res/xml/my_dream.xml) + * + * <dream xmlns:android="http://schemas.android.com/apk/res/android" + * android:settingsActivity="com.example.app/.MyDreamSettingsActivity" /> * </pre> */ public class DreamService extends Service implements Window.Callback { |
