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

Side by Side Diff: content/public/browser/navigation_controller.h

Issue 12001002: InstantExtended: Transient naventry for preview. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Address comment. Created 7 years, 11 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 | Annotate | Revision Log
OLDNEW
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_NAVIGATION_CONTROLLER_H_ 5 #ifndef CONTENT_PUBLIC_BROWSER_NAVIGATION_CONTROLLER_H_
6 #define CONTENT_PUBLIC_BROWSER_NAVIGATION_CONTROLLER_H_ 6 #define CONTENT_PUBLIC_BROWSER_NAVIGATION_CONTROLLER_H_
7 7
8 #include <map> 8 #include <map>
9 #include <string> 9 #include <string>
10 #include <vector> 10 #include <vector>
(...skipping 247 matching lines...) Expand 10 before | Expand all | Expand 10 after
258 // corresponds to a new navigation (created via LoadURL). 258 // corresponds to a new navigation (created via LoadURL).
259 virtual int GetPendingEntryIndex() const = 0; 259 virtual int GetPendingEntryIndex() const = 0;
260 260
261 // Transient entry ----------------------------------------------------------- 261 // Transient entry -----------------------------------------------------------
262 262
263 // Returns the transient entry if any. This is an entry which is removed and 263 // Returns the transient entry if any. This is an entry which is removed and
264 // discarded if any navigation occurs. Note that the returned entry is owned 264 // discarded if any navigation occurs. Note that the returned entry is owned
265 // by the navigation controller and may be deleted at any time. 265 // by the navigation controller and may be deleted at any time.
266 virtual NavigationEntry* GetTransientEntry() const = 0; 266 virtual NavigationEntry* GetTransientEntry() const = 0;
267 267
268 // Adds an entry that is returned by GetActiveEntry(). The entry is
269 // transient: any navigation causes it to be removed and discarded. The
270 // NavigationController becomes the owner of |entry| and deletes it when
271 // it discards it. This is useful with interstitial page that need to be
272 // represented as an entry, but should go away when the user navigates away
273 // from them.
274 // Note that adding a transient entry does not change the active contents.
275 virtual void AddTransientEntry(NavigationEntry* entry) = 0;
276
268 // New navigations ----------------------------------------------------------- 277 // New navigations -----------------------------------------------------------
269 278
270 // Loads the specified URL, specifying extra http headers to add to the 279 // Loads the specified URL, specifying extra http headers to add to the
271 // request. Extra headers are separated by \n. 280 // request. Extra headers are separated by \n.
272 virtual void LoadURL(const GURL& url, 281 virtual void LoadURL(const GURL& url,
273 const Referrer& referrer, 282 const Referrer& referrer,
274 PageTransition type, 283 PageTransition type,
275 const std::string& extra_headers) = 0; 284 const std::string& extra_headers) = 0;
276 285
277 // More general version of LoadURL. See comments in LoadURLParams for 286 // More general version of LoadURL. See comments in LoadURLParams for
(...skipping 97 matching lines...) Expand 10 before | Expand all | Expand 10 after
375 virtual void CopyStateFromAndPrune(NavigationController* source) = 0; 384 virtual void CopyStateFromAndPrune(NavigationController* source) = 0;
376 385
377 // Removes all the entries except the active entry. If there is a new pending 386 // Removes all the entries except the active entry. If there is a new pending
378 // navigation it is preserved. 387 // navigation it is preserved.
379 virtual void PruneAllButActive() = 0; 388 virtual void PruneAllButActive() = 0;
380 }; 389 };
381 390
382 } // namespace content 391 } // namespace content
383 392
384 #endif // CONTENT_PUBLIC_BROWSER_NAVIGATION_CONTROLLER_H_ 393 #endif // CONTENT_PUBLIC_BROWSER_NAVIGATION_CONTROLLER_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698