diff options
author | Simon Hausmann <simon.hausmann@digia.com> | 2012-11-07 11:22:47 +0100 |
---|---|---|
committer | Simon Hausmann <simon.hausmann@digia.com> | 2012-11-07 11:22:47 +0100 |
commit | cfd86b747d32ac22246a1aa908eaa720c63a88c1 (patch) | |
tree | 24d68c6f61c464ecba1e05670b80390ea3b0e50c /Source/WebKit2/UIProcess/PageViewportController.h | |
parent | 69d7c744c9de19d152dbe2d8e46eb7dfd4511d1a (diff) | |
download | qtwebkit-cfd86b747d32ac22246a1aa908eaa720c63a88c1.tar.gz |
Imported WebKit commit 20271caf2e2c016d5cef40184cddeefeac4f1876 (http://svn.webkit.org/repository/webkit/trunk@133733)
New snapshot that contains all previous fixes as well as build fix for latest QtMultimedia API changes.
Diffstat (limited to 'Source/WebKit2/UIProcess/PageViewportController.h')
-rw-r--r-- | Source/WebKit2/UIProcess/PageViewportController.h | 33 |
1 files changed, 4 insertions, 29 deletions
diff --git a/Source/WebKit2/UIProcess/PageViewportController.h b/Source/WebKit2/UIProcess/PageViewportController.h index d38ddb914..97463216b 100644 --- a/Source/WebKit2/UIProcess/PageViewportController.h +++ b/Source/WebKit2/UIProcess/PageViewportController.h @@ -22,6 +22,8 @@ #ifndef PageViewportController_h #define PageViewportController_h +#if USE(TILED_BACKING_STORE) + #include <WebCore/FloatPoint.h> #include <WebCore/FloatRect.h> #include <WebCore/FloatSize.h> @@ -38,32 +40,6 @@ class WebPageProxy; class PageViewportController; class PageViewportControllerClient; -// When interacting with the content, either by animating or by the hand of the user, -// it is important to ensure smooth animations of at least 60fps in order to give a -// good user experience. -// -// In order to do this we need to get rid of unknown factors. These include device -// sensors (geolocation, orientation updates etc), CSS3 animations, JavaScript -// exectution, sub resource loads etc. -// We do this by sending suspend and resume notifications to the web process. -// -// For this purpose the ViewportUpdateDeferrer guard can be used when interacting -// with or animating the content to scope suspend / resume and defer update -// notifications. -// -// If something should only be executed when the content is suspended, it is possible -// to check for that using ASSERT(hasSuspendedContent()). - -class ViewportUpdateDeferrer { -public: - enum SuspendContentFlag { DeferUpdate, DeferUpdateAndSuspendContent }; - ViewportUpdateDeferrer(PageViewportController*, SuspendContentFlag = DeferUpdate); - ~ViewportUpdateDeferrer(); - -private: - PageViewportController* const m_controller; -}; - class PageViewportController { WTF_MAKE_NONCOPYABLE(PageViewportController); @@ -119,7 +95,6 @@ private: bool m_allowsUserScaling; float m_minimumScaleToFit; - int m_activeDeferrerCount; bool m_hasSuspendedContent; bool m_hadUserInteraction; @@ -132,12 +107,12 @@ private: bool m_viewportPosIsLocked; bool m_effectiveScaleIsLocked; WebCore::FloatRect m_lastFrameCoveredRect; - - friend class ViewportUpdateDeferrer; }; bool fuzzyCompare(float, float, float epsilon); } // namespace WebKit +#endif + #endif // PageViewportController_h |