| OLD | NEW |
| 1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be found | 2 // Use of this source code is governed by a BSD-style license that can be found |
| 3 // in the LICENSE file. | 3 // in the LICENSE file. |
| 4 | 4 |
| 5 #include "web/WebViewFrameWidget.h" | 5 #include "web/WebViewFrameWidget.h" |
| 6 | 6 |
| 7 #include "web/WebInputMethodControllerImpl.h" |
| 7 #include "web/WebLocalFrameImpl.h" | 8 #include "web/WebLocalFrameImpl.h" |
| 8 #include "web/WebViewImpl.h" | 9 #include "web/WebViewImpl.h" |
| 9 | 10 |
| 10 namespace blink { | 11 namespace blink { |
| 11 | 12 |
| 12 WebViewFrameWidget::WebViewFrameWidget(WebWidgetClient* client, | 13 WebViewFrameWidget::WebViewFrameWidget(WebWidgetClient* client, |
| 13 WebViewImpl& webView, | 14 WebViewImpl& webView, |
| 14 WebLocalFrameImpl& mainFrame) | 15 WebLocalFrameImpl& mainFrame) |
| 15 : m_client(client), m_webView(&webView), m_mainFrame(&mainFrame) { | 16 : m_client(client), m_webView(&webView), m_mainFrame(&mainFrame) { |
| 16 m_mainFrame->setFrameWidget(this); | 17 m_mainFrame->setFrameWidget(this); |
| (...skipping 90 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 107 } | 108 } |
| 108 | 109 |
| 109 void WebViewFrameWidget::mouseCaptureLost() { | 110 void WebViewFrameWidget::mouseCaptureLost() { |
| 110 return m_webView->mouseCaptureLost(); | 111 return m_webView->mouseCaptureLost(); |
| 111 } | 112 } |
| 112 | 113 |
| 113 void WebViewFrameWidget::setFocus(bool enable) { | 114 void WebViewFrameWidget::setFocus(bool enable) { |
| 114 return m_webView->setFocus(enable); | 115 return m_webView->setFocus(enable); |
| 115 } | 116 } |
| 116 | 117 |
| 117 bool WebViewFrameWidget::setComposition( | |
| 118 const WebString& text, | |
| 119 const WebVector<WebCompositionUnderline>& underlines, | |
| 120 int selectionStart, | |
| 121 int selectionEnd) { | |
| 122 return m_webView->setComposition(text, underlines, selectionStart, | |
| 123 selectionEnd); | |
| 124 } | |
| 125 | |
| 126 bool WebViewFrameWidget::finishComposingText( | |
| 127 ConfirmCompositionBehavior selectionBehavior) { | |
| 128 return m_webView->finishComposingText(selectionBehavior); | |
| 129 } | |
| 130 | |
| 131 bool WebViewFrameWidget::commitText(const WebString& text, | |
| 132 int relativeCaretPosition) { | |
| 133 return m_webView->commitText(text, relativeCaretPosition); | |
| 134 } | |
| 135 | |
| 136 WebRange WebViewFrameWidget::compositionRange() { | 118 WebRange WebViewFrameWidget::compositionRange() { |
| 137 return m_webView->compositionRange(); | 119 return m_webView->compositionRange(); |
| 138 } | 120 } |
| 139 | 121 |
| 140 WebTextInputInfo WebViewFrameWidget::textInputInfo() { | 122 WebTextInputInfo WebViewFrameWidget::textInputInfo() { |
| 141 return m_webView->textInputInfo(); | 123 return m_webView->textInputInfo(); |
| 142 } | 124 } |
| 143 | 125 |
| 144 WebTextInputType WebViewFrameWidget::textInputType() { | 126 WebTextInputType WebViewFrameWidget::textInputType() { |
| 145 return m_webView->textInputType(); | 127 return m_webView->textInputType(); |
| (...skipping 79 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 225 } | 207 } |
| 226 | 208 |
| 227 void WebViewFrameWidget::setBaseBackgroundColor(WebColor color) { | 209 void WebViewFrameWidget::setBaseBackgroundColor(WebColor color) { |
| 228 m_webView->setBaseBackgroundColor(color); | 210 m_webView->setBaseBackgroundColor(color); |
| 229 } | 211 } |
| 230 | 212 |
| 231 WebLocalFrameImpl* WebViewFrameWidget::localRoot() { | 213 WebLocalFrameImpl* WebViewFrameWidget::localRoot() { |
| 232 return m_webView->mainFrameImpl(); | 214 return m_webView->mainFrameImpl(); |
| 233 } | 215 } |
| 234 | 216 |
| 217 WebInputMethodControllerImpl* |
| 218 WebViewFrameWidget::getActiveWebInputMethodController() const { |
| 219 return m_webView->getActiveWebInputMethodController(); |
| 220 } |
| 221 |
| 235 void WebViewFrameWidget::scheduleAnimation() { | 222 void WebViewFrameWidget::scheduleAnimation() { |
| 236 m_webView->scheduleAnimationForWidget(); | 223 m_webView->scheduleAnimationForWidget(); |
| 237 } | 224 } |
| 238 | 225 |
| 239 CompositorProxyClient* WebViewFrameWidget::createCompositorProxyClient() { | 226 CompositorProxyClient* WebViewFrameWidget::createCompositorProxyClient() { |
| 240 return m_webView->createCompositorProxyClient(); | 227 return m_webView->createCompositorProxyClient(); |
| 241 } | 228 } |
| 242 | 229 |
| 243 void WebViewFrameWidget::setRootGraphicsLayer(GraphicsLayer* layer) { | 230 void WebViewFrameWidget::setRootGraphicsLayer(GraphicsLayer* layer) { |
| 244 m_webView->setRootGraphicsLayer(layer); | 231 m_webView->setRootGraphicsLayer(layer); |
| (...skipping 11 matching lines...) Expand all Loading... |
| 256 void WebViewFrameWidget::detachCompositorAnimationTimeline( | 243 void WebViewFrameWidget::detachCompositorAnimationTimeline( |
| 257 CompositorAnimationTimeline* compositorTimeline) { | 244 CompositorAnimationTimeline* compositorTimeline) { |
| 258 m_webView->detachCompositorAnimationTimeline(compositorTimeline); | 245 m_webView->detachCompositorAnimationTimeline(compositorTimeline); |
| 259 } | 246 } |
| 260 | 247 |
| 261 HitTestResult WebViewFrameWidget::coreHitTestResultAt(const WebPoint& point) { | 248 HitTestResult WebViewFrameWidget::coreHitTestResultAt(const WebPoint& point) { |
| 262 return m_webView->coreHitTestResultAt(point); | 249 return m_webView->coreHitTestResultAt(point); |
| 263 } | 250 } |
| 264 | 251 |
| 265 } // namespace blink | 252 } // namespace blink |
| OLD | NEW |