mirror of
https://gitee.com/openharmony/arkui_ace_engine
synced 2024-11-23 15:10:30 +00:00
!48622 revert 47085
Merge pull request !48622 from Zhang Jinyu/dialog_1115
This commit is contained in:
commit
d5340ddc95
@ -583,21 +583,10 @@ void DialogLayoutAlgorithm::ParseSubwindowId(const RefPtr<DialogLayoutProperty>&
|
||||
|
||||
void DialogLayoutAlgorithm::AdjustHeightForKeyboard(LayoutWrapper* layoutWrapper, const RefPtr<LayoutWrapper>& child)
|
||||
{
|
||||
if (Container::LessThanAPITargetVersion(PlatformVersion::VERSION_TWELVE) || !child ||
|
||||
if (Container::LessThanAPITargetVersion(PlatformVersion::VERSION_TWELVE) || !child || !resizeFlag_ ||
|
||||
keyboardAvoidMode_ == KeyboardAvoidMode::NONE) {
|
||||
return;
|
||||
}
|
||||
auto host = child->GetHostNode();
|
||||
CHECK_NULL_VOID(host);
|
||||
auto renderContext = host->GetRenderContext();
|
||||
CHECK_NULL_VOID(renderContext);
|
||||
if (!resizeFlag_) {
|
||||
auto clipEdge = renderContext->GetClipEdge().value_or(false);
|
||||
if (clipEdge) {
|
||||
renderContext->UpdateClipEdge(false);
|
||||
}
|
||||
return;
|
||||
}
|
||||
auto childLayoutProperty = child->GetLayoutProperty();
|
||||
auto dialogProp = DynamicCast<DialogLayoutProperty>(layoutWrapper->GetLayoutProperty());
|
||||
CHECK_NULL_VOID(childLayoutProperty);
|
||||
@ -614,6 +603,8 @@ void DialogLayoutAlgorithm::AdjustHeightForKeyboard(LayoutWrapper* layoutWrapper
|
||||
}
|
||||
child->Measure(childConstraint);
|
||||
child->GetGeometryNode()->SetFrameSize(dialogChildSize_);
|
||||
auto renderContext = child->GetHostNode()->GetRenderContext();
|
||||
CHECK_NULL_VOID(renderContext);
|
||||
renderContext->SetClipToFrame(true);
|
||||
renderContext->UpdateClipEdge(true);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user