| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2013 Google Inc. All rights reserved. | 2 * Copyright (C) 2013 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 107 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 118 return false; | 118 return false; |
| 119 } | 119 } |
| 120 localName = type; | 120 localName = type; |
| 121 } | 121 } |
| 122 | 122 |
| 123 ASSERT(!tryCatch.HasCaught()); | 123 ASSERT(!tryCatch.HasCaught()); |
| 124 tagName = QualifiedName(nullAtom, localName, namespaceURI); | 124 tagName = QualifiedName(nullAtom, localName, namespaceURI); |
| 125 return true; | 125 return true; |
| 126 } | 126 } |
| 127 | 127 |
| 128 RawPtr<CustomElementLifecycleCallbacks> CustomElementConstructorBuilder::createC
allbacks() | 128 CustomElementLifecycleCallbacks* CustomElementConstructorBuilder::createCallback
s() |
| 129 { | 129 { |
| 130 ASSERT(!m_prototype.IsEmpty()); | 130 ASSERT(!m_prototype.IsEmpty()); |
| 131 | 131 |
| 132 v8::TryCatch exceptionCatcher(m_scriptState->isolate()); | 132 v8::TryCatch exceptionCatcher(m_scriptState->isolate()); |
| 133 exceptionCatcher.SetVerbose(true); | 133 exceptionCatcher.SetVerbose(true); |
| 134 | 134 |
| 135 v8::MaybeLocal<v8::Function> created = retrieveCallback("createdCallback"); | 135 v8::MaybeLocal<v8::Function> created = retrieveCallback("createdCallback"); |
| 136 v8::MaybeLocal<v8::Function> attached = retrieveCallback("attachedCallback")
; | 136 v8::MaybeLocal<v8::Function> attached = retrieveCallback("attachedCallback")
; |
| 137 v8::MaybeLocal<v8::Function> detached = retrieveCallback("detachedCallback")
; | 137 v8::MaybeLocal<v8::Function> detached = retrieveCallback("detachedCallback")
; |
| 138 v8::MaybeLocal<v8::Function> attributeChanged = retrieveCallback("attributeC
hangedCallback"); | 138 v8::MaybeLocal<v8::Function> attributeChanged = retrieveCallback("attributeC
hangedCallback"); |
| (...skipping 143 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 282 | 282 |
| 283 ExceptionState exceptionState(ExceptionState::ConstructionContext, "CustomEl
ement", info.Holder(), info.GetIsolate()); | 283 ExceptionState exceptionState(ExceptionState::ConstructionContext, "CustomEl
ement", info.Holder(), info.GetIsolate()); |
| 284 CustomElementProcessingStack::CallbackDeliveryScope deliveryScope; | 284 CustomElementProcessingStack::CallbackDeliveryScope deliveryScope; |
| 285 Element* element = document->createElementNS(namespaceURI, tagName, maybeTyp
e->IsNull() ? nullAtom : type, exceptionState); | 285 Element* element = document->createElementNS(namespaceURI, tagName, maybeTyp
e->IsNull() ? nullAtom : type, exceptionState); |
| 286 if (exceptionState.throwIfNeeded()) | 286 if (exceptionState.throwIfNeeded()) |
| 287 return; | 287 return; |
| 288 v8SetReturnValueFast(info, element, document); | 288 v8SetReturnValueFast(info, element, document); |
| 289 } | 289 } |
| 290 | 290 |
| 291 } // namespace blink | 291 } // namespace blink |
| OLD | NEW |