| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #ifndef CONTENT_BROWSER_GPU_BROWSER_GPU_CHANNEL_HOST_FACTORY_H_ | 5 #ifndef CONTENT_BROWSER_GPU_BROWSER_GPU_CHANNEL_HOST_FACTORY_H_ |
| 6 #define CONTENT_BROWSER_GPU_BROWSER_GPU_CHANNEL_HOST_FACTORY_H_ | 6 #define CONTENT_BROWSER_GPU_BROWSER_GPU_CHANNEL_HOST_FACTORY_H_ |
| 7 | 7 |
| 8 #include <stddef.h> | 8 #include <stddef.h> |
| 9 #include <stdint.h> | 9 #include <stdint.h> |
| 10 | 10 |
| (...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 42 | 42 |
| 43 // Used to skip GpuChannelHost tests when there can be no GPU process. | 43 // Used to skip GpuChannelHost tests when there can be no GPU process. |
| 44 static bool CanUseForTesting(); | 44 static bool CanUseForTesting(); |
| 45 | 45 |
| 46 // Overridden from gpu::GpuChannelEstablishFactory: | 46 // Overridden from gpu::GpuChannelEstablishFactory: |
| 47 // The factory will return a null GpuChannelHost in the callback during | 47 // The factory will return a null GpuChannelHost in the callback during |
| 48 // shutdown. | 48 // shutdown. |
| 49 void EstablishGpuChannel( | 49 void EstablishGpuChannel( |
| 50 const gpu::GpuChannelEstablishedCallback& callback) override; | 50 const gpu::GpuChannelEstablishedCallback& callback) override; |
| 51 scoped_refptr<gpu::GpuChannelHost> EstablishGpuChannelSync() override; | 51 scoped_refptr<gpu::GpuChannelHost> EstablishGpuChannelSync() override; |
| 52 gpu::GpuMemoryBufferManager* GetGpuMemoryBufferManager() override; |
| 52 | 53 |
| 53 private: | 54 private: |
| 54 struct CreateRequest; | 55 struct CreateRequest; |
| 55 class EstablishRequest; | 56 class EstablishRequest; |
| 56 | 57 |
| 57 BrowserGpuChannelHostFactory(); | 58 BrowserGpuChannelHostFactory(); |
| 58 ~BrowserGpuChannelHostFactory() override; | 59 ~BrowserGpuChannelHostFactory() override; |
| 59 | 60 |
| 60 void GpuChannelEstablished(); | 61 void GpuChannelEstablished(); |
| 61 | 62 |
| (...skipping 12 matching lines...) Expand all Loading... |
| 74 std::vector<gpu::GpuChannelEstablishedCallback> established_callbacks_; | 75 std::vector<gpu::GpuChannelEstablishedCallback> established_callbacks_; |
| 75 | 76 |
| 76 static BrowserGpuChannelHostFactory* instance_; | 77 static BrowserGpuChannelHostFactory* instance_; |
| 77 | 78 |
| 78 DISALLOW_COPY_AND_ASSIGN(BrowserGpuChannelHostFactory); | 79 DISALLOW_COPY_AND_ASSIGN(BrowserGpuChannelHostFactory); |
| 79 }; | 80 }; |
| 80 | 81 |
| 81 } // namespace content | 82 } // namespace content |
| 82 | 83 |
| 83 #endif // CONTENT_BROWSER_GPU_BROWSER_GPU_CHANNEL_HOST_FACTORY_H_ | 84 #endif // CONTENT_BROWSER_GPU_BROWSER_GPU_CHANNEL_HOST_FACTORY_H_ |
| OLD | NEW |