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

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

Issue 1908423006: Allow content embedders to create AudioManager. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: ScopedAudioManagerPtr instead of raw pointer Created 4 years, 8 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
« no previous file with comments | « content/public/browser/DEPS ('k') | content/public/browser/content_browser_client.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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/navigation_throttle.h" 21 #include "content/public/browser/navigation_throttle.h"
22 #include "content/public/common/content_client.h" 22 #include "content/public/common/content_client.h"
23 #include "content/public/common/media_stream_request.h" 23 #include "content/public/common/media_stream_request.h"
24 #include "content/public/common/resource_type.h" 24 #include "content/public/common/resource_type.h"
25 #include "content/public/common/socket_permission_request.h" 25 #include "content/public/common/socket_permission_request.h"
26 #include "content/public/common/window_container_type.h" 26 #include "content/public/common/window_container_type.h"
27 #include "media/audio/audio_manager.h"
27 #include "net/base/mime_util.h" 28 #include "net/base/mime_util.h"
28 #include "net/cookies/canonical_cookie.h" 29 #include "net/cookies/canonical_cookie.h"
29 #include "storage/browser/fileapi/file_system_context.h" 30 #include "storage/browser/fileapi/file_system_context.h"
30 #include "third_party/WebKit/public/platform/WebPageVisibilityState.h" 31 #include "third_party/WebKit/public/platform/WebPageVisibilityState.h"
31 #include "ui/base/window_open_disposition.h" 32 #include "ui/base/window_open_disposition.h"
32 33
33 #if defined(OS_POSIX) && !defined(OS_MACOSX) 34 #if defined(OS_POSIX) && !defined(OS_MACOSX)
34 #include "base/posix/global_descriptors.h" 35 #include "base/posix/global_descriptors.h"
35 #endif 36 #endif
36 37
(...skipping 661 matching lines...) Expand 10 before | Expand all | Expand 10 after
698 virtual void RecordURLMetric(const std::string& metric, const GURL& url) {} 699 virtual void RecordURLMetric(const std::string& metric, const GURL& url) {}
699 700
700 // Allows the embedder to register one or more NavigationThrottles for the 701 // Allows the embedder to register one or more NavigationThrottles for the
701 // navigation indicated by |navigation_handle|. A NavigationThrottle is used 702 // navigation indicated by |navigation_handle|. A NavigationThrottle is used
702 // to control the flow of a navigation on the UI thread. The embedder is 703 // to control the flow of a navigation on the UI thread. The embedder is
703 // guaranteed that the throttles will be executed in the order they were 704 // guaranteed that the throttles will be executed in the order they were
704 // provided. 705 // provided.
705 virtual ScopedVector<NavigationThrottle> CreateThrottlesForNavigation( 706 virtual ScopedVector<NavigationThrottle> CreateThrottlesForNavigation(
706 NavigationHandle* navigation_handle); 707 NavigationHandle* navigation_handle);
707 708
709 // Allows the embedder to provide its own AudioManager implementation.
710 // If this function returns nullptr, a default platform implementation
711 // will be used.
712 virtual media::ScopedAudioManagerPtr CreateAudioManager(
713 media::AudioLogFactory* audio_log_factory);
708 // Creates and returns a factory used for creating CDM instances for playing 714 // Creates and returns a factory used for creating CDM instances for playing
709 // protected content. 715 // protected content.
710 virtual std::unique_ptr<media::CdmFactory> CreateCdmFactory(); 716 virtual std::unique_ptr<media::CdmFactory> CreateCdmFactory();
711 717
712 // Populates |mappings| with all files that need to be mapped before launching 718 // Populates |mappings| with all files that need to be mapped before launching
713 // a child process. 719 // a child process.
714 #if defined(OS_ANDROID) 720 #if defined(OS_ANDROID)
715 virtual void GetAdditionalMappedFilesForChildProcess( 721 virtual void GetAdditionalMappedFilesForChildProcess(
716 const base::CommandLine& command_line, 722 const base::CommandLine& command_line,
717 int child_process_id, 723 int child_process_id,
(...skipping 35 matching lines...) Expand 10 before | Expand all | Expand 10 after
753 // Allows an embedder to provide its own ExternalVideoSurfaceContainer 759 // Allows an embedder to provide its own ExternalVideoSurfaceContainer
754 // implementation. Return nullptr to disable external surface video. 760 // implementation. Return nullptr to disable external surface video.
755 virtual ExternalVideoSurfaceContainer* 761 virtual ExternalVideoSurfaceContainer*
756 OverrideCreateExternalVideoSurfaceContainer(WebContents* web_contents); 762 OverrideCreateExternalVideoSurfaceContainer(WebContents* web_contents);
757 #endif 763 #endif
758 }; 764 };
759 765
760 } // namespace content 766 } // namespace content
761 767
762 #endif // CONTENT_PUBLIC_BROWSER_CONTENT_BROWSER_CLIENT_H_ 768 #endif // CONTENT_PUBLIC_BROWSER_CONTENT_BROWSER_CLIENT_H_
OLDNEW
« no previous file with comments | « content/public/browser/DEPS ('k') | content/public/browser/content_browser_client.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698