Only display System section for current user. am: ce37ef51aa
am: 0547440ad7
am: 3d9cb084e9
Change-Id: I5b210e644b2fcdeaa7611a373ab2dbed5db89cd2
This commit is contained in:
@@ -300,10 +300,16 @@ public class PrivateVolumeSettings extends SettingsPreferenceFragment {
|
|||||||
}
|
}
|
||||||
|
|
||||||
private void addItem(PreferenceGroup group, int titleRes, CharSequence title, int userId) {
|
private void addItem(PreferenceGroup group, int titleRes, CharSequence title, int userId) {
|
||||||
if (titleRes == R.string.storage_detail_system && mSystemSize <= 0) {
|
if (titleRes == R.string.storage_detail_system) {
|
||||||
|
if (mSystemSize <= 0) {
|
||||||
Log.w(TAG, "Skipping System storage because its size is " + mSystemSize);
|
Log.w(TAG, "Skipping System storage because its size is " + mSystemSize);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
if (userId != UserHandle.myUserId()) {
|
||||||
|
// Only display system on current user.
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
}
|
||||||
StorageItemPreference item;
|
StorageItemPreference item;
|
||||||
if (mItemPoolIndex < mItemPreferencePool.size()) {
|
if (mItemPoolIndex < mItemPreferencePool.size()) {
|
||||||
item = mItemPreferencePool.get(mItemPoolIndex);
|
item = mItemPreferencePool.get(mItemPoolIndex);
|
||||||
|
Reference in New Issue
Block a user