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

Side by Side Diff: chrome/browser/sessions/persistent_tab_restore_service.cc

Issue 1343833002: Abstract content::SessionStorageNamespace from core TabRestore code (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@extension_tab_helper
Patch Set: Response to review Created 5 years, 3 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 2012 The Chromium Authors. All rights reserved. 1 // Copyright 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 #include "chrome/browser/sessions/persistent_tab_restore_service.h" 5 #include "chrome/browser/sessions/persistent_tab_restore_service.h"
6 6
7 #include <cstring> // memcpy 7 #include <cstring> // memcpy
8 #include <vector> 8 #include <vector>
9 9
10 #include "base/basictypes.h" 10 #include "base/basictypes.h"
11 #include "base/bind.h" 11 #include "base/bind.h"
12 #include "base/compiler_specific.h" 12 #include "base/compiler_specific.h"
13 #include "base/files/file_path.h" 13 #include "base/files/file_path.h"
14 #include "base/logging.h" 14 #include "base/logging.h"
15 #include "base/memory/ref_counted.h" 15 #include "base/memory/ref_counted.h"
16 #include "base/memory/scoped_vector.h" 16 #include "base/memory/scoped_vector.h"
17 #include "base/stl_util.h" 17 #include "base/stl_util.h"
18 #include "base/task/cancelable_task_tracker.h" 18 #include "base/task/cancelable_task_tracker.h"
19 #include "base/time/time.h" 19 #include "base/time/time.h"
20 #include "components/sessions/base_session_service.h" 20 #include "components/sessions/base_session_service.h"
21 #include "components/sessions/base_session_service_commands.h" 21 #include "components/sessions/base_session_service_commands.h"
22 #include "components/sessions/base_session_service_delegate.h" 22 #include "components/sessions/base_session_service_delegate.h"
23 #include "components/sessions/core/session_constants.h" 23 #include "components/sessions/core/session_constants.h"
24 #include "components/sessions/session_command.h" 24 #include "components/sessions/session_command.h"
25 #include "content/public/browser/session_storage_namespace.h"
26 25
27 namespace { 26 namespace {
28 27
29 // Only written if the tab is pinned. 28 // Only written if the tab is pinned.
30 typedef bool PinnedStatePayload; 29 typedef bool PinnedStatePayload;
31 30
32 typedef int32 RestoredEntryPayload; 31 typedef int32 RestoredEntryPayload;
33 32
34 typedef std::map<SessionID::id_type, TabRestoreService::Entry*> IDToEntry; 33 typedef std::map<SessionID::id_type, TabRestoreService::Entry*> IDToEntry;
35 34
(...skipping 971 matching lines...) Expand 10 before | Expand all | Expand 10 after
1007 delegate_->LoadTabsFromLastSession(); 1006 delegate_->LoadTabsFromLastSession();
1008 } 1007 }
1009 1008
1010 TabRestoreService::Entries* PersistentTabRestoreService::mutable_entries() { 1009 TabRestoreService::Entries* PersistentTabRestoreService::mutable_entries() {
1011 return &helper_.entries_; 1010 return &helper_.entries_;
1012 } 1011 }
1013 1012
1014 void PersistentTabRestoreService::PruneEntries() { 1013 void PersistentTabRestoreService::PruneEntries() {
1015 helper_.PruneEntries(); 1014 helper_.PruneEntries();
1016 } 1015 }
OLDNEW
« no previous file with comments | « chrome/browser/sessions/chrome_tab_restore_service_client.cc ('k') | chrome/browser/sessions/tab_restore_service.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698