| OLD | NEW |
| 1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 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 CHROME_BROWSER_MEDIA_ROUTER_OFFSCREEN_PRESENTATION_MANAGER_FACTORY_H_ | 5 #ifndef CHROME_BROWSER_MEDIA_ROUTER_OFFSCREEN_PRESENTATION_MANAGER_FACTORY_H_ |
| 6 #define CHROME_BROWSER_MEDIA_ROUTER_OFFSCREEN_PRESENTATION_MANAGER_FACTORY_H_ | 6 #define CHROME_BROWSER_MEDIA_ROUTER_OFFSCREEN_PRESENTATION_MANAGER_FACTORY_H_ |
| 7 | 7 |
| 8 #include "base/lazy_instance.h" | 8 #include "base/lazy_instance.h" |
| 9 #include "components/keyed_service/content/browser_context_keyed_service_factory
.h" | 9 #include "components/keyed_service/content/browser_context_keyed_service_factory
.h" |
| 10 | 10 |
| (...skipping 17 matching lines...) Expand all Loading... |
| 28 // browser context. | 28 // browser context. |
| 29 static OffscreenPresentationManager* GetOrCreateForWebContents( | 29 static OffscreenPresentationManager* GetOrCreateForWebContents( |
| 30 content::WebContents* web_contents); | 30 content::WebContents* web_contents); |
| 31 static OffscreenPresentationManager* GetOrCreateForBrowserContext( | 31 static OffscreenPresentationManager* GetOrCreateForBrowserContext( |
| 32 content::BrowserContext* context); | 32 content::BrowserContext* context); |
| 33 | 33 |
| 34 // For test use only. | 34 // For test use only. |
| 35 static OffscreenPresentationManagerFactory* GetInstanceForTest(); | 35 static OffscreenPresentationManagerFactory* GetInstanceForTest(); |
| 36 | 36 |
| 37 private: | 37 private: |
| 38 friend struct base::DefaultLazyInstanceTraits< | 38 friend struct base::LazyInstanceTraitsBase< |
| 39 OffscreenPresentationManagerFactory>; | 39 OffscreenPresentationManagerFactory>; |
| 40 | 40 |
| 41 OffscreenPresentationManagerFactory(); | 41 OffscreenPresentationManagerFactory(); |
| 42 ~OffscreenPresentationManagerFactory() override; | 42 ~OffscreenPresentationManagerFactory() override; |
| 43 | 43 |
| 44 // BrowserContextKeyedServiceFactory interface. | 44 // BrowserContextKeyedServiceFactory interface. |
| 45 content::BrowserContext* GetBrowserContextToUse( | 45 content::BrowserContext* GetBrowserContextToUse( |
| 46 content::BrowserContext* context) const override; | 46 content::BrowserContext* context) const override; |
| 47 KeyedService* BuildServiceInstanceFor( | 47 KeyedService* BuildServiceInstanceFor( |
| 48 content::BrowserContext* context) const override; | 48 content::BrowserContext* context) const override; |
| 49 | 49 |
| 50 DISALLOW_COPY_AND_ASSIGN(OffscreenPresentationManagerFactory); | 50 DISALLOW_COPY_AND_ASSIGN(OffscreenPresentationManagerFactory); |
| 51 }; | 51 }; |
| 52 | 52 |
| 53 } // namespace media_router | 53 } // namespace media_router |
| 54 | 54 |
| 55 #endif // CHROME_BROWSER_MEDIA_ROUTER_OFFSCREEN_PRESENTATION_MANAGER_FACTORY_H_ | 55 #endif // CHROME_BROWSER_MEDIA_ROUTER_OFFSCREEN_PRESENTATION_MANAGER_FACTORY_H_ |
| OLD | NEW |