| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2011 Google Inc. All rights reserved. | 2 * Copyright (C) 2011 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 * * Neither the name of Google Inc. nor the names of its | 10 * * Neither the name of Google Inc. nor the names of its |
| (...skipping 97 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 108 return createMarkup(this, ChildrenOnly); | 108 return createMarkup(this, ChildrenOnly); |
| 109 } | 109 } |
| 110 | 110 |
| 111 void ShadowRoot::setInnerHTML(const String& markup, ExceptionState& exceptionSta
te) | 111 void ShadowRoot::setInnerHTML(const String& markup, ExceptionState& exceptionSta
te) |
| 112 { | 112 { |
| 113 if (isOrphan()) { | 113 if (isOrphan()) { |
| 114 exceptionState.throwDOMException(InvalidAccessError, "The ShadowRoot doe
s not have a host."); | 114 exceptionState.throwDOMException(InvalidAccessError, "The ShadowRoot doe
s not have a host."); |
| 115 return; | 115 return; |
| 116 } | 116 } |
| 117 | 117 |
| 118 if (RefPtrWillBeRawPtr<DocumentFragment> fragment = createFragmentForInnerOu
terHTML(markup, host(), AllowScriptingContent, "innerHTML", exceptionState)) | 118 if (RefPtrWillBeRawPtr<DocumentFragment> fragment = createFragmentForInnerOu
terHTML(markup, host(), "innerHTML", exceptionState)) |
| 119 replaceChildrenWithFragment(this, fragment.release(), exceptionState); | 119 replaceChildrenWithFragment(this, fragment.release(), exceptionState); |
| 120 } | 120 } |
| 121 | 121 |
| 122 void ShadowRoot::recalcStyle(StyleRecalcChange change) | 122 void ShadowRoot::recalcStyle(StyleRecalcChange change) |
| 123 { | 123 { |
| 124 // ShadowRoot doesn't support custom callbacks. | 124 // ShadowRoot doesn't support custom callbacks. |
| 125 ASSERT(!hasCustomStyleCallbacks()); | 125 ASSERT(!hasCustomStyleCallbacks()); |
| 126 | 126 |
| 127 if (styleChangeType() >= SubtreeStyleChange) | 127 if (styleChangeType() >= SubtreeStyleChange) |
| 128 change = Force; | 128 change = Force; |
| (...skipping 182 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 311 void ShadowRoot::trace(Visitor* visitor) | 311 void ShadowRoot::trace(Visitor* visitor) |
| 312 { | 312 { |
| 313 visitor->trace(m_prev); | 313 visitor->trace(m_prev); |
| 314 visitor->trace(m_next); | 314 visitor->trace(m_next); |
| 315 visitor->trace(m_shadowRootRareData); | 315 visitor->trace(m_shadowRootRareData); |
| 316 TreeScope::trace(visitor); | 316 TreeScope::trace(visitor); |
| 317 DocumentFragment::trace(visitor); | 317 DocumentFragment::trace(visitor); |
| 318 } | 318 } |
| 319 | 319 |
| 320 } | 320 } |
| OLD | NEW |