• Home
  • History
  • Annotate
  • only in /frameworks/base/packages/SystemUI/src/com/android/systemui/keyguard/
History log of /frameworks/base/packages/SystemUI/src/com/android/systemui/keyguard/
Revision Date Author Comments (<<< Hide modified files) (Show modified files >>>)
b35b11f4cad12b7c746c9e006ff8d5e3d4f6a0f4 20-Jun-2017 Pavel Grafov <pgrafov@google.com> Provide content description for WorkLockActivity.

This way the activity can be brought to foreground using TalkBack
in split-screen and free-form window mode.

Bug: 62814166
Test: Manually.
Change-Id: Idf3a0235fe7ec076b0f1d1f7b88e8b9e237e2d46
orkLockActivity.java
e3e0b06a12ee7ef17d07b34f26fa2a54ce4de6e0 12-Jun-2017 Jorim Jaggi <jjaggi@google.com> Attempted fix for navigation bar flicker

Not 100% sure why it was flickering, but I do know that the
flicker started happening after putting this into a separate
thread, and that with that change it doesn't flicker anymore,
ever.

Adds 0.5ms while unlocking but at this point this is a good trade-
off to make.

Test: Unlock device with FP
Change-Id: I736a3c64d9b63df9d6cdcb7855bde13a19560a83
Fixes: 62380221
eyguardViewMediator.java
b4045d3791566a1965024591def87dff7d120295 17-Mar-2017 Andrew Zeng <zenga@google.com> Notify keyguard of when power button is pressed.

This is done on wear power button doesn't turn off the screen,
when the device wakes from keyguard UI isn't visible yet, so
it needs to react to power press in some way.

Bug: 35147955
Change-Id: I22619ea446770d09b53370e9244215646b60a9db
eyguardService.java
eyguardViewMediator.java
e85f8eb0ca7f7b9788512f85bb1f117a9de3f7d7 19-May-2017 Jorim Jaggi <jjaggi@google.com> Merge "Fix ordering of notifying dismiss callback" into oc-dev
5277deaa591cabb163fa7ad0b139219c3f13313c 18-May-2017 Jorim Jaggi <jjaggi@google.com> Fix ordering of notifying dismiss callback

Otherwise all unlocks will result in onDismissCancelled.

Also fixes a race condition bug where we call
reportKeyguardShowingChanged but we don't wait until the state is
updated. Then, we called onDismissSucceeded such that
KeyguardManager.isDeviceLocked would still return true. Fix this
by waiting for the message to be processed.

Note that delays shouldn't be a problem here as we are soon
calling reportKeyguardShowingChanged from the UiOffloadThread.

Test: KeyguardLockedTests
Change-Id: I0b312a5f02be3a3d1028d8bf0cd1b8e6a33476ce
Fixes: 38219395
eyguardViewMediator.java
e549a8d62108c7c7dabedbf4e77b9a653781723b 15-May-2017 Jorim Jaggi <jjaggi@google.com> Optimize latency when unlocking phone

Latency when unlocking the phone regressed a bit for two reasons:
- For lockscreen -> app we now have to create a full starting
window containing the snapshot, while previously this was just
showing a surface.
- For lockscreen -> home, we can't use the saved surface anymore
because currently we don't support snapshotting translucent
activities. However, in the long term, we want home screen to be
more involved into transitions anyways, so we'll have to wait for
the first frame draw anyways.

However, crystal ball trainee developer Jorim added some
artificial latency in this transition 3 years ago, because he knew
that it is going to be an issue at some point so we have some
headroom to improve! Genius! On a more serious note, it was because
he didn't understand how to read systraces with binders involved (to
be fair, there was also no binder tracing).

Now, we can completely fix the introduces latencies above by
removing this latency of 100ms, and we are 30-70ms better than
before! However, this requires a lot of discipline in SystemUI.
Currently, the callback to dismiss Keyguard takes around 30ms. By
moving all non-essential binder calls of the main thread or to the
next frame, we bring this down to 5ms, such that window animation
and Keyguard animation starts about at the same time.

Test: Take systrace, unlock phone...profit!

Fixes: 38294347
Change-Id: I481fe4ecf358ed09f7142dd9e7ecd290b53c500c
Merged-In: I3ea672bc2eca47221bc6c9f3d7c56b6899df207d
ismissCallbackRegistry.java
eyguardViewMediator.java
775699dc0560ea3768c7228a34043c055e009789 15-May-2017 Evan Rosky <erosky@google.com> Merge "Post setSwitchingUser to main thread" into oc-dev
4be9b2ca3eb18bfbe00be853721ee804105cd247 15-May-2017 TreeHugger Robot <treehugger-gerrit@google.com> Merge "Keyguard shouldn't listen to FP if bouncer showing and keyguard dismissing" into oc-dev
6db7d5fc84ae67cc0d11b0cd376b5cf21a1fafd3 04-May-2017 Kevin Chyn <kchyn@google.com> Keyguard shouldn't listen to FP if bouncer showing and keyguard dismissing

There's a race condition if user unlocks from bouncer and an app underneath
uses FP does onResume()

If a user has an application that's authenticating via FP underneath
keyguard and the user dismisses keyguard via bouncer, the app underneath
will get kicked out since onKeyguardVisibilityChanged(false) calls
shouldListenForFingerprint() during this race.

Keyguard shouldn't listen to FP if bouncer is showing but keyguard is
dismissing

Fixes: 37967985
Test: 1) open FP settings
2) enter keyguard and go to bouncer
3) unlock keyguard via pin/pattern/password (NON FP method)
4) tap any finger on sensor (should vibrate)

Merged-In: Ie38d55e6a1ec9b49f9df0c7520d0bc451315c161
Change-Id: Ie38d55e6a1ec9b49f9df0c7520d0bc451315c161
eyguardViewMediator.java
4e44fcedadf5a43ffabbe71f10181bb2b6b87c78 11-May-2017 Evan Rosky <erosky@google.com> Post setSwitchingUser to main thread

touching view hierarchy should only occur on UI thread

Bug: 37167272
Test: keyguard still works, used Log to see that switching
still gets called
Change-Id: I45ed9894a8f08c38da40de44f84e99cddb683014
eyguardViewMediator.java
b3d265caaabf6ee9e32b81855dfc944447a39817 13-May-2017 Bryce Lee <brycelee@google.com> Merge "Introduce result ranges for activity start return results." into oc-dev
7f9368637c8d2726b87cbe184b240512055da037 10-May-2017 Bryce Lee <brycelee@google.com> Introduce result ranges for activity start return results.

The return result from starting activity actually represents two
pieces of information. First, it conveys whether the activity
started. Secondly, it conveys whether there was a fatal error if
the activity did not start. Many parts of the code assume that a
value greater than or equal to the defined success means that the
activity successfully started. This is not the case as there are a
number of results greater than success where the activity does not
start.

This change addresses the issue by introducing three distinct
result ranges. The first represents results where the activity
could not start due to a fatal error. The second represents results
where the activity did not start due to a non-fatal error. The last
range represents successful activity starts. Two convenience methods
have been added to ActivityManager to return whether the result
represents a fatal error and whether the result was successful.

Change-Id: Ifaf844c353641a28b03b3c2d7b6be053fd9b8b44
Fixes: 38021882
Test: cts-tradefed run cts-dev --module DevicePolicyManager --test com.android.cts.devicepolicy.DeviceOwnerTest#testLockTask_deviceOwnerUser
orkLockActivityController.java
7687aaa9a77a44185df7316713603d6782044bd9 12-May-2017 Jorim Jaggi <jjaggi@google.com> Don't set keyguard state to showing when service disabled

Test: Create restricted profile, reboot
Change-Id: I7c9b215054e6041ff7fb71cb1aaf0e07ad01039c
Fixes: 37221109
eyguardViewMediator.java
4726ae362b807a76c82d7ce112009d4dde680599 09-May-2017 Jorim Jaggi <jjaggi@google.com> Make sure to notify client after Keyguard has been dismissed

To avoid race conditions.

Test: KeyguardLockedTests
Change-Id: I7e2cfaeb7c84f11a24a2889c0fa18ba2f7d241e2
Fixes: 38040006
eyguardViewMediator.java
291df4fc0c3fc7a28bf0d89619b7e7bc0ea672e1 14-Mar-2017 Chad Brubaker <cbrubaker@google.com> Expose Intents to Instant Apps

This exposes Intents used by Android widgets to Instant Apps.

The following Intents are exposed:
Intent.ACTION_TIME_TICK
Intent.ACTION_DATE_CHANGED
Intent.ACTION_TIMEZONE_CHANGED
Intent.ACTION_TIME_CHANGED
Intent.ACTION_CONFIGURATION_CHANGED
Intent.ACTION_LOCALE_CHANGED
Intent.ACTION_SCREEN_OFF
Intent.ACTION_SCREEN_ON
Intent.ACTION_USER_PRESENT

Bug: 33350280
Test: Manually verified that broadcasts are received.
Change-Id: Ife94f594c1ff30f2625a57e1cc69f36cc00d1f34
eyguardViewMediator.java
2f6272ec7dfae348e2f4352ae7cae822a24b7eb6 16-Mar-2017 Selim Cinek <cinek@google.com> Fixed a bug where the notifications could get stuck animating

Notifications could get stuck in the middle of an animation
when the occlusion changed.

Test: launch camera, turn screen off, observe no animation when waking up
Change-Id: I414b9a5f7b01db2f4e2a3198647084f5e2582e8b
Fixes: 34734460
eyguardViewMediator.java
1d996bd7fc6bda5533866e11278184c67513a877 01-Feb-2017 Robin Lee <rgl@google.com> Remove locked user tasks if starting overlay fails

This is a more graceful failure case than giving up and just letting
the task show unmodified on the screen if something goes wrong.

Test: runtest -x WorkLockActivityControllerTest.java
Bug: 31001762
Fix: 31064912
Change-Id: I505c00f411f41fb927c31d2280bdeda69e15b4d4
orkLockActivityController.java
3cb867326ae9d79cc8035ad9fa6c1d656946692f 14-Feb-2017 Robin Lee <rgl@google.com> Merge "Theme work lock activity with the task primaryColor"
3c82d3d5bfea9b6483ad0264e6956eb5a00a2a4a 19-Jan-2017 Robin Lee <rgl@google.com> Theme work lock activity with the task primaryColor

This involves adding another system RPC, getTaskDescription(taskId)
gated on MANAGE_ACTIVITY_STACKS permission.

Bug: 31001762
Test: runtest -x frameworks/base/packages/SystemUI/tests/src/com/android/systemui/keyguard/WorkLockActivityTest.java
Change-Id: Ieb996f7fab5bc79737df570e35733551118118d3
orkLockActivity.java
orkLockActivityController.java
421a9410b462770544c6ae9a554542fa2fe1acb1 06-Feb-2017 Jason Monk <jmonk@google.com> SysUI: Add method for plugins to keep status bar full screen

Lots of things detect overlays these days (installing apps) and the
only way to avoid the problems associated with this is to live in
the status bar window. So allow plugins to hold the window open
when they want to so they can have overlays be in that.

Move StatusBarWindowManager to Dependency to make things easier
as well.

Test: Install the example plugin, test can access QS and interact
with apps

Change-Id: Ib2288bf56704960847217bad01a480ab407e0ffe
eyguardViewMediator.java
2a6ea9c2a1b52b0386270ec73e1e6d6a9b614a34 26-Jan-2017 Jason Monk <jmonk@google.com> Delete BaseStatusBar

It is a relic of a more complex time, but has passed out of all
knowledge for too long.

Test: manual testing on phones and TV
Change-Id: I62a15d9413ea4bda3ac82bf6f7d22c096e2c1cdc
eyguardViewMediator.java
588a3337419d33005555d80594256b364593b35f 18-Jan-2017 Robin Lee <rgl@google.com> Launch work lock scrim as clear_top not single_top

SINGLE_TOP is only guaranteed to work within the current task stack.
If multiple stacks are inactive in the background (eg. temporarily
switching from freeform mode to fullscreen mode by maximising one
activity) some tasks might get missed out and stay visible.

Test: manual -- start two work activities, one in fullscreen & one in freeform. start a personal
Test: activity in freeform too. switch to the fullscreen work app and lock the profile using
Test: `adb shell service call trust 6 i32 $USER_ID i32 1`
Test: __outcome after change__
Test: a) locking work profile should bring up the work password prompt in fullscreen
Test: b) skipping the prompt and switching to the personal freeform app should keep the freeform
Test: work app hidden by WorkLockActivity
Test: __outcome before change__
Test: Only (a) happened, for step (b) the work app was still visible
Bug: 31001762
Change-Id: I5979c5b12670a21c7bcd59e222fc518d395e3e29
orkLockActivityController.java
5d59242c2ec590c5bc57744d4a7ab62890cc76c8 18-Jan-2017 Robin Lee <rgl@google.com> Animate starting work challenge from work lock

Bug: 31001762
Test: adb shell service call trust 6 i32 10 i32 1 && adb shell am start -a com.android.systemui.recents.TOGGLE_RECENTS
Change-Id: Ic6c622c32718bd235eb71704881b853072383dba
orkLockActivity.java
f793d87b805f204473d130ce29ece72ff1b3cec6 18-Jan-2017 Robin Lee <rgl@google.com> Don't set a task description for work lock overlay

Just use the one in the previous activity on the task stack, it's less
code and also has the benefit that if anything new happens in that
activity, all of the observers will be notified about the new
description straight away.

Bug: 29244275
Test: adb shell service call trust 6 i32 10 i32 1 && adb shell am start -a com.android.systemui.recents.TOGGLE_RECENTS
Change-Id: I56d3b627ccda82cd2a2e520de0e170e4fa4acc77
orkLockActivity.java
cbcadc981b927b13ccc6e76614f5cccc0c0fe402 13-Jan-2017 Winson Chung <winsonc@google.com> Ensure that we always resume task overlay activities if requested.

- Distinguish between task overlays that need to be resumed and
those that should not.

Bug: 34240533
Test: Open PiP, tap to show menu.
Change-Id: Ibdb54d544c501a492260f02cdc2de40c5c1a66d1
orkLockActivityController.java
ad0118a358250e2c53a3fdd057cc30910fc47c31 11-Jan-2017 Robin Lee <rgl@google.com> Show work unlock prompt on focus as well as touch

With change I4576aaafa141ef5297f9c18935b747693a80f0fd we can be
reasonably sure this isn't going to instantly bring the prompt into
fullscreen, since launching this activity as an overlay in an
unfocused task won't bring it to the front.

But if it's launched in a focused task, it will get focused and
brought to the front, starting the unlock process. This saves us a
click, and user frustration, and is generally a good thing.

Bug: 31001762
Test: //tests/PoApi/src/com/google/android/afwtest/poapi/WorkChallengeTest (harness)
Change-Id: Ic5a33589e2b63d04e47c5f166da0077188cb55ea
orkLockActivity.java
c41f6ec877309d9c73168ef8cdc277f82eb0d42e 10-Jan-2017 Robin Lee <rgl@google.com> Lock work tasks from SystemUI instead of ActivityStarter

By adding an onTaskProfileLocked(taskId, userId) RPC to
TaskStackListener and routing that through to a new WorkLockController.

Bug: 31001762
Test: //tests/PoApi/src/com/google/android/afwtest/poapi/WorkChallengeTest
Change-Id: I3fd28e6926c3f928e78b3c6ce0fe27413617695f
eyguardViewMediator.java
orkLockActivityController.java
3fef1f284390a2ff7a58e0dcd56cb90bf83d2017 20-Dec-2016 Robin Lee <rgl@google.com> Bounce work challenge through a WorkLockActivity

This stops us from depending on Settings for keeping the work profile
secure. Instead that is delegated to a smaller Activity inside SystemUI
which has just two jobs:

1) Don't let anyone see the content that's supposed to be locked.

2) Start ConfirmCredentialsActivity (still lives in Settings for now)

Bug: 31001762
Test: //cts/hostsidetests/devicepolicy/src/com/android/cts/devicepolicy/MixedManagedProfileOwnerTest#testResetPasswordFbe
Test: //tests/PoApi/src/com/google/android/afwtest/poapi/WorkChallengeTest
Change-Id: If43820b683007a60a37edf32fb65b442a8fb709b
orkLockActivity.java
58ffefa40f1272eb539e1a5ea9fc6d2fb8d98920 28-Dec-2016 Adrian Roos <roosa@google.com> Keyguard: Don't lock on SIM removed during shutdown am: 1f8025adf2
am: c30dc190ba

Change-Id: Ic0b38d7d66f702241ee1d9df7e433076cc40485e
1f8025adf287d96de682de57f18277e2dd523fe1 27-Dec-2016 Adrian Roos <roosa@google.com> Keyguard: Don't lock on SIM removed during shutdown

Fixes a glitch where the SIM is considered removed because
we turn off the radio during shutdown.

Change-Id: Id783114f557b87051b833ea84cecc862f910c6ca
Fixes: 33788000
eyguardViewMediator.java
390a05647407667e2ded84c1874395343ad7ddb0 14-Dec-2016 Adrian Roos <roosa@google.com> Keyguard: Don't lock if SIM is NOT_READY am: e92de95261
am: 6f65fad606

Change-Id: If7fdff7be0851bb3f6141ca0a5362d964c415f5d
e92de95261f45ff9f8b7374eddca63e17866592a 13-Dec-2016 Adrian Roos <roosa@google.com> Keyguard: Don't lock if SIM is NOT_READY

Fixes an issue with MVNOs where the lockscreen
would show in response to a virtual SIM switch.

Now we no longer lock with NOT_READY.

Change-Id: I520200311a5ae3218f1743b1fc9a568c39933ebf
Fixes: 33386149
Bug: 30997251
Test: Set up secure lockscreen, insert Fi SIM, dial *#*#346398#*#*, verify screen does not lock, eject SIM, verify screen locks.
eyguardViewMediator.java
59686605253511d7a68ed14c9b78c2a074917f38 05-Dec-2016 Jorim Jaggi <jjaggi@google.com> Merge "Don't disable search on Keyguard"
fd61f222103e9802610cf404883d0d8f04e0eb2d 29-Nov-2016 Adrian Roos <roosa@google.com> DO NOT MERGE Show keyguard when SIM is removed

If the device has a secure lockscreen and the device'
SIM card is removed, lock the device.

Change-Id: I0369af81297169d65254b85bc9a056e4f4a02b7b
Merged-In: I5b0deea8851b38781059732a3cf6fa0a4a00e3ca
Fixes: 30997251
eyguardViewMediator.java
1cffe3c31f386fda9f10a80bcf7048c232e49a47 29-Nov-2016 Adrian Roos <roosa@google.com> Show keyguard when SIM is removed

If the device has a secure lockscreen and the device'
SIM card is removed, lock the device.

Change-Id: I5b0deea8851b38781059732a3cf6fa0a4a00e3ca
Fixes: 30997251
Test: set up lock screen, insert SIM card, unlock phone, remove SIM card, observe that screen is locked
eyguardViewMediator.java
d25cf04e9880c69d370bab21de0068cec5502267 29-Nov-2016 TreeHugger Robot <treehugger-gerrit@google.com> Merge "Add explicit method to dismiss Keyguard"
3448bdd3401dea4ec25e4fe99142a10235d155f2 29-Nov-2016 Jorim Jaggi <jjaggi@google.com> Don't disable search on Keyguard

Test: Long-press home while Keyguard is occluded, make sure voice
interactor is invoked.
Bug: 33110839

Change-Id: I24a31e1a8a4d7ab9706cdbdb76123165c73e5052
eyguardViewMediator.java
241ae10b2189f449e57d8d660235ac56d8fb1b80 03-Nov-2016 Jorim Jaggi <jjaggi@google.com> Add explicit method to dismiss Keyguard

The flag is a bit clunky for most cases, and a method is more
clear.

Test: cts/hostsidetests/services/activityandwindowmanager/util/run-test
android.server.cts.KeyguardTests

Test: cts/hostsidetests/services/activityandwindowmanager/util/run-test
android.server.cts.KeyguardLockedTests

Test: runtest systemui -c
com.android.systemui.keyguard.DismissCallbackRegistryTest

Bug: 30961403
Bug: 27422134
Change-Id: I39de90c7cfecd99350a74f72cd76418e337f2b79
ismissCallbackRegistry.java
ismissCallbackWrapper.java
eyguardService.java
eyguardViewMediator.java
c52f867875ed7f671bf897f11e359e8104ce8795 18-Nov-2016 Michal Karpinski <mkarpinski@google.com> Strong auth timeout for trust agents

The fingerprint timeout tracking in KeyguardUpdateMonitor has been
extended with use of StrongAuthTracker.

Test: timeout will be CTS tested, testing of unlocking TBD
Bug: 29825955
Change-Id: I5cc49ef46631c412f2d1db88e68a308322b27027
eyguardViewMediator.java
dc589ac82b5fe2063f4cfd94c8ae26d43d5420a0 11-Nov-2016 Sudheer Shanka <sudheersai@google.com> Update usage of ActivityManagerNative.

- Remove references to ActivityManagerProxy.
- Add isSystemReady to ActivityManager.

Bug: 30977067
Test: cts/hostsidetests/services/activityandwindowmanager/util/run-test android.server.cts
adb shell am instrument -e class com.android.server.am.ActivityManagerTest,com.android.server.am.TaskStackChangedListenerTest \
-w com.android.frameworks.servicestests/android.support.test.runner.AndroidJUnitRunner
Change-Id: I07390b6124fb1515821f5c0b37baf6ae74adc8fa
eyguardViewMediator.java
186ea0f170231d5de474738fd07fd2284b097a15 10-Nov-2016 TreeHugger Robot <treehugger-gerrit@google.com> Merge changes I93b8ed74,I43decfee

* changes:
Update callbacks when initializing to initial state
UI Keyguard fixes
e8f321e7495e2c9e61e7dea61c0ccc543768c80f 08-Nov-2016 Jorim Jaggi <jjaggi@google.com> Update callbacks when initializing to initial state

This fixes a bug where activity manager was not informed about the
lockscreen state if Keyguard was disabled and SystemUI crashed, so
we just displayed a black screen.

Test:
- Set no lockscreen
- Crash SystemUI

Change-Id: I93b8ed74dd12af6903ffdb05b59c78f2f12febb4
eyguardViewMediator.java
8d5a6e7ce3c74fb4cebc0ac388e5fcf92e04cecf 03-Nov-2016 Jorim Jaggi <jjaggi@google.com> UI Keyguard fixes

- Streamline the various keyguardDone paths. The keyguard will be
dismissed if and only if both the hide animation has run and the
Keyguard is ready for dismissal. This fixes a bug in which the
hide animation was not run.
- When we get an external dismiss call, make sure to collapse the
panel as well.
- When we execute an action and Keyguard is occluded, we execute
if after the Keyguard is gone so there are no weird transition
because Keyguard might get unoccluded.

Test: Manual for the above flows.

Bug: 30961403
Bug: 27422134
Change-Id: I43decfeec270c4ed628bd9479109150c57201dae
eyguardViewMediator.java
e9d8272e9af29232471dc2c690675362494f5b0a 08-Nov-2016 Adrian Roos <roosa@google.com> Keyguard: Fix screenTurnedOn trace tag

Test: run systrace, check tags are correct
Change-Id: I7c7bbc103d20daedb708997b7a7f40e9e3dcb8d3
eyguardService.java
8d78693157cb3fa7ab1c9072ef913af4d67c6314 27-Oct-2016 Jorim Jaggi <jjaggi@google.com> The big keyguard transition refactor (6/n)

Cleanup:
- Make sure all the state is nicely dumped.
- Remove some unused stuff.
- Fix a flicker when occluded -> unlocked

Bug: 32057734
Change-Id: Id87e26adccef740d608b325c2dc1f6db14dd4ec3
eyguardService.java
eyguardViewMediator.java
fe762344f4475a3a336bb46aef2d59c1fabf32ab 13-Oct-2016 Jorim Jaggi <jjaggi@google.com> The big keyguard transition refactor (1/n)

The heart of this change are two things:
1) Instead of using the force hide mechanism to hide windows behind
Keyguard, we actually make the activities invisible in activity manager.
2) When Keyguard is going away, we change the visibilities in activity
manager and run an app transition.

At the very core we move the responsibility of hiding activities to
ActivityStack, which checks whether Keyguard is showing, and then
hides all non-show-when-locked activities. For that, we need to check
whether any window of an activity has SHOW_WHEN_LOCKED set. We
introduce a callback from WM -> AM in case these Keyguard flags have
changed.

Furthermore, we decide whether to occlude Keyguard in KeyguardController,
which just checks whether the top activity has SHOW_WHEN_LOCKED set. When
this state changes, we prepare an occlude/unocclude app transition, and
in PWM we just inform the Keyguard about the animation so SysUI can play
along this animations in a mostly synchronized manner.

Since we now use an app transition when unlocking the phone, we get
lockscreen launch animations for free - window manager automatically
waits until the activity is drawn, or directly executes the transition
if there is nothing to animate. Thus, we can remove all the infrastructure
around "waitingForActivityDrawn".

The logic to show/hide non-app windows is moved to policy, and we add the
ability to run animations on non-app windows when executing an app
transition.

Test:
1) runtest frameworks-services -c com.android.server.wm.AppTransitionTests
2) Manually test unlocking Keyguard:
2a) Without security
2b) With security
2c) With security but trusted
2d) Portrait while activity behind is in landscape
3) Test launching things from Keyguard
3a) Without security
3b) With security
3c) Launch camera without security
3d) Launch camera with security
3e) Launch camera with securtiy and trusted
3f) Launch voice affordance
4) Set no notifications on lockscreen, drag down, make sure you get
the correct animation
5) Test clicking "emergency" on bouncer
5b) Test "Emergency info" on emergency dialer
5c) Test clicking edit button on emergency info, should show pattern on
Keyguard

Bug: 32057734
Change-Id: Icada03cca74d6a612c1f988845f4d4f601087558
eyguardViewMediator.java
c3fe204780fb99b1d2563a9e4bb6c082b7517aed 07-Oct-2016 Jorim Jaggi <jjaggi@google.com> More latency tests (1/2)

- Move latency fake actions into a central location, LatencyTester
- Add latency test for screen turning on

Change-Id: I8aa3f475d56a4ee7a36b97bd6ece32e60c5851cd
eyguardViewMediator.java
9e60c1f55b894ec5f4dd679b8cbb7e1fcea31bdd 14-Sep-2016 Selim Cinek <cinek@google.com> Escalate HeadsUp when dreaming starts am: 994153944e am: 0234c7f164
am: 205e105306

Change-Id: Id3fc653d2ee1f01b732aea352c36d3fd63937ab4
994153944e6d76d1b1a060afb131129172a915d1 09-Sep-2016 Selim Cinek <cinek@google.com> Escalate HeadsUp when dreaming starts

1. When dreaming starts before locking, notifications can remain
pinned. This is because the device is locked without
screen off, and HeadsUp are not escalated.
As a result is the pinned heads up shown behind the bouncer
when unlocking.
In this case touchable bound is limited to headsup bounds,
so the user can't unlock at all.

2. Escalate HeadsUp when bar state changes to KEYGUARD

3. This also fixed a bug where the bouncer isn't touchable
When device is occluded and locked, HeadsUp can appear.
If the user then clicks on the HeadsUp and try to send
pending intent, Bouncer can be shown without expanding
panel.

Bug:30820511
Change-Id: I8604c9d00d839d773b32d8b913dfdcd2ed72f1dd
eyguardViewMediator.java
32cbdcc8c098b4a42212b3da345b929abad8ad6e 31-Aug-2016 Jorim Jaggi <jjaggi@google.com> resolve merge conflicts of c5bafe2 to master

Change-Id: I19dd5c88c664313c2f8b47d8f8fd556f630c8bf1
6626f54e658e3da44fab8a5cd6d9d3d4852e2cd1 22-Aug-2016 Jorim Jaggi <jjaggi@google.com> Add animation when unoccluding windows (1/2)

Before there was a jump-cut when a window that was occluding Keyguard
was going away, leading to an ugly flicker. To fix this, we do the
following.

- Always show windows with FLAG_SHOW_WHEN_LOCKED above lockscreen, even
if they don't "match" the currently occluding app (which is null in the
animation case)
- Move wallpaper behind last window that is not hidden by policy, so the
window doesn't get occluded by the wallpaper.
- Add a flag in the setOccluded call whether to animate or not. SystemUI
then plays a nice animation when it's set.
- Override the animation to always be the animation that happens when we
exit a window which is revealing the wallpaper behind, to make it
consistent with the home screen case.

Fixes: 30829255
Change-Id: Ib3fe20fc9003a0f9f291c974740f044ed8707e75
eyguardService.java
eyguardViewMediator.java
6fb0e52b85ebd5b31626703e3e0aea212ead70ac 18-Aug-2016 Jorim Jaggi <jjaggi@google.com> Fix a flicker when returning to the lockscreen am: d11d1a9486 am: afaf4ac7a9
am: 9322632f6a

Change-Id: I9cd7ead4caa2843e3063d55ea357e9e989c72f0e
d11d1a9486d44b98e28b70c25711ebfc283b746e 17-Aug-2016 Jorim Jaggi <jjaggi@google.com> Fix a flicker when returning to the lockscreen

If we return to the lockscreen from a FLAG_SHOW_WHEN_LOCKED activity,
there was an additional black flicker as the wallpaper wasn't shown
for a couple of frames. The issue is that we didn't set the wallpaper
flag again, to fix another flicker with lockscreen wallpapers. Now,
we pass the state whether we currently have a lockscreen wallpaper
and if we don't have one, we immediately set the wallpaper flag
again.

Bug: 30829255
Bug: 30883413
Change-Id: I9faeaa77b98eb02058171ce19cf90b43826ebe9e
eyguardViewMediator.java
367e0761c5af88b3b82ffd1c62bad374f40514e0 11-Aug-2016 Adrian Roos <roosa@google.com> Only disable trust agents after lockout am: 9d6fc9246b am: 73b2f5981e
am: bbf52f2e85

Change-Id: I4606854b24313cc8231aaa0ce3ea33ea909f68b0
9d6fc9246ba0b726872a6a8dabe6c334292c3a10 11-Aug-2016 Adrian Roos <roosa@google.com> Only disable trust agents after lockout

Previously trust agents would be disabled even after one
wrong attempt. Now we wait for the cooldown (usually 5 attempts),
the same as fingerprint.

Also adds a TrustArchive entry of when device policy changes are sent to
trust agents.

Bug: 30037948
Change-Id: I9e284d994ddae45ef66b5b8b601297c63d8ba667
eyguardViewMediator.java
13a58a91d362e74933b3064a65be4bf4449cfdc4 28-Jul-2016 Evan Rosky <erosky@google.com> Make user-switch transitions customizable

Make UserSwitcherController subclassable

Add ability for keyguard to animate in without a screen freeze
by adding a keyguardAnimatingIn state that WindowAnimator and
WallpaperController can use to prevent graphical glitches

Bug: 29329555
Change-Id: Idfd40156538b4bfb1777ad1a9a566e7da54e8f32
eyguardViewMediator.java
1839645126c8e7e0909e8ed8f0686c2122ba6078 28-Jul-2016 Evan Rosky <erosky@google.com> Add support for custom user-switch UI

Given config_customUserSwitchUi, AM/UserController will not show any
UI during user-switch (no dialog or screen-freeze).

Provides a mechanism (WM.setSwitchingUser) by which a custom user-switch
UI can notify WM/Keyguard when it expects a user-switch operation to
be running.

Bug: 29329555
Change-Id: Ic903fc251d7ec3a54bc6a77906d3afa45a6a5fac
eyguardService.java
eyguardViewMediator.java
92c9c4f3e6932958f5728705cb7ce1c255aa4a43 05-Aug-2016 Adrian Roos <roosa@google.com> Keyguard: Refactoring for improving trusted unlock while occluded am: d88eb2693b am: cb5642afae
am: bfe5166ac3

Change-Id: I760b5f4d780231b06ec8ef733a8a002c3dd2420d
cb5642afaeb4686e3613130d83223667a0857bc8 05-Aug-2016 Adrian Roos <roosa@google.com> Keyguard: Refactoring for improving trusted unlock while occluded
am: d88eb2693b

Change-Id: I91f6bfe7a0573ad31785c5a3d1bff03a24d1107c
c49dfaf4d6161471a68bbc08d947c5d697a507e2 05-Aug-2016 Adrian Roos <roosa@google.com> Merge changes from topic 'smooth_unlock' into nyc-mr1-dev

* changes:
Keyguard: Improve trusted unlock while occluded
Keyguard: Refactoring for improving trusted unlock while occluded
356955e9e5d6edfea55d699afe8b68f0744dee5a 05-Aug-2016 Jorim Jaggi <jjaggi@google.com> Call userActivity when dismissing keyguard am: b9d0491559 am: f564799b49
am: 501b0cbedd

Change-Id: I254c082fa58b28ea355599d79f71129363f53a38
0659029fd2ee5b4185f34e98ebd2b5d97c85ed16 05-Aug-2016 Jorim Jaggi <jjaggi@google.com> Fix flickering issues with FLAG_SHOW_WHEN_LOCKED and fingerprint wake am: e93e6f9deb am: f6929c4750
am: 864de6a179

Change-Id: Ide3b6febc8a2daf751a94a9ae8ae0d2bcfddf51f
f564799b49a21a72d73eaf17bd48788ca4acfb70 05-Aug-2016 Jorim Jaggi <jjaggi@google.com> Call userActivity when dismissing keyguard
am: b9d0491559

Change-Id: I4b688fae491a5bd7fb531eaf63d4f952657409cf
b11cc6cbd370a991eea4d9fecaa1f0eee5f9002f 05-Aug-2016 TreeHugger Robot <treehugger-gerrit@google.com> Merge "Call userActivity when dismissing keyguard" into nyc-mr1-dev
d88eb2693b6a70af0f5fbc5881ce855e28de33aa 04-Aug-2016 Adrian Roos <roosa@google.com> Keyguard: Refactoring for improving trusted unlock while occluded

- Adds a trusted signal from Keyguard to PhoneWindowManager
- Allows PhoneWindowManager to exempt DISMISS_KEYGUARD windows from force hiding
- Allows PhoneWindowManager to dismiss Keyguard while occluded

Bug: 27410215
Change-Id: I3ad490b64a5805b6f3888a9f37fcfbdd0116395e
eyguardService.java
eyguardViewMediator.java
b9d0491559bc1bdaac32ec068ffbad43517835a9 04-Aug-2016 Jorim Jaggi <jjaggi@google.com> Call userActivity when dismissing keyguard

So we don't run into weird race conditions which could leave Keyguard
unlocked.

Also add some missing debug statements for future investigation.

Change-Id: I7bd463f594d53ddfa84cebc28cf1f63dd2d6c533
Fixes: 28987945
eyguardViewMediator.java
e93e6f9deb8d3c044d673ffb771b73b2346486a3 04-Aug-2016 Jorim Jaggi <jjaggi@google.com> Fix flickering issues with FLAG_SHOW_WHEN_LOCKED and fingerprint wake

The whole sequence is different as Keyguard is occluded. Thus, we are not
doing the normal keyguard exit sequence, but jump directly to dismissing
the Keyguard.

Normally the sequence is:
- keyguardDone
- notifyScreenTurningOn
- startKeyguardExitAnim

In the occluded case, it is:
- keyguardDone
- startKeyguardExitAnim
- notifyScreenTurningOn

Now, the following issues cause the flickering in the occluded case, which
are normally not causing any breakage:
- There was an issued with the draw callback not being reset and reused
at the wrong time.
- mWakeAndUnlocking was not cleared soon enough. This caused a timeout if
notifyScreenTurningOn happens after starKeyguardExitAnim
- We always need to wait for the Keyguard host window, as isForceHiding
isn't set in this case

Change-Id: Id8d0f9fec79ec63b36659513f97c724147c7521f
Fixes: 30483392
eyguardViewMediator.java
aeb2e1e91b447204733807b919306105a269fe2a 28-Jul-2016 Nick Desaulniers <ndesaulniers@google.com> resolve merge conflicts of 9db1877 to master

Change-Id: I12e14d374ab4f71d931ea2cb449354fdf42db004
1d3967506e1cb3843d3bf758187ebc42d1c83485 26-Jul-2016 Nick Desaulniers <ndesaulniers@google.com> framework: SystemUI: add tracing to Keyguard

Helps trace the phone unlock path.

Bug: 29693568
Bug: 30279403
Change-Id: I290864f525e3d08f1efc6b9fc603172a5d139ea0
eyguardService.java
eyguardViewMediator.java
e9842278309d1273f3488bba76b580b38100bb3f 21-Jun-2016 Adrian Roos <roosa@google.com> Merge \\\"Allow trust agents to run during provisioning\\\" into nyc-dev am: 1dd403b61a am: 3d72ca32be
am: 93257a170a

Change-Id: I0398de23140b3128469458b2bc3f16fce0c9443e
93257a170aa68ea2bb46bb6ec0c8636ad8724046 21-Jun-2016 Adrian Roos <roosa@google.com> Merge \\"Allow trust agents to run during provisioning\\" into nyc-dev am: 1dd403b61a
am: 3d72ca32be

Change-Id: I980d01f48434a800153233d4c7ac43423d4d1f08
30181fb1b9b80f95a47960fac88e007f88cec219 21-Jun-2016 Adrian Roos <roosa@google.com> Merge \"Allow trust agents to run during provisioning\" into nyc-dev
am: 1dd403b61a

Change-Id: I3972f2f923b78bf57f8160b3a14a81df3972eea0
fb95a81a8b1ffb3f75e35e14f494361882842731 20-Jun-2016 Adrian Roos <roosa@google.com> Allow trust agents to run during provisioning

Fixes a bug where trust agents weren't able to run during
provisioning, because user presence is only acknowledged after
provisioning completed.

Change-Id: Ib9ed235e8372555fdc40eefd0fc6b1192613abda
Fixes: 29231515
eyguardViewMediator.java
0e29599ffc4dc7fc7e8e2b0e2d4f64cd68f8fb4f 02-Jun-2016 Amith Yamasani <yamasani@google.com> Merge "Setup user restrictions for demo user" into nyc-mr1-dev am: a28576cb72
am: 64fc84e9c7

* commit '64fc84e9c78e143e79a0e5b2dddf97f02d1f40d9':
Setup user restrictions for demo user

Change-Id: I414145f63da75daa63f25879dc2ef8ee167cef10
52c21e34536948ffb02323ffbb2288716854665a 31-May-2016 Amith Yamasani <yamasani@google.com> Setup user restrictions for demo user

Prevent certain actions by demo user
Also eliminate immersive mode confirmation when device is
in demo mode.

Bug: 27280140
Change-Id: I6955b7bb5c1ae13e1df36cef822b6fd39cb51e46
eyguardViewMediator.java
a3d46611e3679371c69b9771f0c676e90ee94a05 18-May-2016 Amith Yamasani <yamasani@google.com> Merge "Retail mode flag and some clients for it" into nyc-mr1-dev am: dbf0dbd8c2
am: 1ab19ea6e6

* commit '1ab19ea6e6575a578244eecbae61d46150bec392':
Retail mode flag and some clients for it

Change-Id: I08eb3539db3fd29403d05d8ef1124862a78d1acc
eb437d4dffb310857e19bb619778dc5b6b7febff 29-Apr-2016 Amith Yamasani <yamasani@google.com> Retail mode flag and some clients for it

Bug: 27280140
Change-Id: Ide33e941b9c71eb925b5977d0b0d62198537ca14
eyguardViewMediator.java
e87b5750466508e3e6a28f95ef035865d022d0b9 06-May-2016 Wale Ogunwale <ogunwale@google.com> Merge "Dismiss docked stack if an activity is shown on top of the lock screen" into nyc-dev am: 5d6a218d9e am: d9125edb98
am: 94d93dd38f

* commit '94d93dd38fbab0ff8f9a9ce397a522cf2fcd6429':
Dismiss docked stack if an activity is shown on top of the lock screen

Change-Id: Iaaf1dc4cd6f4008bf4bc571bb70365d431ea30ed
99732940809058fae558618399323c36b8a0e856 06-May-2016 Wale Ogunwale <ogunwale@google.com> Dismiss docked stack if an activity is shown on top of the lock screen

It is risky/complicated to try to put the activity showing on-top of
the lock screen in the right fullscreen configuration with the current
architecture. So, we just dismiss for now.

Bug: 28195260
Change-Id: I29a0350993ce8fe548d4a465b06d877cde151c78
eyguardViewMediator.java
8702ca7e2d6a1a66e580d039a1f662cfb94ee4ac 22-Apr-2016 Vadim Tryshev <vadimt@google.com> Preventing unnecessary switching to a user upon lockscreen dismissing.

This is the part that will go to master branch.

The fix passes the 'targetUserId' down to
KeyguardViewMediatorWrapper, which explicitly tells what user it need
to switch to.

Bug: 27927399
Change-Id: I7674272eb654c0acd672cbfd66284bf7cc0c4efa
eyguardViewMediator.java
ad0ce3ab5ec6ec1d7f4d8ac0341e386968b1572b 27-Apr-2016 Jorim Jaggi <jjaggi@google.com> Use FLAG_RECEIVER_FOREGROUND for lock intent

To make we get priority for the intent.

Bug: 27391589
Change-Id: I112588116d51012dbe4d66c90b839bb88bc3f21b
eyguardViewMediator.java
428fdd104c6877889da1af2d35af41d5c14833c9 15-Apr-2016 Nicolas Prévot <nprevot@google.com> Merge "Call notifyLockedProfile in TrustManagerService instead of KeyguardViewMediator." into nyc-dev
c662898a182ca8f13d73b71649feeeeceb574edd 14-Apr-2016 Nicolas Prevot <nprevot@google.com> Call notifyLockedProfile in TrustManagerService instead of KeyguardViewMediator.

Setting the profile as locked is not synchronous.
In some cases, KeyguardViewMediator called notifyLockedProfile before
TrustManagerService had actually marked the profile as locked.

BUG:28161912

Change-Id: Ic2ad302c74806ae368d56050eb31503a8ef0bd38
eyguardViewMediator.java
4ab7e595a5deef72448da950f2f973bc0c90fe18 14-Apr-2016 Adrian Roos <roosa@google.com> StrongAuthTracker: Don't rely on USER_PRESENT

USER_PRESENT is sent via the background queue. A delay
there can cause us not to recognize that the user has
unlocked and prompt for the credential again, when trust
or fingerprint would be sufficient.

Also removes an obsolete reference to USER_PRESENT from
TrustManagerService.

Change-Id: Ie8d1a180170df5f0c8f9e71660504fd71eeacd99
Fixes: 27830458
eyguardViewMediator.java
7f98aa4aa93497692f200c553d2d6fff402e3de2 07-Apr-2016 Fyodor Kupolov <fkupolov@google.com> Added getProfileIds method returning array of userIds

Previously many usages of UserManager.getProfiles and getEnabledProfiles
were only using ids of returned users. Given that the list of users needs
to be parceled and unparceled for Binder calls, returning array of ids
minimizes memory usage and serialization time.

A new method getProfileIds was introduced which returns an array of userIds.
Existing method calls were updated where appropriate.

Bug: 27705805
Change-Id: Ic5d5decd77567ba0f749e48837a2c6fa10e812c0
eyguardViewMediator.java
035e92447084b96ef2c9125e77105c237e20bad3 18-Mar-2016 Ricky Wai <rickywai@google.com> Fix work profile screen timeout policy

Settings screen should apply both primary and managed maximum
timeout policy, even separate profile challenge is enabled.

Bug: 27493348
Change-Id: Ia1ec1cafc7665c54816833af64e0f446a77a55b2
eyguardViewMediator.java
f1cdf9558d2b7f8fe5b8cf3d309b48809f04403b 06-Apr-2016 Jorim Jaggi <jjaggi@google.com> Don't lock device when double tapping

Bug: 24265204
Change-Id: Ia19e956def454604ed3f3e3e9815fc1872ef649a
eyguardService.java
eyguardViewMediator.java
9c6e8ced9b6913657f48c38c208b1b594500c0e1 21-Mar-2016 Tony Mak <tonymak@google.com> Show launcher when profile is locked immediately

Previously, we show launcher when keyguard is dismissed.
It introduces these issues:
1. There can be no device lock
2. user could take a quick peek of the work app

Current behavior:
1. We now show launcher once the work profile is locked.
2. Lock profile immediately if there is no device lock
3. Add cancel "lockProfileLater" logic

Bug: 27241680
Bug: 27673460
Change-Id: I765aa22d4c8ae5017c1611f5a340a4b33d463b1e
eyguardViewMediator.java
7400f82699c76618d5ca24d6528580afb4695dbf 15-Mar-2016 Adrian Roos <roosa@google.com> Merge "Don't show wallpaper when backdrop is visible" into nyc-dev
d5c2db630fc816e2d9154a61ccbd6770bc57cff8 09-Mar-2016 Adrian Roos <roosa@google.com> Don't show wallpaper when backdrop is visible

Hides the wallpaper when it's not needed and fixes
the unlock animation to not unnecessairly show the
wallpaper if neither the Keyguard nor the underlying
app need it.

Also fixes a bug where the enter animation had a background
set, which led to uglyness when no wallpaper is involved.

Bug: 27533740
Change-Id: I667c6f7ca6c0e1ff7e9f793c6ddc13f6da8387b1
eyguardViewMediator.java
6593c28c3110daa8cc2f2816ce9640a6848088db 15-Mar-2016 Jim Miller <jaggies@google.com> Merge "Attempt to fix problem where keyguard isn't locking" into nyc-dev
20be5d62471d520eed3a52d90c11944464a71c07 26-Feb-2016 Paul Lawrence <paullawrence@google.com> Add API to IMountService to get encryption state

Bug: 18002358
Change-Id: If7d9c9a5ed38ac37849fcf638ec10c76d2f419a1
eyguardViewMediator.java
a622d3cc551d8f957c07836265947bfe4d36ee5e 03-Mar-2016 Jim Miller <jaggies@google.com> Attempt to fix problem where keyguard isn't locking

Keyguard should be using setExactAndAllowWhileIdle() to guarantee
the device wakes and locks on time.

Bug 27391589

Change-Id: I2b688ee68069ceafeecfb48cada8671435f8d850
eyguardViewMediator.java
3dc575f1358112b232bd74bcd0d102401ef7549e 17-Feb-2016 Clara Bayarri <clarabayarri@google.com> Lock Work Profile immediately when user presses power button

Bug: 26579952
Change-Id: I6e4e0fc2a4f41c72f0d940006f6ceb17e7852682
eyguardViewMediator.java
ed5c8f0216bf97e896936e2a2e24fc3fb18303a1 09-Feb-2016 Michal Karpinski <mkarpinski@google.com> Log strength of auth method used into security log

As approved by Android Security team, added logging of
strength of auth method as well as logging of fingerprint
keyguard actions.

Bug: 26841997
Change-Id: Ic8e3f125f775a7585fe56003f4c6442390edea61
eyguardViewMediator.java
31502d3d95610930b56bb7931dbd57a997f9ce8f 25-Jan-2016 Michal Karpinski <mkarpinski@google.com> Logging of keyguard actions into security log

Bug: 22860162
Change-Id: I7dbe68fff7d9d45b6c417d960cf025c8d0694917
eyguardViewMediator.java
c13723f22e476b4558061942c001ee62eaca79e4 12-Jan-2016 Adrian Roos <roosa@google.com> Improved trust error messaging (1/2)

Tracks why trust agents are disabled and shows
a generic message on the keyguard. Dedicated strings
in follow-up.

Bug: 22704995
Change-Id: Ibb4fd9c9386c4dc12f0734004502b9a9cc6ded79
eyguardViewMediator.java
779aad942f73bd603ed50c160db21f984ed6e8b9 20-Jan-2016 Michal Karpinski <mkarpinski@google.com> Logging of unlock attempts and device locking to security log

Bug: 22860162
Change-Id: Ice18a8f655030e52ae2d9e256b6120e5f87950c5
eyguardViewMediator.java
1b30f79cffbe9e0c2b974fa3ee48001edcdd6c05 06-Jan-2016 Xiyuan Xia <xiyuan@google.com> Refactoring for better extendability

- Exposing members of PhoneStatusBar, StatusBarKeyguardViewManager and
KeyguardBouncer to sub class;
- Add a configuable SystemUIFactory as class factory for components;
- Add logoutCurrentUser and switchToByUserId to UserSwitcherController;

BUG:22407003
Change-Id: I3902baf3c721d89217b27a6310c4202a198cb209
eyguardViewMediator.java
a1771110d67fa7361f92d92f2e91019882ce3305 18-Dec-2015 Clara Bayarri <clarabayarri@google.com> Create Work Challenge per-user condition

Change the current static condition to a per-user condition so we
can check and enable/disable the work challenge properly. Also add
an isAllowed API, as the Work Challenge can only be used when the
user's DPC targets N or above to maintain backwards compatibility.

Change-Id: I0cb8b475838816801868ffb24726407aa257b4de
eyguardViewMediator.java
2967f48f8574ce35acd6c5e4e9f7872c64f159d5 08-Jan-2016 Jim Miller <jaggies@google.com> Fix problem where keyguard shows spontaneously

A recent change caused keyguard to ignore the sequence number
when calling doKeyguardLaterLocked().

It also appears we can get into a situation where multiple
requests to show keyguard are pending. This change ensures
only the latest request gets handled.

Fixes bug 26326350

Change-Id: Ic6cba0054fe235a8838ca8c242b1840c9e8309d6
eyguardViewMediator.java
10ad84a17d7248488c1653bacc9f20d3a7193999 01-Dec-2015 Clara Bayarri <clarabayarri@google.com> Create a separate Work Challenge check

This allows us to tell lock checks from FBE checks separately,
and will be useful when dealing with password unification.

Change-Id: Ifbea425f749fee4d6d51faddd8b64bf717a1a5f8
eyguardViewMediator.java
56878a93989a49538fabccfb7218face645030bf 29-Oct-2015 Clara Bayarri <clarabayarri@google.com> Create work challenge timeout

The work challenge should be locked whenever the device goes to sleep + admin
timeout or when the power button is pressed if the lock setting is on.

This change creates the infrastructure to lock a specific user instead of the
device and uses it in these cases. Then, the current code that brings up the
work challenge can check to only show it if the user is locked.

Change-Id: I89b4342b1458d97734d7afa66be52bf04ec3a3d4
eyguardViewMediator.java
cb15d66f1c7e0175acdf0c0a71d774e841e0b21b 10-Nov-2015 Amith Yamasani <yamasani@google.com> Once system is provisioned, lock the screen on system user

If the device provisioning is complete, check if we need to show
the keyguard. We don't want it to show launcher after finishing
with setupwizard in the system user.

Bug: 25326078

Change-Id: I326069e29122ebf19a59fc00a9120cd5de70f231
eyguardViewMediator.java
27e025b687f49010f40ce978d2d3a96c301fa7e8 06-Nov-2015 Amith Yamasani <yamasani@google.com> Allow activities to show on user 0 until provisioned

In a split-user mode, allow SUW and related apps to show UI
until the device is provisioned. Basically this changes the
logic a bit for when to force keyguard to always show on user 0.

Bug: 25326078
Change-Id: I8e862adae1c38efe9874479b532baa7446070035
eyguardViewMediator.java
3254d7c2b39de66507c09e111d4b047a42f08916 23-Sep-2015 Jorim Jaggi <jjaggi@google.com> am 7e94ae83: am 1bdfd128: am 6da88610: am 302475e9: Fix verifyUnlock

* commit '7e94ae833f34917cc2a034a5f5be31a8cecb2553':
Fix verifyUnlock
302475e93ce00287770aba9668acbe86e8b20a05 22-Sep-2015 Jorim Jaggi <jjaggi@google.com> Fix verifyUnlock

Bug: 23970549
Change-Id: I899d8a92050c257217fa8528c33cb4592ad6d76a
eyguardViewMediator.java
9196534f02649c1bda7d7e8e8dc58440b182a8cc 18-Sep-2015 Jorim Jaggi <jjaggi@google.com> am 2c049cfc: am 3a565669: am 5c2bfa8f: am 58e378b0: Merge "Start fingerprint authentication in onStartedGoingToSleep" into mnc-dr-dev

* commit '2c049cfc613f91fbc9a93adf2ee49a3137f7402f':
Start fingerprint authentication in onStartedGoingToSleep
cc3faeb745eb09839d710dd40f46730d3d71fe76 18-Sep-2015 Jorim Jaggi <jjaggi@google.com> am 538cc90b: am 3ac7e49f: am dc09ffad: am 5c0c5ac8: Handle case correctly when screen times out and locking immediately

* commit '538cc90b413806c0b9624b7d57400295072ddc43':
Handle case correctly when screen times out and locking immediately
58e378b02561d8f606066537b193b0eb62e2404f 18-Sep-2015 Jorim Jaggi <jjaggi@google.com> Merge "Start fingerprint authentication in onStartedGoingToSleep" into mnc-dr-dev
95e4038bb127fdd41bd3b11373a6d2328facb850 17-Sep-2015 Jorim Jaggi <jjaggi@google.com> Start fingerprint authentication in onStartedGoingToSleep

We used to start fingerprint authentication in onFinishedGoingToSleep.
This was a UX issue because then users couldn't place the finger on
the sensor immediately after pressing the power button because
onFinishedGoingToSleep is significantly delayed (around 900ms after
pressing the power button).

Bug: 23570959
Change-Id: I0bf557ebd10e6a8b033ab98a78aa338bf6538dcc
eyguardViewMediator.java
5c0c5ac84552f80ddadc43f451c3a28c5c8c8f84 16-Sep-2015 Jorim Jaggi <jjaggi@google.com> Handle case correctly when screen times out and locking immediately

In case the the screen timed out and the setting was set to "lock now"
in case the screen times out, we locked before finished going to sleep,
leading to all kinds of state messups in Keyguard, including an empty
lockscreen when authenticating with fingerprint during that period.

Bug: 23952388
Change-Id: If1629be1171c841d51ec0555422e6108002fdb73
eyguardViewMediator.java
f669b07c8827db7de9383144c0151f84cd6f2947 17-Sep-2015 Blazej Magnowski <johnasselta@google.com> Merge "Add FalsingManager and Classifier to SystemUI"
235cea07c4475f40dd42374517f6f6e52933c513 17-Sep-2015 Jorim Jaggi <jjaggi@google.com> am ae4874c6: am 7de9e3ea: am 09999fb9: am 18f18ae0: Allow camera launch also when device is interactive

* commit 'ae4874c69dd7d6d41f9e0e1c6025e9111cfc64bf':
Allow camera launch also when device is interactive
18f18ae078ee97bbdfc9da39d4a19866dceb6a3e 11-Sep-2015 Jorim Jaggi <jjaggi@google.com> Allow camera launch also when device is interactive

Bug: 23967648
Change-Id: If91df75e6325b3969dc2351a70af0c160d3eab04
eyguardViewMediator.java
0e2ffbd48bbedf47deb7f6aed96bd07e2fc96f53 10-Sep-2015 Blazej Magnowski <johnasselta@google.com> Add FalsingManager and Classifier to SystemUI

Adds the possibility to analyze and classify touch and sensor events as
human or false touches.

Change-Id: I5079c02406d532fea38ca2d302e8606effae0696
eyguardViewMediator.java
35d648f3f2808ce46dab0df9f17dd759df76d6de 12-Sep-2015 Jorim Jaggi <jjaggi@google.com> am 0e950707: am 12e273fe: am f66e4979: am 84dc08a2: Dump Keyguard state in SystemUI and PhoneWindowManager

* commit '0e95070766dc499f66706c12253dda11d31ab014':
Dump Keyguard state in SystemUI and PhoneWindowManager
84dc08a208eea7a4ddf043cadbb28987cf90ae22 12-Sep-2015 Jorim Jaggi <jjaggi@google.com> Dump Keyguard state in SystemUI and PhoneWindowManager

Bug: 23970549
Change-Id: Iec1e8ac507268086e0e2935847eda606ea1fb700
eyguardViewMediator.java
0e228726663bc579f0014a6c73cf63cb7142e56d 04-Sep-2015 Adrian Roos <roosa@google.com> resolved conflicts for merge of 123fb19d to master

Change-Id: Ie029b8d72eaf968a5224cd0b90d97b112d51ba35
f6d51acec69366b6ea34f5e0c9aa8cc840f04a4d 02-Sep-2015 Adrian Roos <roosa@google.com> Poke fingerprint timeout when vold password is correct

Bug: 23718313
Change-Id: I6c88fbba9ae460594b8e2f1a77c6545b305e5813
eyguardViewMediator.java
762320e7d1605372b8f662a69b04d06b93ee86f4 28-Aug-2015 Jorim Jaggi <jjaggi@google.com> am f757bed7: am 7b933895: am e3238e53: am b774e554: Optimize fp touch to wake: Shortcut for report next draw

* commit 'f757bed7f7fa72528ab2d7225139d9d6f3b1021a':
Optimize fp touch to wake: Shortcut for report next draw
b774e554f32fd65cac30b43d1cf679403ef4af82 24-Aug-2015 Jorim Jaggi <jjaggi@google.com> Optimize fp touch to wake: Shortcut for report next draw

When telling window manager that Keyguard window is in the correct
state for a fp-touch-to-wake sequence, it takes more than 1 frame at
the moment because the signal that WM is waiting for the next draw
is delayed by one frame because it is posted at the end of the
runnable queue.

To correctly fix this, we should post it at the beginning at the
queue, but this is way too risky this late. Instead, add a isolated
SysUI hack to report it faster.

Bug: 23401557
Change-Id: Icf64101e27611c7c01d108123021b22186f1e70c
eyguardViewMediator.java
c3866bf81f70c91e2af942554eaf9b9c8e5fc078 22-Aug-2015 Blazej Magnowski <johnasselta@google.com> Merge "System to track touch and sensor events before unlocking the phone"
e3b07451c3ca7064cb70f1829cf35963cba74bd8 22-Aug-2015 Adrian Roos <roosa@google.com> resolved conflicts for merge of bcc26c02 to master

Change-Id: I4260ff0d090cfa9741fd3adcfcadcbbff6839388
b5e4722891e7bbf2fffcd995af02838667a3abab 15-Aug-2015 Adrian Roos <roosa@google.com> Add StrongAuthTracker

Bug: 22846469
Bug: 22115393
Change-Id: I6ef5322d02e540fc043e7f20d3aabf595ce7c224
eyguardViewMediator.java
7232332dc963c2ce55dda1a3a0367080d5494503 24-Jul-2015 Blazej Magnowski <johnasselta@google.com> System to track touch and sensor events before unlocking the phone

Added a new component which tracks touch and sensor events and
also events like showing the bouncer tapping a notification and
others. The collection is enabled when the screen is turned on and
is disabled after the phone is unlocked. The data is saved in a
protobuf file in internal storage in a directory called
"good_touches". There is also an option to collect events which
end with the screen turning off. These are saved in the
"bad_touches" file. Everything is hidden behind the
ENABLE_ANALYTICS flag which is set by default to false and can be
turned on only if Build.IS_DEBUGGABLE is true. Also
behind the ENFORCE_BOUNCER flag the class shows the bouncer before
expanding a notification, showing quick settings or launching an
affordance from one of the bottom corners.

Change-Id: Iaeae0fb7a0d9c707daf7a270201fa5b1cd84c74a
eyguardViewMediator.java
0772bfd2069e4776dab3dcdbe2a60241873fcca9 19-Aug-2015 Jorim Jaggi <jjaggi@google.com> "resolved conflicts for merge of caacc8ba to master"

Change-Id: I7904ac66ded45c3173af14d2940dc8210088e387
83eb6bb5d83d3994a3750b566a2109a049ab1388 18-Aug-2015 Jorim Jaggi <jjaggi@google.com> Improve motion for wake-and-unlocking while pulsing

- Move all fingerprint related to logic in on central class in
SystemUI that knows all the state of the UI so there is exactly ONE
place in which we decide what to do when we acquire a fingerprint.
- When pulsing and we get a valid finger, we fade the contents of the
Keyguard out and fade the scrim out almost the same way as we would do
in a normal wake-and-unlock sequence.
- Hide shadows while dozing, so we don't see the artifacts when we fade
the dozed Keyguard out.

Bug: 23225107
Change-Id: I82f78e61f2530cf7d507ade80f6f0a340c082567
eyguardViewMediator.java
a393249c3d3d7efad844affade9287202d81e841 14-Aug-2015 Jorim Jaggi <jjaggi@google.com> am a5d38f87: am bafc9eeb: am 7453a0aa: am 587488e0: am 81eeef58: Merge "Update time when turning on screen, in addition to waking up" into mnc-dev

* commit 'a5d38f8782a4fdfeed3c762d775ab470639c056e':
Update time when turning on screen, in addition to waking up
587488e027c41394dc6a1f2248c4dbe8d3530b69 14-Aug-2015 Jorim Jaggi <jjaggi@google.com> am 81eeef58: Merge "Update time when turning on screen, in addition to waking up" into mnc-dev

* commit '81eeef589386483722c21572d9ab6d3f95dd26be':
Update time when turning on screen, in addition to waking up
9373911d41c133fce80b8ecf6e688204f2c667e7 14-Aug-2015 Jorim Jaggi <jjaggi@google.com> Update time when turning on screen, in addition to waking up

When in ambient display mode, we didn't get a callback to
onStartedWakingUp, thus the time was never refreshed. Since
broadcasts are disabled in this low-power state, we need to refresh
the clock manually before turning on the screen, because we can't
rely on the broadcasts to be delivered.

Bug: 23171638
Change-Id: I249f4195a14995f7c1467e73ac2aa400b871f80e
eyguardViewMediator.java
61a5abcf9683d4c528931b855009c920a516d8c9 13-Aug-2015 Jorim Jaggi <jjaggi@google.com> am d5b3a35c: am 5f3af144: am d59f5c02: am a78181b6: Merge "Fix touch-to-wake while dozing" into mnc-dr-dev

* commit 'd5b3a35c14130deba54d9e72a10cce16adf7b99b':
Fix touch-to-wake while dozing
559b8c5f4ef20678d40a2d4161dfa14b378d2d91 13-Aug-2015 Jorim Jaggi <jjaggi@google.com> Merge commit '80581f7a' into master

Change-Id: Ifd8f9c7a854901e0a48bc8a611cfb002fa37298c
aabab270282baefaba4a99399e0eef7be043c615 12-Aug-2015 Jorim Jaggi <jjaggi@google.com> Fix touch-to-wake while dozing

Bug: 23113439
Change-Id: I7abcf1b4298fc832ba78df742c691246766993b1
eyguardViewMediator.java
25b4d4b280c6aa07656328bd9dd90977781d00e1 12-Aug-2015 Jorim Jaggi <jjaggi@google.com> Require strong authentication after a timeout

Bug: 21594472
Change-Id: Iab169d4fa2e4ad134f8c8579654b28e96b5b1385
eyguardService.java
eyguardViewMediator.java
9b1697cd8f3e87aa7a09b2f8a31ca034490c5e39 08-Aug-2015 Jason Monk <jmonk@google.com> am e0d9fe59: am 635270c5: am a01965e2: am 69a07d40: am 69ed3308: Merge "Allow system to disable lockscreen" into mnc-dev

* commit 'e0d9fe59856241fb34212b4ad160dbc8f76e4343':
Allow system to disable lockscreen
b978ce7f25011add50e900d5745f3e066cddfd55 06-Aug-2015 Jason Monk <jmonk@google.com> Allow system to disable lockscreen

Even when there is a pin.

Bug: 22920549
Change-Id: Ib84e1c3ac67be0318d4186c66ee582a49969e373
eyguardViewMediator.java
87d0e254cdc639347b73aa5f60ec8ab6c5327c7e 31-Jul-2015 Xiaohui Chen <xiaohuic@google.com> clean up UserHandle.USER_OWNER reference.

Clean up system ui. As you can see, I can picking up the easy ones
first.

Bug: 19913735
Change-Id: I94d33b108ae8b40ec92bbfca0863e266549f9633
eyguardViewMediator.java
e1d440be81e518450c0c013711926f570b928738 29-Jul-2015 Jorim Jaggi <jjaggi@google.com> am 7580672f: am ce58fa95: am fed9b281: am 353fe1c6: am 0d210f63: Animation for touch, wake and unlock

* commit '7580672fa8455dccc78806dcd878a5e191a62a45':
Animation for touch, wake and unlock
0d210f6395072db4a4c53d4cb8fac4a59a3965b4 10-Jul-2015 Jorim Jaggi <jjaggi@google.com> Animation for touch, wake and unlock

- Add callback to inform SysUI when the screen has been unblocked
and turned on.
- Cleanup inconsistent messaging about device interactive/screen on
and off.
- Add callbacks to inform SysUI about screen states
- Implement a quick fade for the scrim after touch, wake, and unlock.
First, start with a black scrim on top of everything, and then fade
it out.
- Make sure we play the normal unlock animation when device is pulsing
- Override navigation bar animations for touch, wake and unlock: Fade
in the same manner as the scrim.

Bug: 22571198
Bug: 21855614
Change-Id: I8ff08d72cced1e0f03c78d71ff710d8a4f6b848c
eyguardService.java
eyguardViewMediator.java
551a063fc36d2257495b4f57d32dc249796a27b1 25-Jul-2015 Selim Cinek <cinek@google.com> am a69f8531: am fd89d2a0: am 756d5ac2: am e0c0e93a: am d9f1a0c3: Merge "Fixed wake to unlock when the device has never been unlocked" into mnc-dev

* commit 'a69f8531185e0238d173c574bc7e10c43a8a9d0a':
Fixed wake to unlock when the device has never been unlocked
da2ac5770b67c3696aec9e102ce732b7b632590f 25-Jul-2015 Selim Cinek <cinek@google.com> am 25fcf199: am e756d912: am d2e40fab: am 8588b331: am f8acd1d8: Merge "Adapted the behavior when unlocking with fingerprint is not allowed" into mnc-dev

* commit '25fcf1994c24954d34608ade2ee8fb2212e5e9d1':
Adapted the behavior when unlocking with fingerprint is not allowed
ad7310f01329c2ce99c57017873664528280999c 25-Jul-2015 Selim Cinek <cinek@google.com> Fixed wake to unlock when the device has never been unlocked

Previously the fingerprint could still unlock the device
when waking up with the fingerprint sensor, since we were not
checking if it is allowed.

Bug: 22622999
Change-Id: I039a4e0701c1f161f227cf6f1d25e8147548db47
eyguardViewMediator.java
1fcafc49ad34cb8f778862653d452ac0fe61461c 20-Jul-2015 Selim Cinek <cinek@google.com> Adapted the behavior when unlocking with fingerprint is not allowed

We now keep the fingerprint running and switch to the bouncer when
the user successfully authenticated.

Bug: 21618072
Change-Id: If00061cb3914afd4d7a7d75964594484c792a890
eyguardViewMediator.java
740452e8756cb7f51ed185c3906a5ca61b8fcdd4 09-Jul-2015 Jorim Jaggi <jjaggi@google.com> Touch, wake and unlock

- Add onFingerprintAcquired, so Keyguard can grab a wakelock to prevent
the device from sleeping.
- If we get a successful fingerprint, wake the device up, immediately
dismiss the keyguard and tell PWM that we kicked off our frame that
will represent the correct state.
- PWM then waits for this frame to be drawn, and then turns on the
screen, which results in unlocking directly to the previsouly
opened app.

Bug: 21855614
Change-Id: I5f43df17fa5e4e9c6a6392eef4a4590b07df4f96
eyguardService.java
eyguardViewMediator.java
bd36632550a28c53d89afa0a812bd5328c3f13a9 16-Jul-2015 Xiaohui Chen <xiaohuic@google.com> Merge "sys user split: turn off unlocking for sys user."
4cfdcf5b0551e5656ea379c428e78b812c2e5cbe 09-Jul-2015 Jorim Jaggi <jjaggi@google.com> Touch, wake and unlock

- Add onFingerprintAcquired, so Keyguard can grab a wakelock to prevent
the device from sleeping.
- If we get a successful fingerprint, wake the device up, immediately
dismiss the keyguard and tell PWM that we kicked off our frame that
will represent the correct state.
- PWM then waits for this frame to be drawn, and then turns on the
screen, which results in unlocking directly to the previsouly
opened app.

Bug: 21855614
Change-Id: I0c43bcc9d334b509632704fb0c123ab3351edff2
eyguardService.java
eyguardViewMediator.java
f561d7f27598276e6547eea87addb2be9bf83323 10-Jul-2015 Xiaohui Chen <xiaohuic@google.com> sys user split: turn off unlocking for sys user.

This is to unblock the team to test system user split as soon as
possible. This is not how it is going to work eventually.

BUG:19913735
Change-Id: I27aaf4491258fe08a3d64ec06358dae482192fbd
eyguardViewMediator.java
4474f54f4eedbdf5d0b225647d50c0b05466a448 10-Jul-2015 Jorim Jaggi <jjaggi@google.com> Fix empty keyguard for once and all

When a Keyguard exit animation was played while the screen was
turning off, the window animation was cancelled. However, since
we didn't reset mPostKeyguardExitAnimation, we thought we need to
apply it again, with a start time of Long.MIN_VALUE. For some reason,
this animation never ended, and it was stuck at the beginning. Thus,
the alpha was 0 and the user just saw a blank wallpaper.

In addition, we also forbid starting the Keyguard exit animation when
the screen is about to turn off.

Bug: 21124013
Change-Id: Ief022c5bd758a9fedcaab3fe9fc385fa4234b37f
eyguardViewMediator.java
edd32b881780e52b4ecc43f8df3b6b091e70a863 24-Jun-2015 Selim Cinek <cinek@google.com> Fixed a bug with encryption where the keyguard was never shown with PIN

This led to the network being unusable.
We now ensure that the Keyguard is not notified of the SIM PIN
changes until after the initial dismissal logic is done.
In addition, the fullscreen PIN is now always shown immediately
and not until the user swipes up, which was an error before.
Also made sure that the Keyguard Scrim is correctly visible
when shown.

Bug: 21850021
Change-Id: I81804124bae30adf0e17e26cc42f67e48fc446e8
eyguardViewMediator.java
3122fa85b2f18c0a89f5fe1ef0942c530a271843 18-Jun-2015 Selim Cinek <cinek@google.com> Added a message to the keyguard bouncer

A message can now be shown on the keyguard bouncer
explaining why the bouncer is being shown.

Bug: 21618072
Change-Id: I25aea9cc242abbf6a133fb42cc4407f5c2f3f688
eyguardViewMediator.java
9f33d6cb2ed90e2fff3d99cfcf90f6074b1b9f04 16-Jun-2015 Adrian Roos <roosa@google.com> Fix stuck orientation in SetupWizard

Bug: 21755092
Change-Id: I3144a81523ce2ef4bf6dc457c0ea4b9723dae489
eyguardViewMediator.java
5cc86599ce0e5596655859d09c52934030da240b 08-Jun-2015 Jorim Jaggi <jjaggi@google.com> Dismiss Keyguard correctly

When authenticating with fingerprint, we didn't go through the
dismiss action, and thus launching intents was broken when
authenticating with fingerprint from the bouncer. Also fixed a crash.

Bug: 21695578
Change-Id: I61f74b5b63d4d6ddf7f8f3ce96feb63b9644cd52
eyguardViewMediator.java
853cbe38c9aa80671a2e7e616f48a6160c722eea 05-Jun-2015 Jorim Jaggi <jjaggi@google.com> Don't play lock sound when just resetting Keyguard

Bug: 21595440
Change-Id: I9bd470d051f4851dcde83099f1ba1f0a9bae429a
eyguardViewMediator.java
579e7b7b9ac9f9fed052c63a462b49b16baffc16 02-Jun-2015 Adrian Roos <roosa@google.com> Merge "Patches for IKeyguardStateCallback" into mnc-dev
328472ebd8f9c139fef1ad859ed4f7b43b3f86c6 21-May-2015 dooyoung.hwang <dooyoung.hwang@lge.com> Patches for IKeyguardStateCallback

1. Also notify input is restricted or not when IKeyguardStateCallback callback is added.
When first Keyguard is showing after boot, the mInputRestricted is not updated. So,
inKeyguardRestrictedInputMode still returns false, although device is locked.

2. If mShowing remains false during setup time of KeyguardViewMediator, mInputRestricted
is not updated. This is because updateInputRestrictedLocked is called only if showing
value is changed during setup time.
For this reason, when device is not provisioned, inKeyguardRestrictedInputMode returns
false, and device does not restrict key.

3. If one of callbacks causes RemoteException, the other callbacks are not called.
This is because catching RemoteException breaks for-loop.

(cherry-picked from commit 516dad062580201d7a4ad6c112b23434385d5268)

Change-Id: I0281405127bcc75285b908d01485da3ac9b40b52
Signed-off-by: Dooyoung Hwang <dooyoung.hwang@lge.com>
eyguardViewMediator.java
d175b6cfe0b35dfe251cc9315aacb048bf6e54c5 28-May-2015 Jorim Jaggi <jjaggi@google.com> Cleanup Keyguard handling when turning off screen

Before, Keyguard was shown whenever PhoneWindowManager went to sleep.
However, this was too early on some devices, and too late on others.
Now, the callbacks are split up into two phases: startedGoingToSleep
and finishedGoingToSleep. In the first callback, we decide what to
do and play the lock sound if necessary. In the second callback, we
actually show the Keyguard, or reset its state necessary, so it
doesn't interfere with the screen off animation.

Bug: 17929748
Bug: 20782303
Change-Id: I4c4406595b07b7589d64f380cd3fa96bed3d20ee
eyguardService.java
eyguardViewMediator.java
827e0facfefd0c0033dcfb1747b4fa6f80f9e0e2 07-May-2015 Jorim Jaggi <jjaggi@google.com> Make sure the app can draw a frame before unlocking

- The mechanism to stop windows drawing while window animator was
animating was somehow flaky. It relied on the fact that the client
would call relayout() whenever the animating state changed. This is
mostly the case, but not for lockscreen animations. Instead, we now
use a push model, where window manager tells the app that the state
has changed.
- In addition, it only stopped drawing if that window was animating,
but then only resumed drawing after all windows have finished
animating. Now, we do this per window, so we only stop drawing for
windows that are currently animating.
- We resume the top activity now at the very beginning of the
unlocking sequence. This gives the app a chance to draw a frame
before the user sees anything. If it's to slow, then we just use the
outdated framebuffer.

Bug: 19964562
Change-Id: Ifef8abd189a3146d854b81b9b948861e4d38c155
eyguardViewMediator.java
420f2688f0ecfafff6b07755e47f0bd0d34b2fc8 29-Apr-2015 Jorim Jaggi <jjaggi@google.com> Merge "Only listen for fingerprint if needed." into mnc-dev
ea65706d89dc1ab3f295eb53dca548ea39fcb456 28-Apr-2015 Jorim Jaggi <jjaggi@google.com> Only listen for fingerprint if needed.

Clean up fingerprint listening lifecycle. Only listen for fingerprint
if both screen is turned on and Keyguard is actually showing
(not occluded).

Change-Id: I169ce9df308b96487ed9dc5c8ad8f1c301f2ef93
eyguardViewMediator.java
d6aa6cb0cc8c70a30434048e25e14643b1645755 17-Apr-2015 Adrian Roos <roosa@google.com> Remove LockPatternUtils.getCurrentUser()

Bug: 18931518
Change-Id: I177eefe466c12217cf64c85b872f71bc23c7bf05
eyguardViewMediator.java
8150d2a2a12b38598fd55d8ae3c3b5662ec3520f 17-Apr-2015 Adrian Roos <roosa@google.com> Require explicit userId in LockPatternUtils

Bug: 18931518
Change-Id: Ib03f37df9135f0324a998c62d165d8eea46328c8
eyguardViewMediator.java
4a963ac2fa22d633825db1ba1313e11276665ab4 25-Apr-2015 Adrian Roos <roosa@google.com> Fix stale inKeyguardInputRestrictedMode

Bug: 20536027
Change-Id: Ica65b388ae2c58a45c66e9f30efa3fadeded8d47
eyguardViewMediator.java
f3b3bee12994a24b60bd447dede9e8791151fcc9 16-Apr-2015 Jorim Jaggi <jjaggi@google.com> Speedup unlock when authenticating with fingerprint

Change-Id: Ib76ff7a2a42cf6fc77848ef799c2a13b77cfebb2
eyguardViewMediator.java
94e15a59b757678949cccb5d783bee1638e84697 16-Apr-2015 Adrian Roos <roosa@google.com> Allow dismissing Keyguard from TrustAgentService

Bug: 19900313
Change-Id: I44d13ee6fe65070327076e73a3ed96c94acdc108
eyguardViewMediator.java
f253eeb9d3d23d02746406b2b0e721ba3b4563ce 16-Apr-2015 Adrian Roos <roosa@google.com> Fix lockscreen bugs with SHOW_WHEN_LOCKED

When unlocking to a SHOW_WHEN_LOCKED activity by clicking
a notification, we don't get a the startKeyguardExitAnimation
because Keyguard is not actually going away. Instead, we start
it ourselves.

Also fixes the bug where restarting Keyguard while it's occluded
lead to an inconsistent state where the user got stuck on the
lockscreen.

Bug: 16481924
Change-Id: Iebc5bdd1287bbb81415ae01c7428850acc16c53f
eyguardViewMediator.java
ce7eb6daf06a88129da365eb2112537ce0bb1b75 04-Apr-2015 Jim Miller <jaggies@google.com> Clean up FingerprintManager API and make it public.

Change-Id: I6a99dccd485c053cb47dbd0ec08b41a2dc5b17c8
eyguardViewMediator.java
c68b9d6acc69104b67f9f133ee8fefd049d9c21a 08-Apr-2015 Jim Miller <jaggies@google.com> am 5dd10bd1: am e2e945a8: am 40c4021a: Merge "third part apps can disable the secret lockscreen"

* commit '5dd10bd11a524e224a88615444bf8b52b1ec11d6':
third part apps can disable the secret lockscreen
9fc9ac5f774450af80c05ea70847fcf4f4570db8 25-Mar-2015 Jim Miller <jaggies@google.com> Merge "Refactor fingerprint API"
36a1342bce9f8c4c88c13755d694c400dca4de00 25-Mar-2015 John Spurlock <jspurlock@google.com> Fix typo in KeyguardUpdateMonitor.

Change-Id: Iedb2b2051b1a14ab7cc099614f45a57b745ea19d
eyguardViewMediator.java
9f0753f5a378fc80da86305b33244acc6fc53f01 24-Mar-2015 Jim Miller <jaggies@google.com> Refactor fingerprint API

- enroll() and authenticate() now take an explicit callback object.
- better handling of strings
- use framework resources for commonn error strings
- add vendor-specific arrays to resources

Bug 16487912

Change-Id: Idf34242fdd06bba1903cdb22bf20169d15d92b82
eyguardViewMediator.java
261ec767f30c3ed6300cd5668112cb114e05ba18 23-Mar-2015 longyu.huang <longyu.huang@ck-telecom.com> third part apps can disable the secret lockscreen

[Preconditions]
set password or patten lockscreen

[operating steps]
1.install the app (eg QQBrowser) and connected wifi
2.wait a while,the weather notification will shown on statusbar
3.turn off screen,the weather notification will shown on lockscreen too.
4.click the search bar in weather notification,it will disable lockscreen.
5.press HOME button or kill QQBrowser in Recent apps,you can operate the phone
eyguardViewMediator.java
75328b703f8f83fdd62f11105ecd61df2ebe4420 04-Mar-2015 John Spurlock <jspurlock@google.com> Merge "Audio: Remove the concept of master volume."
ee5ad729b90deff435f9875337cbc434be4f8fe7 03-Mar-2015 John Spurlock <jspurlock@google.com> Audio: Remove the concept of master volume.

- Remove two config resources (use master volume, and volume ramp).
- Remove master volume adjustments / getters / intents.
- Retain @hidden setMasterMute, needed for device admin
- Remove master volume logic in AudioService.
- Remove master volume logic in VolumePanel.
- Rename "getMasterStreamType" to "getUiSoundsStreamType" to avoid confusion.

Bug: 19582978
Change-Id: Id02c8fa4898cff3b913147f5ac1b4038e2e7cc24
eyguardViewMediator.java
25d7e51a10828e4433fcca90410d13a4b2342c34 04-Mar-2015 Jim Miller <jaggies@google.com> Change fingerprint behavior in keyguard to dismiss on notification

This changes fingerprint to dismiss the notification screen rather
than moving to a trusted state.

Fixes bug 19592835

Change-Id: I5020408df2e8b73a34c264b5ac052251e3a17b8d
eyguardViewMediator.java
33ae80e35a1b170309999c9b33b310ca91eb3f05 04-Feb-2015 Jorim Jaggi <jjaggi@google.com> Make light status bar fade nicely during unlock transition

By using the timings supplied by window manager for the unlock
transition, the transition from dark -> light status bar looks much
nicer.

Bug: 19233606
Change-Id: I33b9048a10e2bd827ff504ab52f385cc88867112
eyguardViewMediator.java
72b46d429cbab54af962c25ffe087c5f927f7340 30-Jan-2015 Andrew Lee <anwlee@google.com> Reset keyguard/bouncer on "return to call".

+ Add callback, to be invoked when EmergencyButton is clicked when
inside a call.
+ Route callback to the KeyguardViewMediator, to invoke
resetStateLocked() to reset the bouncer.

Bug: 18977746
Change-Id: I4733ccfb6809c4610184a33a28ba38ecf255231f
eyguardViewMediator.java
db0f76e1d85f8cb878a9540ac1b692636f9fd89e 07-Jan-2015 Adrian Roos <roosa@google.com> Directly dispatch USER_REMOVED to LockSettingsService

Bug: 18931518
Change-Id: Ibaf875a06868ae3196115d77eed6874daf2fec16
eyguardViewMediator.java
230635efe7ffb09d6dc56bfd9193aa1d89c8a898 07-Jan-2015 Adrian Roos <roosa@google.com> Purge biometric weak and keyguard widgets

Bug: 18931518
Change-Id: I5da41908b1d6895a69f981e139f2d268327fafcd
eyguardViewMediator.java
6b88cdfba770efc5722338c240ccaada13d7b0d4 22-Dec-2014 Jorim Jaggi <jjaggi@google.com> Remove dead code #8: Remove old keyguard "bouncer"

Also squashes KeyguardViewBase and KeyguardSimpleHostView into
KeyguardHostView, uses a constant for the user activity timeout
(custom value no longer used).

Change-Id: I919b7d3de1dd1590b20e0f14f0e193ee2b3dc21e
eyguardViewMediator.java
a29e81bc7f14ce9df1afb5aa5f7d571a3b441aca 19-Dec-2014 Jorim Jaggi <jjaggi@google.com> Remove dead code #2: Remove unused Keyguard resources

Change-Id: If5e2b62556e6ee158e09e399c7ddec337dba15d5
eyguardViewMediator.java
5c60b647047f744b78f9ae1b1984a654edbda2c6 19-Dec-2014 Jorim Jaggi <jjaggi@google.com> Remove dead code #1: Remove unused Keyguard classes

Change-Id: I08327dd23072b4e793be40635f105ce0aa5f6f6f
eyguardViewMediator.java
a54bf6583380cf328b9858d942b4c387c6163f0f 11-Dec-2014 Wink Saville <wink@google.com> Change tests against INVALID_SUBSCRIPTION_ID to use isValidSubscriptionId.

Rename isValidSubId to isValidSubscriptionId.

Bug: 18668873
Change-Id: Ie709a62bbb74e0a767daeb9e3fb3aecd4c45df44
eyguardViewMediator.java
4b9f8ede4e012e5522716bba84c6037a83ee52f9 01-Dec-2014 Benjamin Franz <bfranz@google.com> Ensure that the USER_PRESENT_INTENT is sent to all profiles of the current user.

This intent is needed by Smart Lock agents to check whether a given user is
active on the device.

Bug: 18530771
Change-Id: I5d460cb0cfa8ec4f7952702a3d25d089db78a50f
eyguardViewMediator.java
95e89caeb252a54807c76d60c7440766829e418c 24-Nov-2014 Jorim Jaggi <jjaggi@google.com> Fix jank when pin/pattern is shown

- Only update layout params of status bar window when needed
- Do not update security method all the time, only when needed (only
when reset gets called)
- Check for actual used security method when updating states for
bouncer

Bug: 18505838
Change-Id: Ib3d0021c0cc364fa5598e06e0a2bae059ae79cbe
eyguardViewMediator.java
ab954546dc49e1070ed8513efbddc8954b529c23 11-Oct-2014 Jim Miller <jaggies@google.com> Make IKeyguardService interface asynchronous

Add a state callback so lockscreen reports back whenever its state
relevant for PhoneWindowManager changed, instead of synchronously
calling into SysUI which can lead to deadlocks. Directly use
LockPatternUtils for isSecure, and optimize the number of calls to
this method to optimize layout performance.

Bug: 17677097
Change-Id: I5d491fc8884d4f84d9562626b9ea0d5eaa5166fc
eyguardService.java
eyguardViewMediator.java
d09c4cad65c708f2c4810d24295456708a2000d2 22-Nov-2014 Wink Saville <wink@google.com> Additional changes to SubscriptionManager API as per API council.

bug: 17575308
Change-Id: Idd98aa46c15a9219ccf28091c62602ac8bf16c62
eyguardViewMediator.java
0284e5e49864a6e039d77210bbea0a013b0e23ec 21-Nov-2014 Jim Miller <jaggies@google.com> Merge "Add multi-sim support to keyguard" into lmp-mr1-dev
481a6df99fea124bc4354da34ff668750cdc9041 20-Nov-2014 Adrian Roos <roosa@google.com> Add device locked API for TrustAgentService

Bug: 18414067
Change-Id: I96c68af9ccc9940acf9fab3b5bd39a3485f01045
eyguardViewMediator.java
52a6133f4ba8b1d08f5158d802790d6a1b16568d 13-Nov-2014 Jim Miller <jaggies@google.com> Add multi-sim support to keyguard

Use new telephony APIs.
Clean up SIM state machine code.
Use cached copy of SubscriptionInfo.
Make SIM PIN and SIM PUK work.

Tested on single and multi-SIM devices.

Fixes bug 18147652

Change-Id: Ic69a4d2898999a5438e6a70b5851705bc05443f1
eyguardViewMediator.java
96afb6f03b87359c3bcb96c2bdb8aadc7b1c3c37 15-Nov-2014 Jim Miller <jaggies@google.com> Fix deadlock caused by synchronous setOccluded() method in keyguard

This fixes a deadlock where WindowManagerService can call into
KeyguardService.setOccluded() while holding a lock. As soon as keyguard
receives the call, it immediately needs to check permission and calls
back into the system service which is waiting for the lock to be
released. Boom!

The fix does a quick check of the calling UID and allows the call
if coming from the System UID, thus bypassing the need for a
binder call to checkPermission().

Fixes bug 18362246

Change-Id: Iab4be8a885f330fb2a62ee7e3579966e1447f8b0
eyguardService.java
f8d77da969edc2f191d349f7d9a30d02edcbd388 11-Nov-2014 Jorim Jaggi <jjaggi@google.com> Improve lockscreen launch animations

- Add a timeout so if WindowManager "forgets" to tell that the
activity has drawn, we still unlock after 3 seconds, so the user
is not completely stuck.

- Use the screen height instead of the window height for the
translation animation.

- Don't run the animation if the attached window is not null. The
animation from the attached window will influence the transformation
as well, so there is no need to run an additional animation in this
case (apps with SurfaceView's had broken unlock transitions because
of this).

- If the starting window needs to go away while the unlock transition
is running, modify the existing animation such that it fades out in
the same transition.

Bug: 15991916
Change-Id: Ia5dfa31e1bc0d5745fe228e1daf08e268733b6f1
eyguardViewMediator.java
44f60cca7bb31e2f9b4b7bf25bb2e0cfb0e3e1e1 07-Nov-2014 Jorim Jaggi <jjaggi@google.com> Fix lockscreen launch animations once and for all

In SysUI, make sure not to dismiss Keyguard multiple times when just
waiting for a deferred dismissal, so WindowManager doesn't get
multiple calls to keyguardGoingAway.

Change heuristics how notifying Keyguard about activity drawn works.
Always notify Keyguard after executing an app transition, and notify
it also when not doing a transition after a startActivity call.

For that to work, update AppWindowToken.startingDisplayed also when
the window is displayed, but force hidden because of Keyguard.

Further, handle the case correctly when a window gets added during
the Keyguard exit animation by overriding the start time for the
animation of that new window. Also don't apply a transition animation
for a window when executing keyguard exit animation, so by removing
a starting window we don't break this animation.

Last but not least, tell Keyguard to start exiting immediately if
animations for exiting are disabled, like when going to phone/camera
on lockscreen. Before, we always had a delay of 1 second because we
waited for the timeout.

Bug: 1599196
Bug: 18272544
Change-Id: I596b2489f814b934abd256e16079d3d3f326e209
eyguardViewMediator.java
b256e4e209afd33bff360ec2652b6ca508df74de 01-Nov-2014 Jim Miller <jaggies@google.com> Fix SetupWizard black screen issue for EDU devices

This fixes a problem where EDU devices show a black screen if
the device is rebooted after setting a pin/pattern/password but
before completing SetupWizard.

The issue is that the system doesn't expect to see a state
where the device is not provisioned but has a pin/pattern/password
because it wasn't possible before. With the addition of the ability
for EDU devices to add a pin/pattern/password, we can now get
into this unforseen state.

The fix ignores provisioning if a password is set so that the
user can reach the security screen to unlock the device and
continue with SetupWizard.

Fixes bug 18022051

Change-Id: Ie88a75530d964c02458c25866f0629877214edf4
eyguardViewMediator.java
2bc75f0821a509e22b23f6718cb5f0543bc4ad4d 18-Sep-2014 Jason Monk <jmonk@google.com> Merge "Fix crash from USER_PRESENT broadcast in sysui" into lmp-dev
cf5a9530f7ded49e830a064526f4290f3a81062c 17-Sep-2014 Jason Monk <jmonk@google.com> Fix crash from USER_PRESENT broadcast in sysui

Since sending the USER_PRESENT broadcast too early in the boot
process can result in a SecurityException, don't do auto-unlock
until after the boot has completed.

Bug: 17464800
Change-Id: Iee3d0b9723ed38abddf0bdde009f95331881008b
eyguardViewMediator.java
61d9409239c5ed360ffc2181eee6b981aad9192b 16-Sep-2014 Adam Lesinski <adamlesinski@google.com> Show the lockscreen when more than 1 user is present

Bug:17399024
Change-Id: Iaf2ea2747cbcd9db45ba9faa7c8fe0389a799855
eyguardViewMediator.java
b60d47ccefc7e4bcee81a91b108244b7dbdd7081 08-Sep-2014 Adrian Roos <roosa@google.com> Initilize LockPatternUtils with the current user

Prevents us from ending up with the wrong user in case
of SystemUI restarts.

Bug: 17343537
Change-Id: I40282380740f8b58adc72d24cb01d1018f07cfe7
eyguardViewMediator.java
705004bebf919b2d851fa86a31f17fc21b0dca34 05-Sep-2014 Jim Miller <jaggies@google.com> Send USER_PRESENT broadcast after keyguard animation finishes

This fixes a potential race between receiving USER_PRESENT
broadcast and testing if keyguard is finished
(KeyguardManager.isKeyguardLocked())

This also fixes an issue where USER_PRESENT isn't sent when
device encryption is enabled.

Fixes bug 17322844
Fixes bug 17301385

Change-Id: Icab3068c24032942ffdf6554d6d53cc656ae6666
eyguardViewMediator.java
053ff3c776d51dd216f3b87b692336570439033b 03-Sep-2014 Adrian Roos <roosa@google.com> Merge "Auto dismiss lockscreen when switching to guest" into lmp-dev
be47b07bef0596dd9bf7137ea08cc1112328c6e8 03-Sep-2014 Adrian Roos <roosa@google.com> Auto dismiss lockscreen when switching to guest

Bug: 16659674
Change-Id: I8d24a3997ac7493cd8a8317f8a35532eaf5c3cfe
eyguardViewMediator.java
7ff6eb6429ae3b0facc93214acefd657d378f4da 03-Sep-2014 Selim Cinek <cinek@google.com> Correctly forwarding the screen off event on lockscreen

Bug: 17364635
Change-Id: I88730238e3622522674268438d266fd2334410cd
eyguardViewMediator.java
118aecea584499fb41966fd8a0ea0ac60ac6bdb6 25-Aug-2014 Jorim Jaggi <jjaggi@google.com> Fix swipe up affordance bugs

- Fix that you could invoke the gesture from bouncer
- Fix that sometimes the card got stuck
- Decrease threshold to invoke the gesture

Bug: 17201962
Bug: 17200912
Bug: 17199841
Change-Id: I19f1e1a69395c3bcd82cdad0d814916a3cdd3428
eyguardViewMediator.java
49e057d7eedb44f5397781254acab4e0ef08a9cf 13-Aug-2014 Adrian Roos <roosa@google.com> Play "device trusted" sound when onTrustInitiatedByUser fires

Bug: 16840500
Change-Id: I73fbe5c2cff665ccb637abb9039d57f377d9df53
eyguardViewMediator.java
84a3e7aacf6dbeccf4afb36a29f2f069dca7d486 13-Aug-2014 Jorim Jaggi <jjaggi@google.com> Use different unlock animation when going to full shade

Also fixes a bug that the notify flag was not reset, and fix the
transition for the phone/camera affordance (in these cases, no
animation is needed).

Bug: 15991916
Change-Id: Idbb4fa40f86bda597cd66cc38da838ef4f75514d
eyguardViewMediator.java
8de4311c51229efbe2f2d0afbf298982c5cadd96 11-Aug-2014 Jorim Jaggi <jjaggi@google.com> Lockscreen launch animations

- Get rid of ActivityManager.dismissKeyguardOnNextActivity, which was
used for two different things: Dismiss keyguard from somewhere else
(not really necessary anymore), wait to actually dismiss keyguard
after the window behind is drawn. Instead, introduce
keyguardWaitingForActivityDrawn(), and change the semantics where
necessary.
- Make wallpaper_close_enter consistent with task_open_enter and the
Keyguard launch animation.
- Close the panel even on lockscreen when launching a notification.
- Block notification shade updates during the collapsing motion so
notification don't play the disappear animation immediately after
having launched a notification.

Bug: 15991916

Change-Id: I133c177b84e926c87c1a404ba93d633593fec3ab
eyguardService.java
eyguardViewMediator.java
76a1623afc170a13923b68f3256057d8adeb7937 08-Aug-2014 Jorim Jaggi <jjaggi@google.com> Preparations for lockscreen launch animations

- Update unlock animations to new spec to make the consistent with
lockscreen launch animations.
- Introduce disappearing motion for security views which runs before
we actually dismiss Keyguard.
- If a window is running the un-force-hide animation, treat as it
would have the wallpaper flag set so the wallpaper stays until
the animation is completely done.
- Run an animation on the wallpaper if the wallpaper is going away.

Bug: 15991916
Bug: 16234603
Bug: 15326120
Change-Id: I063aa4f269ddcf75b9a705e90f0c3056b541b642
eyguardViewMediator.java
0002a45034b1103ffc5ecf4d5a14b7d1ba225005 03-Jul-2014 Adrian Roos <roosa@google.com> Show bouncer when opening notification in occluded mode

When showing apps on top of keyguard, properly put up
a bouncer when a notification is clicked.

Bug: 15588412

Change-Id: I48bcc5cc17c32856c11e7ab28182cdc3f253ad98
eyguardViewMediator.java
b690f0d5023fcf144f2701058d5a6f88d66cc97a 03-Jul-2014 Jorim Jaggi <jjaggi@google.com> Clean up user activity handling

- Only call userActivity in down touch event
- Use normal timeout when QS is open
- Clean up old code regarding user activity in Keyguard

Change-Id: I968eeed33fef44def37b68eb1ddc63f1a531ab35
eyguardViewMediator.java
d0b698f074a8a251781b62346a791de48d39d2a4 02-Jul-2014 Jorim Jaggi <jjaggi@google.com> Fix "None" lock screen option

Now that we have a user switcher in quick settings, we don't need to
show the lockscreen if multi-user is enabled.

Bug: 15864584
Change-Id: I1a7ea69963fdd5a4f79584f565beff36612468f5
eyguardViewMediator.java
f41fc9664febbdbf138e8540fd7a8281f1278eb1 19-Jun-2014 Jim Miller <jaggies@google.com> Add fingerprint detection support to Keyguard.

Tested:
- power-on with fingerprint sensor
- dismiss bouncer with fingerprint
- fingerprint to enter trusted state

Change-Id: I6aab7591d370412a143fe219a1575b2719a4de96
eyguardViewMediator.java
53c68a44acbd9343dda648c17652e921c28fda1d 18-Jun-2014 Jorim Jaggi <jjaggi@google.com> Fix bug when Keyguard gets hidden.

We make sure in Keyguard that we only hide ourselves in
startKeyguardExitAnimation ourselves when we requested a hide.

In addition, this change also fixes a bug in WindowAnimator that
it should only call startKeyguardExitAnimation when Keyguard actually
requested a hide.

Bug: 15676717
Change-Id: I2279cccb9916985b7e9a2f41137878be5782cb9c
eyguardViewMediator.java
34f521e2af11b82b131b92a149ee30e23452a41e 04-Jun-2014 Jorim Jaggi <jjaggi@google.com> am 7a49d92b: Merge "Fix invalid Keyguard state with encrypted devices." into lmp-preview-dev

* commit '7a49d92bf6fd23af7dff29fd3cb97fcd5c05cfc9':
Fix invalid Keyguard state with encrypted devices.
b9d6079120747205e2ae18162aa730fad3b58d9c 03-Jun-2014 Jorim Jaggi <jjaggi@google.com> Fix invalid Keyguard state with encrypted devices.

Bug: 15389720
Change-Id: I0a18e78043e5c08f40cf3288abc07f75ea6261a0
eyguardViewMediator.java
897752a6f7a061e3a0463baee5040b18c21fec60 02-Jun-2014 Adrian Roos <roosa@google.com> Disable now defunct touch analysis facility - DO NOT MERGE

Bug: 15381470
Change-Id: I2ab252e4c0122d79c9a78b3df643bfd46a105cf0
eyguardViewMediator.java
bba9a212a07ed95a14e86b5d6a18792a90b47f7b 02-Jun-2014 Adrian Roos <roosa@google.com> Remove now defunct touch analysis facility

Bug: 15381470
Change-Id: I2ab252e4c0122d79c9a78b3df643bfd46a105cf0
eyguardViewMediator.java
e29b2dbc762bfa66093d76f5a65f55328d8753c9 30-May-2014 Jorim Jaggi <jjaggi@google.com> Fade scrim in unlock animation.

This also introduces a startTime which gets sent from window manager
to SystemUI, which tells when the animation should start, to allow
for a more synchronized animation with fading out the scrim and
fading in the activity behind.

Bug: 15163546
Change-Id: I16212b1ef9eb76f1f98734da1d14fc5b7e626937
eyguardService.java
eyguardViewMediator.java
0d674623facfbd3e9c520d2be4ed98977b92a1a2 21-May-2014 Jorim Jaggi <jjaggi@google.com> Add methods to coordinate unlock animation.

Introduce IWindowManager.keyguardGoingAway to notify that Keyguard
wants to dismiss it self. This method starts the state machine in
WindowAnimator which animates in the activity behind the keyguard.
Animating out the keyguard is done by the StatusBar/Keyguard
software when it receives the startKeyguardExitAnimation() callback.

Bug: 14118756

Change-Id: Id3b8f41189410bad808b4892fbec74245e59efce
eyguardService.java
eyguardViewMediator.java
ecc798e6668046c2f67cf30c6ab1db2eba80cab1 26-May-2014 Jorim Jaggi <jjaggi@google.com> Improve scrim handling

Bug: 15163546
Change-Id: I0d2c05b035f832f4b4e6a2fc34113fe9d5677525
eyguardViewMediator.java
b601162a60663329355720083bfa199909dbf6ef 14-May-2014 Adrian Roos <roosa@google.com> Fix visibility and add bouncer event in KeyguardUpdateMonitor

Bug: 14087751
Change-Id: I45bc2213dfcce751180762d18ead0382f68cac74
eyguardViewMediator.java
fb0448ab4b42c1b390cd75c3660ec0de511b7b3b 02-May-2014 Jeff Brown <jeffbrown@google.com> resolved conflicts for merge of 4f8cd188 to master

Change-Id: I148cd616cd14d834915978aa2dc3f9e27188dbd3
1568250853d81befcdaef63cc8588435353c3d12 23-Apr-2014 Jorim Jaggi <jjaggi@google.com> Move redaction logic showing from Keyguard to PhoneStatusBar.

This removes a race condition and makes redaction more stable.

Change-Id: I4084cdf490c0e52fe26f45cb00524e0876a068bc
eyguardViewMediator.java
a6310293c5a861cdb54f2c894e90a8d9da87f8d7 16-Apr-2014 Jorim Jaggi <jjaggi@google.com> Hide navigation bar on Keyguard.

This also moves the camera affordance from navbar to the navigation
panel, so it is still visible on the Keyguard.

Bug: 14086354
Bug: 14085922
Bug: 14110532
Bug: 14059294
Change-Id: I93b51381915a67c688cdffd055fd149f2a220b00
eyguardViewMediator.java
a005f1b6853e8852c328f4fdc02fb8f9c9ae1cd6 16-Apr-2014 Jorim Jaggi <jjaggi@google.com> Show enter PIN/PUK before notifications on Keyguard.

Change-Id: Icec12a43487fe76378e10bb8aaaa163c53b69075
eyguardViewMediator.java
3beffdf4a0081a97356f46d50e10541b1a213153 03-Apr-2014 Jorim Jaggi <jjaggi@google.com> Fix crash when taking screenshot.

Start SystemUI services only if needed.

Bug: 13635952
Change-Id: I76a5e3333ed8f51a267e33b2cf172d6c775ac914
eyguardService.java
03c701ec58ff6de3cc3c53b05342a475a63a11cf 02-Apr-2014 Jorim Jaggi <jjaggi@google.com> Basic implementation for notifications on lockscreen.

This change makes PhoneStatusBar expand while the lockscreen is
showing. Further, the KeyguardSimpleHostView is shown by
KeyguardBouncer, and the Bouncer is shown whenever the user tries to
unlock the phone (closing the shade).

Bug: 13635952
Change-Id: I4354b7a7937af6e1c93abf16ad6e485376d16bc2
eyguardViewMediator.java
ae6ffcc3c74d12ebf59a26cce24d04fdd2b56f4e 02-Apr-2014 Jorim Jaggi <jjaggi@google.com> Merge "Wait for Keyguard to be drawn after boot." into master-lockscreen-dev
cff0acb6b1eea23c3f44a078a0a5e81c11faea35 31-Mar-2014 Jorim Jaggi <jjaggi@google.com> Wait for Keyguard to be drawn after boot.

The old logic with waiting for the Keyguard to be drawn assumed that
it is in an own window, and just checked for the visibility. This is
no longer possible as the Keyguard is in the status bar, and the status
bar might have been drawn without the Keyguard. So we have to wait
explicitely until Keyguard told PhoneWindowManager that it has now been
drawn and we can turn on the screen.

In addition, the starting logic of SystemUI is moved into
SystemUIApplication such the we can make sure that the status bar
already exists when the callbacks from PhoneWindowManager reach
KeyguardService. This simplifies the logic a lot.

Bug: 13635952
Change-Id: Ifd6ba795647edcf3501641e39052e4d04bc826fb
eyguardService.java
eyguardStatusBarBinder.java
eyguardViewMediator.java
d2cf756996be2cbc915227f1f384704427ab88e6 01-Apr-2014 Paul Lawrence <paullawrence@google.com> am df42723d: Merge "Don\'t double prompt on booting encrypted device"

* commit 'df42723d6b717fd2882c98c930a0f93c75af2474':
Don't double prompt on booting encrypted device
78d9aece821cf8f40eb95aa962cb3ea707669413 31-Mar-2014 Adrian Roos <roosa@google.com> am 46842d94: Make Keyguard trust aware

* commit '46842d946d1777c22f05e6bb96933c1b5cbd00d4':
Make Keyguard trust aware
5cf17879a31b7b78c09ec50b727f921840dcf783 26-Mar-2014 Jorim Jaggi <jjaggi@google.com> Reuse KeyguardViewMediator for new Keyguard implementation.

This change reuses KeyguardViewMediator for the new Keyguard
implementation in status bar. KeyguardViewManager is replaced by
StatusBarKeyguardManager which handles adding the view, setting the
state etc. StatusBarWindowManager is introduced to managed the window
of the status bar, which has the logic of both the old Keyguard window
and the old status bar window. In the current implementation, Keyguard
gets displayed like it would be in the bouncer state, but that's likely
to change in the future. Also, setHidden in IKeyguardService is also
renamed to setOccluded, as the word hidden interferes with the
terminology when dismissing the Keyguard.

Bug: 13635952
Change-Id: I1c5d5a49d810d8532089f464cb2efe35e577f517
eyguardService.java
eyguardStatusBarBinder.java
eyguardViewMediator.java
380ecb81db52a9d0197ca969951d07b91c20d2b9 14-Mar-2014 Jorim Jaggi <jjaggi@google.com> Make Keyguard a library and make StatusBar the new Keyguard.

This change achieves a couple of things:
- Let Keyguard be a library, so we can use it in SystemUI.
- Introduce FLAG_KEYGUARD for windows and deprecate TYPE_KEYGUARD. Make
all the TYPE_KEYGUARD behaviour dependant on the flag.
- Implement a new KeyguardService in SystemUI, and bind that service
from PhoneWindowManager.
- Introduce BaseStatusBar.setKeyguardState and inflate
KeyguardSimpleHostView there and use FLAG_KEYGUARD for the window, such
that the status bar window essentially gets the Keyguard.

Bug: 13635952
Change-Id: I059d80d8b9b9818a778ab685f4672ea2694def63
eyguardService.java
eyguardStatusBarBinder.java