| 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_PUBLIC_BROWSER_CONTENT_BROWSER_CLIENT_H_ | 5 #ifndef CONTENT_PUBLIC_BROWSER_CONTENT_BROWSER_CLIENT_H_ |
| 6 #define CONTENT_PUBLIC_BROWSER_CONTENT_BROWSER_CLIENT_H_ | 6 #define CONTENT_PUBLIC_BROWSER_CONTENT_BROWSER_CLIENT_H_ |
| 7 | 7 |
| 8 #include <stddef.h> | 8 #include <stddef.h> |
| 9 | 9 |
| 10 #include <map> | 10 #include <map> |
| 11 #include <memory> | 11 #include <memory> |
| 12 #include <string> | 12 #include <string> |
| 13 #include <utility> | 13 #include <utility> |
| 14 #include <vector> | 14 #include <vector> |
| 15 | 15 |
| 16 #include "base/callback_forward.h" | 16 #include "base/callback_forward.h" |
| 17 #include "base/memory/scoped_vector.h" | 17 #include "base/memory/scoped_vector.h" |
| 18 #include "base/values.h" | 18 #include "base/values.h" |
| 19 #include "build/build_config.h" | 19 #include "build/build_config.h" |
| 20 #include "content/public/browser/certificate_request_result_type.h" | 20 #include "content/public/browser/certificate_request_result_type.h" |
| 21 #include "content/public/browser/geolocation_provider.h" |
| 21 #include "content/public/browser/navigation_throttle.h" | 22 #include "content/public/browser/navigation_throttle.h" |
| 22 #include "content/public/common/content_client.h" | 23 #include "content/public/common/content_client.h" |
| 23 #include "content/public/common/media_stream_request.h" | 24 #include "content/public/common/media_stream_request.h" |
| 24 #include "content/public/common/mojo_application_info.h" | 25 #include "content/public/common/mojo_application_info.h" |
| 25 #include "content/public/common/resource_type.h" | 26 #include "content/public/common/resource_type.h" |
| 26 #include "content/public/common/socket_permission_request.h" | 27 #include "content/public/common/socket_permission_request.h" |
| 27 #include "content/public/common/window_container_type.h" | 28 #include "content/public/common/window_container_type.h" |
| 28 #include "media/audio/audio_manager.h" | 29 #include "media/audio/audio_manager.h" |
| 29 #include "net/base/mime_util.h" | 30 #include "net/base/mime_util.h" |
| 30 #include "net/cookies/canonical_cookie.h" | 31 #include "net/cookies/canonical_cookie.h" |
| (...skipping 492 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 523 virtual void ResourceDispatcherHostCreated() {} | 524 virtual void ResourceDispatcherHostCreated() {} |
| 524 | 525 |
| 525 // Allows the embedder to return a delegate for the SpeechRecognitionManager. | 526 // Allows the embedder to return a delegate for the SpeechRecognitionManager. |
| 526 // The delegate will be owned by the manager. It's valid to return nullptr. | 527 // The delegate will be owned by the manager. It's valid to return nullptr. |
| 527 virtual SpeechRecognitionManagerDelegate* | 528 virtual SpeechRecognitionManagerDelegate* |
| 528 CreateSpeechRecognitionManagerDelegate(); | 529 CreateSpeechRecognitionManagerDelegate(); |
| 529 | 530 |
| 530 // Getters for common objects. | 531 // Getters for common objects. |
| 531 virtual net::NetLog* GetNetLog(); | 532 virtual net::NetLog* GetNetLog(); |
| 532 | 533 |
| 533 // Creates a new AccessTokenStore for gelocation. | 534 // Allows the embedder to provide a Delegate for Geolocation to override some |
| 534 virtual AccessTokenStore* CreateAccessTokenStore(); | 535 // functionality of the API (e.g. AccessTokenStore, LocationProvider). |
| 536 virtual GeolocationProvider::Delegate* CreateGeolocationDelegate(); |
| 535 | 537 |
| 536 // Returns true if fast shutdown is possible. | 538 // Returns true if fast shutdown is possible. |
| 537 virtual bool IsFastShutdownPossible(); | 539 virtual bool IsFastShutdownPossible(); |
| 538 | 540 |
| 539 // Called by WebContents to override the WebKit preferences that are used by | 541 // Called by WebContents to override the WebKit preferences that are used by |
| 540 // the renderer. The content layer will add its own settings, and then it's up | 542 // the renderer. The content layer will add its own settings, and then it's up |
| 541 // to the embedder to update it if it wants. | 543 // to the embedder to update it if it wants. |
| 542 virtual void OverrideWebkitPrefs(RenderViewHost* render_view_host, | 544 virtual void OverrideWebkitPrefs(RenderViewHost* render_view_host, |
| 543 WebPreferences* prefs) {} | 545 WebPreferences* prefs) {} |
| 544 | 546 |
| (...skipping 69 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 614 | 616 |
| 615 // Returns additional file system backends for FileSystem API. | 617 // Returns additional file system backends for FileSystem API. |
| 616 // |browser_context| is needed in the additional FileSystemBackends. | 618 // |browser_context| is needed in the additional FileSystemBackends. |
| 617 // It has mount points to create objects returned by additional | 619 // It has mount points to create objects returned by additional |
| 618 // FileSystemBackends, and SpecialStoragePolicy for permission granting. | 620 // FileSystemBackends, and SpecialStoragePolicy for permission granting. |
| 619 virtual void GetAdditionalFileSystemBackends( | 621 virtual void GetAdditionalFileSystemBackends( |
| 620 BrowserContext* browser_context, | 622 BrowserContext* browser_context, |
| 621 const base::FilePath& storage_partition_path, | 623 const base::FilePath& storage_partition_path, |
| 622 ScopedVector<storage::FileSystemBackend>* additional_backends) {} | 624 ScopedVector<storage::FileSystemBackend>* additional_backends) {} |
| 623 | 625 |
| 624 // Allows an embedder to return its own LocationProvider implementation. | |
| 625 // Return nullptr to use the default one for the platform to be created. | |
| 626 // Caller takes ownership of the returned LocationProvider. | |
| 627 // FYI: Used by an external project; please don't remove. | |
| 628 // Contact Viatcheslav Ostapenko at sl.ostapenko@samsung.com for more | |
| 629 // information. | |
| 630 virtual LocationProvider* OverrideSystemLocationProvider(); | |
| 631 | |
| 632 // Returns true if the location API should use network-based | |
| 633 // location approximation in addition to the system provider, if any. | |
| 634 virtual bool UseNetworkLocationProviders(); | |
| 635 | |
| 636 // Creates a new DevToolsManagerDelegate. The caller owns the returned value. | 626 // Creates a new DevToolsManagerDelegate. The caller owns the returned value. |
| 637 // It's valid to return nullptr. | 627 // It's valid to return nullptr. |
| 638 virtual DevToolsManagerDelegate* GetDevToolsManagerDelegate(); | 628 virtual DevToolsManagerDelegate* GetDevToolsManagerDelegate(); |
| 639 | 629 |
| 640 // Creates a new TracingDelegate. The caller owns the returned value. | 630 // Creates a new TracingDelegate. The caller owns the returned value. |
| 641 // It's valid to return nullptr. | 631 // It's valid to return nullptr. |
| 642 virtual TracingDelegate* GetTracingDelegate(); | 632 virtual TracingDelegate* GetTracingDelegate(); |
| 643 | 633 |
| 644 // Returns true if plugin referred to by the url can use | 634 // Returns true if plugin referred to by the url can use |
| 645 // pp::FileIO::RequestOSFileHandle. | 635 // pp::FileIO::RequestOSFileHandle. |
| (...skipping 143 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 789 // Allows an embedder to provide its own ExternalVideoSurfaceContainer | 779 // Allows an embedder to provide its own ExternalVideoSurfaceContainer |
| 790 // implementation. Return nullptr to disable external surface video. | 780 // implementation. Return nullptr to disable external surface video. |
| 791 virtual ExternalVideoSurfaceContainer* | 781 virtual ExternalVideoSurfaceContainer* |
| 792 OverrideCreateExternalVideoSurfaceContainer(WebContents* web_contents); | 782 OverrideCreateExternalVideoSurfaceContainer(WebContents* web_contents); |
| 793 #endif | 783 #endif |
| 794 }; | 784 }; |
| 795 | 785 |
| 796 } // namespace content | 786 } // namespace content |
| 797 | 787 |
| 798 #endif // CONTENT_PUBLIC_BROWSER_CONTENT_BROWSER_CLIENT_H_ | 788 #endif // CONTENT_PUBLIC_BROWSER_CONTENT_BROWSER_CLIENT_H_ |
| OLD | NEW |