Merge "Prevent guest user from toggling mobile data Quick Setting"
This commit is contained in:
@@ -23,6 +23,7 @@ import android.app.AlertDialog.Builder;
|
||||
import android.content.Context;
|
||||
import android.content.Intent;
|
||||
import android.content.res.Resources;
|
||||
import android.os.UserHandle;
|
||||
import android.provider.Settings;
|
||||
import android.service.quicksettings.Tile;
|
||||
import android.telephony.SubscriptionManager;
|
||||
@@ -230,7 +231,8 @@ public class CellularTile extends QSTileImpl<SignalState> {
|
||||
|
||||
@Override
|
||||
public boolean isAvailable() {
|
||||
return mController.hasMobileDataFeature();
|
||||
return mController.hasMobileDataFeature()
|
||||
&& mHost.getUserContext().getUserId() == UserHandle.USER_SYSTEM;
|
||||
}
|
||||
|
||||
private static final class CallbackInfo {
|
||||
|
||||
Reference in New Issue
Block a user