修复UEC多实例问题

Signed-off-by: cuijiawei2022 <cuijiawei14@huawei.com>
This commit is contained in:
cuijiawei2022 2024-11-04 22:17:08 +08:00
parent b57d56134c
commit d6437bdeb6
2 changed files with 3 additions and 0 deletions

View File

@ -457,6 +457,7 @@ void SecuritySessionWrapperImpl::NotifyCreate() {}
void SecuritySessionWrapperImpl::NotifyForeground()
{
ContainerScope scope(instanceId_);
CHECK_NULL_VOID(session_);
auto pipeline = PipelineBase::GetCurrentContext();
CHECK_NULL_VOID(pipeline);

View File

@ -349,6 +349,7 @@ Rosen::SessionViewportConfig ConvertToRosenSessionViewportConfig(const SessionVi
void SessionWrapperImpl::CreateSession(const AAFwk::Want& want, const SessionConfig& config)
{
ContainerScope scope(instanceId_);
UIEXT_LOGI("The session is created with want = %{private}s", want.ToString().c_str());
auto container = Platform::AceContainer::GetContainer(instanceId_);
CHECK_NULL_VOID(container);
@ -581,6 +582,7 @@ int32_t SessionWrapperImpl::GetWindowSceneId()
void SessionWrapperImpl::NotifyForeground()
{
ContainerScope scope(instanceId_);
CHECK_NULL_VOID(session_);
auto container = Platform::AceContainer::GetContainer(instanceId_);
CHECK_NULL_VOID(container);