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

Side by Side Diff: Source/core/dom/Document.cpp

Issue 298893006: Split modules-dependent Event code in core. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 6 years, 7 months 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 unified diff | Download patch
« no previous file with comments | « Source/core/core_generated.gyp ('k') | Source/core/events/Event.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) 2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org)
3 * (C) 1999 Antti Koivisto (koivisto@kde.org) 3 * (C) 1999 Antti Koivisto (koivisto@kde.org)
4 * (C) 2001 Dirk Mueller (mueller@kde.org) 4 * (C) 2001 Dirk Mueller (mueller@kde.org)
5 * (C) 2006 Alexey Proskuryakov (ap@webkit.org) 5 * (C) 2006 Alexey Proskuryakov (ap@webkit.org)
6 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2011, 2012 Apple Inc. All r ights reserved. 6 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2011, 2012 Apple Inc. All r ights reserved.
7 * Copyright (C) 2008, 2009 Torch Mobile Inc. All rights reserved. (http://www.t orchmobile.com/) 7 * Copyright (C) 2008, 2009 Torch Mobile Inc. All rights reserved. (http://www.t orchmobile.com/)
8 * Copyright (C) 2008, 2009, 2011, 2012 Google Inc. All rights reserved. 8 * Copyright (C) 2008, 2009, 2011, 2012 Google Inc. All rights reserved.
9 * Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies) 9 * Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies)
10 * Copyright (C) Research In Motion Limited 2010-2011. All rights reserved. 10 * Copyright (C) Research In Motion Limited 2010-2011. All rights reserved.
(...skipping 3894 matching lines...) Expand 10 before | Expand all | Expand 10 after
3905 RefPtrWillBeRawPtr<Event> event = Event::create(EventTypeNames::resize); 3905 RefPtrWillBeRawPtr<Event> event = Event::create(EventTypeNames::resize);
3906 event->setTarget(domWindow()); 3906 event->setTarget(domWindow());
3907 ensureScriptedAnimationController().enqueuePerFrameEvent(event.release()); 3907 ensureScriptedAnimationController().enqueuePerFrameEvent(event.release());
3908 } 3908 }
3909 3909
3910 PassRefPtrWillBeRawPtr<Event> Document::createEvent(const String& eventType, Exc eptionState& exceptionState) 3910 PassRefPtrWillBeRawPtr<Event> Document::createEvent(const String& eventType, Exc eptionState& exceptionState)
3911 { 3911 {
3912 RefPtrWillBeRawPtr<Event> event = EventFactory::create(eventType); 3912 RefPtrWillBeRawPtr<Event> event = EventFactory::create(eventType);
3913 if (event) 3913 if (event)
3914 return event.release(); 3914 return event.release();
3915 event = EventModulesFactory::create(eventType); // TODO: move this to module s http://crbug.com/358074
3916 if (event)
3917 return event.release();
3915 3918
3916 exceptionState.throwDOMException(NotSupportedError, "The provided event type ('" + eventType + "') is invalid."); 3919 exceptionState.throwDOMException(NotSupportedError, "The provided event type ('" + eventType + "') is invalid.");
3917 return nullptr; 3920 return nullptr;
3918 } 3921 }
3919 3922
3920 void Document::addMutationEventListenerTypeIfEnabled(ListenerType listenerType) 3923 void Document::addMutationEventListenerTypeIfEnabled(ListenerType listenerType)
3921 { 3924 {
3922 if (ContextFeatures::mutationEventsEnabled(this)) 3925 if (ContextFeatures::mutationEventsEnabled(this))
3923 addListenerType(listenerType); 3926 addListenerType(listenerType);
3924 } 3927 }
(...skipping 1836 matching lines...) Expand 10 before | Expand all | Expand 10 after
5761 visitor->trace(m_timeline); 5764 visitor->trace(m_timeline);
5762 visitor->trace(m_compositorPendingAnimations); 5765 visitor->trace(m_compositorPendingAnimations);
5763 visitor->registerWeakMembers<Document, &Document::clearWeakMembers>(this); 5766 visitor->registerWeakMembers<Document, &Document::clearWeakMembers>(this);
5764 DocumentSupplementable::trace(visitor); 5767 DocumentSupplementable::trace(visitor);
5765 TreeScope::trace(visitor); 5768 TreeScope::trace(visitor);
5766 ContainerNode::trace(visitor); 5769 ContainerNode::trace(visitor);
5767 ExecutionContext::trace(visitor); 5770 ExecutionContext::trace(visitor);
5768 } 5771 }
5769 5772
5770 } // namespace WebCore 5773 } // namespace WebCore
OLDNEW
« no previous file with comments | « Source/core/core_generated.gyp ('k') | Source/core/events/Event.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698