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> |
(...skipping 483 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
494 virtual MediaObserver* GetMediaObserver(); | 494 virtual MediaObserver* GetMediaObserver(); |
495 | 495 |
496 // Returns the platform notification service, capable of displaying Web | 496 // Returns the platform notification service, capable of displaying Web |
497 // Notifications to the user. The embedder can return a nullptr if they don't | 497 // Notifications to the user. The embedder can return a nullptr if they don't |
498 // support this functionality. May be called from any thread. | 498 // support this functionality. May be called from any thread. |
499 virtual PlatformNotificationService* GetPlatformNotificationService(); | 499 virtual PlatformNotificationService* GetPlatformNotificationService(); |
500 | 500 |
501 // Returns true if the given page is allowed to open a window of the given | 501 // Returns true if the given page is allowed to open a window of the given |
502 // type. If true is returned, |no_javascript_access| will indicate whether | 502 // type. If true is returned, |no_javascript_access| will indicate whether |
503 // the window that is created should be scriptable/in the same process. | 503 // the window that is created should be scriptable/in the same process. |
504 // This is called on the IO thread. | 504 // This is called on the UI thread. |
505 virtual bool CanCreateWindow( | 505 virtual bool CanCreateWindow( |
506 int opener_render_process_id, | 506 RenderFrameHost* opener, |
507 int opener_render_frame_id, | |
508 const GURL& opener_url, | 507 const GURL& opener_url, |
509 const GURL& opener_top_level_frame_url, | 508 const GURL& opener_top_level_frame_url, |
510 const GURL& source_origin, | 509 const GURL& source_origin, |
511 content::mojom::WindowContainerType container_type, | 510 content::mojom::WindowContainerType container_type, |
512 const GURL& target_url, | 511 const GURL& target_url, |
513 const Referrer& referrer, | 512 const Referrer& referrer, |
514 const std::string& frame_name, | 513 const std::string& frame_name, |
515 WindowOpenDisposition disposition, | 514 WindowOpenDisposition disposition, |
516 const blink::mojom::WindowFeatures& features, | 515 const blink::mojom::WindowFeatures& features, |
517 bool user_gesture, | 516 bool user_gesture, |
518 bool opener_suppressed, | 517 bool opener_suppressed, |
519 ResourceContext* context, | |
520 bool* no_javascript_access); | 518 bool* no_javascript_access); |
521 | 519 |
522 // Notifies the embedder that the ResourceDispatcherHost has been created. | 520 // Notifies the embedder that the ResourceDispatcherHost has been created. |
523 // This is when it can optionally add a delegate. | 521 // This is when it can optionally add a delegate. |
524 virtual void ResourceDispatcherHostCreated() {} | 522 virtual void ResourceDispatcherHostCreated() {} |
525 | 523 |
526 // Allows the embedder to return a delegate for the SpeechRecognitionManager. | 524 // 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. | 525 // The delegate will be owned by the manager. It's valid to return nullptr. |
528 virtual SpeechRecognitionManagerDelegate* | 526 virtual SpeechRecognitionManagerDelegate* |
529 CreateSpeechRecognitionManagerDelegate(); | 527 CreateSpeechRecognitionManagerDelegate(); |
(...skipping 297 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
827 virtual bool ShouldRedirectDOMStorageTaskRunner(); | 825 virtual bool ShouldRedirectDOMStorageTaskRunner(); |
828 | 826 |
829 // If this returns true, all BrowserThreads (but UI/IO) that support it on | 827 // If this returns true, all BrowserThreads (but UI/IO) that support it on |
830 // this platform will experimentally be redirected to TaskScheduler. | 828 // this platform will experimentally be redirected to TaskScheduler. |
831 virtual bool RedirectNonUINonIOBrowserThreadsToTaskScheduler(); | 829 virtual bool RedirectNonUINonIOBrowserThreadsToTaskScheduler(); |
832 }; | 830 }; |
833 | 831 |
834 } // namespace content | 832 } // namespace content |
835 | 833 |
836 #endif // CONTENT_PUBLIC_BROWSER_CONTENT_BROWSER_CLIENT_H_ | 834 #endif // CONTENT_PUBLIC_BROWSER_CONTENT_BROWSER_CLIENT_H_ |
OLD | NEW |