Chromium Code Reviews| Index: third_party/WebKit/Source/core/frame/LocalDOMWindow.cpp |
| diff --git a/third_party/WebKit/Source/core/frame/LocalDOMWindow.cpp b/third_party/WebKit/Source/core/frame/LocalDOMWindow.cpp |
| index e3135f1287c06d78933b25eb417a9570161103b4..abf4836a9dfa17662230ca6846fb32c27f502d83 100644 |
| --- a/third_party/WebKit/Source/core/frame/LocalDOMWindow.cpp |
| +++ b/third_party/WebKit/Source/core/frame/LocalDOMWindow.cpp |
| @@ -425,7 +425,12 @@ void LocalDOMWindow::EnqueuePageshowEvent(PageshowEventPersistence persisted) { |
| // FIXME: https://bugs.webkit.org/show_bug.cgi?id=36334 Pageshow event needs |
| // to fire asynchronously. As per spec pageshow must be triggered |
| // asynchronously. However to be compatible with other browsers blink fires |
|
tkent
2017/04/13 01:26:16
Did you check behavior of latest versions of other
tkent
2017/04/13 06:19:14
We had offline discussion.
It's too difficult to r
|
| - // pageshow synchronously. |
| + // pageshow synchronously unless we are in EventQueueScope. |
| + if (ScopedEventQueue::Instance()->ShouldQueueEvents() && document_) { |
|
yosin_UTC9
2017/04/12 10:08:03
Nice finding. I've not known |(ScopedEventQueue::I
|
| + EnqueueWindowEvent( |
| + PageTransitionEvent::Create(EventTypeNames::pageshow, persisted)); |
| + return; |
| + } |
| DispatchEvent( |
| PageTransitionEvent::Create(EventTypeNames::pageshow, persisted), |
| document_.Get()); |