Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(524)

Side by Side Diff: content/public/browser/content_browser_client.h

Issue 2098553002: Geolocation: extract ContentBrowserClient methods specific to Geolocation into a class (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Michael's comments (plenty of renames) Created 4 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
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 493 matching lines...) Expand 10 before | Expand all | Expand 10 after
524 virtual void ResourceDispatcherHostCreated() {} 525 virtual void ResourceDispatcherHostCreated() {}
525 526
526 // Allows the embedder to return a delegate for the SpeechRecognitionManager. 527 // Allows the embedder to return a delegate for the SpeechRecognitionManager.
527 // The delegate will be owned by the manager. It's valid to return nullptr. 528 // The delegate will be owned by the manager. It's valid to return nullptr.
528 virtual SpeechRecognitionManagerDelegate* 529 virtual SpeechRecognitionManagerDelegate*
529 CreateSpeechRecognitionManagerDelegate(); 530 CreateSpeechRecognitionManagerDelegate();
530 531
531 // Getters for common objects. 532 // Getters for common objects.
532 virtual net::NetLog* GetNetLog(); 533 virtual net::NetLog* GetNetLog();
533 534
534 // Creates a new AccessTokenStore for gelocation. 535 // Allows the Embedder to provide a Delegate for Geolocation to override some
535 virtual AccessTokenStore* CreateAccessTokenStore(); 536 // functionality of the API (e.g. AccessTokenStore, LocationProvider).
537 virtual GeolocationProvider::Delegate* CreateGeolocationDelegate();
536 538
537 // Returns true if fast shutdown is possible. 539 // Returns true if fast shutdown is possible.
538 virtual bool IsFastShutdownPossible(); 540 virtual bool IsFastShutdownPossible();
539 541
540 // Called by WebContents to override the WebKit preferences that are used by 542 // Called by WebContents to override the WebKit preferences that are used by
541 // the renderer. The content layer will add its own settings, and then it's up 543 // the renderer. The content layer will add its own settings, and then it's up
542 // to the embedder to update it if it wants. 544 // to the embedder to update it if it wants.
543 virtual void OverrideWebkitPrefs(RenderViewHost* render_view_host, 545 virtual void OverrideWebkitPrefs(RenderViewHost* render_view_host,
544 WebPreferences* prefs) {} 546 WebPreferences* prefs) {}
545 547
(...skipping 69 matching lines...) Expand 10 before | Expand all | Expand 10 after
615 617
616 // Returns additional file system backends for FileSystem API. 618 // Returns additional file system backends for FileSystem API.
617 // |browser_context| is needed in the additional FileSystemBackends. 619 // |browser_context| is needed in the additional FileSystemBackends.
618 // It has mount points to create objects returned by additional 620 // It has mount points to create objects returned by additional
619 // FileSystemBackends, and SpecialStoragePolicy for permission granting. 621 // FileSystemBackends, and SpecialStoragePolicy for permission granting.
620 virtual void GetAdditionalFileSystemBackends( 622 virtual void GetAdditionalFileSystemBackends(
621 BrowserContext* browser_context, 623 BrowserContext* browser_context,
622 const base::FilePath& storage_partition_path, 624 const base::FilePath& storage_partition_path,
623 ScopedVector<storage::FileSystemBackend>* additional_backends) {} 625 ScopedVector<storage::FileSystemBackend>* additional_backends) {}
624 626
625 // Allows an embedder to return its own LocationProvider implementation.
626 // Return nullptr to use the default one for the platform to be created.
627 // Caller takes ownership of the returned LocationProvider.
628 // FYI: Used by an external project; please don't remove.
629 // Contact Viatcheslav Ostapenko at sl.ostapenko@samsung.com for more
630 // information.
631 virtual LocationProvider* OverrideSystemLocationProvider();
632
633 // Returns true if the location API should use network-based
634 // location approximation in addition to the system provider, if any.
635 virtual bool UseNetworkLocationProviders();
636
637 // Creates a new DevToolsManagerDelegate. The caller owns the returned value. 627 // Creates a new DevToolsManagerDelegate. The caller owns the returned value.
638 // It's valid to return nullptr. 628 // It's valid to return nullptr.
639 virtual DevToolsManagerDelegate* GetDevToolsManagerDelegate(); 629 virtual DevToolsManagerDelegate* GetDevToolsManagerDelegate();
640 630
641 // Creates a new TracingDelegate. The caller owns the returned value. 631 // Creates a new TracingDelegate. The caller owns the returned value.
642 // It's valid to return nullptr. 632 // It's valid to return nullptr.
643 virtual TracingDelegate* GetTracingDelegate(); 633 virtual TracingDelegate* GetTracingDelegate();
644 634
645 // Returns true if plugin referred to by the url can use 635 // Returns true if plugin referred to by the url can use
646 // pp::FileIO::RequestOSFileHandle. 636 // pp::FileIO::RequestOSFileHandle.
(...skipping 143 matching lines...) Expand 10 before | Expand all | Expand 10 after
790 // Allows an embedder to provide its own ExternalVideoSurfaceContainer 780 // Allows an embedder to provide its own ExternalVideoSurfaceContainer
791 // implementation. Return nullptr to disable external surface video. 781 // implementation. Return nullptr to disable external surface video.
792 virtual ExternalVideoSurfaceContainer* 782 virtual ExternalVideoSurfaceContainer*
793 OverrideCreateExternalVideoSurfaceContainer(WebContents* web_contents); 783 OverrideCreateExternalVideoSurfaceContainer(WebContents* web_contents);
794 #endif 784 #endif
795 }; 785 };
796 786
797 } // namespace content 787 } // namespace content
798 788
799 #endif // CONTENT_PUBLIC_BROWSER_CONTENT_BROWSER_CLIENT_H_ 789 #endif // CONTENT_PUBLIC_BROWSER_CONTENT_BROWSER_CLIENT_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698