|
@@ -0,0 +1,46 @@
|
|
|
+From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
|
|
+From: Jana Grill <[email protected]>
|
|
|
+Date: Wed, 14 Apr 2021 08:40:10 +0000
|
|
|
+Subject: Forbid script execution while updating the paint lifecycle.
|
|
|
+
|
|
|
+(cherry picked from commit 5425d3b100fab533ea9ddc2ed8fbfc4870db0587)
|
|
|
+
|
|
|
+Bug: 1196781
|
|
|
+Change-Id: Idc8d24792d5c413691977b09ca821de4e13887ad
|
|
|
+Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2812000
|
|
|
+Commit-Queue: Adrian Taylor <[email protected]>
|
|
|
+Commit-Queue: Robert Flack <[email protected]>
|
|
|
+Reviewed-by: Xianzhu Wang <[email protected]>
|
|
|
+Cr-Original-Commit-Position: refs/heads/master@{#870275}
|
|
|
+Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2821879
|
|
|
+Reviewed-by: Robert Flack <[email protected]>
|
|
|
+Reviewed-by: Achuith Bhandarkar <[email protected]>
|
|
|
+Reviewed-by: Victor-Gabriel Savu <[email protected]>
|
|
|
+Commit-Queue: Jana Grill <[email protected]>
|
|
|
+Cr-Commit-Position: refs/branch-heads/4240@{#1601}
|
|
|
+Cr-Branched-From: f297677702651916bbf65e59c0d4bbd4ce57d1ee-refs/heads/master@{#800218}
|
|
|
+
|
|
|
+diff --git a/third_party/blink/renderer/core/frame/local_frame_view.cc b/third_party/blink/renderer/core/frame/local_frame_view.cc
|
|
|
+index 9a4c7a5249424b021759bf7895dd3f343b9641e6..37054d34157e7f4b4d65b022cdb83c832deb26a8 100644
|
|
|
+--- a/third_party/blink/renderer/core/frame/local_frame_view.cc
|
|
|
++++ b/third_party/blink/renderer/core/frame/local_frame_view.cc
|
|
|
+@@ -2648,11 +2648,14 @@ void LocalFrameView::RunPaintLifecyclePhase() {
|
|
|
+ for (PaintLayerScrollableArea* area : *animating_scrollable_areas)
|
|
|
+ area->UpdateCompositorScrollAnimations();
|
|
|
+ }
|
|
|
+- frame_view.GetLayoutView()
|
|
|
+- ->GetDocument()
|
|
|
+- .GetDocumentAnimations()
|
|
|
+- .UpdateAnimations(DocumentLifecycle::kPaintClean,
|
|
|
+- paint_artifact_compositor_.get());
|
|
|
++ {
|
|
|
++ ScriptForbiddenScope forbid_script;
|
|
|
++ frame_view.GetLayoutView()
|
|
|
++ ->GetDocument()
|
|
|
++ .GetDocumentAnimations()
|
|
|
++ .UpdateAnimations(DocumentLifecycle::kPaintClean,
|
|
|
++ paint_artifact_compositor_.get());
|
|
|
++ }
|
|
|
+ });
|
|
|
+
|
|
|
+ // Initialize animation properties in the newly created paint property
|