Stop calling Element::ensureShadowRoot() if it is used in construction phase.
authormorrita@google.com <morrita@google.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 9 Feb 2012 05:46:57 +0000 (05:46 +0000)
committermorrita@google.com <morrita@google.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 9 Feb 2012 05:46:57 +0000 (05:46 +0000)
commit6b18c3fd28d122713cec6cff7602414b660b8a38
treecd080c84658f25e9be9807bc1fcf8b8c9c59e274
parent3769bf8b35532523a502e223988aa772c800a7dd
Stop calling Element::ensureShadowRoot() if it is used in construction phase.
https://bugs.webkit.org/show_bug.cgi?id=77929

Patch by Shinya Kawanaka <shinyak@google.com> on 2012-02-08
Reviewed by Hajime Morita.

ShadowRoot's life cycle can be consufing If Element::ensureShadowRoot() is used.
So we want to remove Element::ensureShadowRoot().
This patch replaces Element::ensureShadowRoot() if it is used in object construction phase.

No new tests, no change in behavior.

* dom/ShadowRoot.cpp:
(WebCore::ShadowRoot::create):
  Initialize exception code before calling appendChild.
* html/HTMLDetailsElement.cpp:
(WebCore::HTMLDetailsElement::createShadowSubtree):
* html/HTMLKeygenElement.cpp:
(WebCore::HTMLKeygenElement::HTMLKeygenElement):
* html/HTMLMeterElement.cpp:
(WebCore::HTMLMeterElement::createShadowSubtree):
* html/HTMLProgressElement.cpp:
(WebCore::HTMLProgressElement::createShadowSubtree):
* html/HTMLSummaryElement.cpp:
(WebCore::HTMLSummaryElement::createShadowSubtree):
* html/HTMLTextAreaElement.cpp:
(WebCore::HTMLTextAreaElement::createShadowSubtree):

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@107178 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Source/WebCore/ChangeLog
Source/WebCore/dom/ShadowRoot.cpp
Source/WebCore/html/HTMLDetailsElement.cpp
Source/WebCore/html/HTMLKeygenElement.cpp
Source/WebCore/html/HTMLMeterElement.cpp
Source/WebCore/html/HTMLProgressElement.cpp
Source/WebCore/html/HTMLSummaryElement.cpp
Source/WebCore/html/HTMLTextAreaElement.cpp