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

Side by Side Diff: chrome/browser/chrome_content_browser_client.cc

Issue 2759333002: Move chrome-specific SerializedNavigation code to chrome/. (Closed)
Patch Set: Fix Android Created 3 years, 9 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 (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 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/chrome_content_browser_client.h" 5 #include "chrome/browser/chrome_content_browser_client.h"
6 6
7 #include <map> 7 #include <map>
8 #include <set> 8 #include <set>
9 #include <utility> 9 #include <utility>
10 #include <vector> 10 #include <vector>
(...skipping 159 matching lines...) Expand 10 before | Expand all | Expand 10 after
170 #include "content/public/browser/storage_partition.h" 170 #include "content/public/browser/storage_partition.h"
171 #include "content/public/browser/vpn_service_proxy.h" 171 #include "content/public/browser/vpn_service_proxy.h"
172 #include "content/public/browser/web_contents.h" 172 #include "content/public/browser/web_contents.h"
173 #include "content/public/common/child_process_host.h" 173 #include "content/public/common/child_process_host.h"
174 #include "content/public/common/content_descriptors.h" 174 #include "content/public/common/content_descriptors.h"
175 #include "content/public/common/content_features.h" 175 #include "content/public/common/content_features.h"
176 #include "content/public/common/content_switches.h" 176 #include "content/public/common/content_switches.h"
177 #include "content/public/common/sandbox_type.h" 177 #include "content/public/common/sandbox_type.h"
178 #include "content/public/common/service_manager_connection.h" 178 #include "content/public/common/service_manager_connection.h"
179 #include "content/public/common/service_names.mojom.h" 179 #include "content/public/common/service_names.mojom.h"
180 #include "content/public/common/url_constants.h"
181 #include "content/public/common/url_utils.h" 180 #include "content/public/common/url_utils.h"
182 #include "content/public/common/web_preferences.h" 181 #include "content/public/common/web_preferences.h"
183 #include "device/bluetooth/adapter_factory.h" 182 #include "device/bluetooth/adapter_factory.h"
184 #include "device/bluetooth/public/interfaces/adapter.mojom.h" 183 #include "device/bluetooth/public/interfaces/adapter.mojom.h"
185 #include "device/usb/public/interfaces/chooser_service.mojom.h" 184 #include "device/usb/public/interfaces/chooser_service.mojom.h"
186 #include "device/usb/public/interfaces/device_manager.mojom.h" 185 #include "device/usb/public/interfaces/device_manager.mojom.h"
187 #include "extensions/features/features.h" 186 #include "extensions/features/features.h"
188 #include "gpu/config/gpu_switches.h" 187 #include "gpu/config/gpu_switches.h"
189 #include "media/audio/audio_manager.h" 188 #include "media/audio/audio_manager.h"
190 #include "media/media_features.h" 189 #include "media/media_features.h"
(...skipping 456 matching lines...) Expand 10 before | Expand all | Expand 10 after
647 browser_context, *url)) 646 browser_context, *url))
648 return false; 647 return false;
649 648
650 #if defined(OS_CHROMEOS) 649 #if defined(OS_CHROMEOS)
651 // Special case : in ChromeOS in Guest mode bookmarks and history are 650 // Special case : in ChromeOS in Guest mode bookmarks and history are
652 // disabled for security reasons. New tab page explains the reasons, so 651 // disabled for security reasons. New tab page explains the reasons, so
653 // we redirect user to new tab page. 652 // we redirect user to new tab page.
654 if (user_manager::UserManager::Get()->IsLoggedInAsGuest()) { 653 if (user_manager::UserManager::Get()->IsLoggedInAsGuest()) {
655 if (url->SchemeIs(content::kChromeUIScheme) && 654 if (url->SchemeIs(content::kChromeUIScheme) &&
656 (url->DomainIs(chrome::kChromeUIBookmarksHost) || 655 (url->DomainIs(chrome::kChromeUIBookmarksHost) ||
657 url->DomainIs(content::kChromeUIHistoryHost))) { 656 url->DomainIs(chrome::kChromeUIHistoryHost))) {
658 // Rewrite with new tab URL 657 // Rewrite with new tab URL
659 *url = GURL(chrome::kChromeUINewTabURL); 658 *url = GURL(chrome::kChromeUINewTabURL);
660 } 659 }
661 } 660 }
662 #endif 661 #endif
663 662
664 return true; 663 return true;
665 } 664 }
666 665
667 // Reverse URL handler for Web UI. Maps "chrome://chrome/foo/" to 666 // Reverse URL handler for Web UI. Maps "chrome://chrome/foo/" to
(...skipping 2898 matching lines...) Expand 10 before | Expand all | Expand 10 after
3566 RedirectNonUINonIOBrowserThreadsToTaskScheduler() { 3565 RedirectNonUINonIOBrowserThreadsToTaskScheduler() {
3567 return variations::GetVariationParamValue( 3566 return variations::GetVariationParamValue(
3568 "BrowserScheduler", "RedirectNonUINonIOBrowserThreads") == "true"; 3567 "BrowserScheduler", "RedirectNonUINonIOBrowserThreads") == "true";
3569 } 3568 }
3570 3569
3571 // static 3570 // static
3572 void ChromeContentBrowserClient::SetDefaultQuotaSettingsForTesting( 3571 void ChromeContentBrowserClient::SetDefaultQuotaSettingsForTesting(
3573 const storage::QuotaSettings* settings) { 3572 const storage::QuotaSettings* settings) {
3574 g_default_quota_settings = settings; 3573 g_default_quota_settings = settings;
3575 } 3574 }
OLDNEW
« no previous file with comments | « chrome/browser/chrome_browser_main.cc ('k') | chrome/browser/sessions/chrome_serialized_navigation_driver.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698