| 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 867 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 878 } | 878 } |
| 879 return scroll_handled; | 879 return scroll_handled; |
| 880 } | 880 } |
| 881 | 881 |
| 882 Frame* WebViewImpl::GetFocusedWebCoreFrame() { | 882 Frame* WebViewImpl::GetFocusedWebCoreFrame() { |
| 883 return page_.get() ? page_->focusController()->focusedOrMainFrame() : NULL; | 883 return page_.get() ? page_->focusController()->focusedOrMainFrame() : NULL; |
| 884 } | 884 } |
| 885 | 885 |
| 886 // static | 886 // static |
| 887 WebViewImpl* WebViewImpl::FromPage(WebCore::Page* page) { | 887 WebViewImpl* WebViewImpl::FromPage(WebCore::Page* page) { |
| 888 return WebFrameImpl::FromFrame(page->mainFrame())->webview_impl(); | 888 return WebFrameImpl::FromFrame(page->mainFrame())->GetWebViewImpl(); |
| 889 } | 889 } |
| 890 | 890 |
| 891 // WebView -------------------------------------------------------------------- | 891 // WebView -------------------------------------------------------------------- |
| 892 | 892 |
| 893 bool WebViewImpl::ShouldClose() { | 893 bool WebViewImpl::ShouldClose() { |
| 894 // TODO(creis): This should really cause a recursive depth-first walk of all | 894 // TODO(creis): This should really cause a recursive depth-first walk of all |
| 895 // frames in the tree, calling each frame's onbeforeunload. At the moment, | 895 // frames in the tree, calling each frame's onbeforeunload. At the moment, |
| 896 // we're consistent with Safari 3.1, not IE/FF. | 896 // we're consistent with Safari 3.1, not IE/FF. |
| 897 Frame* frame = page_->focusController()->focusedOrMainFrame(); | 897 Frame* frame = page_->focusController()->focusedOrMainFrame(); |
| 898 if (!frame) | 898 if (!frame) |
| (...skipping 1051 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1950 | 1950 |
| 1951 return document->focusedNode(); | 1951 return document->focusedNode(); |
| 1952 } | 1952 } |
| 1953 | 1953 |
| 1954 HitTestResult WebViewImpl::HitTestResultForWindowPos(const IntPoint& pos) { | 1954 HitTestResult WebViewImpl::HitTestResultForWindowPos(const IntPoint& pos) { |
| 1955 IntPoint doc_point( | 1955 IntPoint doc_point( |
| 1956 page_->mainFrame()->view()->windowToContents(pos)); | 1956 page_->mainFrame()->view()->windowToContents(pos)); |
| 1957 return page_->mainFrame()->eventHandler()-> | 1957 return page_->mainFrame()->eventHandler()-> |
| 1958 hitTestResultAtPoint(doc_point, false); | 1958 hitTestResultAtPoint(doc_point, false); |
| 1959 } | 1959 } |
| OLD | NEW |