Chromium Code Reviews| Index: content/common/gpu/gpu_channel_manager.h |
| diff --git a/content/common/gpu/gpu_channel_manager.h b/content/common/gpu/gpu_channel_manager.h |
| index 875656f47b697e82be97ce436e0e9609a6c3198b..039c469f331233be7c8001b6ac85e00706201474 100644 |
| --- a/content/common/gpu/gpu_channel_manager.h |
| +++ b/content/common/gpu/gpu_channel_manager.h |
| @@ -107,6 +107,7 @@ class CONTENT_EXPORT GpuChannelManager { |
| void RemoveChannel(int client_id); |
| void LoseAllContexts(); |
| + void MaybeExitOnContextLost(); |
| #if defined(OS_MACOSX) |
| void AddBufferPresentedCallback(int32_t routing_id, |
| @@ -146,6 +147,10 @@ class CONTENT_EXPORT GpuChannelManager { |
| void DidAccessGpu(); |
| #endif |
| + bool IsExitingForContextLost() { |
|
esprehn
2016/04/08 02:17:16
why isn't this override or hacker_case?
|
| + return exiting_for_lost_context_; |
| + } |
| + |
| protected: |
| virtual scoped_ptr<GpuChannel> CreateGpuChannel( |
| int client_id, |
| @@ -215,6 +220,9 @@ class CONTENT_EXPORT GpuChannelManager { |
| base::TimeTicks begin_wake_up_time_; |
| #endif |
| + // Set during intentional GPU process shutdown. |
| + bool exiting_for_lost_context_; |
| + |
| // Member variables should appear before the WeakPtrFactory, to ensure |
| // that any WeakPtrs to Controller are invalidated before its members |
| // variable's destructors are executed, rendering them invalid. |