Skip to content

Commit

Permalink
Fix overlay alignment
Browse files Browse the repository at this point in the history
  • Loading branch information
yiqunw700 committed Jan 7, 2025
1 parent 1111f77 commit 9757277
Showing 1 changed file with 6 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -648,12 +648,12 @@ private fun generateOverlayNode(
// Make a view based on the child node which uses a synthesized style.
val layoutStyleBuilder = node.style.layoutStyle.toBuilder()
layoutStyleBuilder.positionType = PositionType.POSITION_TYPE_ABSOLUTE
layoutStyleBuilder.top = dimensionProto { points = 0.0f }
layoutStyleBuilder.left = dimensionProto { points = 0.0f }
layoutStyleBuilder.right = dimensionProto { points = 0.0f }
layoutStyleBuilder.bottom = dimensionProto { points = 0.0f }
layoutStyleBuilder.width = dimensionProto { points = 0.0f }
layoutStyleBuilder.height = dimensionProto { points = 0.0f }
layoutStyleBuilder.top = dimensionProto { percent = 0.0f }
layoutStyleBuilder.left = dimensionProto { percent = 0.0f }
layoutStyleBuilder.right = dimensionProto { percent = 0.0f }
layoutStyleBuilder.bottom = dimensionProto { percent = 0.0f }
layoutStyleBuilder.width = dimensionProto { percent = 1.0f }
layoutStyleBuilder.height = dimensionProto { percent = 1.0f }
layoutStyleBuilder.flexDirection = FlexDirection.FLEX_DIRECTION_COLUMN
when (overlay.overlayPositionType) {
OverlayPositionType.OVERLAY_POSITION_TYPE_TOP_LEFT -> {
Expand Down

0 comments on commit 9757277

Please sign in to comment.