Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 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 CONTENT_COMMON_SITE_ISOLATION_POLICY_H_ | 5 #ifndef CONTENT_COMMON_SITE_ISOLATION_POLICY_H_ |
| 6 #define CONTENT_COMMON_SITE_ISOLATION_POLICY_H_ | 6 #define CONTENT_COMMON_SITE_ISOLATION_POLICY_H_ |
| 7 | 7 |
| 8 #include "base/macros.h" | 8 #include "base/macros.h" |
| 9 #include "content/common/content_export.h" | 9 #include "content/common/content_export.h" |
| 10 #include "url/gurl.h" | 10 #include "url/gurl.h" |
| (...skipping 19 matching lines...) Expand all Loading... | |
| 30 // | 30 // |
| 31 // Instead of calling this method, prefer to examine object state to see | 31 // Instead of calling this method, prefer to examine object state to see |
| 32 // whether a particular frame happens to have a cross-process relationship | 32 // whether a particular frame happens to have a cross-process relationship |
| 33 // with another, or to consult DoesSiteRequireDedicatedProcess() to see if a | 33 // with another, or to consult DoesSiteRequireDedicatedProcess() to see if a |
| 34 // particular site merits protection. | 34 // particular site merits protection. |
| 35 static bool AreCrossProcessFramesPossible(); | 35 static bool AreCrossProcessFramesPossible(); |
| 36 | 36 |
| 37 // Returns true if every site should be placed in a dedicated process. | 37 // Returns true if every site should be placed in a dedicated process. |
| 38 static bool UseDedicatedProcessesForAllSites(); | 38 static bool UseDedicatedProcessesForAllSites(); |
| 39 | 39 |
| 40 // Returns true if third-party subframes of a page should be kept in a | |
| 41 // different process from the main frame. | |
| 42 static bool UseDedicatedProcessForTopDocument(); | |
|
Charlie Reis
2016/03/18 21:15:13
IsTopDocumentIsolationEnabled or something similar
| |
| 43 | |
| 40 // Returns true if navigation and history code should maintain per-frame | 44 // Returns true if navigation and history code should maintain per-frame |
| 41 // navigation entries. This is an in-progress feature related to site | 45 // navigation entries. This is an in-progress feature related to site |
| 42 // isolation, so the return value is currently tied to --site-per-process. | 46 // isolation, so the return value is currently tied to --site-per-process. |
| 43 // TODO(creis, avi): Make this the default, and eliminate this. | 47 // TODO(creis, avi): Make this the default, and eliminate this. |
| 44 static bool UseSubframeNavigationEntries(); | 48 static bool UseSubframeNavigationEntries(); |
| 45 | 49 |
| 46 private: | 50 private: |
| 47 SiteIsolationPolicy(); // Not instantiable. | 51 SiteIsolationPolicy(); // Not instantiable. |
| 48 | 52 |
| 49 DISALLOW_COPY_AND_ASSIGN(SiteIsolationPolicy); | 53 DISALLOW_COPY_AND_ASSIGN(SiteIsolationPolicy); |
| 50 }; | 54 }; |
| 51 | 55 |
| 52 } // namespace content | 56 } // namespace content |
| 53 | 57 |
| 54 #endif // CONTENT_COMMON_SITE_ISOLATION_POLICY_H_ | 58 #endif // CONTENT_COMMON_SITE_ISOLATION_POLICY_H_ |
| OLD | NEW |