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

Commit 23183907 authored by android-build-team Robot's avatar android-build-team Robot
Browse files

Snap for 7142794 from e7dbe60d to rvc-qpr3-release

Change-Id: I5ed083b12e0209e34148817e1ddf6050b118381b
parents 1a52fb9c e7dbe60d
Loading
Loading
Loading
Loading
+2 −2
Original line number Diff line number Diff line
@@ -618,7 +618,7 @@ public class DividerView extends FrameLayout implements OnTouchListener,
            mEntranceAnimationRunning = false;
            mExitAnimationRunning = false;
            if (!dismissed && !wasMinimizeInteraction) {
                WindowManagerProxy.applyResizeSplits(snapTarget.position, mSplitLayout);
                mWindowManagerProxy.applyResizeSplits(snapTarget.position, mSplitLayout);
            }
            if (mCallback != null) {
                mCallback.onDraggingEnd();
@@ -889,7 +889,7 @@ public class DividerView extends FrameLayout implements OnTouchListener,
        t.hide(sc).apply();
        mTiles.releaseTransaction(t);
        int midPos = mSplitLayout.getSnapAlgorithm().getMiddleTarget().position;
        WindowManagerProxy.applyResizeSplits(midPos, mSplitLayout);
        mWindowManagerProxy.applyResizeSplits(midPos, mSplitLayout);
    }

    public void setMinimizedDockStack(boolean minimized, long animDuration,
+2 −3
Original line number Diff line number Diff line
@@ -37,7 +37,6 @@ import android.view.WindowManagerGlobal;
import android.window.TaskOrganizer;
import android.window.WindowContainerToken;
import android.window.WindowContainerTransaction;
import android.window.WindowOrganizer;

import com.android.internal.annotations.GuardedBy;
import com.android.systemui.TransactionPool;
@@ -112,10 +111,10 @@ public class WindowManagerProxy {
        mExecutor.execute(mSetTouchableRegionRunnable);
    }

    static void applyResizeSplits(int position, SplitDisplayLayout splitLayout) {
    void applyResizeSplits(int position, SplitDisplayLayout splitLayout) {
        WindowContainerTransaction t = new WindowContainerTransaction();
        splitLayout.resizeSplits(position, t);
        WindowOrganizer.applyTransaction(t);
        applySyncTransaction(t);
    }

    private static boolean getHomeAndRecentsTasks(List<ActivityManager.RunningTaskInfo> out,
+8 −19
Original line number Diff line number Diff line
@@ -1565,9 +1565,6 @@ public class StatsPullAtomService extends SystemService {
        // Aggregate times for the same uids.
        SparseArray<long[]> aggregated = new SparseArray<>();
        mCpuUidFreqTimeReader.readAbsolute((uid, cpuFreqTimeMs) -> {
            // For uids known to be aggregated from many entries allow mutating in place to avoid
            // many copies. Otherwise, copy before aggregating.
            boolean mutateInPlace = false;
            if (UserHandle.isIsolated(uid)) {
                // Skip individual isolated uids because they are recycled and quickly removed from
                // the underlying data source.
@@ -1575,27 +1572,19 @@ public class StatsPullAtomService extends SystemService {
            } else if (UserHandle.isSharedAppGid(uid)) {
                // All shared app gids are accounted together.
                uid = LAST_SHARED_APPLICATION_GID;
                mutateInPlace = true;
            } else if (UserHandle.isApp(uid)) {
                // Apps are accounted under their app id.
            } else {
                // Everything else is accounted under their base uid.
                uid = UserHandle.getAppId(uid);
            }

            long[] aggCpuFreqTimeMs = aggregated.get(uid);
            if (aggCpuFreqTimeMs != null) {
                if (!mutateInPlace) {
                    aggCpuFreqTimeMs = Arrays.copyOf(aggCpuFreqTimeMs, cpuFreqTimeMs.length);
            if (aggCpuFreqTimeMs == null) {
                aggCpuFreqTimeMs = new long[cpuFreqTimeMs.length];
                aggregated.put(uid, aggCpuFreqTimeMs);
            }
            for (int freqIndex = 0; freqIndex < cpuFreqTimeMs.length; ++freqIndex) {
                aggCpuFreqTimeMs[freqIndex] += cpuFreqTimeMs[freqIndex];
            }
            } else {
                if (mutateInPlace) {
                    cpuFreqTimeMs = Arrays.copyOf(cpuFreqTimeMs, cpuFreqTimeMs.length);
                }
                aggregated.put(uid, cpuFreqTimeMs);
            }
        });

        int size = aggregated.size();