| Index: ui/android/java/src/org/chromium/ui/display/DisplayAndroid.java
|
| diff --git a/ui/android/java/src/org/chromium/ui/display/DisplayAndroid.java b/ui/android/java/src/org/chromium/ui/display/DisplayAndroid.java
|
| index 9092e61c2f2bf15cd61bfcfa5e63e681184bf220..7bb899059bd0bcc379e08d40abe0157889a674a9 100644
|
| --- a/ui/android/java/src/org/chromium/ui/display/DisplayAndroid.java
|
| +++ b/ui/android/java/src/org/chromium/ui/display/DisplayAndroid.java
|
| @@ -46,7 +46,6 @@ public class DisplayAndroid {
|
|
|
| private final int mDisplayId;
|
| private Point mSize;
|
| - private Point mPhysicalSize;
|
| private float mDipScale;
|
| private int mBitsPerPixel;
|
| private int mBitsPerComponent;
|
| @@ -98,20 +97,6 @@ public class DisplayAndroid {
|
| }
|
|
|
| /**
|
| - * @return Real physical display height in physical pixels. Or 0 if not supported.
|
| - */
|
| - public int getPhysicalDisplayHeight() {
|
| - return mPhysicalSize.y;
|
| - }
|
| -
|
| - /**
|
| - * @return Real physical display width in physical pixels. Or 0 if not supported.
|
| - */
|
| - public int getPhysicalDisplayWidth() {
|
| - return mPhysicalSize.x;
|
| - }
|
| -
|
| - /**
|
| * @return current orientation. One of Surface.ORIENTATION_* values.
|
| */
|
| public int getRotation() {
|
| @@ -195,7 +180,6 @@ public class DisplayAndroid {
|
| mDisplayId = displayId;
|
| mObservers = new WeakHashMap<>();
|
| mSize = new Point();
|
| - mPhysicalSize = new Point();
|
| }
|
|
|
| private DisplayAndroidObserver[] getObservers() {
|
| @@ -206,24 +190,22 @@ public class DisplayAndroid {
|
| /**
|
| * Update the display to the provided parameters. Null values leave the parameter unchanged.
|
| */
|
| - protected void update(Point size, Point physicalSize, Float dipScale, Integer bitsPerPixel,
|
| + protected void update(Point size, Float dipScale, Integer bitsPerPixel,
|
| Integer bitsPerComponent, Integer rotation) {
|
| boolean sizeChanged = size != null && !mSize.equals(size);
|
| - boolean physicalSizeChanged = physicalSize != null && !mPhysicalSize.equals(physicalSize);
|
| // Intentional comparison of floats: we assume that if scales differ, they differ
|
| // significantly.
|
| boolean dipScaleChanged = dipScale != null && mDipScale != dipScale;
|
| boolean bitsPerPixelChanged = bitsPerPixel != null && mBitsPerPixel != bitsPerPixel;
|
| - boolean bitsPerComponentChanged = bitsPerComponent != null
|
| - && mBitsPerComponent != bitsPerComponent;
|
| + boolean bitsPerComponentChanged =
|
| + bitsPerComponent != null && mBitsPerComponent != bitsPerComponent;
|
| boolean rotationChanged = rotation != null && mRotation != rotation;
|
|
|
| - boolean changed = sizeChanged || physicalSizeChanged || dipScaleChanged
|
| - || bitsPerPixelChanged || bitsPerComponentChanged || rotationChanged;
|
| + boolean changed = sizeChanged || dipScaleChanged || bitsPerPixelChanged
|
| + || bitsPerComponentChanged || rotationChanged;
|
| if (!changed) return;
|
|
|
| if (sizeChanged) mSize = size;
|
| - if (physicalSizeChanged) mPhysicalSize = physicalSize;
|
| if (dipScaleChanged) mDipScale = dipScale;
|
| if (bitsPerPixelChanged) mBitsPerPixel = bitsPerPixel;
|
| if (bitsPerComponentChanged) mBitsPerComponent = bitsPerComponent;
|
|
|