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

Unified Diff: chrome/browser/ui/views/apps/chrome_native_app_window_views_win.cc

Issue 1682183002: Remove PerAppSettingsService (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: 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/ui/extensions/application_launch.cc ('k') | chrome/chrome_browser_extensions.gypi » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/ui/views/apps/chrome_native_app_window_views_win.cc
diff --git a/chrome/browser/ui/views/apps/chrome_native_app_window_views_win.cc b/chrome/browser/ui/views/apps/chrome_native_app_window_views_win.cc
index e9aa438026481fbca9c68ed1a6121456c721ef18..73bb70b3bbbd3fcdbfa469cfd87aafda0d477b68 100644
--- a/chrome/browser/ui/views/apps/chrome_native_app_window_views_win.cc
+++ b/chrome/browser/ui/views/apps/chrome_native_app_window_views_win.cc
@@ -9,8 +9,6 @@
#include "base/files/file_util.h"
#include "base/strings/utf_string_conversions.h"
#include "base/threading/sequenced_worker_pool.h"
-#include "chrome/browser/apps/per_app_settings_service.h"
-#include "chrome/browser/apps/per_app_settings_service_factory.h"
#include "chrome/browser/profiles/profile.h"
#include "chrome/browser/shell_integration.h"
#include "chrome/browser/ui/views/apps/app_window_desktop_native_widget_aura_win.h"
@@ -55,29 +53,6 @@ void ChromeNativeAppWindowViewsWin::OnBeforeWidgetInit(
views::Widget* widget) {
ChromeNativeAppWindowViewsAura::OnBeforeWidgetInit(create_params, init_params,
widget);
-
- content::BrowserContext* browser_context = app_window()->browser_context();
- std::string extension_id = app_window()->extension_id();
- // If an app has any existing windows, ensure new ones are created on the
- // same desktop.
- extensions::AppWindow* any_existing_window =
- extensions::AppWindowRegistry::Get(browser_context)
- ->GetCurrentAppWindowForApp(extension_id);
- chrome::HostDesktopType desktop_type;
- if (any_existing_window) {
- desktop_type = chrome::GetHostDesktopTypeForNativeWindow(
- any_existing_window->GetNativeWindow());
- } else {
- PerAppSettingsService* settings =
- PerAppSettingsServiceFactory::GetForBrowserContext(browser_context);
- if (settings->HasDesktopLastLaunchedFrom(extension_id)) {
- desktop_type = settings->GetDesktopLastLaunchedFrom(extension_id);
- } else {
- // We don't know what desktop this app was last launched from, so take our
- // best guess as to what desktop the user is on.
- desktop_type = chrome::GetActiveDesktop();
- }
- }
init_params->native_widget = new AppWindowDesktopNativeWidgetAuraWin(this);
is_translucent_ =
« no previous file with comments | « chrome/browser/ui/extensions/application_launch.cc ('k') | chrome/chrome_browser_extensions.gypi » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698