summaryrefslogtreecommitdiffstats
path: root/third_party/WebKit/Source
diff options
context:
space:
mode:
authortkent@chromium.org <tkent@chromium.org@bbb929c8-8fbe-4397-9dbb-9b2b20218538>2013-08-30 02:09:49 +0000
committertkent@chromium.org <tkent@chromium.org@bbb929c8-8fbe-4397-9dbb-9b2b20218538>2013-08-30 02:09:49 +0000
commitf3aa39934f8a1e0b19ce0a2f82bd083d68f79520 (patch)
tree9368d9db49ab1e5fa05167d09cc7335d9c5db86d /third_party/WebKit/Source
parent47efada1670781d342502aa75bca58337fdf4b0d (diff)
downloadchromium_src-f3aa39934f8a1e0b19ce0a2f82bd083d68f79520.zip
chromium_src-f3aa39934f8a1e0b19ce0a2f82bd083d68f79520.tar.gz
chromium_src-f3aa39934f8a1e0b19ce0a2f82bd083d68f79520.tar.bz2
Refactoring: Remove Event::create(const AtomicString&, bool, bool).
Add Event::createCancelableBubble(), and replace all of existing call sites of Event::create with bool arguments with new factory functions. BUG=none TEST=none; no behavior changes. Review URL: https://chromiumcodereview.appspot.com/23490016 git-svn-id: svn://svn.chromium.org/blink/trunk@156949 bbb929c8-8fbe-4397-9dbb-9b2b20218538
Diffstat (limited to 'third_party/WebKit/Source')
-rw-r--r--third_party/WebKit/Source/core/dom/DocumentEventQueue.cpp3
-rw-r--r--third_party/WebKit/Source/core/dom/Event.h4
-rw-r--r--third_party/WebKit/Source/core/editing/FrameSelection.cpp6
-rw-r--r--third_party/WebKit/Source/core/html/HTMLFormElement.cpp6
-rw-r--r--third_party/WebKit/Source/core/html/HTMLMediaElement.cpp12
-rw-r--r--third_party/WebKit/Source/core/html/parser/HTMLScriptRunner.cpp2
-rw-r--r--third_party/WebKit/Source/core/page/EventHandler.cpp4
-rw-r--r--third_party/WebKit/Source/core/page/FocusController.cpp6
-rw-r--r--third_party/WebKit/Source/core/page/Page.cpp2
-rw-r--r--third_party/WebKit/Source/modules/encryptedmedia/MediaKeySession.cpp4
-rw-r--r--third_party/WebKit/Source/modules/indexeddb/IDBDatabase.cpp2
-rw-r--r--third_party/WebKit/Source/modules/indexeddb/IDBOpenDBRequest.cpp2
-rw-r--r--third_party/WebKit/Source/modules/indexeddb/IDBRequest.cpp4
-rw-r--r--third_party/WebKit/Source/modules/indexeddb/IDBTransaction.cpp2
-rw-r--r--third_party/WebKit/Source/modules/mediasource/MediaSourceBase.cpp2
-rw-r--r--third_party/WebKit/Source/modules/mediasource/SourceBuffer.cpp2
-rw-r--r--third_party/WebKit/Source/modules/mediasource/SourceBufferList.cpp2
-rw-r--r--third_party/WebKit/Source/modules/mediasource/WebKitSourceBufferList.cpp2
-rw-r--r--third_party/WebKit/Source/modules/notifications/Notification.cpp10
-rw-r--r--third_party/WebKit/Source/modules/speech/SpeechRecognition.cpp16
-rw-r--r--third_party/WebKit/Source/modules/webaudio/AudioScheduledSourceNode.cpp2
-rw-r--r--third_party/WebKit/Source/web/ApplicationCacheHost.cpp2
22 files changed, 48 insertions, 49 deletions
diff --git a/third_party/WebKit/Source/core/dom/DocumentEventQueue.cpp b/third_party/WebKit/Source/core/dom/DocumentEventQueue.cpp
index 8768c1e..2165a9c 100644
--- a/third_party/WebKit/Source/core/dom/DocumentEventQueue.cpp
+++ b/third_party/WebKit/Source/core/dom/DocumentEventQueue.cpp
@@ -84,8 +84,7 @@ void DocumentEventQueue::enqueueOrDispatchScrollEvent(PassRefPtr<Node> target, S
return;
// Per the W3C CSSOM View Module, scroll events fired at the document should bubble, others should not.
- bool canBubble = targetType == ScrollEventDocumentTarget;
- RefPtr<Event> scrollEvent = Event::create(eventNames().scrollEvent, canBubble, false /* non cancelleable */);
+ RefPtr<Event> scrollEvent = targetType == ScrollEventDocumentTarget ? Event::createBubble(eventNames().scrollEvent) : Event::create(eventNames().scrollEvent);
if (!m_nodesWithQueuedScrollEvents.add(target.get()).isNewEntry)
return;
diff --git a/third_party/WebKit/Source/core/dom/Event.h b/third_party/WebKit/Source/core/dom/Event.h
index f867528..56dd5f9 100644
--- a/third_party/WebKit/Source/core/dom/Event.h
+++ b/third_party/WebKit/Source/core/dom/Event.h
@@ -92,9 +92,9 @@ public:
{
return adoptRef(new Event(type, true, false));
}
- static PassRefPtr<Event> create(const AtomicString& type, bool canBubble, bool cancelable)
+ static PassRefPtr<Event> createCancelableBubble(const AtomicString& type)
{
- return adoptRef(new Event(type, canBubble, cancelable));
+ return adoptRef(new Event(type, true, true));
}
static PassRefPtr<Event> create(const AtomicString& type, const EventInit& initializer)
diff --git a/third_party/WebKit/Source/core/editing/FrameSelection.cpp b/third_party/WebKit/Source/core/editing/FrameSelection.cpp
index 026e1fa..ea5fb2b 100644
--- a/third_party/WebKit/Source/core/editing/FrameSelection.cpp
+++ b/third_party/WebKit/Source/core/editing/FrameSelection.cpp
@@ -300,7 +300,7 @@ void FrameSelection::setSelection(const VisibleSelection& newSelection, SetSelec
}
notifyAccessibilityForSelectionChange();
- m_frame->document()->enqueueDocumentEvent(Event::create(eventNames().selectionchangeEvent, false, false));
+ m_frame->document()->enqueueDocumentEvent(Event::create(eventNames().selectionchangeEvent));
}
static bool removingNodeRemovesPosition(Node* node, const Position& position)
@@ -1445,7 +1445,7 @@ void FrameSelection::selectAll()
if (!root)
return;
- if (selectStartTarget && !selectStartTarget->dispatchEvent(Event::create(eventNames().selectstartEvent, true, true)))
+ if (selectStartTarget && !selectStartTarget->dispatchEvent(Event::createCancelableBubble(eventNames().selectstartEvent)))
return;
VisibleSelection newSelection(VisibleSelection::selectionFromContentsOfNode(root.get()));
@@ -1890,7 +1890,7 @@ bool FrameSelection::dispatchSelectStart()
if (!selectStartTarget)
return true;
- return selectStartTarget->dispatchEvent(Event::create(eventNames().selectstartEvent, true, true));
+ return selectStartTarget->dispatchEvent(Event::createCancelableBubble(eventNames().selectstartEvent));
}
inline bool FrameSelection::visualWordMovementEnabled() const
diff --git a/third_party/WebKit/Source/core/html/HTMLFormElement.cpp b/third_party/WebKit/Source/core/html/HTMLFormElement.cpp
index d86650c..1783d82 100644
--- a/third_party/WebKit/Source/core/html/HTMLFormElement.cpp
+++ b/third_party/WebKit/Source/core/html/HTMLFormElement.cpp
@@ -275,7 +275,7 @@ bool HTMLFormElement::prepareForSubmission(Event* event)
RefPtr<FormState> formState = FormState::create(this, controlNamesAndValues, document(), NotSubmittedByJavaScript);
frame->loader()->client()->dispatchWillSendSubmitEvent(formState.release());
- if (dispatchEvent(Event::create(eventNames().submitEvent, true, true)))
+ if (dispatchEvent(Event::createCancelableBubble(eventNames().submitEvent)))
m_shouldSubmit = true;
m_isSubmittingOrPreparingForSubmission = false;
@@ -391,7 +391,7 @@ void HTMLFormElement::reset()
m_isInResetFunction = true;
- if (!dispatchEvent(Event::create(eventNames().resetEvent, true, true))) {
+ if (!dispatchEvent(Event::createCancelableBubble(eventNames().resetEvent))) {
m_isInResetFunction = false;
return;
}
@@ -425,7 +425,7 @@ void HTMLFormElement::finishRequestAutocomplete(AutocompleteResult result)
{
RefPtr<Event> event;
if (result == AutocompleteResultSuccess)
- event = Event::create(eventNames().autocompleteEvent, false, false);
+ event = Event::create(eventNames().autocompleteEvent);
else if (result == AutocompleteResultErrorDisabled)
event = AutocompleteErrorEvent::create("disabled");
else if (result == AutocompleteResultErrorCancel)
diff --git a/third_party/WebKit/Source/core/html/HTMLMediaElement.cpp b/third_party/WebKit/Source/core/html/HTMLMediaElement.cpp
index 626022e..2779957 100644
--- a/third_party/WebKit/Source/core/html/HTMLMediaElement.cpp
+++ b/third_party/WebKit/Source/core/html/HTMLMediaElement.cpp
@@ -1119,18 +1119,18 @@ void HTMLMediaElement::updateActiveTextTrackCues(double movieTime)
// correctly identifies the type of the event, if the startTime is
// less than the endTime in the cue.
if (eventTasks[i].second->startTime() >= eventTasks[i].second->endTime()) {
- event = Event::create(eventNames().enterEvent, false, false);
+ event = Event::create(eventNames().enterEvent);
event->setTarget(eventTasks[i].second);
m_asyncEventQueue->enqueueEvent(event.release());
- event = Event::create(eventNames().exitEvent, false, false);
+ event = Event::create(eventNames().exitEvent);
event->setTarget(eventTasks[i].second);
m_asyncEventQueue->enqueueEvent(event.release());
} else {
if (eventTasks[i].first == eventTasks[i].second->startTime())
- event = Event::create(eventNames().enterEvent, false, false);
+ event = Event::create(eventNames().enterEvent);
else
- event = Event::create(eventNames().exitEvent, false, false);
+ event = Event::create(eventNames().exitEvent);
event->setTarget(eventTasks[i].second);
m_asyncEventQueue->enqueueEvent(event.release());
@@ -1144,7 +1144,7 @@ void HTMLMediaElement::updateActiveTextTrackCues(double movieTime)
// 15 - For each text track in affected tracks, in the list order, queue a
// task to fire a simple event named cuechange at the TextTrack object, and, ...
for (size_t i = 0; i < affectedTracks.size(); ++i) {
- RefPtr<Event> event = Event::create(eventNames().cuechangeEvent, false, false);
+ RefPtr<Event> event = Event::create(eventNames().cuechangeEvent);
event->setTarget(affectedTracks[i]);
m_asyncEventQueue->enqueueEvent(event.release());
@@ -1152,7 +1152,7 @@ void HTMLMediaElement::updateActiveTextTrackCues(double movieTime)
// ... if the text track has a corresponding track element, to then fire a
// simple event named cuechange at the track element as well.
if (affectedTracks[i]->trackType() == TextTrack::TrackElement) {
- RefPtr<Event> event = Event::create(eventNames().cuechangeEvent, false, false);
+ RefPtr<Event> event = Event::create(eventNames().cuechangeEvent);
HTMLTrackElement* trackElement = static_cast<LoadableTextTrack*>(affectedTracks[i])->trackElement();
ASSERT(trackElement);
event->setTarget(trackElement);
diff --git a/third_party/WebKit/Source/core/html/parser/HTMLScriptRunner.cpp b/third_party/WebKit/Source/core/html/parser/HTMLScriptRunner.cpp
index 9fd7510..f03d204 100644
--- a/third_party/WebKit/Source/core/html/parser/HTMLScriptRunner.cpp
+++ b/third_party/WebKit/Source/core/html/parser/HTMLScriptRunner.cpp
@@ -81,7 +81,7 @@ static KURL documentURLForScriptExecution(Document* document)
inline PassRefPtr<Event> createScriptLoadEvent()
{
- return Event::create(eventNames().loadEvent, false, false);
+ return Event::create(eventNames().loadEvent);
}
ScriptSourceCode HTMLScriptRunner::sourceFromPendingScript(const PendingScript& script, bool& errorOccurred) const
diff --git a/third_party/WebKit/Source/core/page/EventHandler.cpp b/third_party/WebKit/Source/core/page/EventHandler.cpp
index 453825b..3a2002d 100644
--- a/third_party/WebKit/Source/core/page/EventHandler.cpp
+++ b/third_party/WebKit/Source/core/page/EventHandler.cpp
@@ -379,7 +379,7 @@ static inline bool dispatchSelectStart(Node* node)
if (!node || !node->renderer())
return true;
- return node->dispatchEvent(Event::create(eventNames().selectstartEvent, true, true));
+ return node->dispatchEvent(Event::createCancelableBubble(eventNames().selectstartEvent));
}
static VisibleSelection expandSelectionToRespectUserSelectAll(Node* targetNode, const VisibleSelection& selection)
@@ -3466,7 +3466,7 @@ void EventHandler::capsLockStateMayHaveChanged()
void EventHandler::sendResizeEvent()
{
- m_frame->document()->enqueueWindowEvent(Event::create(eventNames().resizeEvent, false, false));
+ m_frame->document()->enqueueWindowEvent(Event::create(eventNames().resizeEvent));
}
void EventHandler::sendScrollEvent()
diff --git a/third_party/WebKit/Source/core/page/FocusController.cpp b/third_party/WebKit/Source/core/page/FocusController.cpp
index 0e7540a..94bbad0 100644
--- a/third_party/WebKit/Source/core/page/FocusController.cpp
+++ b/third_party/WebKit/Source/core/page/FocusController.cpp
@@ -137,7 +137,7 @@ static inline void dispatchEventsOnWindowAndFocusedNode(Document* document, bool
if (!focused && document->focusedElement())
document->focusedElement()->dispatchBlurEvent(0);
- document->dispatchWindowEvent(Event::create(focused ? eventNames().focusEvent : eventNames().blurEvent, false, false));
+ document->dispatchWindowEvent(Event::create(focused ? eventNames().focusEvent : eventNames().blurEvent));
if (focused && document->focusedElement())
document->focusedElement()->dispatchFocusEvent(0, FocusDirectionPage);
}
@@ -222,12 +222,12 @@ void FocusController::setFocusedFrame(PassRefPtr<Frame> frame)
// Now that the frame is updated, fire events and update the selection focused states of both frames.
if (oldFrame && oldFrame->view()) {
oldFrame->selection()->setFocused(false);
- oldFrame->document()->dispatchWindowEvent(Event::create(eventNames().blurEvent, false, false));
+ oldFrame->document()->dispatchWindowEvent(Event::create(eventNames().blurEvent));
}
if (newFrame && newFrame->view() && isFocused()) {
newFrame->selection()->setFocused(true);
- newFrame->document()->dispatchWindowEvent(Event::create(eventNames().focusEvent, false, false));
+ newFrame->document()->dispatchWindowEvent(Event::create(eventNames().focusEvent));
}
m_isChangingFocusedFrame = false;
diff --git a/third_party/WebKit/Source/core/page/Page.cpp b/third_party/WebKit/Source/core/page/Page.cpp
index 37b360d..82a710c 100644
--- a/third_party/WebKit/Source/core/page/Page.cpp
+++ b/third_party/WebKit/Source/core/page/Page.cpp
@@ -78,7 +78,7 @@ static void networkStateChanged()
AtomicString eventName = networkStateNotifier().onLine() ? eventNames().onlineEvent : eventNames().offlineEvent;
for (unsigned i = 0; i < frames.size(); i++)
- frames[i]->document()->dispatchWindowEvent(Event::create(eventName, false, false));
+ frames[i]->document()->dispatchWindowEvent(Event::create(eventName));
}
float deviceScaleFactor(Frame* frame)
diff --git a/third_party/WebKit/Source/modules/encryptedmedia/MediaKeySession.cpp b/third_party/WebKit/Source/modules/encryptedmedia/MediaKeySession.cpp
index 549945c..21bc97a3 100644
--- a/third_party/WebKit/Source/modules/encryptedmedia/MediaKeySession.cpp
+++ b/third_party/WebKit/Source/modules/encryptedmedia/MediaKeySession.cpp
@@ -149,7 +149,7 @@ void MediaKeySession::addKeyTimerFired(Timer<MediaKeySession>*)
void MediaKeySession::keyAdded()
{
- RefPtr<Event> event = Event::create(eventNames().webkitkeyaddedEvent, false, false);
+ RefPtr<Event> event = Event::create(eventNames().webkitkeyaddedEvent);
event->setTarget(this);
m_asyncEventQueue->enqueueEvent(event.release());
}
@@ -174,7 +174,7 @@ void MediaKeySession::keyError(MediaKeyErrorCode errorCode, unsigned long system
m_error = MediaKeyError::create(mediaKeyErrorCode, systemCode);
// 3. queue a task to fire a simple event named keyerror at the MediaKeySession object.
- RefPtr<Event> event = Event::create(eventNames().webkitkeyerrorEvent, false, false);
+ RefPtr<Event> event = Event::create(eventNames().webkitkeyerrorEvent);
event->setTarget(this);
m_asyncEventQueue->enqueueEvent(event.release());
}
diff --git a/third_party/WebKit/Source/modules/indexeddb/IDBDatabase.cpp b/third_party/WebKit/Source/modules/indexeddb/IDBDatabase.cpp
index 2701a24..c36692e 100644
--- a/third_party/WebKit/Source/modules/indexeddb/IDBDatabase.cpp
+++ b/third_party/WebKit/Source/modules/indexeddb/IDBDatabase.cpp
@@ -307,7 +307,7 @@ void IDBDatabase::forceClose()
for (TransactionMap::const_iterator::Values it = m_transactions.begin().values(), end = m_transactions.end().values(); it != end; ++it)
(*it)->abort(IGNORE_EXCEPTION);
this->close();
- enqueueEvent(Event::create(eventNames().closeEvent, false, false));
+ enqueueEvent(Event::create(eventNames().closeEvent));
}
void IDBDatabase::close()
diff --git a/third_party/WebKit/Source/modules/indexeddb/IDBOpenDBRequest.cpp b/third_party/WebKit/Source/modules/indexeddb/IDBOpenDBRequest.cpp
index 407062d..5e97675 100644
--- a/third_party/WebKit/Source/modules/indexeddb/IDBOpenDBRequest.cpp
+++ b/third_party/WebKit/Source/modules/indexeddb/IDBOpenDBRequest.cpp
@@ -132,7 +132,7 @@ void IDBOpenDBRequest::onSuccess(PassRefPtr<IDBDatabaseBackendInterface> prpBack
m_result = IDBAny::create(idbDatabase.get());
}
idbDatabase->setMetadata(metadata);
- enqueueEvent(Event::create(eventNames().successEvent, false, false));
+ enqueueEvent(Event::create(eventNames().successEvent));
}
bool IDBOpenDBRequest::shouldEnqueueEvent() const
diff --git a/third_party/WebKit/Source/modules/indexeddb/IDBRequest.cpp b/third_party/WebKit/Source/modules/indexeddb/IDBRequest.cpp
index 795e157..2ae6069 100644
--- a/third_party/WebKit/Source/modules/indexeddb/IDBRequest.cpp
+++ b/third_party/WebKit/Source/modules/indexeddb/IDBRequest.cpp
@@ -244,12 +244,12 @@ void IDBRequest::onError(PassRefPtr<DOMError> error)
m_error = error;
m_pendingCursor.clear();
- enqueueEvent(Event::create(eventNames().errorEvent, true, true));
+ enqueueEvent(Event::createCancelableBubble(eventNames().errorEvent));
}
static PassRefPtr<Event> createSuccessEvent()
{
- return Event::create(eventNames().successEvent, false, false);
+ return Event::create(eventNames().successEvent);
}
void IDBRequest::onSuccess(const Vector<String>& stringList)
diff --git a/third_party/WebKit/Source/modules/indexeddb/IDBTransaction.cpp b/third_party/WebKit/Source/modules/indexeddb/IDBTransaction.cpp
index e492423..bcbb4be 100644
--- a/third_party/WebKit/Source/modules/indexeddb/IDBTransaction.cpp
+++ b/third_party/WebKit/Source/modules/indexeddb/IDBTransaction.cpp
@@ -319,7 +319,7 @@ void IDBTransaction::onComplete()
closeOpenCursors();
// Enqueue events before notifying database, as database may close which enqueues more events and order matters.
- enqueueEvent(Event::create(eventNames().completeEvent, false, false));
+ enqueueEvent(Event::create(eventNames().completeEvent));
m_database->transactionFinished(this);
}
diff --git a/third_party/WebKit/Source/modules/mediasource/MediaSourceBase.cpp b/third_party/WebKit/Source/modules/mediasource/MediaSourceBase.cpp
index 420ddd8..9f99961 100644
--- a/third_party/WebKit/Source/modules/mediasource/MediaSourceBase.cpp
+++ b/third_party/WebKit/Source/modules/mediasource/MediaSourceBase.cpp
@@ -289,7 +289,7 @@ void MediaSourceBase::scheduleEvent(const AtomicString& eventName)
{
ASSERT(m_asyncEventQueue);
- RefPtr<Event> event = Event::create(eventName, false, false);
+ RefPtr<Event> event = Event::create(eventName);
event->setTarget(this);
m_asyncEventQueue->enqueueEvent(event.release());
diff --git a/third_party/WebKit/Source/modules/mediasource/SourceBuffer.cpp b/third_party/WebKit/Source/modules/mediasource/SourceBuffer.cpp
index 5cf1e16..6b9646e 100644
--- a/third_party/WebKit/Source/modules/mediasource/SourceBuffer.cpp
+++ b/third_party/WebKit/Source/modules/mediasource/SourceBuffer.cpp
@@ -359,7 +359,7 @@ void SourceBuffer::scheduleEvent(const AtomicString& eventName)
{
ASSERT(m_asyncEventQueue);
- RefPtr<Event> event = Event::create(eventName, false, false);
+ RefPtr<Event> event = Event::create(eventName);
event->setTarget(this);
m_asyncEventQueue->enqueueEvent(event.release());
diff --git a/third_party/WebKit/Source/modules/mediasource/SourceBufferList.cpp b/third_party/WebKit/Source/modules/mediasource/SourceBufferList.cpp
index ee0aa7d..948a19b 100644
--- a/third_party/WebKit/Source/modules/mediasource/SourceBufferList.cpp
+++ b/third_party/WebKit/Source/modules/mediasource/SourceBufferList.cpp
@@ -74,7 +74,7 @@ void SourceBufferList::scheduleEvent(const AtomicString& eventName)
{
ASSERT(m_asyncEventQueue);
- RefPtr<Event> event = Event::create(eventName, false, false);
+ RefPtr<Event> event = Event::create(eventName);
event->setTarget(this);
m_asyncEventQueue->enqueueEvent(event.release());
diff --git a/third_party/WebKit/Source/modules/mediasource/WebKitSourceBufferList.cpp b/third_party/WebKit/Source/modules/mediasource/WebKitSourceBufferList.cpp
index a949c8e..6639a133 100644
--- a/third_party/WebKit/Source/modules/mediasource/WebKitSourceBufferList.cpp
+++ b/third_party/WebKit/Source/modules/mediasource/WebKitSourceBufferList.cpp
@@ -86,7 +86,7 @@ void WebKitSourceBufferList::createAndFireEvent(const AtomicString& eventName)
{
ASSERT(m_asyncEventQueue);
- RefPtr<Event> event = Event::create(eventName, false, false);
+ RefPtr<Event> event = Event::create(eventName);
event->setTarget(this);
m_asyncEventQueue->enqueueEvent(event.release());
diff --git a/third_party/WebKit/Source/modules/notifications/Notification.cpp b/third_party/WebKit/Source/modules/notifications/Notification.cpp
index a2d0c8d..01a3c7e 100644
--- a/third_party/WebKit/Source/modules/notifications/Notification.cpp
+++ b/third_party/WebKit/Source/modules/notifications/Notification.cpp
@@ -200,27 +200,27 @@ void Notification::finalize()
void Notification::dispatchShowEvent()
{
#if ENABLE(LEGACY_NOTIFICATIONS)
- dispatchEvent(Event::create(eventNames().displayEvent, false, false));
+ dispatchEvent(Event::create(eventNames().displayEvent));
#endif
- dispatchEvent(Event::create(eventNames().showEvent, false, false));
+ dispatchEvent(Event::create(eventNames().showEvent));
}
void Notification::dispatchClickEvent()
{
UserGestureIndicator gestureIndicator(DefinitelyProcessingNewUserGesture);
WindowFocusAllowedIndicator windowFocusAllowed;
- dispatchEvent(Event::create(eventNames().clickEvent, false, false));
+ dispatchEvent(Event::create(eventNames().clickEvent));
}
void Notification::dispatchCloseEvent()
{
- dispatchEvent(Event::create(eventNames().closeEvent, false, false));
+ dispatchEvent(Event::create(eventNames().closeEvent));
finalize();
}
void Notification::dispatchErrorEvent()
{
- dispatchEvent(Event::create(eventNames().errorEvent, false, false));
+ dispatchEvent(Event::create(eventNames().errorEvent));
}
#if ENABLE(NOTIFICATIONS)
diff --git a/third_party/WebKit/Source/modules/speech/SpeechRecognition.cpp b/third_party/WebKit/Source/modules/speech/SpeechRecognition.cpp
index 07b1ee0..d60e9b0 100644
--- a/third_party/WebKit/Source/modules/speech/SpeechRecognition.cpp
+++ b/third_party/WebKit/Source/modules/speech/SpeechRecognition.cpp
@@ -79,32 +79,32 @@ void SpeechRecognition::abort()
void SpeechRecognition::didStartAudio()
{
- dispatchEvent(Event::create(eventNames().audiostartEvent, /*canBubble=*/false, /*cancelable=*/false));
+ dispatchEvent(Event::create(eventNames().audiostartEvent));
}
void SpeechRecognition::didStartSound()
{
- dispatchEvent(Event::create(eventNames().soundstartEvent, /*canBubble=*/false, /*cancelable=*/false));
+ dispatchEvent(Event::create(eventNames().soundstartEvent));
}
void SpeechRecognition::didStartSpeech()
{
- dispatchEvent(Event::create(eventNames().speechstartEvent, /*canBubble=*/false, /*cancelable=*/false));
+ dispatchEvent(Event::create(eventNames().speechstartEvent));
}
void SpeechRecognition::didEndSpeech()
{
- dispatchEvent(Event::create(eventNames().speechendEvent, /*canBubble=*/false, /*cancelable=*/false));
+ dispatchEvent(Event::create(eventNames().speechendEvent));
}
void SpeechRecognition::didEndSound()
{
- dispatchEvent(Event::create(eventNames().soundendEvent, /*canBubble=*/false, /*cancelable=*/false));
+ dispatchEvent(Event::create(eventNames().soundendEvent));
}
void SpeechRecognition::didEndAudio()
{
- dispatchEvent(Event::create(eventNames().audioendEvent, /*canBubble=*/false, /*cancelable=*/false));
+ dispatchEvent(Event::create(eventNames().audioendEvent));
}
void SpeechRecognition::didReceiveResults(const Vector<RefPtr<SpeechRecognitionResult> >& newFinalResults, const Vector<RefPtr<SpeechRecognitionResult> >& currentInterimResults)
@@ -134,7 +134,7 @@ void SpeechRecognition::didReceiveError(PassRefPtr<SpeechRecognitionError> error
void SpeechRecognition::didStart()
{
- dispatchEvent(Event::create(eventNames().startEvent, /*canBubble=*/false, /*cancelable=*/false));
+ dispatchEvent(Event::create(eventNames().startEvent));
}
void SpeechRecognition::didEnd()
@@ -142,7 +142,7 @@ void SpeechRecognition::didEnd()
m_started = false;
m_stopping = false;
if (!m_stoppedByActiveDOMObject)
- dispatchEvent(Event::create(eventNames().endEvent, /*canBubble=*/false, /*cancelable=*/false));
+ dispatchEvent(Event::create(eventNames().endEvent));
unsetPendingActivity(this);
}
diff --git a/third_party/WebKit/Source/modules/webaudio/AudioScheduledSourceNode.cpp b/third_party/WebKit/Source/modules/webaudio/AudioScheduledSourceNode.cpp
index db216bc..c467527 100644
--- a/third_party/WebKit/Source/modules/webaudio/AudioScheduledSourceNode.cpp
+++ b/third_party/WebKit/Source/modules/webaudio/AudioScheduledSourceNode.cpp
@@ -190,7 +190,7 @@ void AudioScheduledSourceNode::notifyEndedDispatch(void* userData)
void AudioScheduledSourceNode::notifyEnded()
{
- RefPtr<Event> event = Event::create(eventNames().endedEvent, FALSE, FALSE);
+ RefPtr<Event> event = Event::create(eventNames().endedEvent);
event->setTarget(this);
dispatchEvent(event.get());
}
diff --git a/third_party/WebKit/Source/web/ApplicationCacheHost.cpp b/third_party/WebKit/Source/web/ApplicationCacheHost.cpp
index ca87e03..3d952dd 100644
--- a/third_party/WebKit/Source/web/ApplicationCacheHost.cpp
+++ b/third_party/WebKit/Source/web/ApplicationCacheHost.cpp
@@ -220,7 +220,7 @@ void ApplicationCacheHost::dispatchDOMEvent(EventID id, int total, int done)
if (id == PROGRESS_EVENT)
event = ProgressEvent::create(eventType, true, done, total);
else
- event = Event::create(eventType, false, false);
+ event = Event::create(eventType);
m_domApplicationCache->dispatchEvent(event, ASSERT_NO_EXCEPTION);
}
}