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

Unified Diff: remoting/android/java/src/org/chromium/chromoting/DesktopCanvas.java

Issue 2146303002: Fixing a cursor position initialization problem (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Addressing CR Feedback Created 4 years, 5 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 | « no previous file | remoting/android/java/src/org/chromium/chromoting/TouchInputHandler.java » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: remoting/android/java/src/org/chromium/chromoting/DesktopCanvas.java
diff --git a/remoting/android/java/src/org/chromium/chromoting/DesktopCanvas.java b/remoting/android/java/src/org/chromium/chromoting/DesktopCanvas.java
index b0e9d31f33eb571c0bf63ab786d53308a95163ad..76b5a24e0adfefbfab50fa02715b43594677f807 100644
--- a/remoting/android/java/src/org/chromium/chromoting/DesktopCanvas.java
+++ b/remoting/android/java/src/org/chromium/chromoting/DesktopCanvas.java
@@ -78,6 +78,18 @@ public class DesktopCanvas {
}
/**
+ * Sets the desired center position of the viewport.
+ *
+ * @param newX The new x coordinate value for the desired center position.
+ * @param newY The new y coordinate value for the desired center position.
+ */
+ public void setViewportPosition(float newX, float newY) {
+ synchronized (mRenderData) {
+ mViewportPosition.set(newX, newY);
+ }
+ }
+
+ /**
* Returns the current size of the viewport. This size includes the offset calculations for
* any visible system UI.
*
« no previous file with comments | « no previous file | remoting/android/java/src/org/chromium/chromoting/TouchInputHandler.java » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698