Merge "Fixed a bug where systemui could crash while cloning" into oc-dev

am: b9eb205bd7

Change-Id: I5b1ff4ba5708c7d470940fd46074aefe9c210b83
This commit is contained in:
Selim Cinek
2017-06-09 04:30:51 +00:00
committed by android-build-merger
2 changed files with 2 additions and 2 deletions

View File

@@ -2342,7 +2342,7 @@ public class RemoteViews implements Parcelable, Filter {
} }
public RemoteViews clone() { public synchronized RemoteViews clone() {
Preconditions.checkState(mIsRoot, "RemoteView has been attached to another RemoteView. " Preconditions.checkState(mIsRoot, "RemoteView has been attached to another RemoteView. "
+ "May only clone the root of a RemoteView hierarchy."); + "May only clone the root of a RemoteView hierarchy.");

View File

@@ -438,7 +438,7 @@ public class NotificationData {
final int N = mEntries.size(); final int N = mEntries.size();
for (int i = 0; i < N; i++) { for (int i = 0; i < N; i++) {
Entry entry = mEntries.valueAt(i); Entry entry = mEntries.valueAt(i);
final StatusBarNotification oldSbn = entry.notification.clone(); final StatusBarNotification oldSbn = entry.notification.cloneLight();
final String overrideGroupKey = getOverrideGroupKey(entry.key); final String overrideGroupKey = getOverrideGroupKey(entry.key);
if (!Objects.equals(oldSbn.getOverrideGroupKey(), overrideGroupKey)) { if (!Objects.equals(oldSbn.getOverrideGroupKey(), overrideGroupKey)) {
entry.notification.setOverrideGroupKey(overrideGroupKey); entry.notification.setOverrideGroupKey(overrideGroupKey);