| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2012 Google Inc. All rights reserved. | 2 * Copyright (C) 2012 Google Inc. All rights reserved. |
| 3 * | 3 * |
| 4 * Redistribution and use in source and binary forms, with or without | 4 * Redistribution and use in source and binary forms, with or without |
| 5 * modification, are permitted provided that the following conditions are | 5 * modification, are permitted provided that the following conditions are |
| 6 * met: | 6 * met: |
| 7 * | 7 * |
| 8 * * Redistributions of source code must retain the above copyright | 8 * * Redistributions of source code must retain the above copyright |
| 9 * notice, this list of conditions and the following disclaimer. | 9 * notice, this list of conditions and the following disclaimer. |
| 10 * * Redistributions in binary form must reproduce the above | 10 * * Redistributions in binary form must reproduce the above |
| (...skipping 71 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 82 | 82 |
| 83 Entry& entryFor(ContextFeatures::FeatureType type) | 83 Entry& entryFor(ContextFeatures::FeatureType type) |
| 84 { | 84 { |
| 85 size_t index = static_cast<size_t>(type); | 85 size_t index = static_cast<size_t>(type); |
| 86 ASSERT_WITH_SECURITY_IMPLICATION(index < ContextFeatures::FeatureTypeSiz
e); | 86 ASSERT_WITH_SECURITY_IMPLICATION(index < ContextFeatures::FeatureTypeSiz
e); |
| 87 return m_entries[index]; | 87 return m_entries[index]; |
| 88 } | 88 } |
| 89 | 89 |
| 90 void validateAgainst(Document*); | 90 void validateAgainst(Document*); |
| 91 | 91 |
| 92 virtual void trace(Visitor* visitor) override |
| 93 { |
| 94 DocumentSupplement::trace(visitor); |
| 95 } |
| 96 |
| 92 private: | 97 private: |
| 93 String m_domain; | 98 String m_domain; |
| 94 Entry m_entries[ContextFeatures::FeatureTypeSize]; | 99 Entry m_entries[ContextFeatures::FeatureTypeSize]; |
| 95 }; | 100 }; |
| 96 | 101 |
| 97 const char* ContextFeaturesCache::supplementName() | 102 const char* ContextFeaturesCache::supplementName() |
| 98 { | 103 { |
| 99 return "ContextFeaturesCache"; | 104 return "ContextFeaturesCache"; |
| 100 } | 105 } |
| 101 | 106 |
| (...skipping 43 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 145 case ContextFeatures::MutationEvents: | 150 case ContextFeatures::MutationEvents: |
| 146 return frame->permissionClient()->allowMutationEvents(defaultValue); | 151 return frame->permissionClient()->allowMutationEvents(defaultValue); |
| 147 case ContextFeatures::PushState: | 152 case ContextFeatures::PushState: |
| 148 return frame->permissionClient()->allowPushState(); | 153 return frame->permissionClient()->allowPushState(); |
| 149 default: | 154 default: |
| 150 return defaultValue; | 155 return defaultValue; |
| 151 } | 156 } |
| 152 } | 157 } |
| 153 | 158 |
| 154 } // namespace blink | 159 } // namespace blink |
| OLD | NEW |