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

Unified Diff: chrome/browser/browser_navigator.h

Issue 3834002: Make all browser code use browser::Navigate to open tabs.... (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: '' Created 10 years, 2 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « chrome/browser/browser_init.cc ('k') | chrome/browser/browser_navigator.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/browser_navigator.h
===================================================================
--- chrome/browser/browser_navigator.h (revision 64601)
+++ chrome/browser/browser_navigator.h (working copy)
@@ -47,13 +47,15 @@
NavigateParams(Browser* browser, TabContents* a_target_contents);
~NavigateParams();
- // The URL/referrer to be loaded. Can be empty if |contents| is specified
- // non-NULL.
+ // The URL/referrer to be loaded. Ignored if |target_contents| is non-NULL.
GURL url;
GURL referrer;
// [in] A TabContents to be navigated or inserted into the target Browser's
- // tabstrip. If NULL, |url| or the homepage will be used instead.
+ // tabstrip. If NULL, |url| or the homepage will be used instead. When
+ // non-NULL, Navigate() assumes it has already been navigated to its
+ // intended destination and will not load any URL in it (i.e. |url| is
+ // ignored).
// Default is NULL.
// [out] The TabContents in which the navigation occurred or that was
// inserted. Guaranteed non-NULL except for note below:
@@ -70,7 +72,18 @@
TabContents* source_contents;
// The disposition requested by the navigation source. Default is
- // CURRENT_TAB.
+ // CURRENT_TAB. What follows is a set of coercions that happen to this value
+ // when other factors are at play:
+ //
+ // [in]: Condition: [out]:
+ // NEW_BACKGROUND_TAB target browser tabstrip is empty NEW_FOREGROUND_TAB
+ // CURRENT_TAB " " " NEW_FOREGROUND_TAB
+ // OFF_THE_RECORD target browser profile is incog. NEW_FOREGROUND_TAB
+ //
+ // If disposition is NEW_WINDOW or NEW_POPUP, |show_window| is set to true
+ // automatically.
+ // If disposition is NEW_BACKGROUND_TAB, TabStripModel::ADD_SELECTED is
+ // removed from |tabstrip_add_types| automatically.
WindowOpenDisposition disposition;
// The transition type of the navigation. Default is PageTransition::LINK
@@ -99,7 +112,8 @@
gfx::Rect window_bounds;
// True if the target window should be made visible at the end of the call
- // to Navigate(). Default is false.
+ // to Navigate(). This activates the window if it was already visible.
+ // Default is false.
bool show_window;
// [in] Specifies a Browser object where the navigation could occur or the
« no previous file with comments | « chrome/browser/browser_init.cc ('k') | chrome/browser/browser_navigator.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698