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

Side by Side Diff: content/browser/frame_host/render_frame_host_manager.h

Issue 743773003: OOPIF: Data URLs are now rendered in the renderer that initiated the navigation. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: fixing android compile Created 6 years 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 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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_BROWSER_FRAME_HOST_RENDER_FRAME_HOST_MANAGER_H_ 5 #ifndef CONTENT_BROWSER_FRAME_HOST_RENDER_FRAME_HOST_MANAGER_H_
6 #define CONTENT_BROWSER_FRAME_HOST_RENDER_FRAME_HOST_MANAGER_H_ 6 #define CONTENT_BROWSER_FRAME_HOST_RENDER_FRAME_HOST_MANAGER_H_
7 7
8 #include <list> 8 #include <list>
9 9
10 #include "base/basictypes.h" 10 #include "base/basictypes.h"
(...skipping 402 matching lines...) Expand 10 before | Expand all | Expand 10 after
413 // to |bindings|. 413 // to |bindings|.
414 scoped_ptr<WebUIImpl> CreateWebUI(const GURL& url, int bindings); 414 scoped_ptr<WebUIImpl> CreateWebUI(const GURL& url, int bindings);
415 415
416 // Returns true if it is safe to reuse the current WebUI when navigating from 416 // Returns true if it is safe to reuse the current WebUI when navigating from
417 // |current_entry| to |new_url|. 417 // |current_entry| to |new_url|.
418 bool ShouldReuseWebUI( 418 bool ShouldReuseWebUI(
419 const NavigationEntry* current_entry, 419 const NavigationEntry* current_entry,
420 const GURL& new_url) const; 420 const GURL& new_url) const;
421 421
422 // Returns the SiteInstance to use for the navigation. 422 // Returns the SiteInstance to use for the navigation.
423 SiteInstance* GetSiteInstanceForNavigation( 423 SiteInstance* GetSiteInstanceForNavigation(const GURL& dest_url,
424 const GURL& dest_url, 424 SiteInstance* source_instance,
425 SiteInstance* dest_instance, 425 SiteInstance* dest_instance,
426 ui::PageTransition dest_transition, 426 ui::PageTransition transition,
427 bool dest_is_restore, 427 bool dest_is_restore,
428 bool dest_is_view_source_mode); 428 bool dest_is_view_source_mode);
429 429
430 // Returns an appropriate SiteInstance object for the given |dest_url|, 430 // Returns an appropriate SiteInstance object for the given |dest_url|,
431 // possibly reusing the current SiteInstance. If --process-per-tab is used, 431 // possibly reusing the current SiteInstance. If --process-per-tab is used,
432 // this is only called when ShouldSwapBrowsingInstancesForNavigation returns 432 // this is only called when ShouldSwapBrowsingInstancesForNavigation returns
433 // true. |dest_instance| will be used if it is not null. 433 // true. |source_instance| is the SiteInstance of the frame that initiated the
434 // navigation. |current_instance| is the SiteInstance of the frame that is
435 // currently navigating. |dest_instance|, is a predetermined SiteInstance
436 // that'll be used if not null.
437 // For example, if you have a parent frame A, which has a child frame B, and
438 // A is trying to change the src attribute of B, this will cause a navigation
439 // where the source SiteInstance is A and B is the current SiteInstance.
434 // This is a helper function for GetSiteInstanceForNavigation. 440 // This is a helper function for GetSiteInstanceForNavigation.
435 SiteInstance* GetSiteInstanceForURL( 441 SiteInstance* GetSiteInstanceForURL(const GURL& dest_url,
436 const GURL& dest_url, 442 SiteInstance* source_instance,
437 SiteInstance* dest_instance, 443 SiteInstance* current_instance,
438 ui::PageTransition dest_transition, 444 SiteInstance* dest_instance,
439 bool dest_is_restore, 445 ui::PageTransition transition,
440 bool dest_is_view_source_mode, 446 bool dest_is_restore,
441 SiteInstance* current_instance, 447 bool dest_is_view_source_mode,
442 bool force_browsing_instance_swap); 448 bool force_browsing_instance_swap);
443 449
444 // Determines the appropriate url to use as the current url for SiteInstance 450 // Determines the appropriate url to use as the current url for SiteInstance
445 // selection. 451 // selection.
446 const GURL& GetCurrentURLForSiteInstance( 452 const GURL& GetCurrentURLForSiteInstance(
447 SiteInstance* current_instance, 453 SiteInstance* current_instance,
448 NavigationEntry* current_entry); 454 NavigationEntry* current_entry);
449 455
450 // Creates a new RenderFrameHostImpl for the |new_instance| and assign it to 456 // Creates a new RenderFrameHostImpl for the |new_instance| and assign it to
451 // |pending_render_frame_host_| while respecting the opener route if needed 457 // |pending_render_frame_host_| while respecting the opener route if needed
452 // and stores it in pending_render_frame_host_. 458 // and stores it in pending_render_frame_host_.
(...skipping 60 matching lines...) Expand 10 before | Expand all | Expand 10 after
513 519
514 // Clears pending_render_frame_host_, returning it to the caller for disposal. 520 // Clears pending_render_frame_host_, returning it to the caller for disposal.
515 scoped_ptr<RenderFrameHostImpl> UnsetPendingRenderFrameHost(); 521 scoped_ptr<RenderFrameHostImpl> UnsetPendingRenderFrameHost();
516 522
517 // Helper method to set the active RenderFrameHost. Returns the old 523 // Helper method to set the active RenderFrameHost. Returns the old
518 // RenderFrameHost and updates counts. 524 // RenderFrameHost and updates counts.
519 scoped_ptr<RenderFrameHostImpl> SetRenderFrameHost( 525 scoped_ptr<RenderFrameHostImpl> SetRenderFrameHost(
520 scoped_ptr<RenderFrameHostImpl> render_frame_host); 526 scoped_ptr<RenderFrameHostImpl> render_frame_host);
521 527
522 RenderFrameHostImpl* UpdateStateForNavigate( 528 RenderFrameHostImpl* UpdateStateForNavigate(
523 const GURL& url, 529 const GURL& dest_url,
524 SiteInstance* instance, 530 SiteInstance* source_instance,
531 SiteInstance* dest_instance,
525 ui::PageTransition transition, 532 ui::PageTransition transition,
526 bool is_restore, 533 bool dest_is_restore,
527 bool is_view_source_mode, 534 bool dest_is_view_source_mode,
528 const GlobalRequestID& transferred_request_id, 535 const GlobalRequestID& transferred_request_id,
529 int bindings); 536 int bindings);
530 537
531 // Called when a renderer process is starting to close. We should not 538 // Called when a renderer process is starting to close. We should not
532 // schedule new navigations in its swapped out RenderFrameHosts after this. 539 // schedule new navigations in its swapped out RenderFrameHosts after this.
533 void RendererProcessClosing(RenderProcessHost* render_process_host); 540 void RendererProcessClosing(RenderProcessHost* render_process_host);
534 541
535 // Helper method to delete a RenderFrameProxyHost from the list, if one exists 542 // Helper method to delete a RenderFrameProxyHost from the list, if one exists
536 // for the given |instance|. 543 // for the given |instance|.
537 void DeleteRenderFrameProxyHost(SiteInstance* instance); 544 void DeleteRenderFrameProxyHost(SiteInstance* instance);
(...skipping 68 matching lines...) Expand 10 before | Expand all | Expand 10 after
606 NotificationRegistrar registrar_; 613 NotificationRegistrar registrar_;
607 614
608 base::WeakPtrFactory<RenderFrameHostManager> weak_factory_; 615 base::WeakPtrFactory<RenderFrameHostManager> weak_factory_;
609 616
610 DISALLOW_COPY_AND_ASSIGN(RenderFrameHostManager); 617 DISALLOW_COPY_AND_ASSIGN(RenderFrameHostManager);
611 }; 618 };
612 619
613 } // namespace content 620 } // namespace content
614 621
615 #endif // CONTENT_BROWSER_FRAME_HOST_RENDER_FRAME_HOST_MANAGER_H_ 622 #endif // CONTENT_BROWSER_FRAME_HOST_RENDER_FRAME_HOST_MANAGER_H_
OLDNEW
« no previous file with comments | « content/browser/frame_host/render_frame_host_impl.cc ('k') | content/browser/frame_host/render_frame_host_manager.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698