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

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

Issue 2613803003: Simplifying ContentBrowserClient::GetAdditionalMappedFiles...() (Closed)
Patch Set: Created 3 years, 11 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>
(...skipping 747 matching lines...) Expand 10 before | Expand all | Expand 10 after
758 // If this function returns nullptr, a default platform implementation 758 // If this function returns nullptr, a default platform implementation
759 // will be used. 759 // will be used.
760 virtual media::ScopedAudioManagerPtr CreateAudioManager( 760 virtual media::ScopedAudioManagerPtr CreateAudioManager(
761 media::AudioLogFactory* audio_log_factory); 761 media::AudioLogFactory* audio_log_factory);
762 // Creates and returns a factory used for creating CDM instances for playing 762 // Creates and returns a factory used for creating CDM instances for playing
763 // protected content. 763 // protected content.
764 virtual std::unique_ptr<media::CdmFactory> CreateCdmFactory(); 764 virtual std::unique_ptr<media::CdmFactory> CreateCdmFactory();
765 765
766 // Populates |mappings| with all files that need to be mapped before launching 766 // Populates |mappings| with all files that need to be mapped before launching
767 // a child process. 767 // a child process.
768 #if defined(OS_ANDROID) 768 #if defined(OS_POSIX) && !defined(OS_MACOSX)
769 virtual void GetAdditionalMappedFilesForChildProcess(
770 const base::CommandLine& command_line,
771 int child_process_id,
772 content::FileDescriptorInfo* mappings,
773 std::map<int, base::MemoryMappedFile::Region>* regions) {}
774 #elif defined(OS_POSIX) && !defined(OS_MACOSX)
775 virtual void GetAdditionalMappedFilesForChildProcess( 769 virtual void GetAdditionalMappedFilesForChildProcess(
776 const base::CommandLine& command_line, 770 const base::CommandLine& command_line,
777 int child_process_id, 771 int child_process_id,
778 content::FileDescriptorInfo* mappings) {} 772 content::FileDescriptorInfo* mappings) {}
779 #endif // defined(OS_ANDROID) 773 #endif // defined(OS_POSIX) && !defined(OS_MACOSX)
780 774
781 #if defined(OS_WIN) 775 #if defined(OS_WIN)
782 // This is called on the PROCESS_LAUNCHER thread before the renderer process 776 // This is called on the PROCESS_LAUNCHER thread before the renderer process
783 // is launched. It gives the embedder a chance to add loosen the sandbox 777 // is launched. It gives the embedder a chance to add loosen the sandbox
784 // policy. 778 // policy.
785 virtual bool PreSpawnRenderer(sandbox::TargetPolicy* policy); 779 virtual bool PreSpawnRenderer(sandbox::TargetPolicy* policy);
786 780
787 // Returns the AppContainer SID for the specified sandboxed process type, or 781 // Returns the AppContainer SID for the specified sandboxed process type, or
788 // empty string if this sandboxed process type does not support living inside 782 // empty string if this sandboxed process type does not support living inside
789 // an AppContainer. 783 // an AppContainer.
(...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after
821 virtual bool ShouldRedirectDOMStorageTaskRunner(); 815 virtual bool ShouldRedirectDOMStorageTaskRunner();
822 816
823 // If this returns true, all BrowserThreads (but UI/IO) that support it on 817 // If this returns true, all BrowserThreads (but UI/IO) that support it on
824 // this platform will experimentally be redirected to TaskScheduler. 818 // this platform will experimentally be redirected to TaskScheduler.
825 virtual bool RedirectNonUINonIOBrowserThreadsToTaskScheduler(); 819 virtual bool RedirectNonUINonIOBrowserThreadsToTaskScheduler();
826 }; 820 };
827 821
828 } // namespace content 822 } // namespace content
829 823
830 #endif // CONTENT_PUBLIC_BROWSER_CONTENT_BROWSER_CLIENT_H_ 824 #endif // CONTENT_PUBLIC_BROWSER_CONTENT_BROWSER_CLIENT_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698