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

Side by Side Diff: components/sessions/content/content_serialized_navigation_builder.h

Issue 1440573003: Remove ScopedVector from NavigationController. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: aw Created 5 years, 1 month 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 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 COMPONENTS_SESSIONS_CONTENT_CONTENT_SERIALIZED_NAVIGATION_BUILDER_H_ 5 #ifndef COMPONENTS_SESSIONS_CONTENT_CONTENT_SERIALIZED_NAVIGATION_BUILDER_H_
6 #define COMPONENTS_SESSIONS_CONTENT_CONTENT_SERIALIZED_NAVIGATION_BUILDER_H_ 6 #define COMPONENTS_SESSIONS_CONTENT_CONTENT_SERIALIZED_NAVIGATION_BUILDER_H_
7 7
8 #include <vector> 8 #include <vector>
9 9
10 #include "base/memory/scoped_ptr.h" 10 #include "base/memory/scoped_ptr.h"
11 #include "base/memory/scoped_vector.h"
12 #include "components/sessions/core/sessions_export.h" 11 #include "components/sessions/core/sessions_export.h"
13 12
14 namespace content { 13 namespace content {
15 class BrowserContext; 14 class BrowserContext;
16 class NavigationEntry; 15 class NavigationEntry;
17 } 16 }
18 17
19 namespace sessions { 18 namespace sessions {
20 class SerializedNavigationEntry; 19 class SerializedNavigationEntry;
21 20
(...skipping 10 matching lines...) Expand all
32 // Convert the given SerializedNavigationEntry into a NavigationEntry with the 31 // Convert the given SerializedNavigationEntry into a NavigationEntry with the
33 // given page ID and context. The NavigationEntry will have a transition type 32 // given page ID and context. The NavigationEntry will have a transition type
34 // of PAGE_TRANSITION_RELOAD and a new unique ID. 33 // of PAGE_TRANSITION_RELOAD and a new unique ID.
35 static scoped_ptr<content::NavigationEntry> ToNavigationEntry( 34 static scoped_ptr<content::NavigationEntry> ToNavigationEntry(
36 const SerializedNavigationEntry* navigation, 35 const SerializedNavigationEntry* navigation,
37 int page_id, 36 int page_id,
38 content::BrowserContext* browser_context); 37 content::BrowserContext* browser_context);
39 38
40 // Converts a set of SerializedNavigationEntrys into a list of 39 // Converts a set of SerializedNavigationEntrys into a list of
41 // NavigationEntrys with sequential page IDs and the given context. 40 // NavigationEntrys with sequential page IDs and the given context.
42 static ScopedVector<content::NavigationEntry> ToNavigationEntries( 41 static std::vector<scoped_ptr<content::NavigationEntry>> ToNavigationEntries(
43 const std::vector<SerializedNavigationEntry>& navigations, 42 const std::vector<SerializedNavigationEntry>& navigations,
44 content::BrowserContext* browser_context); 43 content::BrowserContext* browser_context);
45 }; 44 };
46 45
47 } // namespace sessions 46 } // namespace sessions
48 47
49 #endif // COMPONENTS_SESSIONS_CONTENT_CONTENT_SERIALIZED_NAVIGATION_BUILDER_H_ 48 #endif // COMPONENTS_SESSIONS_CONTENT_CONTENT_SERIALIZED_NAVIGATION_BUILDER_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698