| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright 2007 Google Inc. All Rights Reserved. | 2 * Copyright 2007 Google Inc. All Rights Reserved. |
| 3 * | 3 * |
| 4 * Portions Copyright (C) 2006 Apple Computer, Inc. All rights reserved. | 4 * Portions Copyright (C) 2006 Apple Computer, Inc. All rights reserved. |
| 5 * | 5 * |
| 6 * ***** BEGIN LICENSE BLOCK ***** | 6 * ***** BEGIN LICENSE BLOCK ***** |
| 7 * | 7 * |
| 8 * Redistribution and use in source and binary forms, with or without | 8 * Redistribution and use in source and binary forms, with or without |
| 9 * modification, are permitted provided that the following conditions | 9 * modification, are permitted provided that the following conditions |
| 10 * are met: | 10 * are met: |
| (...skipping 889 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 900 | 900 |
| 901 if (page_.get()) { | 901 if (page_.get()) { |
| 902 // Initiate shutdown for the entire frameset. This will cause a lot of | 902 // Initiate shutdown for the entire frameset. This will cause a lot of |
| 903 // notifications to be sent. | 903 // notifications to be sent. |
| 904 if (page_->mainFrame()) | 904 if (page_->mainFrame()) |
| 905 page_->mainFrame()->loader()->frameDetached(); | 905 page_->mainFrame()->loader()->frameDetached(); |
| 906 page_.reset(); | 906 page_.reset(); |
| 907 } | 907 } |
| 908 | 908 |
| 909 // Should happen after page_.reset(). | 909 // Should happen after page_.reset(). |
| 910 devtools_agent_.reset(NULL); | 910 if (devtools_agent_.get()) |
| 911 devtools_agent_.reset(NULL); |
| 911 | 912 |
| 912 Release(); // Balances AddRef from WebView::Create | 913 Release(); // Balances AddRef from WebView::Create |
| 913 } | 914 } |
| 914 | 915 |
| 915 WebViewDelegate* WebViewImpl::GetDelegate() { | 916 WebViewDelegate* WebViewImpl::GetDelegate() { |
| 916 return delegate_; | 917 return delegate_; |
| 917 } | 918 } |
| 918 | 919 |
| 919 void WebViewImpl::SetDelegate(WebViewDelegate* delegate) { | 920 void WebViewImpl::SetDelegate(WebViewDelegate* delegate) { |
| 920 delegate_ = delegate; | 921 delegate_ = delegate; |
| (...skipping 1005 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1926 | 1927 |
| 1927 return document->focusedNode(); | 1928 return document->focusedNode(); |
| 1928 } | 1929 } |
| 1929 | 1930 |
| 1930 HitTestResult WebViewImpl::HitTestResultForWindowPos(const IntPoint& pos) { | 1931 HitTestResult WebViewImpl::HitTestResultForWindowPos(const IntPoint& pos) { |
| 1931 IntPoint doc_point( | 1932 IntPoint doc_point( |
| 1932 page_->mainFrame()->view()->windowToContents(pos)); | 1933 page_->mainFrame()->view()->windowToContents(pos)); |
| 1933 return page_->mainFrame()->eventHandler()-> | 1934 return page_->mainFrame()->eventHandler()-> |
| 1934 hitTestResultAtPoint(doc_point, false); | 1935 hitTestResultAtPoint(doc_point, false); |
| 1935 } | 1936 } |
| OLD | NEW |