diff options
author | Ricardo Cerqueira <cyanogenmod@cerqueira.org> | 2013-02-13 14:24:59 +0000 |
---|---|---|
committer | Ricardo Cerqueira <cyanogenmod@cerqueira.org> | 2013-02-15 00:30:09 +0000 |
commit | 4815d6e5a658bb1b301f7724c8e8fff6bc764bba (patch) | |
tree | 66f6e6484d239545197d73bcca8ad2505246c981 /core/java/android/hardware | |
parent | eaa7d1835c8691dd656fea99ae3d61b039ebe1b7 (diff) | |
parent | 763ef60466ac752a3031719fb86b08486c9946b1 (diff) | |
download | frameworks_base-4815d6e5a658bb1b301f7724c8e8fff6bc764bba.zip frameworks_base-4815d6e5a658bb1b301f7724c8e8fff6bc764bba.tar.gz frameworks_base-4815d6e5a658bb1b301f7724c8e8fff6bc764bba.tar.bz2 |
Merge commit 'android-4.2.2_r1' into mr1.1-staging
Conflicts:
core/java/android/os/Trace.java
core/java/android/widget/Toast.java
core/res/res/values-cs/strings.xml
core/res/res/values-el/strings.xml
core/res/res/values-iw/strings.xml
core/res/res/values/config.xml
core/res/res/values/symbols.xml
media/java/android/media/AudioService.java
packages/SystemUI/res/values-sv/strings.xml
packages/SystemUI/src/com/android/systemui/statusbar/phone/NotificationPanelView.java
packages/SystemUI/src/com/android/systemui/statusbar/policy/BatteryController.java
packages/SystemUI/src/com/android/systemui/usb/StorageNotification.java
policy/src/com/android/internal/policy/impl/keyguard/KeyguardHostView.java
policy/src/com/android/internal/policy/impl/keyguard/KeyguardMessageArea.java
policy/src/com/android/internal/policy/impl/keyguard/KeyguardViewManager.java
policy/src/com/android/internal/policy/impl/keyguard/KeyguardViewMediator.java
services/java/com/android/server/NotificationManagerService.java
services/java/com/android/server/power/ElectronBeam.java
Change-Id: I60b8ddf20a1d7bcf9dc7b1a4ed841aaa4d953294
Diffstat (limited to 'core/java/android/hardware')
-rw-r--r-- | core/java/android/hardware/SensorEventListener.java | 2 | ||||
-rw-r--r-- | core/java/android/hardware/display/WifiDisplay.java | 9 |
2 files changed, 10 insertions, 1 deletions
diff --git a/core/java/android/hardware/SensorEventListener.java b/core/java/android/hardware/SensorEventListener.java index 716d0d4..677d244 100644 --- a/core/java/android/hardware/SensorEventListener.java +++ b/core/java/android/hardware/SensorEventListener.java @@ -30,7 +30,7 @@ public interface SensorEventListener { * * <p><b>NOTE:</b> The application doesn't own the * {@link android.hardware.SensorEvent event} - * object passed as a parameter and therefore cannot hold on o it. + * object passed as a parameter and therefore cannot hold on to it. * The object may be part of an internal pool and may be reused by * the framework. * diff --git a/core/java/android/hardware/display/WifiDisplay.java b/core/java/android/hardware/display/WifiDisplay.java index 0138b1c..2fd52b8 100644 --- a/core/java/android/hardware/display/WifiDisplay.java +++ b/core/java/android/hardware/display/WifiDisplay.java @@ -107,6 +107,15 @@ public final class WifiDisplay implements Parcelable { && Objects.equal(mDeviceAlias, other.mDeviceAlias); } + /** + * Returns true if the other display is not null and has the same address as this one. + * Can be used to perform identity comparisons on displays ignoring properties + * that might change during a connection such as the name or alias. + */ + public boolean hasSameAddress(WifiDisplay other) { + return other != null && mDeviceAddress.equals(other.mDeviceAddress); + } + @Override public int hashCode() { // The address on its own should be sufficiently unique for hashing purposes. |