| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2011, 2012 Google Inc. All rights reserved. | 2 * Copyright (C) 2011, 2012 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 20 matching lines...) Expand all Loading... |
| 31 #include "config.h" | 31 #include "config.h" |
| 32 #include "web/WebViewImpl.h" | 32 #include "web/WebViewImpl.h" |
| 33 | 33 |
| 34 #include "core/CSSValueKeywords.h" | 34 #include "core/CSSValueKeywords.h" |
| 35 #include "core/HTMLNames.h" | 35 #include "core/HTMLNames.h" |
| 36 #include "core/InputTypeNames.h" | 36 #include "core/InputTypeNames.h" |
| 37 #include "core/accessibility/AXObjectCache.h" | 37 #include "core/accessibility/AXObjectCache.h" |
| 38 #include "core/clipboard/DataObject.h" | 38 #include "core/clipboard/DataObject.h" |
| 39 #include "core/dom/Document.h" | 39 #include "core/dom/Document.h" |
| 40 #include "core/dom/DocumentMarkerController.h" | 40 #include "core/dom/DocumentMarkerController.h" |
| 41 #include "core/dom/Element.h" |
| 41 #include "core/dom/Fullscreen.h" | 42 #include "core/dom/Fullscreen.h" |
| 42 #include "core/dom/NodeRenderingTraversal.h" | 43 #include "core/dom/NodeRenderingTraversal.h" |
| 43 #include "core/dom/Text.h" | 44 #include "core/dom/Text.h" |
| 44 #include "core/editing/Editor.h" | 45 #include "core/editing/Editor.h" |
| 45 #include "core/editing/FrameSelection.h" | 46 #include "core/editing/FrameSelection.h" |
| 46 #include "core/editing/HTMLInterchange.h" | 47 #include "core/editing/HTMLInterchange.h" |
| 47 #include "core/editing/InputMethodController.h" | 48 #include "core/editing/InputMethodController.h" |
| 48 #include "core/editing/TextIterator.h" | 49 #include "core/editing/TextIterator.h" |
| 49 #include "core/editing/markup.h" | 50 #include "core/editing/markup.h" |
| 50 #include "core/events/KeyboardEvent.h" | 51 #include "core/events/KeyboardEvent.h" |
| (...skipping 63 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 114 #include "platform/graphics/ImageBuffer.h" | 115 #include "platform/graphics/ImageBuffer.h" |
| 115 #include "platform/scroll/ScrollbarTheme.h" | 116 #include "platform/scroll/ScrollbarTheme.h" |
| 116 #include "platform/weborigin/SchemeRegistry.h" | 117 #include "platform/weborigin/SchemeRegistry.h" |
| 117 #include "public/platform/Platform.h" | 118 #include "public/platform/Platform.h" |
| 118 #include "public/platform/WebCompositeAndReadbackAsyncCallback.h" | 119 #include "public/platform/WebCompositeAndReadbackAsyncCallback.h" |
| 119 #include "public/platform/WebDragData.h" | 120 #include "public/platform/WebDragData.h" |
| 120 #include "public/platform/WebFloatPoint.h" | 121 #include "public/platform/WebFloatPoint.h" |
| 121 #include "public/platform/WebGestureCurve.h" | 122 #include "public/platform/WebGestureCurve.h" |
| 122 #include "public/platform/WebImage.h" | 123 #include "public/platform/WebImage.h" |
| 123 #include "public/platform/WebLayerTreeView.h" | 124 #include "public/platform/WebLayerTreeView.h" |
| 125 #include "public/platform/WebTeleportCallback.h" |
| 124 #include "public/platform/WebURLRequest.h" | 126 #include "public/platform/WebURLRequest.h" |
| 125 #include "public/platform/WebVector.h" | 127 #include "public/platform/WebVector.h" |
| 126 #include "public/web/WebAXObject.h" | 128 #include "public/web/WebAXObject.h" |
| 127 #include "public/web/WebActiveWheelFlingParameters.h" | 129 #include "public/web/WebActiveWheelFlingParameters.h" |
| 128 #include "public/web/WebAutofillClient.h" | 130 #include "public/web/WebAutofillClient.h" |
| 129 #include "public/web/WebBeginFrameArgs.h" | 131 #include "public/web/WebBeginFrameArgs.h" |
| 130 #include "public/web/WebFrameClient.h" | 132 #include "public/web/WebFrameClient.h" |
| 131 #include "public/web/WebHitTestResult.h" | 133 #include "public/web/WebHitTestResult.h" |
| 132 #include "public/web/WebInputElement.h" | 134 #include "public/web/WebInputElement.h" |
| 133 #include "public/web/WebMediaPlayerAction.h" | 135 #include "public/web/WebMediaPlayerAction.h" |
| (...skipping 4184 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 4318 WebSize scrollOffset = mainFrame()->scrollOffset(); | 4320 WebSize scrollOffset = mainFrame()->scrollOffset(); |
| 4319 scrollOffset.width += scrollDelta.width; | 4321 scrollOffset.width += scrollDelta.width; |
| 4320 scrollOffset.height += scrollDelta.height; | 4322 scrollOffset.height += scrollDelta.height; |
| 4321 | 4323 |
| 4322 WebPoint scrollPoint(scrollOffset.width, scrollOffset.height); | 4324 WebPoint scrollPoint(scrollOffset.width, scrollOffset.height); |
| 4323 setPageScaleFactor(pageScaleFactor() * pageScaleDelta, scrollPoint); | 4325 setPageScaleFactor(pageScaleFactor() * pageScaleDelta, scrollPoint); |
| 4324 m_doubleTapZoomPending = false; | 4326 m_doubleTapZoomPending = false; |
| 4325 } | 4327 } |
| 4326 } | 4328 } |
| 4327 | 4329 |
| 4330 void WebViewImpl::applyTeleportValues(const WebTeleportValues& values) |
| 4331 { |
| 4332 TRACE_EVENT1("teleport", "WebViewImpl::applyTeleportValues", "count", int(va
lues.size())); |
| 4333 Element::applyToBoundAnimatedProperties(values); |
| 4334 } |
| 4335 |
| 4328 void WebViewImpl::updateLayerTreeViewport() | 4336 void WebViewImpl::updateLayerTreeViewport() |
| 4329 { | 4337 { |
| 4330 if (!page() || !m_layerTreeView) | 4338 if (!page() || !m_layerTreeView) |
| 4331 return; | 4339 return; |
| 4332 | 4340 |
| 4333 m_layerTreeView->setPageScaleFactorAndLimits(pageScaleFactor(), minimumPageS
caleFactor(), maximumPageScaleFactor()); | 4341 m_layerTreeView->setPageScaleFactorAndLimits(pageScaleFactor(), minimumPageS
caleFactor(), maximumPageScaleFactor()); |
| 4334 } | 4342 } |
| 4335 | 4343 |
| 4336 void WebViewImpl::updateLayerTreeBackgroundColor() | 4344 void WebViewImpl::updateLayerTreeBackgroundColor() |
| 4337 { | 4345 { |
| (...skipping 135 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 4473 const PageScaleConstraints& constraints = m_pageScaleConstraintsSet.pageDefi
nedConstraints(); | 4481 const PageScaleConstraints& constraints = m_pageScaleConstraintsSet.pageDefi
nedConstraints(); |
| 4474 | 4482 |
| 4475 if (!mainFrameImpl() || !mainFrameImpl()->frameView()) | 4483 if (!mainFrameImpl() || !mainFrameImpl()->frameView()) |
| 4476 return false; | 4484 return false; |
| 4477 | 4485 |
| 4478 return mainFrameImpl()->frameView()->layoutSize().width() == m_size.width | 4486 return mainFrameImpl()->frameView()->layoutSize().width() == m_size.width |
| 4479 || (constraints.minimumScale == constraints.maximumScale && constraints.
minimumScale != -1); | 4487 || (constraints.minimumScale == constraints.maximumScale && constraints.
minimumScale != -1); |
| 4480 } | 4488 } |
| 4481 | 4489 |
| 4482 } // namespace blink | 4490 } // namespace blink |
| OLD | NEW |