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 1809 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1820 | 1820 |
1821 WebDevToolsAgent* WebViewImpl::GetWebDevToolsAgent() { | 1821 WebDevToolsAgent* WebViewImpl::GetWebDevToolsAgent() { |
1822 return GetWebDevToolsAgentImpl(); | 1822 return GetWebDevToolsAgentImpl(); |
1823 } | 1823 } |
1824 | 1824 |
1825 WebDevToolsAgentImpl* WebViewImpl::GetWebDevToolsAgentImpl() { | 1825 WebDevToolsAgentImpl* WebViewImpl::GetWebDevToolsAgentImpl() { |
1826 return devtools_agent_.get(); | 1826 return devtools_agent_.get(); |
1827 } | 1827 } |
1828 | 1828 |
1829 void WebViewImpl::SetIsTransparent(bool is_transparent) { | 1829 void WebViewImpl::SetIsTransparent(bool is_transparent) { |
| 1830 // Set any existing frames to be transparent. |
| 1831 WebCore::Frame* frame = page_->mainFrame(); |
| 1832 while (frame) { |
| 1833 frame->view()->setTransparent(is_transparent); |
| 1834 frame = frame->tree()->traverseNext(); |
| 1835 } |
| 1836 |
| 1837 // Future frames check this to know whether to be transparent. |
1830 is_transparent_ = is_transparent; | 1838 is_transparent_ = is_transparent; |
1831 } | 1839 } |
1832 | 1840 |
1833 bool WebViewImpl::GetIsTransparent() const { | 1841 bool WebViewImpl::GetIsTransparent() const { |
1834 return is_transparent_; | 1842 return is_transparent_; |
1835 } | 1843 } |
1836 | 1844 |
1837 void WebViewImpl::DidCommitLoad(bool* is_new_navigation) { | 1845 void WebViewImpl::DidCommitLoad(bool* is_new_navigation) { |
1838 if (is_new_navigation) | 1846 if (is_new_navigation) |
1839 *is_new_navigation = observed_new_navigation_; | 1847 *is_new_navigation = observed_new_navigation_; |
(...skipping 101 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1941 | 1949 |
1942 return document->focusedNode(); | 1950 return document->focusedNode(); |
1943 } | 1951 } |
1944 | 1952 |
1945 HitTestResult WebViewImpl::HitTestResultForWindowPos(const IntPoint& pos) { | 1953 HitTestResult WebViewImpl::HitTestResultForWindowPos(const IntPoint& pos) { |
1946 IntPoint doc_point( | 1954 IntPoint doc_point( |
1947 page_->mainFrame()->view()->windowToContents(pos)); | 1955 page_->mainFrame()->view()->windowToContents(pos)); |
1948 return page_->mainFrame()->eventHandler()-> | 1956 return page_->mainFrame()->eventHandler()-> |
1949 hitTestResultAtPoint(doc_point, false); | 1957 hitTestResultAtPoint(doc_point, false); |
1950 } | 1958 } |
OLD | NEW |