mirror of
https://bitbucket.org/chromiumembedded/cef
synced 2025-02-23 23:47:43 +01:00
osr: Implement InvalidateLocalSurfaceIdOnEviction (fixes issue #2483)
This fixes an empty-rendering issue when the view is shown after being evicted.
This commit is contained in:
parent
f7bea2419e
commit
b156d790e3
@ -114,7 +114,9 @@ class CefDelegatedFrameHostClient : public content::DelegatedFrameHostClient {
|
|||||||
return view_->render_widget_host()->CollectSurfaceIdsForEviction();
|
return view_->render_widget_host()->CollectSurfaceIdsForEviction();
|
||||||
}
|
}
|
||||||
|
|
||||||
void InvalidateLocalSurfaceIdOnEviction() override {}
|
void InvalidateLocalSurfaceIdOnEviction() override {
|
||||||
|
view_->InvalidateLocalSurfaceId();
|
||||||
|
}
|
||||||
|
|
||||||
bool ShouldShowStaleContentOnEviction() override { return false; }
|
bool ShouldShowStaleContentOnEviction() override { return false; }
|
||||||
|
|
||||||
|
@ -274,6 +274,11 @@ class CefRenderWidgetHostViewOSR
|
|||||||
|
|
||||||
void ReleaseCompositor();
|
void ReleaseCompositor();
|
||||||
|
|
||||||
|
// Marks the current viz::LocalSurfaceId as invalid. AllocateLocalSurfaceId
|
||||||
|
// must be called before submitting new CompositorFrames. May be called by
|
||||||
|
// content::DelegatedFrameHostClient::InvalidateLocalSurfaceIdOnEviction.
|
||||||
|
void InvalidateLocalSurfaceId();
|
||||||
|
|
||||||
private:
|
private:
|
||||||
void SetFrameRate();
|
void SetFrameRate();
|
||||||
bool SetDeviceScaleFactor();
|
bool SetDeviceScaleFactor();
|
||||||
@ -321,10 +326,6 @@ class CefRenderWidgetHostViewOSR
|
|||||||
// Returns the current viz::LocalSurfaceIdAllocation.
|
// Returns the current viz::LocalSurfaceIdAllocation.
|
||||||
const viz::LocalSurfaceId& GetOrCreateLocalSurfaceId();
|
const viz::LocalSurfaceId& GetOrCreateLocalSurfaceId();
|
||||||
|
|
||||||
// Marks the current viz::LocalSurfaceId as invalid. AllocateLocalSurfaceId
|
|
||||||
// must be called before submitting new CompositorFrames.
|
|
||||||
void InvalidateLocalSurfaceId();
|
|
||||||
|
|
||||||
void AddDamageRect(uint32_t sequence, const gfx::Rect& rect);
|
void AddDamageRect(uint32_t sequence, const gfx::Rect& rect);
|
||||||
|
|
||||||
// Applies background color without notifying the RenderWidget about
|
// Applies background color without notifying the RenderWidget about
|
||||||
|
Loading…
x
Reference in New Issue
Block a user