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

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

Issue 2895543004: Remove visibilityChangeOnUnload runtime flag (as it's shipped) (Closed)
Patch Set: Created 3 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 | « no previous file | third_party/WebKit/Source/platform/RuntimeEnabledFeatures.json5 » ('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 6 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2011, 2012 Apple Inc. All
7 * rights reserved. 7 * rights reserved.
8 * Copyright (C) 2008, 2009 Torch Mobile Inc. All rights reserved. 8 * Copyright (C) 2008, 2009 Torch Mobile Inc. All rights reserved.
9 * (http://www.torchmobile.com/) 9 * (http://www.torchmobile.com/)
10 * Copyright (C) 2008, 2009, 2011, 2012 Google Inc. All rights reserved. 10 * Copyright (C) 2008, 2009, 2011, 2012 Google Inc. All rights reserved.
(...skipping 3226 matching lines...) Expand 10 before | Expand all | Expand 10 after
3237 if (load_event_progress_ < kPageHideInProgress) { 3237 if (load_event_progress_ < kPageHideInProgress) {
3238 load_event_progress_ = kPageHideInProgress; 3238 load_event_progress_ = kPageHideInProgress;
3239 if (LocalDOMWindow* window = domWindow()) 3239 if (LocalDOMWindow* window = domWindow())
3240 window->DispatchEvent( 3240 window->DispatchEvent(
3241 PageTransitionEvent::Create(EventTypeNames::pagehide, false), this); 3241 PageTransitionEvent::Create(EventTypeNames::pagehide, false), this);
3242 if (!frame_) 3242 if (!frame_)
3243 return; 3243 return;
3244 3244
3245 PageVisibilityState visibility_state = GetPageVisibilityState(); 3245 PageVisibilityState visibility_state = GetPageVisibilityState();
3246 load_event_progress_ = kUnloadVisibilityChangeInProgress; 3246 load_event_progress_ = kUnloadVisibilityChangeInProgress;
3247 if (visibility_state != kPageVisibilityStateHidden && 3247 if (visibility_state != kPageVisibilityStateHidden) {
3248 RuntimeEnabledFeatures::visibilityChangeOnUnloadEnabled()) {
3249 // Dispatch visibilitychange event, but don't bother doing 3248 // Dispatch visibilitychange event, but don't bother doing
3250 // other notifications as we're about to be unloaded. 3249 // other notifications as we're about to be unloaded.
3251 DispatchEvent(Event::CreateBubble(EventTypeNames::visibilitychange)); 3250 DispatchEvent(Event::CreateBubble(EventTypeNames::visibilitychange));
3252 DispatchEvent( 3251 DispatchEvent(
3253 Event::CreateBubble(EventTypeNames::webkitvisibilitychange)); 3252 Event::CreateBubble(EventTypeNames::webkitvisibilitychange));
3254 } 3253 }
3255 if (!frame_) 3254 if (!frame_)
3256 return; 3255 return;
3257 3256
3258 DocumentLoader* document_loader = 3257 DocumentLoader* document_loader =
(...skipping 3555 matching lines...) Expand 10 before | Expand all | Expand 10 after
6814 } 6813 }
6815 6814
6816 void showLiveDocumentInstances() { 6815 void showLiveDocumentInstances() {
6817 WeakDocumentSet& set = liveDocumentSet(); 6816 WeakDocumentSet& set = liveDocumentSet();
6818 fprintf(stderr, "There are %u documents currently alive:\n", set.size()); 6817 fprintf(stderr, "There are %u documents currently alive:\n", set.size());
6819 for (blink::Document* document : set) 6818 for (blink::Document* document : set)
6820 fprintf(stderr, "- Document %p URL: %s\n", document, 6819 fprintf(stderr, "- Document %p URL: %s\n", document,
6821 document->Url().GetString().Utf8().data()); 6820 document->Url().GetString().Utf8().data());
6822 } 6821 }
6823 #endif 6822 #endif
OLDNEW
« no previous file with comments | « no previous file | third_party/WebKit/Source/platform/RuntimeEnabledFeatures.json5 » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698