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 101 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
112 #include "public/platform/Platform.h" | 112 #include "public/platform/Platform.h" |
113 #include "public/platform/WebDragData.h" | 113 #include "public/platform/WebDragData.h" |
114 #include "public/platform/WebFloatPoint.h" | 114 #include "public/platform/WebFloatPoint.h" |
115 #include "public/platform/WebGestureCurve.h" | 115 #include "public/platform/WebGestureCurve.h" |
116 #include "public/platform/WebImage.h" | 116 #include "public/platform/WebImage.h" |
117 #include "public/platform/WebLayerTreeView.h" | 117 #include "public/platform/WebLayerTreeView.h" |
118 #include "public/platform/WebVector.h" | 118 #include "public/platform/WebVector.h" |
119 #include "public/web/WebAXObject.h" | 119 #include "public/web/WebAXObject.h" |
120 #include "public/web/WebActiveWheelFlingParameters.h" | 120 #include "public/web/WebActiveWheelFlingParameters.h" |
121 #include "public/web/WebAutofillClient.h" | 121 #include "public/web/WebAutofillClient.h" |
| 122 #include "public/web/WebBeginFrameArgs.h" |
122 #include "public/web/WebFrameClient.h" | 123 #include "public/web/WebFrameClient.h" |
123 #include "public/web/WebHitTestResult.h" | 124 #include "public/web/WebHitTestResult.h" |
124 #include "public/web/WebInputElement.h" | 125 #include "public/web/WebInputElement.h" |
125 #include "public/web/WebMediaPlayerAction.h" | 126 #include "public/web/WebMediaPlayerAction.h" |
126 #include "public/web/WebNode.h" | 127 #include "public/web/WebNode.h" |
127 #include "public/web/WebPlugin.h" | 128 #include "public/web/WebPlugin.h" |
128 #include "public/web/WebPluginAction.h" | 129 #include "public/web/WebPluginAction.h" |
129 #include "public/web/WebRange.h" | 130 #include "public/web/WebRange.h" |
130 #include "public/web/WebTextInputInfo.h" | 131 #include "public/web/WebTextInputInfo.h" |
131 #include "public/web/WebViewClient.h" | 132 #include "public/web/WebViewClient.h" |
(...skipping 1561 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1693 void WebViewImpl::willExitFullScreen() | 1694 void WebViewImpl::willExitFullScreen() |
1694 { | 1695 { |
1695 m_fullscreenController->willExitFullScreen(); | 1696 m_fullscreenController->willExitFullScreen(); |
1696 } | 1697 } |
1697 | 1698 |
1698 void WebViewImpl::didExitFullScreen() | 1699 void WebViewImpl::didExitFullScreen() |
1699 { | 1700 { |
1700 m_fullscreenController->didExitFullScreen(); | 1701 m_fullscreenController->didExitFullScreen(); |
1701 } | 1702 } |
1702 | 1703 |
1703 void WebViewImpl::animate(double monotonicFrameBeginTime) | 1704 void WebViewImpl::beginFrame(const WebBeginFrameArgs& frameTime) |
1704 { | 1705 { |
1705 TRACE_EVENT0("blink", "WebViewImpl::animate"); | 1706 TRACE_EVENT0("blink", "WebViewImpl::beginFrame"); |
1706 | 1707 |
| 1708 double monotonicFrameBeginTime = frameTime.lastFrameTimeMonotonic; |
1707 if (!monotonicFrameBeginTime) | 1709 if (!monotonicFrameBeginTime) |
1708 monotonicFrameBeginTime = monotonicallyIncreasingTime(); | 1710 monotonicFrameBeginTime = monotonicallyIncreasingTime(); |
1709 | 1711 |
1710 // Create synthetic wheel events as necessary for fling. | 1712 // Create synthetic wheel events as necessary for fling. |
1711 if (m_gestureAnimation) { | 1713 if (m_gestureAnimation) { |
1712 if (m_gestureAnimation->animate(monotonicFrameBeginTime)) | 1714 if (m_gestureAnimation->animate(monotonicFrameBeginTime)) |
1713 scheduleAnimation(); | 1715 scheduleAnimation(); |
1714 else { | 1716 else { |
1715 endActiveFlingAnimation(); | 1717 endActiveFlingAnimation(); |
1716 | 1718 |
(...skipping 2497 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
4214 const PageScaleConstraints& constraints = m_pageScaleConstraintsSet.pageDefi
nedConstraints(); | 4216 const PageScaleConstraints& constraints = m_pageScaleConstraintsSet.pageDefi
nedConstraints(); |
4215 | 4217 |
4216 if (!mainFrameImpl() || !mainFrameImpl()->frameView()) | 4218 if (!mainFrameImpl() || !mainFrameImpl()->frameView()) |
4217 return false; | 4219 return false; |
4218 | 4220 |
4219 return mainFrameImpl()->frameView()->layoutSize().width() == m_size.width | 4221 return mainFrameImpl()->frameView()->layoutSize().width() == m_size.width |
4220 || (constraints.minimumScale == constraints.maximumScale && constraints.
minimumScale != -1); | 4222 || (constraints.minimumScale == constraints.maximumScale && constraints.
minimumScale != -1); |
4221 } | 4223 } |
4222 | 4224 |
4223 } // namespace blink | 4225 } // namespace blink |
OLD | NEW |