Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(817)

Unified Diff: Source/core/dom/custom/CustomElementResolutionStep.cpp

Issue 106903007: Let unresolved custom element go through CustomElementCallbackQueue. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Updated Created 7 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: Source/core/dom/custom/CustomElementResolutionStep.cpp
diff --git a/Source/modules/mediastream/NavigatorUserMediaError.cpp b/Source/core/dom/custom/CustomElementResolutionStep.cpp
similarity index 77%
copy from Source/modules/mediastream/NavigatorUserMediaError.cpp
copy to Source/core/dom/custom/CustomElementResolutionStep.cpp
index e9cef28d55f28832dcf3cf43e3528dda82d29eec..24bc8d44d45ce46e5f24da72b160ceac1a339ffe 100644
--- a/Source/modules/mediastream/NavigatorUserMediaError.cpp
+++ b/Source/core/dom/custom/CustomElementResolutionStep.cpp
@@ -29,22 +29,21 @@
*/
#include "config.h"
-#include "modules/mediastream/NavigatorUserMediaError.h"
+#include "core/dom/custom/CustomElementResolutionStep.h"
+
+#include "core/dom/Element.h"
+#include "core/dom/custom/CustomElementRegistrationContext.h"
namespace WebCore {
-String NavigatorUserMediaError::name() const
+PassOwnPtr<CustomElementResolutionStep> CustomElementResolutionStep::create(const CustomElementDescriptor& descriptor)
{
- switch (m_name) {
- case NamePermissionDenied:
- return "PermissionDeniedError";
-
- case NameConstraintNotSatisfied:
- return "ConstraintNotSatisfiedError";
- }
+ return adoptPtr(new CustomElementResolutionStep(descriptor));
+}
- ASSERT_NOT_REACHED();
- return String();
+void CustomElementResolutionStep::dispatch(Element* element)
+{
+ element->document().registrationContext()->resolve(element, m_descriptor);
dominicc (has gone to gerrit) 2013/12/14 02:42:39 Looking up the registration context this way will
Hajime Morrita 2013/12/16 09:00:34 Done, added a test also.
}
} // namespace WebCore

Powered by Google App Engine
This is Rietveld 408576698