!1186 统一渲染下,锁屏进入桌面会黑一帧

Merge pull request !1186 from lastking/master
This commit is contained in:
openharmony_ci
2022-07-19 02:49:33 +00:00
committed by Gitee
+6
View File
@@ -21,6 +21,7 @@
#include <display_power_mgr_client.h>
#include <hitrace_meter.h>
#include <power_mgr_client.h>
#include "transaction/rs_transaction.h"
#include "common_event_manager.h"
#include "dm_common.h"
@@ -1195,6 +1196,7 @@ void WindowNodeContainer::TraverseAndUpdateWindowState(WindowState state, int32_
for (auto& node : rootNodes) {
UpdateWindowState(node, topPriority, state);
}
RSTransaction::FlushImplicitTransaction();
}
void WindowNodeContainer::UpdateWindowState(sptr<WindowNode> node, int32_t topPriority, WindowState state)
@@ -1209,6 +1211,10 @@ void WindowNodeContainer::UpdateWindowState(sptr<WindowNode> node, int32_t topPr
node->GetWindowToken()->UpdateWindowState(state);
}
HandleKeepScreenOn(node, state);
auto surfaceNode = node->surfaceNode_;
if (surfaceNode) {
surfaceNode->SetVisible(state == WindowState::STATE_FROZEN ? false : true);
}
}
}
for (auto& childNode : node->children_) {