| Index: content/browser/tab_contents/navigation_details.h
|
| ===================================================================
|
| --- content/browser/tab_contents/navigation_details.h (revision 91739)
|
| +++ content/browser/tab_contents/navigation_details.h (working copy)
|
| @@ -37,8 +37,16 @@
|
| // The previous URL that the user was on. This may be empty if none.
|
| GURL previous_url;
|
|
|
| + // True when this load was non-user initated. This corresponds to a
|
| + // a NavigationGestureAuto call from WebKit (see webview_delegate.h).
|
| + // We also count reloads and meta-refreshes as "auto" to account for the
|
| + // fact that WebKit doesn't always set the user gesture properly in these
|
| + // cases (see bug 1051891).
|
| + bool is_auto;
|
| +
|
| // True if the committed entry has replaced the exisiting one.
|
| // A non-user initiated redirect causes such replacement.
|
| + // This is somewhat similiar to is_auto, but not exactly the same.
|
| bool did_replace_entry;
|
|
|
| // True if the navigation was in-page. This means that the active entry's
|
| @@ -55,11 +63,12 @@
|
| // Use SSLManager::DeserializeSecurityInfo to decode it.
|
| std::string serialized_security_info;
|
|
|
| - // Returns whether the main frame navigated to a different page (e.g., not
|
| - // scrolling to a fragment inside the current page). We often need this logic
|
| - // for showing or hiding something.
|
| - bool is_navigation_to_different_page() const {
|
| - return is_main_frame && !is_in_page;
|
| + // Returns whether the user probably felt like they navigated somewhere new.
|
| + // We often need this logic for showing or hiding something, and this
|
| + // returns true only for main frame loads that the user initiated, that go
|
| + // to a new page.
|
| + bool is_user_initiated_main_frame_load() const {
|
| + return !is_auto && !is_in_page && is_main_frame;
|
| }
|
|
|
| // The HTTP status code for this entry..
|
|
|