Merge "Convert IntentResolver data object to IntentFilter for comparison" into rvc-dev am: 302f62cea1
Change-Id: I2576f2bbf1b865f59f8de51d15f929d7ae0f92ca
This commit is contained in:
@@ -687,7 +687,7 @@ public abstract class IntentResolver<F, R extends Object> {
|
|||||||
}
|
}
|
||||||
|
|
||||||
private final void remove_all_objects(ArrayMap<String, F[]> map, String name,
|
private final void remove_all_objects(ArrayMap<String, F[]> map, String name,
|
||||||
Object object) {
|
F object) {
|
||||||
F[] array = map.get(name);
|
F[] array = map.get(name);
|
||||||
if (array != null) {
|
if (array != null) {
|
||||||
int LAST = array.length-1;
|
int LAST = array.length-1;
|
||||||
@@ -695,7 +695,8 @@ public abstract class IntentResolver<F, R extends Object> {
|
|||||||
LAST--;
|
LAST--;
|
||||||
}
|
}
|
||||||
for (int idx=LAST; idx>=0; idx--) {
|
for (int idx=LAST; idx>=0; idx--) {
|
||||||
if (array[idx] == object) {
|
F arrayValue = array[idx];
|
||||||
|
if (arrayValue != null && getIntentFilter(arrayValue) == getIntentFilter(object)) {
|
||||||
final int remain = LAST - idx;
|
final int remain = LAST - idx;
|
||||||
if (remain > 0) {
|
if (remain > 0) {
|
||||||
System.arraycopy(array, idx+1, array, idx, remain);
|
System.arraycopy(array, idx+1, array, idx, remain);
|
||||||
|
|||||||
Reference in New Issue
Block a user