Index: ui/android/java/src/org/chromium/ui/base/EventHandler.java |
diff --git a/ui/android/java/src/org/chromium/ui/base/EventHandler.java b/ui/android/java/src/org/chromium/ui/base/EventHandler.java |
new file mode 100644 |
index 0000000000000000000000000000000000000000..38a2ba3480dd03af7f8e2e7bc67d47ed565da7aa |
--- /dev/null |
+++ b/ui/android/java/src/org/chromium/ui/base/EventHandler.java |
@@ -0,0 +1,29 @@ |
+// Copyright 2016 The Chromium Authors. All rights reserved. |
+// Use of this source code is governed by a BSD-style license that can be |
+// found in the LICENSE file. |
+ |
+package org.chromium.ui.base; |
+ |
+import org.chromium.base.annotations.JNINamespace; |
+ |
+/** |
+ * Class used to forward view, input events down to native. |
+ */ |
+@JNINamespace("ui") |
+public class EventHandler { |
+ private final long mNativeEventHandler; |
+ |
+ private int mPhysicalBackingWidthPix; |
+ private int mPhysicalBackingHeightPix; |
+ |
+ public EventHandler(long nativeEventHandler) { |
+ mNativeEventHandler = nativeEventHandler; |
+ } |
+ |
+ public void onPhysicalBackingSizeChanged(int width, int height) { |
+ nativeOnPhysicalBackingSizeChanged(mNativeEventHandler, width, height); |
+ } |
+ |
+ private native void nativeOnPhysicalBackingSizeChanged(long nativeEventHandler, |
+ int width, int height); |
+} |