| OLD | NEW |
| 1 // Copyright (c) 2009 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2009 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 #ifndef CHROME_BROWSER_RENDERER_HOST_SITE_INSTANCE_H_ | 5 #ifndef CHROME_BROWSER_RENDERER_HOST_SITE_INSTANCE_H_ |
| 6 #define CHROME_BROWSER_RENDERER_HOST_SITE_INSTANCE_H_ | 6 #define CHROME_BROWSER_RENDERER_HOST_SITE_INSTANCE_H_ |
| 7 #pragma once | 7 #pragma once |
| 8 | 8 |
| 9 #include "chrome/browser/renderer_host/render_process_host.h" | 9 #include "chrome/browser/renderer_host/render_process_host.h" |
| 10 #include "chrome/common/notification_observer.h" | 10 #include "chrome/common/notification_observer.h" |
| (...skipping 143 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 154 // extension as the host. This has the effect of grouping apps together in | 154 // extension as the host. This has the effect of grouping apps together in |
| 155 // a common SiteInstance. | 155 // a common SiteInstance. |
| 156 static GURL GetEffectiveURL(Profile* profile, const GURL& url); | 156 static GURL GetEffectiveURL(Profile* profile, const GURL& url); |
| 157 | 157 |
| 158 // Returns the type of renderer process this instance belongs in, for grouping | 158 // Returns the type of renderer process this instance belongs in, for grouping |
| 159 // purposes. | 159 // purposes. |
| 160 RenderProcessHost::Type GetRendererType(); | 160 RenderProcessHost::Type GetRendererType(); |
| 161 | 161 |
| 162 private: | 162 private: |
| 163 // NotificationObserver implementation. | 163 // NotificationObserver implementation. |
| 164 void Observe(NotificationType type, | 164 virtual void Observe(NotificationType type, |
| 165 const NotificationSource& source, | 165 const NotificationSource& source, |
| 166 const NotificationDetails& details); | 166 const NotificationDetails& details); |
| 167 | 167 |
| 168 NotificationRegistrar registrar_; | 168 NotificationRegistrar registrar_; |
| 169 | 169 |
| 170 // BrowsingInstance to which this SiteInstance belongs. | 170 // BrowsingInstance to which this SiteInstance belongs. |
| 171 scoped_refptr<BrowsingInstance> browsing_instance_; | 171 scoped_refptr<BrowsingInstance> browsing_instance_; |
| 172 | 172 |
| 173 // Factory for new RenderProcessHosts, not owned by this class. NULL indiactes | 173 // Factory for new RenderProcessHosts, not owned by this class. NULL indiactes |
| 174 // that the default BrowserRenderProcessHost should be created. | 174 // that the default BrowserRenderProcessHost should be created. |
| 175 const RenderProcessHostFactory* render_process_host_factory_; | 175 const RenderProcessHostFactory* render_process_host_factory_; |
| 176 | 176 |
| (...skipping 11 matching lines...) Expand all Loading... |
| 188 // The web site that this SiteInstance is rendering pages for. | 188 // The web site that this SiteInstance is rendering pages for. |
| 189 GURL site_; | 189 GURL site_; |
| 190 | 190 |
| 191 // Whether SetSite has been called. | 191 // Whether SetSite has been called. |
| 192 bool has_site_; | 192 bool has_site_; |
| 193 | 193 |
| 194 DISALLOW_COPY_AND_ASSIGN(SiteInstance); | 194 DISALLOW_COPY_AND_ASSIGN(SiteInstance); |
| 195 }; | 195 }; |
| 196 | 196 |
| 197 #endif // CHROME_BROWSER_RENDERER_HOST_SITE_INSTANCE_H_ | 197 #endif // CHROME_BROWSER_RENDERER_HOST_SITE_INSTANCE_H_ |
| OLD | NEW |