OLD | NEW |
---|---|
1 /* | 1 /* |
2 * Copyright (C) 2014 Google Inc. All rights reserved. | 2 * Copyright (C) 2014 Google Inc. All rights reserved. |
3 * | 3 * |
4 * Redistribution and use in source and binary forms, with or without | 4 * Redistribution and use in source and binary forms, with or without |
5 * modification, are permitted provided that the following conditions are | 5 * modification, are permitted provided that the following conditions are |
6 * met: | 6 * met: |
7 * | 7 * |
8 * * Redistributions of source code must retain the above copyright | 8 * * Redistributions of source code must retain the above copyright |
9 * notice, this list of conditions and the following disclaimer. | 9 * notice, this list of conditions and the following disclaimer. |
10 * * Redistributions in binary form must reproduce the above | 10 * * Redistributions in binary form must reproduce the above |
(...skipping 17 matching lines...) Expand all Loading... | |
28 * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. | 28 * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. |
29 */ | 29 */ |
30 | 30 |
31 #include "web/WebFrameWidgetImpl.h" | 31 #include "web/WebFrameWidgetImpl.h" |
32 | 32 |
33 #include "core/editing/EditingUtilities.h" | 33 #include "core/editing/EditingUtilities.h" |
34 #include "core/editing/Editor.h" | 34 #include "core/editing/Editor.h" |
35 #include "core/editing/FrameSelection.h" | 35 #include "core/editing/FrameSelection.h" |
36 #include "core/editing/InputMethodController.h" | 36 #include "core/editing/InputMethodController.h" |
37 #include "core/editing/PlainTextRange.h" | 37 #include "core/editing/PlainTextRange.h" |
38 #include "core/frame/FrameHost.h" | |
38 #include "core/frame/FrameView.h" | 39 #include "core/frame/FrameView.h" |
39 #include "core/frame/RemoteFrame.h" | 40 #include "core/frame/RemoteFrame.h" |
40 #include "core/frame/Settings.h" | 41 #include "core/frame/Settings.h" |
41 #include "core/input/EventHandler.h" | 42 #include "core/input/EventHandler.h" |
42 #include "core/layout/LayoutView.h" | 43 #include "core/layout/LayoutView.h" |
43 #include "core/layout/compositing/PaintLayerCompositor.h" | 44 #include "core/layout/compositing/PaintLayerCompositor.h" |
44 #include "core/page/ContextMenuController.h" | 45 #include "core/page/ContextMenuController.h" |
45 #include "core/page/FocusController.h" | 46 #include "core/page/FocusController.h" |
46 #include "core/page/Page.h" | 47 #include "core/page/Page.h" |
47 #include "platform/KeyboardCodes.h" | 48 #include "platform/KeyboardCodes.h" |
(...skipping 144 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
192 updateLayerTreeViewport(); | 193 updateLayerTreeViewport(); |
193 } else { | 194 } else { |
194 WebRect damagedRect(0, 0, m_size.width, m_size.height); | 195 WebRect damagedRect(0, 0, m_size.width, m_size.height); |
195 m_client->didInvalidateRect(damagedRect); | 196 m_client->didInvalidateRect(damagedRect); |
196 } | 197 } |
197 } | 198 } |
198 } | 199 } |
199 | 200 |
200 void WebFrameWidgetImpl::resizeVisualViewport(const WebSize& newSize) | 201 void WebFrameWidgetImpl::resizeVisualViewport(const WebSize& newSize) |
201 { | 202 { |
202 // FIXME: Implement visual viewport for out-of-process iframes. | 203 page()->frameHost().visualViewport().setSize(newSize); |
204 page()->frameHost().visualViewport().clampToBoundaries(); | |
alexmos
2016/03/26 00:00:48
Note that I didn't have to add any plumbing for se
kenrb
2016/03/31 17:41:58
Eventually we might want to change some of the res
alexmos
2016/03/31 23:03:47
Good point. I suppose this means that in cases li
| |
203 } | 205 } |
204 | 206 |
205 void WebFrameWidgetImpl::updateMainFrameLayoutSize() | 207 void WebFrameWidgetImpl::updateMainFrameLayoutSize() |
206 { | 208 { |
207 if (!m_localRoot) | 209 if (!m_localRoot) |
208 return; | 210 return; |
209 | 211 |
210 RefPtrWillBeRawPtr<FrameView> view = m_localRoot->frameView(); | 212 RefPtrWillBeRawPtr<FrameView> view = m_localRoot->frameView(); |
211 if (!view) | 213 if (!view) |
212 return; | 214 return; |
(...skipping 880 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
1093 | 1095 |
1094 HitTestResult WebFrameWidgetImpl::hitTestResultForRootFramePos(const IntPoint& p osInRootFrame) | 1096 HitTestResult WebFrameWidgetImpl::hitTestResultForRootFramePos(const IntPoint& p osInRootFrame) |
1095 { | 1097 { |
1096 IntPoint docPoint(m_localRoot->frame()->view()->rootFrameToContents(posInRoo tFrame)); | 1098 IntPoint docPoint(m_localRoot->frame()->view()->rootFrameToContents(posInRoo tFrame)); |
1097 HitTestResult result = m_localRoot->frame()->eventHandler().hitTestResultAtP oint(docPoint, HitTestRequest::ReadOnly | HitTestRequest::Active); | 1099 HitTestResult result = m_localRoot->frame()->eventHandler().hitTestResultAtP oint(docPoint, HitTestRequest::ReadOnly | HitTestRequest::Active); |
1098 result.setToShadowHostIfInUserAgentShadowRoot(); | 1100 result.setToShadowHostIfInUserAgentShadowRoot(); |
1099 return result; | 1101 return result; |
1100 } | 1102 } |
1101 | 1103 |
1102 } // namespace blink | 1104 } // namespace blink |
OLD | NEW |