| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2011, 2012 Google Inc. All rights reserved. | 2 * Copyright (C) 2011, 2012 Google Inc. All rights reserved. |
| 3 * | 3 * |
| 4 * Redistribution and use in source and binary forms, with or without | 4 * Redistribution and use in source and binary forms, with or without |
| 5 * modification, are permitted provided that the following conditions are | 5 * modification, are permitted provided that the following conditions are |
| 6 * met: | 6 * met: |
| 7 * | 7 * |
| 8 * * Redistributions of source code must retain the above copyright | 8 * * Redistributions of source code must retain the above copyright |
| 9 * notice, this list of conditions and the following disclaimer. | 9 * notice, this list of conditions and the following disclaimer. |
| 10 * * Redistributions in binary form must reproduce the above | 10 * * Redistributions in binary form must reproduce the above |
| (...skipping 2449 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2460 if (!frame) | 2460 if (!frame) |
| 2461 return true; | 2461 return true; |
| 2462 | 2462 |
| 2463 return frame->loader().shouldClose(); | 2463 return frame->loader().shouldClose(); |
| 2464 } | 2464 } |
| 2465 | 2465 |
| 2466 void WebViewImpl::dispatchUnloadEvent() | 2466 void WebViewImpl::dispatchUnloadEvent() |
| 2467 { | 2467 { |
| 2468 // Run unload handlers. | 2468 // Run unload handlers. |
| 2469 m_page->mainFrame()->loader().closeURL(); | 2469 m_page->mainFrame()->loader().closeURL(); |
| 2470 m_page->mainFrame()->loader().detachChildren(); |
| 2470 } | 2471 } |
| 2471 | 2472 |
| 2472 WebFrame* WebViewImpl::mainFrame() | 2473 WebFrame* WebViewImpl::mainFrame() |
| 2473 { | 2474 { |
| 2474 return mainFrameImpl(); | 2475 return mainFrameImpl(); |
| 2475 } | 2476 } |
| 2476 | 2477 |
| 2477 WebFrame* WebViewImpl::findFrameByName( | 2478 WebFrame* WebViewImpl::findFrameByName( |
| 2478 const WebString& name, WebFrame* relativeToFrame) | 2479 const WebString& name, WebFrame* relativeToFrame) |
| 2479 { | 2480 { |
| (...skipping 1510 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3990 const PageScaleConstraints& constraints = m_pageScaleConstraintsSet.pageDefi
nedConstraints(); | 3991 const PageScaleConstraints& constraints = m_pageScaleConstraintsSet.pageDefi
nedConstraints(); |
| 3991 | 3992 |
| 3992 if (!mainFrameImpl() || !mainFrameImpl()->frameView()) | 3993 if (!mainFrameImpl() || !mainFrameImpl()->frameView()) |
| 3993 return false; | 3994 return false; |
| 3994 | 3995 |
| 3995 return mainFrameImpl()->frameView()->layoutSize().width() == m_size.width | 3996 return mainFrameImpl()->frameView()->layoutSize().width() == m_size.width |
| 3996 || (constraints.minimumScale == constraints.maximumScale && constraints.
minimumScale != -1); | 3997 || (constraints.minimumScale == constraints.maximumScale && constraints.
minimumScale != -1); |
| 3997 } | 3998 } |
| 3998 | 3999 |
| 3999 } // namespace blink | 4000 } // namespace blink |
| OLD | NEW |