Skip to content
Commit 6861e91b authored by Galia Peycheva's avatar Galia Peycheva
Browse files

Make DreamService use an Activity

Currently, the DreamService uses a floating Window to display the
content of the dream on the screen. This introduces difficulties in the
interactions with the Assistant application, which is an activity.
By design, if the Assistant is invoked while the device is dreaming, the
Assistant should be shown on top. However, since floating windows are
always drawn on top of all activities, the Assistant can't be shown on
top of the Dream.

Here, we migrate the implementation of the DreamService to use an
Activity (DreamActivity). Since the screensaver application is not part
of the framework, we can't declare the activity in their AndroidManifest.xml.
Therefore, we start the dream activity with a dedicated method in
ActivityTaskManagerService.

Bug: 133216167
Test: 1. m && ./vendor/google/tools/flashall
      2. Go to Settings > Device Preferences > Screensaver > Start now
      3. Verify dream appears
      4. Click any key to wake up the dream
      5. Verify that dream disappears

Merged-In: I8dff0a124cd1b41fb925a73528305431b49ee06d
Change-Id: I8dff0a124cd1b41fb925a73528305431b49ee06d
(cherry picked from commit 148478a8)
parent a8e46412
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment