Chromium Code Reviews| Index: cc/output/output_surface.cc |
| diff --git a/cc/output/output_surface.cc b/cc/output/output_surface.cc |
| index 0f68b5b048d749842289dd6aac531dad516bbeda..69312b009aaf3813082b1651170383a6399ab14b 100644 |
| --- a/cc/output/output_surface.cc |
| +++ b/cc/output/output_surface.cc |
| @@ -163,7 +163,7 @@ void OutputSurface::ReleaseGL() { |
| DCHECK(client_); |
| DCHECK(context_provider_); |
| client_->ReleaseGL(); |
| - ResetContext3d(); |
| + DCHECK(!context_provider_); |
|
boliu
2014/05/20 23:31:38
This DCHECK and two lines above is verifying that
danakj
2014/05/21 15:34:17
Ah, yeh okay thanks.
|
| } |
| void OutputSurface::SetUpContext3d() { |
| @@ -181,6 +181,12 @@ void OutputSurface::SetUpContext3d() { |
| base::Unretained(this))); |
| } |
| +void OutputSurface::ReleaseContextProvider() { |
| + DCHECK(client_); |
| + DCHECK(context_provider_); |
| + ResetContext3d(); |
| +} |
| + |
| void OutputSurface::ResetContext3d() { |
| if (context_provider_.get()) { |
| while (!pending_gpu_latency_query_ids_.empty()) { |