Skip to content

[ios]Platform view always has a FlutterOverlayView of height 1, even when there's no overlap between flutter widget and platform view.  #143420

@hellohuanlin

Description

@hellohuanlin

By running the example with multiple ad banners, and inspect the view hierarchy. We notice that each platform view is accompanied with an overlay view of height 1 pixel (0.5 points)

1 pixel height overlay

Proposal

This is related to the unobstructed platform view work. I suspect that this is due to roundOut when computing the intersection of flutter widgets and platform view.

For example, if we interleave flutter widget and platform view in a list, and let's say we have a flutter widget (top = 0, bottom = 100.1), and a platform view below that widget (top = 100.1, bottom = 200). They are NOT supposed to be overlapping.

However, after rounding out (expanding out), we will get flutter widget (top = 0, bottom = 101), and platform view (top = 100, bottom 200). This will result in 1 pixel overlap as long as there's a floating point in the coord.

Likely can be resolved in flow level, but can experiment on iOS embedder first.

Metadata

Metadata

Assignees

Labels

a: platform-viewsEmbedding Android/iOS views in Flutter appsplatform-iosiOS applications specificallyteam-iosOwned by iOS platform team

Type

No type

Projects

Status

Done

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions