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

Commit 5a196bdc authored by Louis Chang's avatar Louis Chang Committed by Android Build Coastguard Worker
Browse files

Remove normalize_home_intent flag

Bug: 378505461
Test: wm presubmit
Flag: EXEMPT remove flag
(cherry picked from https://googleplex-android-review.googlesource.com/q/commit:f207b00bc1eff76bc788f5a2578e3e3f2c960f6b)
(cherry picked from https://googleplex-android-review.googlesource.com/q/commit:3f9327ec06278c80fc59171dc4aa2c063d10ee7a)
Merged-In: I071d4d9e451f1aaab5c625444232b2285bbd472a
Change-Id: I071d4d9e451f1aaab5c625444232b2285bbd472a
parent da0bb76e
Loading
Loading
Loading
Loading
+0 −10
Original line number Diff line number Diff line
@@ -138,13 +138,3 @@ flag {
        purpose: PURPOSE_BUGFIX
    }
}

flag {
    namespace: "windowing_sdk"
    name: "normalize_home_intent"
    description: "To ensure home is started in correct intent"
    bug: "378505461"
    metadata {
        purpose: PURPOSE_BUGFIX
    }
}
+18 −25
Original line number Diff line number Diff line
@@ -71,7 +71,6 @@ import com.android.internal.app.UnlaunchableAppActivity;
import com.android.server.LocalServices;
import com.android.server.am.ActivityManagerService;
import com.android.server.wm.ActivityInterceptorCallback.ActivityInterceptResult;
import com.android.window.flags.Flags;

/**
 * A class that contains activity intercepting logic for {@link ActivityStarter#execute()}
@@ -502,7 +501,6 @@ class ActivityStartInterceptor {
        }

        boolean intercepted = false;
        if (Flags.normalizeHomeIntent()) {
       if (!ACTION_MAIN.equals(mIntent.getAction()) || (!mIntent.hasCategory(CATEGORY_HOME)
                && !mIntent.hasCategory(CATEGORY_SECONDARY_HOME))) {
            // not a home intent
@@ -525,11 +523,6 @@ class ActivityStartInterceptor {
            normalizeHomeIntent();
            intercepted = true;
        }
        } else {
            if (!ActivityRecord.isHomeIntent(mIntent)) {
                return false;
            }
        }

        intercepted |= replaceToSecondaryHomeIntentIfNeeded();
        if (intercepted) {
+0 −3
Original line number Diff line number Diff line
@@ -53,7 +53,6 @@ import android.content.pm.UserPackage;
import android.os.RemoteException;
import android.os.UserHandle;
import android.os.UserManager;
import android.platform.test.annotations.EnableFlags;
import android.platform.test.annotations.Presubmit;
import android.platform.test.flag.junit.SetFlagsRule;
import android.testing.DexmakerShareClassLoaderRule;
@@ -68,7 +67,6 @@ import com.android.internal.app.SuspendedAppActivity;
import com.android.internal.app.UnlaunchableAppActivity;
import com.android.server.LocalServices;
import com.android.server.am.ActivityManagerService;
import com.android.window.flags.Flags;

import org.junit.After;
import org.junit.Before;
@@ -242,7 +240,6 @@ public class ActivityStartInterceptorTest {
    }

    @Test
    @EnableFlags(Flags.FLAG_NORMALIZE_HOME_INTENT)
    public void testInterceptIncorrectHomeIntent() {
        // Create a non-standard home intent
        final Intent homeIntent = new Intent(Intent.ACTION_MAIN);