| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2009, 2012 Google Inc. All rights reserved. | 2 * Copyright (C) 2009, 2012 Google Inc. All rights reserved. |
| 3 * Copyright (C) 2011 Apple Inc. All rights reserved. | 3 * Copyright (C) 2011 Apple Inc. All rights reserved. |
| 4 * | 4 * |
| 5 * Redistribution and use in source and binary forms, with or without | 5 * Redistribution and use in source and binary forms, with or without |
| 6 * modification, are permitted provided that the following conditions are | 6 * modification, are permitted provided that the following conditions are |
| 7 * met: | 7 * met: |
| 8 * | 8 * |
| 9 * * Redistributions of source code must retain the above copyright | 9 * * Redistributions of source code must retain the above copyright |
| 10 * notice, this list of conditions and the following disclaimer. | 10 * notice, this list of conditions and the following disclaimer. |
| (...skipping 421 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 432 m_webFrame->viewImpl()->didCommitLoad(commitType == StandardCommit, false); | 432 m_webFrame->viewImpl()->didCommitLoad(commitType == StandardCommit, false); |
| 433 if (m_webFrame->client()) | 433 if (m_webFrame->client()) |
| 434 m_webFrame->client()->didCommitProvisionalLoad(m_webFrame, WebHistoryIte
m(item), static_cast<WebHistoryCommitType>(commitType)); | 434 m_webFrame->client()->didCommitProvisionalLoad(m_webFrame, WebHistoryIte
m(item), static_cast<WebHistoryCommitType>(commitType)); |
| 435 // FIXME(dgozman): update this for out-of-process. | 435 // FIXME(dgozman): update this for out-of-process. |
| 436 WebDevToolsAgent* devToolsAgent = m_webFrame->top()->isWebLocalFrame() ? toW
ebLocalFrameImpl(m_webFrame->top())->viewImpl()->devToolsAgent() : nullptr; | 436 WebDevToolsAgent* devToolsAgent = m_webFrame->top()->isWebLocalFrame() ? toW
ebLocalFrameImpl(m_webFrame->top())->viewImpl()->devToolsAgent() : nullptr; |
| 437 if (devToolsAgent) | 437 if (devToolsAgent) |
| 438 static_cast<WebDevToolsAgentImpl*>(devToolsAgent)->didCommitLoadForLocal
Frame(m_webFrame->frame()); | 438 static_cast<WebDevToolsAgentImpl*>(devToolsAgent)->didCommitLoadForLocal
Frame(m_webFrame->frame()); |
| 439 } | 439 } |
| 440 | 440 |
| 441 void FrameLoaderClientImpl::dispatchDidFailProvisionalLoad( | 441 void FrameLoaderClientImpl::dispatchDidFailProvisionalLoad( |
| 442 const ResourceError& error) | 442 const ResourceError& error, HistoryCommitType commitType) |
| 443 { | 443 { |
| 444 OwnPtr<WebPluginLoadObserver> observer = pluginLoadObserver(m_webFrame->fram
e()->loader().provisionalDocumentLoader()); | 444 OwnPtr<WebPluginLoadObserver> observer = pluginLoadObserver(m_webFrame->fram
e()->loader().provisionalDocumentLoader()); |
| 445 m_webFrame->didFail(error, true); | 445 m_webFrame->didFail(error, true, commitType); |
| 446 if (observer) | 446 if (observer) |
| 447 observer->didFailLoading(error); | 447 observer->didFailLoading(error); |
| 448 } | 448 } |
| 449 | 449 |
| 450 void FrameLoaderClientImpl::dispatchDidFailLoad(const ResourceError& error) | 450 void FrameLoaderClientImpl::dispatchDidFailLoad(const ResourceError& error, Hist
oryCommitType commitType) |
| 451 { | 451 { |
| 452 OwnPtr<WebPluginLoadObserver> observer = pluginLoadObserver(m_webFrame->fram
e()->loader().documentLoader()); | 452 OwnPtr<WebPluginLoadObserver> observer = pluginLoadObserver(m_webFrame->fram
e()->loader().documentLoader()); |
| 453 m_webFrame->didFail(error, false); | 453 m_webFrame->didFail(error, false, commitType); |
| 454 if (observer) | 454 if (observer) |
| 455 observer->didFailLoading(error); | 455 observer->didFailLoading(error); |
| 456 | 456 |
| 457 // Don't clear the redirect chain, this will happen in the middle of client | 457 // Don't clear the redirect chain, this will happen in the middle of client |
| 458 // redirects, and we need the context. The chain will be cleared when the | 458 // redirects, and we need the context. The chain will be cleared when the |
| 459 // provisional load succeeds or fails, not the "real" one. | 459 // provisional load succeeds or fails, not the "real" one. |
| 460 } | 460 } |
| 461 | 461 |
| 462 void FrameLoaderClientImpl::dispatchDidFinishLoad() | 462 void FrameLoaderClientImpl::dispatchDidFinishLoad() |
| 463 { | 463 { |
| (...skipping 505 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 969 | 969 |
| 970 void FrameLoaderClientImpl::suddenTerminationDisablerChanged(bool present, Sudde
nTerminationDisablerType type) | 970 void FrameLoaderClientImpl::suddenTerminationDisablerChanged(bool present, Sudde
nTerminationDisablerType type) |
| 971 { | 971 { |
| 972 if (m_webFrame->client()) { | 972 if (m_webFrame->client()) { |
| 973 m_webFrame->client()->suddenTerminationDisablerChanged( | 973 m_webFrame->client()->suddenTerminationDisablerChanged( |
| 974 present, static_cast<WebFrameClient::SuddenTerminationDisablerType>(
type)); | 974 present, static_cast<WebFrameClient::SuddenTerminationDisablerType>(
type)); |
| 975 } | 975 } |
| 976 } | 976 } |
| 977 | 977 |
| 978 } // namespace blink | 978 } // namespace blink |
| OLD | NEW |