Skip to content
This repository was archived by the owner on Feb 25, 2025. It is now read-only.
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -137,7 +137,14 @@ void AndroidExternalViewEmbedder::SubmitFrame(
// slighly larger. For example, {0.3, 0.5, 3.1, 4.7} becomes {0, 0, 4,
// 5}.
intersection_rect.set(intersection_rect.roundOut());
overlay_layers.at(view_id).push_back(intersection_rect);
if (overlay_layers.at(view_id).empty()) {
overlay_layers.at(view_id).push_back(intersection_rect);
} else if (intersection_rect.contains(
overlay_layers.at(view_id).back())) {
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I was expecting the overlay layers to be associated with two different view_ids since there are two platform views, and the fab button intersects both.

Do you mind verifying why a single view_id contain the two overlay surfaces?

overlay_layers.at(view_id).back() = intersection_rect;
} else {
overlay_layers.at(view_id).back().join(intersection_rect);
}
// Clip the background canvas, so it doesn't contain any of the pixels
// drawn on the overlay layer.
background_canvas->clipRect(intersection_rect, SkClipOp::kDifference);
Expand Down