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

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

Issue 1002803002: Classify navigations without page id in parallel to the existing classifier. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: better crash url Created 5 years, 9 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 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_NAVIGATION_CONTROLLER_IMPL_H_ 5 #ifndef CONTENT_BROWSER_FRAME_HOST_NAVIGATION_CONTROLLER_IMPL_H_
6 #define CONTENT_BROWSER_FRAME_HOST_NAVIGATION_CONTROLLER_IMPL_H_ 6 #define CONTENT_BROWSER_FRAME_HOST_NAVIGATION_CONTROLLER_IMPL_H_
7 7
8 #include "base/callback.h" 8 #include "base/callback.h"
9 #include "base/compiler_specific.h" 9 #include "base/compiler_specific.h"
10 #include "base/gtest_prod_util.h" 10 #include "base/gtest_prod_util.h"
(...skipping 89 matching lines...) Expand 10 before | Expand all | Expand 10 after
100 100
101 // Returns the index of the specified entry, or -1 if entry is not contained 101 // Returns the index of the specified entry, or -1 if entry is not contained
102 // in this NavigationController. 102 // in this NavigationController.
103 int GetIndexOfEntry(const NavigationEntryImpl* entry) const; 103 int GetIndexOfEntry(const NavigationEntryImpl* entry) const;
104 104
105 // Return the index of the entry with the corresponding instance and page_id, 105 // Return the index of the entry with the corresponding instance and page_id,
106 // or -1 if not found. 106 // or -1 if not found.
107 int GetEntryIndexWithPageID(SiteInstance* instance, 107 int GetEntryIndexWithPageID(SiteInstance* instance,
108 int32 page_id) const; 108 int32 page_id) const;
109 109
110 // Return the index of the entry with the given unique id, or -1 if not found.
111 int GetEntryIndexWithUniqueID(int nav_entry_id) const;
112
110 // Return the entry with the corresponding instance and page_id, or NULL if 113 // Return the entry with the corresponding instance and page_id, or NULL if
111 // not found. 114 // not found.
112 NavigationEntryImpl* GetEntryWithPageID( 115 NavigationEntryImpl* GetEntryWithPageID(
113 SiteInstance* instance, 116 SiteInstance* instance,
114 int32 page_id) const; 117 int32 page_id) const;
115 118
116 NavigationControllerDelegate* delegate() const { 119 NavigationControllerDelegate* delegate() const {
117 return delegate_; 120 return delegate_;
118 } 121 }
119 122
(...skipping 103 matching lines...) Expand 10 before | Expand all | Expand 10 after
223 // |low_water_mark_| is the first time in a sequence of adjusted 226 // |low_water_mark_| is the first time in a sequence of adjusted
224 // times and |high_water_mark_| is the last. 227 // times and |high_water_mark_| is the last.
225 base::Time low_water_mark_; 228 base::Time low_water_mark_;
226 base::Time high_water_mark_; 229 base::Time high_water_mark_;
227 }; 230 };
228 231
229 // Classifies the given renderer navigation (see the NavigationType enum). 232 // Classifies the given renderer navigation (see the NavigationType enum).
230 NavigationType ClassifyNavigation( 233 NavigationType ClassifyNavigation(
231 RenderFrameHostImpl* rfh, 234 RenderFrameHostImpl* rfh,
232 const FrameHostMsg_DidCommitProvisionalLoad_Params& params) const; 235 const FrameHostMsg_DidCommitProvisionalLoad_Params& params) const;
236 // This does the same as above (hopefully), but does so without any use of
237 // deprecated page id values. http://crbug.com/369661
Charlie Reis 2015/03/12 18:28:17 Mention that we currently only call it in debug bu
Avi (use Gerrit) 2015/03/12 19:21:17 That depends on how we want to land this.
238 NavigationType ClassifyNavigationWithoutPageID(
239 RenderFrameHostImpl* rfh,
240 const FrameHostMsg_DidCommitProvisionalLoad_Params& params) const;
233 241
234 // Causes the controller to load the specified entry. The function assumes 242 // Causes the controller to load the specified entry. The function assumes
235 // ownership of the pointer since it is put in the navigation list. 243 // ownership of the pointer since it is put in the navigation list.
236 // NOTE: Do not pass an entry that the controller already owns! 244 // NOTE: Do not pass an entry that the controller already owns!
237 void LoadEntry(NavigationEntryImpl* entry); 245 void LoadEntry(NavigationEntryImpl* entry);
238 246
239 // Handlers for the different types of navigation types. They will actually 247 // Handlers for the different types of navigation types. They will actually
240 // handle the navigations corresponding to the different NavClasses above. 248 // handle the navigations corresponding to the different NavClasses above.
241 // They will NOT broadcast the commit notification, that should be handled by 249 // They will NOT broadcast the commit notification, that should be handled by
242 // the caller. 250 // the caller.
(...skipping 165 matching lines...) Expand 10 before | Expand all | Expand 10 after
408 TimeSmoother time_smoother_; 416 TimeSmoother time_smoother_;
409 417
410 scoped_ptr<NavigationEntryScreenshotManager> screenshot_manager_; 418 scoped_ptr<NavigationEntryScreenshotManager> screenshot_manager_;
411 419
412 DISALLOW_COPY_AND_ASSIGN(NavigationControllerImpl); 420 DISALLOW_COPY_AND_ASSIGN(NavigationControllerImpl);
413 }; 421 };
414 422
415 } // namespace content 423 } // namespace content
416 424
417 #endif // CONTENT_BROWSER_FRAME_HOST_NAVIGATION_CONTROLLER_IMPL_H_ 425 #endif // CONTENT_BROWSER_FRAME_HOST_NAVIGATION_CONTROLLER_IMPL_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698