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

Commit 163a3d92 authored by Treehugger Robot's avatar Treehugger Robot Committed by Android (Google) Code Review
Browse files

Merge "Remove intent_save_to_xml_package flag" into main

parents 16a21767 d03b3611
Loading
Loading
Loading
Loading
+6 −7
Original line number Diff line number Diff line
@@ -1088,13 +1088,12 @@ public final class ApplicationStartInfo implements Parcelable {
        final ApplicationStartInfo o = (ApplicationStartInfo) other;

        boolean intentEquals = true;
        if (android.content.flags.Flags.intentSaveToXmlPackage()) {
        if (mStartIntent == null) {
            intentEquals = o.mStartIntent == null;
        } else {
            intentEquals = mStartIntent.filterEquals(o.mStartIntent);
        }
        }


        return mPid == o.mPid
                && mRealUid == o.mRealUid
@@ -1118,7 +1117,7 @@ public final class ApplicationStartInfo implements Parcelable {
        return Objects.hash(mPid, mRealUid, mPackageUid, mDefiningUid, mReason, mStartupState,
                mStartType, mLaunchMode, mPackageName, mProcessName, mStartupTimestampsNs,
                mMonotonicCreationTimeMs, mStartComponent,
                android.content.flags.Flags.intentSaveToXmlPackage() ? mStartIntent : null);
                mStartIntent);
    }

    private boolean timestampsEquals(@NonNull ApplicationStartInfo other) {
+2 −3
Original line number Diff line number Diff line
@@ -13006,7 +13006,7 @@ public class Intent implements Parcelable, Cloneable {
        if (mComponent != null) {
            out.attribute(null, ATTR_COMPONENT, mComponent.flattenToShortString());
        }
        if (android.content.flags.Flags.intentSaveToXmlPackage() && mPackage != null) {
        if (mPackage != null) {
            out.attribute(null, ATTR_PACKAGE, mPackage);
        }
        out.attribute(null, ATTR_FLAGS, Integer.toHexString(getFlags()));
@@ -13042,8 +13042,7 @@ public class Intent implements Parcelable, Cloneable {
                intent.setComponent(ComponentName.unflattenFromString(attrValue));
            } else if (ATTR_FLAGS.equals(attrName)) {
                intent.setFlags(Integer.parseInt(attrValue, 16));
            } else if (android.content.flags.Flags.intentSaveToXmlPackage()
                    && ATTR_PACKAGE.equals(attrName)) {
            } else if (ATTR_PACKAGE.equals(attrName)) {
                intent.setPackage(attrValue);
            } else {
                Log.e(TAG, "restoreFromXml: unknown attribute=" + attrName);
+0 −10
Original line number Diff line number Diff line
@@ -9,16 +9,6 @@ flag {
    bug: "312706530"
}

flag {
     namespace: "system_performance"
     name: "intent_save_to_xml_package"
     description: "Add package to saveToXml so save then restore passes filterEquals."
     bug: "369856202"
     metadata {
         purpose: PURPOSE_BUGFIX
     }
}

flag {
    name: "stop_voice_command"
    is_exported: true
+0 −1
Original line number Diff line number Diff line
@@ -286,7 +286,6 @@ public class IntentTest {
    }

    @Test
    @RequiresFlagsEnabled(android.content.flags.Flags.FLAG_INTENT_SAVE_TO_XML_PACKAGE)
    public void testSaveToXmlAndRestore() throws Exception {
        // Create an intent and set fields.
        Intent original = new Intent();