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

Commit b1026eb4 authored by Android Build Coastguard Worker's avatar Android Build Coastguard Worker
Browse files

Snap for 8282142 from 2a9d5a42 to sc-qpr3-release

Change-Id: I4f14e1528fe7c05fab43856f8497757178a5fef6
parents 4f542d02 2a9d5a42
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -55,4 +55,5 @@ interface IPackageInstallerSession {
    int getParentSessionId();

    boolean isStaged();
    int getInstallFlags();
}
+12 −0
Original line number Diff line number Diff line
@@ -1431,6 +1431,18 @@ public class PackageInstaller {
            }
        }

        /**
         * @return Session's {@link SessionParams#installFlags}.
         * @hide
         */
        public int getInstallFlags() {
            try {
                return mSession.getInstallFlags();
            } catch (RemoteException e) {
                throw e.rethrowFromSystemServer();
            }
        }

        /**
         * @return the session ID of the multi-package session that this belongs to or
         * {@link SessionInfo#INVALID_ID} if it does not belong to a multi-package session.
+12 −0
Original line number Diff line number Diff line
@@ -78,6 +78,18 @@
    <!-- Checkbox label for USB device dialogs with warning text for USB device dialogs.  [CHAR LIMIT=200]-->
    <string name="usb_device_permission_prompt_warn">Allow <xliff:g id="application" example= "Usb Mega Player">%1$s</xliff:g> to access <xliff:g id="usb_device" example="USB Headphones">%2$s</xliff:g>?\nThis app has not been granted record permission but could capture audio through this USB device.</string>

    <!-- USB audio device permission dialog title.  [CHAR LIMIT=200]-->
    <string name="usb_audio_device_permission_prompt_title">Allow <xliff:g id="application" example= "Usb Mega Player">%1$s</xliff:g> to access <xliff:g id="usb_device" example="USB Headphones">%2$s</xliff:g>?</string>

    <!-- USB audio device confirm dialog title.  [CHAR LIMIT=200]-->
    <string name="usb_audio_device_confirm_prompt_title">Open <xliff:g id="application" example= "Usb Mega Player">%1$s</xliff:g> to handle <xliff:g id="usb_device" example="USB Headphones">%2$s</xliff:g>?</string>

    <!-- Checkbox label for USB audio device dialogs with warning text for USB audio device dialogs.  [CHAR LIMIT=NONE]-->
    <string name="usb_audio_device_prompt_warn">This app has not been granted record permission but could capture audio through this USB device. Using <xliff:g id="application" example= "Usb Mega Player">%1$s</xliff:g> with this device might prevent hearing calls, notifications and alarms.</string>

    <!-- Prompt for the USB audio device permission dialog [CHAR LIMIT=NONE] -->
    <string name="usb_audio_device_prompt">Using <xliff:g id="application" example= "Usb Mega Player">%1$s</xliff:g> with this device might prevent hearing calls, notifications and alarms.</string>

    <!-- Prompt for the USB accessory permission dialog [CHAR LIMIT=80] -->
    <string name="usb_accessory_permission_prompt">Allow <xliff:g id="application" example= "Usb Mega Player">%1$s</xliff:g> to access <xliff:g id="usb_accessory"  example="USB Dock">%2$s</xliff:g>?</string>

+11 −0
Original line number Diff line number Diff line
@@ -126,6 +126,7 @@ import android.system.StructStat;
import android.text.TextUtils;
import android.util.ArrayMap;
import android.util.ArraySet;
import android.util.EventLog;
import android.util.ExceptionUtils;
import android.util.MathUtils;
import android.util.Slog;
@@ -3097,6 +3098,11 @@ public class PackageInstallerSession extends IPackageInstallerSession.Stub {
            if (mResolvedBaseFile == null) {
                mResolvedBaseFile = new File(appInfo.getBaseCodePath());
                inheritFileLocked(mResolvedBaseFile);
            } else if ((params.installFlags & PackageManager.INSTALL_DONT_KILL_APP) != 0) {
                EventLog.writeEvent(0x534e4554, "219044664");

                // Installing base.apk. Make sure the app is restarted.
                params.setDontKillApp(false);
            }

            // Inherit splits if not overridden.
@@ -3742,6 +3748,11 @@ public class PackageInstallerSession extends IPackageInstallerSession.Stub {
        return params.isStaged;
    }

    @Override
    public int getInstallFlags() {
        return params.installFlags;
    }

    @Override
    public DataLoaderParamsParcel getDataLoaderParams() {
        mContext.enforceCallingOrSelfPermission(Manifest.permission.USE_INSTALLER_V2, null);