OSDN Git Service
(root)
/
android-x86
/
packages-apps-Trebuchet.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
7e4e4ba
)
Fixing concurrent modification exception when iterating through new apps list. (Bug...
author
Winson Chung
<winsonc@google.com>
Mon, 25 Jun 2012 21:21:37 +0000
(14:21 -0700)
committer
Winson Chung
<winsonc@google.com>
Mon, 25 Jun 2012 21:23:29 +0000
(14:23 -0700)
Change-Id: Idf4fae51c65e0e53520740dd0b2050eeac00b251
src/com/android/launcher2/Workspace.java
patch
|
blob
|
history
diff --git
a/src/com/android/launcher2/Workspace.java
b/src/com/android/launcher2/Workspace.java
index
0192630
..
2d2340a
100644
(file)
--- a/
src/com/android/launcher2/Workspace.java
+++ b/
src/com/android/launcher2/Workspace.java
@@
-3684,12
+3684,13
@@
public class Workspace extends SmoothPagedView
// Remove all queued items that match the same package
if (newApps != null) {
synchronized (newApps) {
- for (String intentStr : newApps) {
+ Iterator<String> iter = newApps.iterator();
+ while (iter.hasNext()) {
try {
- Intent intent = Intent.parseUri(i
ntentStr
, 0);
+ Intent intent = Intent.parseUri(i
ter.next()
, 0);
String pn = ItemInfo.getPackageName(intent);
if (packageNames.contains(pn)) {
-
newApps.remove(intentStr
);
+
iter.remove(
);
}
} catch (URISyntaxException e) {}
}