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

Unified Diff: chrome/browser/sessions/session_service.h

Issue 1319473014: Introduce TabRestoreServiceClient and //chrome implementation. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
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 side-by-side diff with in-line comments
Download patch
Index: chrome/browser/sessions/session_service.h
diff --git a/chrome/browser/sessions/session_service.h b/chrome/browser/sessions/session_service.h
index 0b5212d293ce1a3e40e6eaddc3fc754b1dcdef18..0b93d26a098e0345b6a44f4480a6094c277a0cc8 100644
--- a/chrome/browser/sessions/session_service.h
+++ b/chrome/browser/sessions/session_service.h
@@ -21,6 +21,7 @@
#include "chrome/browser/ui/browser_finder.h"
#include "chrome/browser/ui/browser_list_observer.h"
#include "components/keyed_service/core/keyed_service.h"
+#include "components/sessions/core/tab_restore_service_client.h"
#include "components/sessions/session_service_commands.h"
#include "content/public/browser/notification_observer.h"
#include "content/public/browser/notification_registrar.h"
@@ -206,16 +207,11 @@ class SessionService : public BaseSessionServiceDelegateImpl,
const SessionID& tab_id,
base::TimeTicks last_active_time);
- // Callback from GetLastSession.
- // The second parameter is the id of the window that was last active.
- typedef base::Callback<void(ScopedVector<sessions::SessionWindow>,
- SessionID::id_type)> SessionCallback;
-
// Fetches the contents of the last session, notifying the callback when
// done. If the callback is supplied an empty vector of SessionWindows
// it means the session could not be restored.
base::CancelableTaskTracker::TaskId GetLastSession(
- const SessionCallback& callback,
+ const sessions::GetLastSessionCallback& callback,
base::CancelableTaskTracker* tracker);
// BaseSessionServiceDelegateImpl:
@@ -257,7 +253,7 @@ class SessionService : public BaseSessionServiceDelegateImpl,
void OnBrowserSetLastActive(Browser* browser) override;
// Converts |commands| to SessionWindows and notifies the callback.
- void OnGotSessionCommands(const SessionCallback& callback,
+ void OnGotSessionCommands(const sessions::GetLastSessionCallback& callback,
ScopedVector<sessions::SessionCommand> commands);
// Adds commands to commands that will recreate the state of the specified
« no previous file with comments | « chrome/browser/sessions/persistent_tab_restore_service_unittest.cc ('k') | chrome/browser/sessions/session_service.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698