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

Side by Side Diff: Source/modules/indexeddb/IDBTransaction.cpp

Issue 1241613004: Rework dispatchEvent so it is consistent for isTrusted support. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Work around MSVC optimization bug Created 5 years, 5 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
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2010 Google Inc. All rights reserved. 2 * Copyright (C) 2010 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 5 * modification, are permitted provided that the following conditions
6 * are met: 6 * are met:
7 * 7 *
8 * 1. Redistributions of source code must retain the above copyright 8 * 1. 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 * 2. Redistributions in binary form must reproduce the above copyright 10 * 2. Redistributions in binary form must reproduce the above copyright
(...skipping 332 matching lines...) Expand 10 before | Expand all | Expand 10 after
343 const AtomicString& IDBTransaction::interfaceName() const 343 const AtomicString& IDBTransaction::interfaceName() const
344 { 344 {
345 return EventTargetNames::IDBTransaction; 345 return EventTargetNames::IDBTransaction;
346 } 346 }
347 347
348 ExecutionContext* IDBTransaction::executionContext() const 348 ExecutionContext* IDBTransaction::executionContext() const
349 { 349 {
350 return ActiveDOMObject::executionContext(); 350 return ActiveDOMObject::executionContext();
351 } 351 }
352 352
353 bool IDBTransaction::dispatchEvent(PassRefPtrWillBeRawPtr<Event> event) 353 bool IDBTransaction::dispatchEventInternal(PassRefPtrWillBeRawPtr<Event> event)
354 { 354 {
355 IDB_TRACE("IDBTransaction::dispatchEvent"); 355 IDB_TRACE("IDBTransaction::dispatchEvent");
356 if (m_contextStopped || !executionContext()) { 356 if (m_contextStopped || !executionContext()) {
357 m_state = Finished; 357 m_state = Finished;
358 return false; 358 return false;
359 } 359 }
360 ASSERT(m_state != Finished); 360 ASSERT(m_state != Finished);
361 ASSERT(m_hasPendingActivity); 361 ASSERT(m_hasPendingActivity);
362 ASSERT(executionContext()); 362 ASSERT(executionContext());
363 ASSERT(event->target() == this); 363 ASSERT(event->target() == this);
(...skipping 44 matching lines...) Expand 10 before | Expand all | Expand 10 after
408 event->setTarget(this); 408 event->setTarget(this);
409 eventQueue->enqueueEvent(event); 409 eventQueue->enqueueEvent(event);
410 } 410 }
411 411
412 WebIDBDatabase* IDBTransaction::backendDB() const 412 WebIDBDatabase* IDBTransaction::backendDB() const
413 { 413 {
414 return m_database->backend(); 414 return m_database->backend();
415 } 415 }
416 416
417 } // namespace blink 417 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698