[PE] Avoid cache conflict when painting LocalFrameView outside of lifecycle

Rename LocalFrameView methods:
  PaintWithLifecycleUpdate() -> PaintOutsideOfLifecycle()
  PaintContents() -> PaintContentsOutsideOfLifecycle()
because they are special paints outside of lifecycle update (vs the
normal paint executed during lifecycle update).

They may conflict with normal painting about paint controller caching.
Previously in pre-CompositeAfterPaint we assumed no conflict by either
- using transient paint controller (through PaintRecordBuilder), or
- assuming the local frame root of the LocalFrameView doesn't have
  graphics layers.

The above assumption was not always true. One case is the validation
message popup which may contain complex composited contents.

Add check for conflicting paints outside of lifecycle.

Add PaintArtifact::GetPaintRecord() and LocalFrameView::GetPaintRecord()
for fast path in CompositedAfterPaint.

Change-Id: I8222dd58cf5b8e1e86493476c02761e844675c01
Reviewed-on: https://chromium-review.googlesource.com/c/1374779
Reviewed-by: Philip Rogers <pdr@chromium.org>
Commit-Queue: Xianzhu Wang <wangxianzhu@chromium.org>
Cr-Commit-Position: refs/heads/master@{#616446}
17 files changed