Node::InsertionNotificationRequest HTMLAnchorElement::insertedInto(ContainerNode* insertionPoint) { if (insertionPoint->inDocument()) { V8DOMActivityLogger* activityLogger = V8DOMActivityLogger::currentActivityLoggerIfIsolatedWorld(); if (activityLogger) { Vector<String> argv; argv.append("a"); argv.append(fastGetAttribute(hrefAttr)); activityLogger->logEvent("blinkAddElement", argv.size(), argv.data()); } } return HTMLElement::insertedInto(insertionPoint); }
void HTMLAnchorElement::attributeWillChange(const QualifiedName& name, const AtomicString& oldValue, const AtomicString& newValue) { if (name == hrefAttr && inDocument()) { V8DOMActivityLogger* activityLogger = V8DOMActivityLogger::currentActivityLoggerIfIsolatedWorld(); if (activityLogger) { Vector<String> argv; argv.append("a"); argv.append(hrefAttr.toString()); argv.append(oldValue); argv.append(newValue); activityLogger->logEvent("blinkSetAttribute", argv.size(), argv.data()); } } HTMLElement::attributeWillChange(name, oldValue, newValue); }
bool EventTarget::addEventListenerInternal(const AtomicString& eventType, PassRefPtrWillBeRawPtr<EventListener> listener, const EventListenerOptions& options) { if (!listener) return false; V8DOMActivityLogger* activityLogger = V8DOMActivityLogger::currentActivityLoggerIfIsolatedWorld(); if (activityLogger) { Vector<String> argv; argv.append(toNode() ? toNode()->nodeName() : interfaceName()); argv.append(eventType); activityLogger->logEvent("blinkAddEventListener", argv.size(), argv.data()); } return ensureEventTargetData().eventListenerMap.add(eventType, listener, options); }
Node::InsertionNotificationRequest HTMLFormElement::insertedInto(ContainerNode* insertionPoint) { if (insertionPoint->inDocument()) { V8DOMActivityLogger* activityLogger = V8DOMActivityLogger::currentActivityLoggerIfIsolatedWorld(); if (activityLogger) { Vector<String> argv; argv.append("form"); argv.append(fastGetAttribute(methodAttr)); argv.append(fastGetAttribute(actionAttr)); activityLogger->logEvent("blinkAddElement", argv.size(), argv.data()); } } HTMLElement::insertedInto(insertionPoint); if (insertionPoint->inDocument()) this->document().didAssociateFormControl(this); return InsertionDone; }
Node::InsertionNotificationRequest HTMLScriptElement::insertedInto(ContainerNode* insertionPoint) { if (insertionPoint->inDocument()) { V8DOMActivityLogger* activityLogger = V8DOMActivityLogger::currentActivityLoggerIfIsolatedWorld(); if (activityLogger) { Vector<String> argv; argv.append("script"); argv.append(fastGetAttribute(srcAttr)); activityLogger->logEvent("blinkAddElement", argv.size(), argv.data()); } if (hasSourceAttribute() && !loader()->isScriptTypeSupported(ScriptLoader::DisallowLegacyTypeInTypeAttribute)) UseCounter::count(document(), UseCounter::ScriptElementWithInvalidTypeHasSrc); } HTMLElement::insertedInto(insertionPoint); return InsertionShouldCallDidNotifySubtreeInsertions; }
bool EventTarget::addEventListener(const AtomicString& eventType, PassRefPtr<EventListener> listener, bool useCapture) { // FIXME: listener null check should throw TypeError (and be done in // generated bindings), but breaks legacy content. http://crbug.com/249598 if (!listener) return false; V8DOMActivityLogger* activityLogger = V8DOMActivityLogger::currentActivityLoggerIfIsolatedWorld(); if (activityLogger) { Vector<String> argv; argv.append(toNode() ? toNode()->nodeName() : interfaceName()); argv.append(eventType); activityLogger->logEvent("blinkAddEventListener", argv.size(), argv.data()); } return ensureEventTargetData().eventListenerMap.add(eventType, listener, useCapture); }