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

Side by Side Diff: pdf/out_of_process_instance.h

Issue 2781613002: PDF Viewer pinch zoom: Update state for zoom in following a zoom out. (Closed)
Patch Set: Remove redundant code and clarify variable. Created 3 years, 8 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 unified diff | Download patch
« no previous file with comments | « no previous file | pdf/out_of_process_instance.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef PDF_OUT_OF_PROCESS_INSTANCE_H_ 5 #ifndef PDF_OUT_OF_PROCESS_INSTANCE_H_
6 #define PDF_OUT_OF_PROCESS_INSTANCE_H_ 6 #define PDF_OUT_OF_PROCESS_INSTANCE_H_
7 7
8 #include <stdint.h> 8 #include <stdint.h>
9 #include <string.h> 9 #include <string.h>
10 10
(...skipping 231 matching lines...) Expand 10 before | Expand all | Expand 10 after
242 enum PinchPhase { 242 enum PinchPhase {
243 PINCH_NONE = 0, 243 PINCH_NONE = 0,
244 PINCH_START = 1, 244 PINCH_START = 1,
245 PINCH_UPDATE_ZOOM_OUT = 2, 245 PINCH_UPDATE_ZOOM_OUT = 2,
246 PINCH_UPDATE_ZOOM_IN = 3, 246 PINCH_UPDATE_ZOOM_IN = 3,
247 PINCH_END = 4 247 PINCH_END = 4
248 }; 248 };
249 249
250 // Current zoom factor. 250 // Current zoom factor.
251 double zoom_; 251 double zoom_;
252 double initial_zoom_ratio_;
253 // True if we request a new bitmap rendering. 252 // True if we request a new bitmap rendering.
254 bool needs_reraster_; 253 bool needs_reraster_;
255 // Scroll position at the start of a pinch zoom. 254 // The scroll position for the last raster, before any transformations are
256 pp::FloatPoint starting_scroll_offset_; 255 // applied.
256 pp::FloatPoint scroll_offset_at_last_raster_;
257 // True if last bitmap was smaller than screen. 257 // True if last bitmap was smaller than screen.
258 bool last_bitmap_smaller_; 258 bool last_bitmap_smaller_;
259 // Current device scale factor. 259 // Current device scale factor.
260 float device_scale_; 260 float device_scale_;
261 // True if the plugin is full-page. 261 // True if the plugin is full-page.
262 bool full_; 262 bool full_;
263 263
264 PaintManager paint_manager_; 264 PaintManager paint_manager_;
265 265
266 struct BackgroundPart { 266 struct BackgroundPart {
(...skipping 122 matching lines...) Expand 10 before | Expand all | Expand 10 after
389 389
390 // True if the plugin is loaded in print preview, otherwise false. 390 // True if the plugin is loaded in print preview, otherwise false.
391 bool is_print_preview_; 391 bool is_print_preview_;
392 392
393 DISALLOW_COPY_AND_ASSIGN(OutOfProcessInstance); 393 DISALLOW_COPY_AND_ASSIGN(OutOfProcessInstance);
394 }; 394 };
395 395
396 } // namespace chrome_pdf 396 } // namespace chrome_pdf
397 397
398 #endif // PDF_OUT_OF_PROCESS_INSTANCE_H_ 398 #endif // PDF_OUT_OF_PROCESS_INSTANCE_H_
OLDNEW
« no previous file with comments | « no previous file | pdf/out_of_process_instance.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698