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

Unified Diff: chrome/browser/extensions/api/sessions/sessions_api.cc

Issue 1697183003: Remove HostDesktopType from sessions and tab restore (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@metro-mode-19
Patch Set: mac Created 4 years, 10 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
« no previous file with comments | « chrome/browser/app_controller_mac.mm ('k') | chrome/browser/sessions/chrome_tab_restore_service_client.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/extensions/api/sessions/sessions_api.cc
diff --git a/chrome/browser/extensions/api/sessions/sessions_api.cc b/chrome/browser/extensions/api/sessions/sessions_api.cc
index a570d88119ffbad9195816e7aa25e115b8f5c0b1..6f9534f7491d6266b496ea04e50f8400c3e8087f 100644
--- a/chrome/browser/extensions/api/sessions/sessions_api.cc
+++ b/chrome/browser/extensions/api/sessions/sessions_api.cc
@@ -446,7 +446,6 @@ bool SessionsRestoreFunction::SetResultRestoredWindow(int window_id) {
bool SessionsRestoreFunction::RestoreMostRecentlyClosed(Browser* browser) {
sessions::TabRestoreService* tab_restore_service =
TabRestoreServiceFactory::GetForProfile(GetProfile());
- chrome::HostDesktopType host_desktop_type = browser->host_desktop_type();
sessions::TabRestoreService::Entries entries = tab_restore_service->entries();
if (entries.empty()) {
@@ -459,7 +458,7 @@ bool SessionsRestoreFunction::RestoreMostRecentlyClosed(Browser* browser) {
BrowserLiveTabContext::FindContextForWebContents(
browser->tab_strip_model()->GetActiveWebContents());
std::vector<sessions::LiveTab*> restored_tabs =
- tab_restore_service->RestoreMostRecentEntry(context, host_desktop_type);
+ tab_restore_service->RestoreMostRecentEntry(context);
DCHECK(restored_tabs.size());
sessions::ContentLiveTab* first_tab =
@@ -477,7 +476,6 @@ bool SessionsRestoreFunction::RestoreLocalSession(const SessionId& session_id,
Browser* browser) {
sessions::TabRestoreService* tab_restore_service =
TabRestoreServiceFactory::GetForProfile(GetProfile());
- chrome::HostDesktopType host_desktop_type = browser->host_desktop_type();
sessions::TabRestoreService::Entries entries = tab_restore_service->entries();
if (entries.empty()) {
@@ -501,8 +499,7 @@ bool SessionsRestoreFunction::RestoreLocalSession(const SessionId& session_id,
BrowserLiveTabContext::FindContextForWebContents(
browser->tab_strip_model()->GetActiveWebContents());
std::vector<sessions::LiveTab*> restored_tabs =
- tab_restore_service->RestoreEntryById(context, session_id.id(),
- host_desktop_type, UNKNOWN);
+ tab_restore_service->RestoreEntryById(context, session_id.id(), UNKNOWN);
// If the ID is invalid, restored_tabs will be empty.
if (!restored_tabs.size()) {
SetInvalidIdError(session_id.ToString());
« no previous file with comments | « chrome/browser/app_controller_mac.mm ('k') | chrome/browser/sessions/chrome_tab_restore_service_client.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698