Retain expanded state across more than one violent update.

Bug: 6680363
Change-Id: Iebf2387fc5c8774c1c001dde5a4608d4e60720aa
This commit is contained in:
Chris Wren
2012-06-28 14:35:43 -04:00
parent c9433ecb51
commit 5ae1ea8400
2 changed files with 7 additions and 0 deletions

View File

@@ -913,6 +913,7 @@ public abstract class BaseStatusBar extends SystemUI implements
if (wasExpanded) {
final NotificationData.Entry newEntry = mNotificationData.findByKey(key);
expandView(newEntry, true);
newEntry.setUserExpanded(true);
}
}

View File

@@ -65,6 +65,12 @@ public class NotificationData {
public boolean userExpanded() {
return NotificationData.getUserExpanded(row);
}
/**
* Set the flag indicating that this was manually expanded by the user.
*/
public boolean setUserExpanded(boolean userExpanded) {
return NotificationData.setUserExpanded(row, userExpanded);
}
}
private final ArrayList<Entry> mEntries = new ArrayList<Entry>();
private final Comparator<Entry> mEntryCmp = new Comparator<Entry>() {