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

Unified Diff: content/browser/compositor/owned_mailbox.cc

Issue 2083853002: exo: Recreate Surface resources on context lost. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: fix nits Created 4 years, 6 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/compositor/owned_mailbox.cc
diff --git a/content/browser/compositor/owned_mailbox.cc b/content/browser/compositor/owned_mailbox.cc
index b23d3c8d3f8dda04f20d61d077a8e13d97d18565..1729c38673cdcaa9454d75c6d31fbe8a79346e00 100644
--- a/content/browser/compositor/owned_mailbox.cc
+++ b/content/browser/compositor/owned_mailbox.cc
@@ -14,7 +14,7 @@ OwnedMailbox::OwnedMailbox(display_compositor::GLHelper* gl_helper)
: texture_id_(0), gl_helper_(gl_helper) {
texture_id_ = gl_helper_->CreateTexture();
mailbox_holder_ = gl_helper_->ProduceMailboxHolderFromTexture(texture_id_);
- ImageTransportFactory::GetInstance()->AddObserver(this);
+ ImageTransportFactory::GetInstance()->GetContextFactory()->AddObserver(this);
}
OwnedMailbox::~OwnedMailbox() {
@@ -28,7 +28,8 @@ void OwnedMailbox::UpdateSyncToken(const gpu::SyncToken& sync_token) {
}
void OwnedMailbox::Destroy() {
- ImageTransportFactory::GetInstance()->RemoveObserver(this);
+ ImageTransportFactory::GetInstance()->GetContextFactory()->RemoveObserver(
+ this);
gl_helper_->WaitSyncToken(mailbox_holder_.sync_token);
gl_helper_->DeleteTexture(texture_id_);
texture_id_ = 0;
« no previous file with comments | « content/browser/compositor/owned_mailbox.h ('k') | content/browser/compositor/test/no_transport_image_transport_factory.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698