Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(772)

Unified Diff: cc/pinch_zoom_viewport.h

Issue 12045002: Delete zoomed_viewport_offset_ and its users. (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: Add imports for DisabledTest and rebase to 179449 Created 7 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « cc/layer_tree_impl.cc ('k') | cc/pinch_zoom_viewport.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/pinch_zoom_viewport.h
diff --git a/cc/pinch_zoom_viewport.h b/cc/pinch_zoom_viewport.h
index 9efe38667345bcbece241c50e5f493250ebe1319..52a4186217022dd54b3b3aef37cb9440a86d34ad 100644
--- a/cc/pinch_zoom_viewport.h
+++ b/cc/pinch_zoom_viewport.h
@@ -11,10 +11,6 @@
namespace cc {
-// PinchZoomViewport models the bounds and offset of the viewport that is used
-// during a pinch-zoom operation. It tracks the layout-space dimensions of the
-// viewport before any applied scale, and then tracks the layout-space
-// coordinates of the viewport respecting the pinch settings.
class CC_EXPORT PinchZoomViewport {
public:
PinchZoomViewport();
@@ -47,15 +43,6 @@ class CC_EXPORT PinchZoomViewport {
float min_page_scale_factor,
float max_page_scale_factor);
- // Returns the zoomed viewport in layout space. The rect's position is an
- // offset from the root layer's scroll position (therefore, zero if fully
- // zoomed out).
- gfx::RectF ZoomedViewport() const;
-
- const gfx::Vector2dF& zoomed_viewport_offset() const {
- return zoomed_viewport_offset_;
- }
-
void set_layout_viewport_size(const gfx::SizeF& size) {
layout_viewport_size_ = size;
}
@@ -66,16 +53,9 @@ class CC_EXPORT PinchZoomViewport {
device_viewport_size_ = size;
}
- // Apply the scroll offset in layout space to the offset of the pinch-zoom
- // viewport. The viewport cannot be scrolled outside of the layout viewport
- // bounds. Returns the component of the scroll that is un-applied due to this
- // constraint.
- gfx::Vector2dF ApplyScroll(const gfx::Vector2dF);
-
- // The implTransform goes from the origin of the unzoomedDeviceViewport to the
- // origin of the zoomedDeviceViewport.
+ // The implTransform applies the page scale transformation.
//
- // implTransform = S[pageScale] * Tr[-zoomedDeviceViewportOffset]
+ // implTransform = S[pageScaleFactor] * S[pageScaleDelta]
gfx::Transform ImplTransform(bool page_scale_pinch_zoom_enabled) const;
private:
@@ -86,7 +66,6 @@ class CC_EXPORT PinchZoomViewport {
float min_page_scale_factor_;
float device_scale_factor_;
- gfx::Vector2dF zoomed_viewport_offset_;
gfx::SizeF layout_viewport_size_;
gfx::SizeF device_viewport_size_;
};
« no previous file with comments | « cc/layer_tree_impl.cc ('k') | cc/pinch_zoom_viewport.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698