Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 3b32d267 authored by TreeHugger Robot's avatar TreeHugger Robot Committed by Android (Google) Code Review
Browse files

Merge "Remove the getConfiguration and updatePersistentConfiguration"

parents 96e21451 4c7e4629
Loading
Loading
Loading
Loading
+0 −6
Original line number Diff line number Diff line
@@ -21,15 +21,12 @@ import static com.android.internal.telephony.cat.CatCmdMessage.SetupEventListCon
import static com.android.internal.telephony.cat.CatCmdMessage.SetupEventListConstants.USER_ACTIVITY_EVENT;

import android.app.ActivityManager;
import android.app.ActivityManagerNative;
import android.app.IActivityManager;
import android.app.backup.BackupManager;
import android.compat.annotation.UnsupportedAppUsage;
import android.content.Context;
import android.content.Intent;
import android.content.pm.PackageManager;
import android.content.pm.ResolveInfo;
import android.content.res.Configuration;
import android.content.res.Resources.NotFoundException;
import android.os.AsyncResult;
import android.os.Handler;
@@ -1174,8 +1171,6 @@ public class CatService extends Handler implements AppInterface {
    }

    private void changeLanguage(String language) throws RemoteException {
        IActivityManager am = ActivityManagerNative.getDefault();
        Configuration config = am.getConfiguration();
        // get locale list, combined with language locale and default locale list.
        LocaleList defaultLocaleList = LocaleList.getDefault();
        Locale[] locales = new Locale[defaultLocaleList.size() + 1];
@@ -1184,7 +1179,6 @@ public class CatService extends Handler implements AppInterface {
            locales[i+1] = defaultLocaleList.get(i);
        }
        mContext.getSystemService(ActivityManager.class).setDeviceLocales(new LocaleList(locales));
        am.updatePersistentConfiguration(config);
        BackupManager.dataChanged("com.android.providers.settings");
    }
}