Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(442)

Unified Diff: content/browser/renderer_host/delegated_frame_evictor.cc

Issue 174323003: Expose locks for CopyFromCompositingSurface/CopyFromBackingStore API (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: added NOTIMPLEMENTED() and put back CanCopyFromBackingStore() Created 6 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: content/browser/renderer_host/delegated_frame_evictor.cc
diff --git a/content/browser/renderer_host/delegated_frame_evictor.cc b/content/browser/renderer_host/delegated_frame_evictor.cc
index 33d6b2c479f62224886927a18dc8bfa1f09d09fb..1926617e1d3566ebc0ad3b32a98d77ce50209a45 100644
--- a/content/browser/renderer_host/delegated_frame_evictor.cc
+++ b/content/browser/renderer_host/delegated_frame_evictor.cc
@@ -48,4 +48,10 @@ void DelegatedFrameEvictor::EvictCurrentFrame() {
client_->EvictDelegatedFrame();
}
+bool DelegatedFrameEvictor::FrameLocked() {
+ // The first lock is the visible/invisible state.
+ return has_frame_ &&
+ RendererFrameManager::GetInstance()->LockedCount(this) > 1;
+}
+
} // namespace content

Powered by Google App Engine
This is Rietveld 408576698