OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2009 Google Inc. All rights reserved. | 2 * Copyright (C) 2009 Google Inc. All rights reserved. |
3 * Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies). | 3 * Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies). |
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 179 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
190 void ChromeClientImpl::takeFocus(WebFocusType type) | 190 void ChromeClientImpl::takeFocus(WebFocusType type) |
191 { | 191 { |
192 if (!m_webView->client()) | 192 if (!m_webView->client()) |
193 return; | 193 return; |
194 if (type == WebFocusTypeBackward) | 194 if (type == WebFocusTypeBackward) |
195 m_webView->client()->focusPrevious(); | 195 m_webView->client()->focusPrevious(); |
196 else | 196 else |
197 m_webView->client()->focusNext(); | 197 m_webView->client()->focusNext(); |
198 } | 198 } |
199 | 199 |
200 void ChromeClientImpl::focusedNodeChanged(Node* node) | 200 void ChromeClientImpl::focusedNodeChanged(Node* fromNode, Node* toNode) |
201 { | 201 { |
202 m_webView->client()->focusedNodeChanged(WebNode(node)); | 202 // FIXME: remove. |
| 203 m_webView->client()->focusedNodeChanged(WebNode(toNode)); |
| 204 m_webView->client()->focusedNodeChanged(WebNode(fromNode), WebNode(toNode)); |
203 | 205 |
204 WebURL focusURL; | 206 WebURL focusURL; |
205 if (node && node->isElementNode() && toElement(node)->isLiveLink()) | 207 if (toNode && toNode->isElementNode() && toElement(toNode)->isLiveLink()) |
206 focusURL = toElement(node)->hrefURL(); | 208 focusURL = toElement(toNode)->hrefURL(); |
207 m_webView->client()->setKeyboardFocusURL(focusURL); | 209 m_webView->client()->setKeyboardFocusURL(focusURL); |
208 } | 210 } |
209 | 211 |
210 void ChromeClientImpl::focusedFrameChanged(LocalFrame* frame) | 212 void ChromeClientImpl::focusedFrameChanged(LocalFrame* frame) |
211 { | 213 { |
212 WebLocalFrameImpl* webframe = WebLocalFrameImpl::fromFrame(frame); | 214 WebLocalFrameImpl* webframe = WebLocalFrameImpl::fromFrame(frame); |
213 if (webframe && webframe->client()) | 215 if (webframe && webframe->client()) |
214 webframe->client()->frameFocused(); | 216 webframe->client()->frameFocused(); |
215 } | 217 } |
216 | 218 |
(...skipping 665 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
882 webframe->autofillClient()->dataListOptionsChanged(WebInputElement(&inpu
t)); | 884 webframe->autofillClient()->dataListOptionsChanged(WebInputElement(&inpu
t)); |
883 } | 885 } |
884 | 886 |
885 void ChromeClientImpl::registerViewportLayers() const | 887 void ChromeClientImpl::registerViewportLayers() const |
886 { | 888 { |
887 if (m_webView->rootGraphicsLayer() && m_webView->layerTreeView() && m_webVie
w->pinchVirtualViewportEnabled()) | 889 if (m_webView->rootGraphicsLayer() && m_webView->layerTreeView() && m_webVie
w->pinchVirtualViewportEnabled()) |
888 m_webView->page()->frameHost().pinchViewport().registerLayersWithTreeVie
w(m_webView->layerTreeView()); | 890 m_webView->page()->frameHost().pinchViewport().registerLayersWithTreeVie
w(m_webView->layerTreeView()); |
889 } | 891 } |
890 | 892 |
891 } // namespace blink | 893 } // namespace blink |
OLD | NEW |