diff options
Diffstat (limited to 'core/java')
| -rw-r--r-- | core/java/android/hardware/camera2/CameraDevice.java | 13 | ||||
| -rw-r--r-- | core/java/android/net/ConnectivityManager.java | 10 | ||||
| -rw-r--r-- | core/java/android/os/BatteryStats.java | 2 | ||||
| -rw-r--r-- | core/java/android/widget/AdapterView.java | 14 | ||||
| -rw-r--r-- | core/java/com/android/internal/util/StateMachine.java | 15 |
5 files changed, 38 insertions, 16 deletions
diff --git a/core/java/android/hardware/camera2/CameraDevice.java b/core/java/android/hardware/camera2/CameraDevice.java index 4a71aa0..20b0be1 100644 --- a/core/java/android/hardware/camera2/CameraDevice.java +++ b/core/java/android/hardware/camera2/CameraDevice.java @@ -480,8 +480,11 @@ public abstract class CameraDevice implements AutoCloseable { * the configurations in the tables below are also guaranteed for creating a reprocessable * capture session if the camera device supports YUV reprocessing or PRIVATE reprocessing. * However, not all output targets used to create a reprocessable session may be used in a - * {@link CaptureRequest} simultaneously. The guaranteed output targets that can be included - * in a {@link CaptureRequest} simultaneously are listed in the tables under + * {@link CaptureRequest} simultaneously. For devices that support only 1 output target in a + * reprocess {@link CaptureRequest}, submitting a reprocess {@link CaptureRequest} with multiple + * output targets will result in a {@link CaptureFailure}. For devices that support multiple + * output targets in a reprocess {@link CaptureRequest}, the guaranteed output targets that can + * be included in a {@link CaptureRequest} simultaneously are listed in the tables under * {@link #createCaptureSession createCaptureSession}. For example, with a FULL-capability * ({@link CameraCharacteristics#INFO_SUPPORTED_HARDWARE_LEVEL} {@code == } * {@link CameraMetadata#INFO_SUPPORTED_HARDWARE_LEVEL_FULL FULL}) device that supports PRIVATE @@ -532,8 +535,6 @@ public abstract class CameraDevice implements AutoCloseable { * <tr> <td>{@code PRIV}/{@code YUV}</td><td id="rb">{@code MAXIMUM}</td> <td>Same as input</td><td id="rb">{@code MAXIMUM}</td> <td>{@code PRIV}</td><td id="rb">{@code PREVIEW}</td> <td>{@code YUV}</td><td id="rb">{@code RECORD}</td> <td></td><td id="rb"></td> <td>High-resolution ZSL in-app video processing with regular preview.</td> </tr> * <tr> <td>{@code PRIV}</td><td id="rb">{@code MAXIMUM}</td> <td>{@code PRIV}</td><td id="rb">{@code MAXIMUM}</td> <td>{@code PRIV}</td><td id="rb">{@code PREVIEW}</td> <td>{@code YUV}</td><td id="rb">{@code MAXIMUM}</td> <td></td><td id="rb"></td> <td>Maximum-resolution ZSL in-app processing with regular preview.</td> </tr> * <tr> <td>{@code PRIV}</td><td id="rb">{@code MAXIMUM}</td> <td>{@code PRIV}</td><td id="rb">{@code MAXIMUM}</td> <td>{@code YUV}</td><td id="rb">{@code PREVIEW}</td> <td>{@code YUV}</td><td id="rb">{@code MAXIMUM}</td> <td></td><td id="rb"></td> <td>Maximum-resolution two-input ZSL in-app processing.</td> </tr> - * <tr> <td>{@code PRIV}/{@code YUV}</td><td id="rb">{@code MAXIMUM}</td> <td>Same as input</td><td id="rb">{@code MAXIMUM}</td> <td>{@code PRIV}</td><td id="rb">{@code PREVIEW}</td> <td>{@code YUV}</td><td id="rb">{@code RECORD}</td> <td>{@code JPEG}</td><td id="rb">{@code RECORD}</td> <td>High-resolution ZSL in-app video processing and video snapshot with regular preview.</td> </tr> - * <tr> <td>{@code PRIV}</td><td id="rb">{@code MAXIMUM}</td> <td>{@code PRIV}</td><td id="rb">{@code MAXIMUM}</td> <td>{@code YUV}</td><td id="rb">{@code PREVIEW}</td> <td>{@code PRIV}</td><td id="rb">{@code PREVIEW}</td> <td>{@code YUV}</td><td id="rb">{@code MAXIMUM}</td> <td>Maximum-resolution two-input ZSL in-app processing with regular preview.</td> </tr> * <tr> <td>{@code PRIV}/{@code YUV}</td><td id="rb">{@code MAXIMUM}</td> <td>Same as input</td><td id="rb">{@code MAXIMUM}</td> <td>{@code PRIV}</td><td id="rb">{@code PREVIEW}</td> <td>{@code YUV}</td><td id="rb">{@code PREVIEW}</td> <td>{@code JPEG}</td><td id="rb">{@code MAXIMUM}</td> <td>ZSL still capture and in-app processing.</td> </tr> * </table><br> * </p> @@ -711,7 +712,9 @@ public abstract class CameraDevice implements AutoCloseable { * provide input images to camera device via {@link android.media.ImageWriter#queueInputImage}. * The application must use the capture result of one of those output images to create a * reprocess capture request so that the camera device can use the information to achieve - * optimal reprocess image quality. + * optimal reprocess image quality. For camera devices that support only 1 output + * {@link Surface}, submitting a reprocess {@link CaptureRequest} with multiple + * output targets will result in a {@link CaptureFailure}. * * @param inputResult The capture result of the output image or one of the output images used * to generate the reprocess input image for this capture request. diff --git a/core/java/android/net/ConnectivityManager.java b/core/java/android/net/ConnectivityManager.java index ff6dd32..8e55736 100644 --- a/core/java/android/net/ConnectivityManager.java +++ b/core/java/android/net/ConnectivityManager.java @@ -1038,11 +1038,13 @@ public class ConnectivityManager { type = "enableDUN"; result = TYPE_MOBILE_DUN; } else if (netCap.hasCapability(NetworkCapabilities.NET_CAPABILITY_SUPL)) { - type = "enableSUPL"; + type = "enableSUPL"; result = TYPE_MOBILE_SUPL; - } else if (netCap.hasCapability(NetworkCapabilities.NET_CAPABILITY_MMS)) { - type = "enableMMS"; - result = TYPE_MOBILE_MMS; + // back out this hack for mms as they no longer need this and it's causing + // device slowdowns - b/23350688 (note, supl still needs this) + //} else if (netCap.hasCapability(NetworkCapabilities.NET_CAPABILITY_MMS)) { + // type = "enableMMS"; + // result = TYPE_MOBILE_MMS; } else if (netCap.hasCapability(NetworkCapabilities.NET_CAPABILITY_INTERNET)) { type = "enableHIPRI"; result = TYPE_MOBILE_HIPRI; diff --git a/core/java/android/os/BatteryStats.java b/core/java/android/os/BatteryStats.java index 80169a9..4ad9d6d 100644 --- a/core/java/android/os/BatteryStats.java +++ b/core/java/android/os/BatteryStats.java @@ -169,7 +169,7 @@ public abstract class BatteryStats implements Parcelable { /** * Current version of checkin data format. */ - static final String CHECKIN_VERSION = "14"; + static final String CHECKIN_VERSION = "15"; /** * Old version, we hit 9 and ran out of room, need to remove. diff --git a/core/java/android/widget/AdapterView.java b/core/java/android/widget/AdapterView.java index 6962711..0cc1b25 100644 --- a/core/java/android/widget/AdapterView.java +++ b/core/java/android/widget/AdapterView.java @@ -612,7 +612,7 @@ public abstract class AdapterView<T extends Adapter> extends ViewGroup { View listItem = view; try { View v; - while (!(v = (View) listItem.getParent()).equals(this)) { + while ((v = (View) listItem.getParent()) != null && !v.equals(this)) { listItem = v; } } catch (ClassCastException e) { @@ -620,11 +620,13 @@ public abstract class AdapterView<T extends Adapter> extends ViewGroup { return INVALID_POSITION; } - // Search the children for the list item - final int childCount = getChildCount(); - for (int i = 0; i < childCount; i++) { - if (getChildAt(i).equals(listItem)) { - return mFirstPosition + i; + if (listItem != null) { + // Search the children for the list item + final int childCount = getChildCount(); + for (int i = 0; i < childCount; i++) { + if (getChildAt(i).equals(listItem)) { + return mFirstPosition + i; + } } } diff --git a/core/java/com/android/internal/util/StateMachine.java b/core/java/com/android/internal/util/StateMachine.java index 916f19d..447292c 100644 --- a/core/java/com/android/internal/util/StateMachine.java +++ b/core/java/com/android/internal/util/StateMachine.java @@ -29,6 +29,7 @@ import java.io.StringWriter; import java.util.ArrayList; import java.util.Calendar; import java.util.Collection; +import java.util.Iterator; import java.util.HashMap; import java.util.Vector; @@ -1864,6 +1865,20 @@ public class StateMachine { } /** + * Removes a message from the deferred messages queue. + */ + protected final void removeDeferredMessages(int what) { + SmHandler smh = mSmHandler; + if (smh == null) return; + + Iterator<Message> iterator = smh.mDeferredMessages.iterator(); + while (iterator.hasNext()) { + Message msg = iterator.next(); + if (msg.what == what) iterator.remove(); + } + } + + /** * Validate that the message was sent by * {@link StateMachine#quit} or {@link StateMachine#quitNow}. * */ |
