mirror of
https://gitee.com/openharmony/account_os_account
synced 2024-11-23 10:10:11 +00:00
!2144 delay kill scb when transition
Merge pull request !2144 from Jasonye/delay
This commit is contained in:
commit
11bc4ae5b9
@ -2246,6 +2246,9 @@ ErrCode IInnerOsAccountManager::UpdateAccountToBackground(int32_t oldId)
|
||||
if (errCode != ERR_OK) {
|
||||
return ERR_ACCOUNT_COMMON_ACCOUNT_NOT_EXIST_ERROR;
|
||||
}
|
||||
if (oldOsAccountInfo.GetIsForeground()) {
|
||||
std::this_thread::sleep_for(std::chrono::milliseconds(DELAY_FOR_REMOVING_FOREGROUND_OS_ACCOUNT));
|
||||
}
|
||||
oldOsAccountInfo.SetIsForeground(false);
|
||||
oldOsAccountInfo.SetDisplayId(Constants::INVALID_DISPALY_ID);
|
||||
errCode = osAccountControl_->UpdateOsAccount(oldOsAccountInfo);
|
||||
|
Loading…
Reference in New Issue
Block a user