Skip to content
Commit 1b73896e authored by Evan Laird's avatar Evan Laird
Browse files

Phase 1 of status bar system event animations

Sketch of how things might work:
    - SystemEventCoordinator ties together arbitrary events and funnels
      them to the scheduler
    - Scheduler - a very simple prioritization and scheduling utility,
      since we don't want a spammy status bar
    - Animation controller - this class is probably going to evolve the
      most. Once an animation has a clear path, this class will actually
      make sure views are visible and allow individual view to animate
      in and out properly. It also potentially keeps the status bar open
      in immersive mode

This CL stands up a couple of things meant to achieve system animations
(currently only privacy items) that live in the status bar:

  1. SystemStatusAnimationScheduler - simple prioritization queue
     which can take requests to play system status animations. It also
     handles the running of said animations by maintaining
     ValueAnimators and providing callbacks for the system to get out of
     the way while animations are happening.

  2. SystemEventCoordinator - This is the front end for generating
     system events which trigger animations. Pretty simple, it sends
     StatusEvent objects to the scheduler to maybe play the relevant
     animation.

  3. StatusEvent - Events are sent to be scheduled, and wrap a priority
     int. They also create the view that is to be animated (still WIP)

  4. SystemStatusChipAnimationController - handles the presentation of
     the chip view. Still needs to be updated with prettier animations

  5. PrivacyDotViewController - the most bespoke of classes added here.
     controls the location of the privacy dots (more on this below)

System spaces are expected to listen for callbacks from the scheduler
and do whatever is appropriate to get out of the way. E.g., hide the
status bar system elements, keep the status bar window open in immersive
mode, or hide keyguard elements.

And finally, a note on the dot: for reasons(tm), the dot lives in
ScreenDecorations. But since screen decorations creates very special
windows that don't "just rotate", the locations are controlled by the
PrivacyDotController. However, to create the illusion that the dots are
in the status bar, they are always positioned on either side of where
the status bar happens to be.

Bug: 177323724
Test: coming soon to a theater near you
Change-Id: If528bd7e9d1e0ca3be7391f83f7416fa10e7a41b
parent 1198ed06
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment