This can result in the keyguard not being re-enabled, the status
bar being in a bad state, and various other weirdness. When a task
is going away, it needs to send the standard lock task ending
messages so that exiting the state can be handled properly.
Bug:
16010327
Change-Id: Id7ee632f4765af0af209b70fb69dd75f2e541820
void endLockTaskModeIfTaskEnding(TaskRecord task) {
if (mLockTaskModeTask != null && mLockTaskModeTask == task) {
+ final Message lockTaskMsg = Message.obtain();
+ lockTaskMsg.arg1 = mLockTaskModeTask.userId;
+ lockTaskMsg.what = LOCK_TASK_END_MSG;
mLockTaskModeTask = null;
+ mHandler.sendMessage(lockTaskMsg);
}
}