| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include "content/renderer/render_view_impl.h" | 5 #include "content/renderer/render_view_impl.h" |
| 6 | 6 |
| 7 #include <algorithm> | 7 #include <algorithm> |
| 8 #include <cmath> | 8 #include <cmath> |
| 9 | 9 |
| 10 #include "base/auto_reset.h" | 10 #include "base/auto_reset.h" |
| (...skipping 3136 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3147 WebFrame* focused_frame = webview()->focusedFrame(); | 3147 WebFrame* focused_frame = webview()->focusedFrame(); |
| 3148 if (focused_frame) { | 3148 if (focused_frame) { |
| 3149 WebDocument doc = focused_frame->document(); | 3149 WebDocument doc = focused_frame->document(); |
| 3150 if (!doc.isNull()) | 3150 if (!doc.isNull()) |
| 3151 return doc.focusedElement(); | 3151 return doc.focusedElement(); |
| 3152 } | 3152 } |
| 3153 | 3153 |
| 3154 return WebElement(); | 3154 return WebElement(); |
| 3155 } | 3155 } |
| 3156 | 3156 |
| 3157 blink::WebNode RenderViewImpl::GetContextMenuNode() const { | |
| 3158 return context_menu_node_; | |
| 3159 } | |
| 3160 | |
| 3161 bool RenderViewImpl::IsEditableNode(const WebNode& node) const { | 3157 bool RenderViewImpl::IsEditableNode(const WebNode& node) const { |
| 3162 if (node.isNull()) | 3158 if (node.isNull()) |
| 3163 return false; | 3159 return false; |
| 3164 | 3160 |
| 3165 if (node.isContentEditable()) | 3161 if (node.isContentEditable()) |
| 3166 return true; | 3162 return true; |
| 3167 | 3163 |
| 3168 if (node.isElementNode()) { | 3164 if (node.isElementNode()) { |
| 3169 const WebElement& element = node.toConst<WebElement>(); | 3165 const WebElement& element = node.toConst<WebElement>(); |
| 3170 if (element.isTextFormControlElement()) | 3166 if (element.isTextFormControlElement()) |
| (...skipping 1986 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 5157 for (size_t i = 0; i < icon_urls.size(); i++) { | 5153 for (size_t i = 0; i < icon_urls.size(); i++) { |
| 5158 WebURL url = icon_urls[i].iconURL(); | 5154 WebURL url = icon_urls[i].iconURL(); |
| 5159 if (!url.isEmpty()) | 5155 if (!url.isEmpty()) |
| 5160 urls.push_back(FaviconURL(url, | 5156 urls.push_back(FaviconURL(url, |
| 5161 ToFaviconType(icon_urls[i].iconType()))); | 5157 ToFaviconType(icon_urls[i].iconType()))); |
| 5162 } | 5158 } |
| 5163 SendUpdateFaviconURL(urls); | 5159 SendUpdateFaviconURL(urls); |
| 5164 } | 5160 } |
| 5165 | 5161 |
| 5166 } // namespace content | 5162 } // namespace content |
| OLD | NEW |