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

Unified Diff: pdf/paint_manager.h

Issue 2400743002: Improved Pinch-Zoom for PDF. (Closed)
Patch Set: Small changes. Created 4 years, 1 month 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 | « pdf/out_of_process_instance.cc ('k') | pdf/paint_manager.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: pdf/paint_manager.h
diff --git a/pdf/paint_manager.h b/pdf/paint_manager.h
index dd99f9d2a61f4203be6d884667a268783a3f6ad7..16dcb773782ff6d4ed26593ad534cfd4d6c46616 100644
--- a/pdf/paint_manager.h
+++ b/pdf/paint_manager.h
@@ -146,6 +146,18 @@ class PaintManager {
pp::Size GetEffectiveSize() const;
float GetEffectiveDeviceScale() const;
+ // Set the transform for the graphics layer.
+ // If |schedule_flush| is true, it ensures a flush will be scheduled for
+ // this change. If |schedule_flush| is false, then the change will not take
+ // effect until another change causes a flush.
+ void SetTransform(float scale,
+ const pp::Point& origin,
+ const pp::Point& translate,
+ bool schedule_flush);
+ // Resets any transform for the graphics layer.
+ // This does not schedule a flush.
+ void ClearTransform();
+
private:
// Disallow copy and assign (these are unimplemented).
PaintManager(const PaintManager&);
@@ -160,6 +172,9 @@ class PaintManager {
// Does the client paint and executes a Flush if necessary.
void DoPaint();
+ // Executes a Flush.
+ void Flush();
+
// Callback for asynchronous completion of Flush.
void OnFlushComplete(int32_t);
@@ -185,6 +200,7 @@ class PaintManager {
// See comment for EnsureCallbackPending for more on how these work.
bool manual_callback_pending_;
bool flush_pending_;
+ bool flush_requested_;
// When we get a resize, we don't bind right away (see SetSize). The
// has_pending_resize_ tells us that we need to do a resize for the next
« no previous file with comments | « pdf/out_of_process_instance.cc ('k') | pdf/paint_manager.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698