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

Side by Side Diff: Source/core/loader/FrameLoader.cpp

Issue 1229263003: Add an empty boolean to WebFrameClient::didFinishDocumentLoad (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: empty -> documentIsEmpty 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 | Annotate | Revision Log
« no previous file with comments | « Source/core/loader/EmptyClients.h ('k') | Source/core/loader/FrameLoaderClient.h » ('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) 2006, 2007, 2008, 2009, 2010, 2011 Apple Inc. All rights reserv ed. 2 * Copyright (C) 2006, 2007, 2008, 2009, 2010, 2011 Apple Inc. All rights reserv ed.
3 * Copyright (C) 2008 Nokia Corporation and/or its subsidiary(-ies) 3 * Copyright (C) 2008 Nokia Corporation and/or its subsidiary(-ies)
4 * Copyright (C) 2008, 2009 Torch Mobile Inc. All rights reserved. (http://www.t orchmobile.com/) 4 * Copyright (C) 2008, 2009 Torch Mobile Inc. All rights reserved. (http://www.t orchmobile.com/)
5 * Copyright (C) 2008 Alp Toker <alp@atoker.com> 5 * Copyright (C) 2008 Alp Toker <alp@atoker.com>
6 * Copyright (C) Research In Motion Limited 2009. All rights reserved. 6 * Copyright (C) Research In Motion Limited 2009. All rights reserved.
7 * Copyright (C) 2011 Kris Jordan <krisjordan@gmail.com> 7 * Copyright (C) 2011 Kris Jordan <krisjordan@gmail.com>
8 * Copyright (C) 2011 Google Inc. All rights reserved. 8 * Copyright (C) 2011 Google Inc. All rights reserved.
9 * 9 *
10 * Redistribution and use in source and binary forms, with or without 10 * Redistribution and use in source and binary forms, with or without
(...skipping 458 matching lines...) Expand 10 before | Expand all | Expand 10 after
469 { 469 {
470 if (m_stateMachine.creatingInitialEmptyDocument()) 470 if (m_stateMachine.creatingInitialEmptyDocument())
471 return; 471 return;
472 472
473 // This can be called from the LocalFrame's destructor, in which case we sho uldn't protect ourselves 473 // This can be called from the LocalFrame's destructor, in which case we sho uldn't protect ourselves
474 // because doing so will cause us to re-enter the destructor when protector goes out of scope. 474 // because doing so will cause us to re-enter the destructor when protector goes out of scope.
475 // Null-checking the FrameView indicates whether or not we're in the destruc tor. 475 // Null-checking the FrameView indicates whether or not we're in the destruc tor.
476 RefPtrWillBeRawPtr<LocalFrame> protect(m_frame->view() ? m_frame.get() : nul lptr); 476 RefPtrWillBeRawPtr<LocalFrame> protect(m_frame->view() ? m_frame.get() : nul lptr);
477 477
478 if (client()) 478 if (client())
479 client()->dispatchDidFinishDocumentLoad(); 479 client()->dispatchDidFinishDocumentLoad(m_documentLoader->isCommittedBut Empty());
480 480
481 checkCompleted(); 481 checkCompleted();
482 482
483 if (!m_frame->view()) 483 if (!m_frame->view())
484 return; // We are being destroyed by something checkCompleted called. 484 return; // We are being destroyed by something checkCompleted called.
485 485
486 // Check if the scrollbars are really needed for the content. 486 // Check if the scrollbars are really needed for the content.
487 // If not, remove them, relayout, and repaint. 487 // If not, remove them, relayout, and repaint.
488 m_frame->view()->restoreScrollbar(); 488 m_frame->view()->restoreScrollbar();
489 processFragment(m_frame->document()->url(), NavigationToDifferentDocument); 489 processFragment(m_frame->document()->url(), NavigationToDifferentDocument);
(...skipping 1004 matching lines...) Expand 10 before | Expand all | Expand 10 after
1494 // FIXME: We need a way to propagate insecure requests policy flags to 1494 // FIXME: We need a way to propagate insecure requests policy flags to
1495 // out-of-process frames. For now, we'll always use default behavior. 1495 // out-of-process frames. For now, we'll always use default behavior.
1496 if (!parentFrame->isLocalFrame()) 1496 if (!parentFrame->isLocalFrame())
1497 return nullptr; 1497 return nullptr;
1498 1498
1499 ASSERT(toLocalFrame(parentFrame)->document()); 1499 ASSERT(toLocalFrame(parentFrame)->document());
1500 return toLocalFrame(parentFrame)->document()->insecureNavigationsToUpgrade() ; 1500 return toLocalFrame(parentFrame)->document()->insecureNavigationsToUpgrade() ;
1501 } 1501 }
1502 1502
1503 } // namespace blink 1503 } // namespace blink
OLDNEW
« no previous file with comments | « Source/core/loader/EmptyClients.h ('k') | Source/core/loader/FrameLoaderClient.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698