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

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

Issue 2784433002: Ensures that audio tasks cannot run after AudioManager is deleted. (Closed)
Patch Set: rebase Created 3 years, 7 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.h" 16 #include "base/callback.h"
17 #include "base/task_scheduler/task_scheduler.h" 17 #include "base/task_scheduler/task_scheduler.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/associated_interface_registry.h" 22 #include "content/public/common/associated_interface_registry.h"
23 #include "content/public/common/content_client.h" 23 #include "content/public/common/content_client.h"
24 #include "content/public/common/media_stream_request.h" 24 #include "content/public/common/media_stream_request.h"
25 #include "content/public/common/resource_type.h" 25 #include "content/public/common/resource_type.h"
26 #include "content/public/common/service_info.h" 26 #include "content/public/common/service_info.h"
27 #include "content/public/common/socket_permission_request.h" 27 #include "content/public/common/socket_permission_request.h"
28 #include "content/public/common/window_container_type.mojom.h" 28 #include "content/public/common/window_container_type.mojom.h"
29 #include "media/audio/audio_manager.h"
30 #include "media/media_features.h" 29 #include "media/media_features.h"
31 #include "media/mojo/interfaces/remoting.mojom.h" 30 #include "media/mojo/interfaces/remoting.mojom.h"
32 #include "net/base/mime_util.h" 31 #include "net/base/mime_util.h"
33 #include "net/cookies/canonical_cookie.h" 32 #include "net/cookies/canonical_cookie.h"
34 #include "storage/browser/fileapi/file_system_context.h" 33 #include "storage/browser/fileapi/file_system_context.h"
35 #include "storage/browser/quota/quota_manager.h" 34 #include "storage/browser/quota/quota_manager.h"
36 #include "third_party/WebKit/public/platform/WebPageVisibilityState.h" 35 #include "third_party/WebKit/public/platform/WebPageVisibilityState.h"
37 #include "third_party/WebKit/public/web/window_features.mojom.h" 36 #include "third_party/WebKit/public/web/window_features.mojom.h"
38 #include "ui/base/page_transition_types.h" 37 #include "ui/base/page_transition_types.h"
39 #include "ui/base/window_open_disposition.h" 38 #include "ui/base/window_open_disposition.h"
(...skipping 15 matching lines...) Expand all
55 54
56 namespace gfx { 55 namespace gfx {
57 class ImageSkia; 56 class ImageSkia;
58 } 57 }
59 58
60 namespace gpu { 59 namespace gpu {
61 class GpuChannelEstablishFactory; 60 class GpuChannelEstablishFactory;
62 } 61 }
63 62
64 namespace media { 63 namespace media {
64 class AudioLogFactory;
65 class AudioManager;
65 class CdmFactory; 66 class CdmFactory;
66 } 67 }
67 68
68 namespace service_manager { 69 namespace service_manager {
69 class BinderRegistry; 70 class BinderRegistry;
70 class Service; 71 class Service;
71 struct BindSourceInfo; 72 struct BindSourceInfo;
72 } 73 }
73 74
74 namespace net { 75 namespace net {
(...skipping 694 matching lines...) Expand 10 before | Expand all | Expand 10 after
769 770
770 // PlzNavigate 771 // PlzNavigate
771 // Called at the start of the navigation to get opaque data the embedder 772 // Called at the start of the navigation to get opaque data the embedder
772 // wants to see passed to the corresponding URLRequest on the IO thread. 773 // wants to see passed to the corresponding URLRequest on the IO thread.
773 virtual std::unique_ptr<NavigationUIData> GetNavigationUIData( 774 virtual std::unique_ptr<NavigationUIData> GetNavigationUIData(
774 NavigationHandle* navigation_handle); 775 NavigationHandle* navigation_handle);
775 776
776 // Allows the embedder to provide its own AudioManager implementation. 777 // Allows the embedder to provide its own AudioManager implementation.
777 // If this function returns nullptr, a default platform implementation 778 // If this function returns nullptr, a default platform implementation
778 // will be used. 779 // will be used.
779 virtual media::ScopedAudioManagerPtr CreateAudioManager( 780 virtual std::unique_ptr<media::AudioManager> CreateAudioManager(
780 media::AudioLogFactory* audio_log_factory); 781 media::AudioLogFactory* audio_log_factory);
781 // Creates and returns a factory used for creating CDM instances for playing 782 // Creates and returns a factory used for creating CDM instances for playing
782 // protected content. 783 // protected content.
783 virtual std::unique_ptr<media::CdmFactory> CreateCdmFactory(); 784 virtual std::unique_ptr<media::CdmFactory> CreateCdmFactory();
784 785
785 // Populates |mappings| with all files that need to be mapped before launching 786 // Populates |mappings| with all files that need to be mapped before launching
786 // a child process. 787 // a child process.
787 #if defined(OS_POSIX) && !defined(OS_MACOSX) 788 #if defined(OS_POSIX) && !defined(OS_MACOSX)
788 virtual void GetAdditionalMappedFilesForChildProcess( 789 virtual void GetAdditionalMappedFilesForChildProcess(
789 const base::CommandLine& command_line, 790 const base::CommandLine& command_line,
(...skipping 42 matching lines...) Expand 10 before | Expand all | Expand 10 after
832 virtual bool ShouldRedirectDOMStorageTaskRunner(); 833 virtual bool ShouldRedirectDOMStorageTaskRunner();
833 834
834 // If this returns true, all BrowserThreads (but UI/IO) that support it on 835 // If this returns true, all BrowserThreads (but UI/IO) that support it on
835 // this platform will experimentally be redirected to TaskScheduler. 836 // this platform will experimentally be redirected to TaskScheduler.
836 virtual bool RedirectNonUINonIOBrowserThreadsToTaskScheduler(); 837 virtual bool RedirectNonUINonIOBrowserThreadsToTaskScheduler();
837 }; 838 };
838 839
839 } // namespace content 840 } // namespace content
840 841
841 #endif // CONTENT_PUBLIC_BROWSER_CONTENT_BROWSER_CLIENT_H_ 842 #endif // CONTENT_PUBLIC_BROWSER_CONTENT_BROWSER_CLIENT_H_
OLDNEW
« no previous file with comments | « content/browser/speech/speech_recognizer_impl_unittest.cc ('k') | content/public/browser/content_browser_client.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698