OLD | NEW |
---|---|
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 2674 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
2685 } | 2685 } |
2686 | 2686 |
2687 if (!m_frame) | 2687 if (!m_frame) |
2688 return; | 2688 return; |
2689 | 2689 |
2690 // Don't remove event listeners from a transitional empty document (see http s://bugs.webkit.org/show_bug.cgi?id=28716 for more information). | 2690 // Don't remove event listeners from a transitional empty document (see http s://bugs.webkit.org/show_bug.cgi?id=28716 for more information). |
2691 bool keepEventListeners = m_frame->loader().stateMachine()->isDisplayingInit ialEmptyDocument() && m_frame->loader().provisionalDocumentLoader() | 2691 bool keepEventListeners = m_frame->loader().stateMachine()->isDisplayingInit ialEmptyDocument() && m_frame->loader().provisionalDocumentLoader() |
2692 && isSecureTransitionTo(m_frame->loader().provisionalDocumentLoader()->u rl()); | 2692 && isSecureTransitionTo(m_frame->loader().provisionalDocumentLoader()->u rl()); |
2693 if (!keepEventListeners) | 2693 if (!keepEventListeners) |
2694 removeAllEventListenersRecursively(); | 2694 removeAllEventListenersRecursively(); |
2695 if (RuntimeEnabledFeatures::scrollCustomizationEnabled()) | |
2696 Element::removeScrollCustomizationCallbacksForDocument(this); | |
haraken
2015/08/13 23:42:05
Why do we need to remove callbacks in dispatchUnlo
| |
2695 } | 2697 } |
2696 | 2698 |
2697 Document::PageDismissalType Document::pageDismissalEventBeingDispatched() const | 2699 Document::PageDismissalType Document::pageDismissalEventBeingDispatched() const |
2698 { | 2700 { |
2699 if (m_loadEventProgress == BeforeUnloadEventInProgress) | 2701 if (m_loadEventProgress == BeforeUnloadEventInProgress) |
2700 return BeforeUnloadDismissal; | 2702 return BeforeUnloadDismissal; |
2701 if (m_loadEventProgress == PageHideInProgress) | 2703 if (m_loadEventProgress == PageHideInProgress) |
2702 return PageHideDismissal; | 2704 return PageHideDismissal; |
2703 if (m_loadEventProgress == UnloadEventInProgress) | 2705 if (m_loadEventProgress == UnloadEventInProgress) |
2704 return UnloadDismissal; | 2706 return UnloadDismissal; |
(...skipping 3076 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
5781 #ifndef NDEBUG | 5783 #ifndef NDEBUG |
5782 using namespace blink; | 5784 using namespace blink; |
5783 void showLiveDocumentInstances() | 5785 void showLiveDocumentInstances() |
5784 { | 5786 { |
5785 WeakDocumentSet& set = liveDocumentSet(); | 5787 WeakDocumentSet& set = liveDocumentSet(); |
5786 fprintf(stderr, "There are %u documents currently alive:\n", set.size()); | 5788 fprintf(stderr, "There are %u documents currently alive:\n", set.size()); |
5787 for (Document* document : set) | 5789 for (Document* document : set) |
5788 fprintf(stderr, "- Document %p URL: %s\n", document, document->url().str ing().utf8().data()); | 5790 fprintf(stderr, "- Document %p URL: %s\n", document, document->url().str ing().utf8().data()); |
5789 } | 5791 } |
5790 #endif | 5792 #endif |
OLD | NEW |