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

Side by Side Diff: chrome/browser/extensions/extension_process_manager.cc

Issue 11000027: Rename GetSite in SiteInstance to GetSiteURL. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years, 2 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 | Annotate | Revision Log
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 "base/bind.h" 5 #include "base/bind.h"
6 #include "base/command_line.h" 6 #include "base/command_line.h"
7 #include "base/lazy_instance.h" 7 #include "base/lazy_instance.h"
8 #include "base/logging.h" 8 #include "base/logging.h"
9 #include "base/message_loop.h" 9 #include "base/message_loop.h"
10 #include "base/metrics/histogram.h" 10 #include "base/metrics/histogram.h"
(...skipping 39 matching lines...) Expand 10 before | Expand all | Expand 10 after
50 using extensions::ExtensionHost; 50 using extensions::ExtensionHost;
51 51
52 namespace { 52 namespace {
53 53
54 std::string GetExtensionID(RenderViewHost* render_view_host) { 54 std::string GetExtensionID(RenderViewHost* render_view_host) {
55 // This works for both apps and extensions because the site has been 55 // This works for both apps and extensions because the site has been
56 // normalized to the extension URL for apps. 56 // normalized to the extension URL for apps.
57 if (!render_view_host->GetSiteInstance()) 57 if (!render_view_host->GetSiteInstance())
58 return ""; 58 return "";
59 59
60 return render_view_host->GetSiteInstance()->GetSite().host(); 60 return render_view_host->GetSiteInstance()->GetSiteURL().host();
61 } 61 }
62 62
63 // Incognito profiles use this process manager. It is mostly a shim that decides 63 // Incognito profiles use this process manager. It is mostly a shim that decides
64 // whether to fall back on the original profile's ExtensionProcessManager based 64 // whether to fall back on the original profile's ExtensionProcessManager based
65 // on whether a given extension uses "split" or "spanning" incognito behavior. 65 // on whether a given extension uses "split" or "spanning" incognito behavior.
66 class IncognitoExtensionProcessManager : public ExtensionProcessManager { 66 class IncognitoExtensionProcessManager : public ExtensionProcessManager {
67 public: 67 public:
68 explicit IncognitoExtensionProcessManager(Profile* profile); 68 explicit IncognitoExtensionProcessManager(Profile* profile);
69 virtual ~IncognitoExtensionProcessManager() {} 69 virtual ~IncognitoExtensionProcessManager() {}
70 virtual ExtensionHost* CreateViewHost( 70 virtual ExtensionHost* CreateViewHost(
(...skipping 744 matching lines...) Expand 10 before | Expand all | Expand 10 after
815 CreateBackgroundHostsForProfileStartup(GetProfile(), 815 CreateBackgroundHostsForProfileStartup(GetProfile(),
816 this, service->extensions()); 816 this, service->extensions());
817 } 817 }
818 break; 818 break;
819 } 819 }
820 default: 820 default:
821 ExtensionProcessManager::Observe(type, source, details); 821 ExtensionProcessManager::Observe(type, source, details);
822 break; 822 break;
823 } 823 }
824 } 824 }
OLDNEW
« no previous file with comments | « chrome/browser/chrome_content_browser_client.cc ('k') | chrome/browser/renderer_host/chrome_render_view_host_observer.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698