Only empty the view on tab change
Previously it was done when removing a limiter which caused a brief flicker
This commit is contained in:
parent
03821bbae5
commit
74664dbb2b
@ -185,14 +185,17 @@ public class MediaAdapter extends BaseAdapter implements Filterable {
|
||||
}
|
||||
}
|
||||
|
||||
public void hideAll()
|
||||
{
|
||||
mObjects = new ArrayList<Song>();
|
||||
notifyDataSetInvalidated();
|
||||
}
|
||||
|
||||
public void setLimiter(int field, Song media)
|
||||
{
|
||||
mLimiterField = field;
|
||||
mLimiterMedia = media;
|
||||
|
||||
mObjects = new ArrayList<Song>();
|
||||
notifyDataSetInvalidated();
|
||||
|
||||
getFilter().filter(mLastFilter);
|
||||
}
|
||||
|
||||
|
@ -236,8 +236,10 @@ public class SongSelector extends TabActivity implements AdapterView.OnItemClick
|
||||
}
|
||||
updateLimiterViews();
|
||||
} else {
|
||||
for (int i = data.field; i != 3; ++i)
|
||||
for (int i = data.field; i != 3; ++i) {
|
||||
mAdapters[i].setLimiter(data.field, data.media);
|
||||
mAdapters[i].hideAll();
|
||||
}
|
||||
mTabHost.setCurrentTab(data.field);
|
||||
}
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user