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

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

Snap for 8071527 from ab0466f9 to sc-v2-release

Change-Id: I9bc2724dfd568a37f9936a08609f5bca0abd1e6a
parents 0a307620 ab0466f9
Loading
Loading
Loading
Loading
+7 −0
Original line number Diff line number Diff line
@@ -524,6 +524,7 @@ public class InputMethodService extends AbstractInputMethodService {
    private Handler mHandler;
    private boolean mImeSurfaceScheduledForRemoval;
    private ImsConfigurationTracker mConfigTracker = new ImsConfigurationTracker();
    private boolean mDestroyed;

    /**
     * An opaque {@link Binder} token of window requesting {@link InputMethodImpl#showSoftInput}
@@ -604,6 +605,11 @@ public class InputMethodService extends AbstractInputMethodService {
                Log.w(TAG, "The token has already registered, ignore this initialization.");
                return;
            }
            if (mDestroyed) {
                Log.i(TAG, "The InputMethodService has already onDestroyed()."
                    + "Ignore the initialization.");
                return;
            }
            Trace.traceBegin(TRACE_TAG_WINDOW_MANAGER, "IMS.initializeInternal");
            mConfigTracker.onInitialize(configChanges);
            mPrivOps.set(privilegedOperations);
@@ -1403,6 +1409,7 @@ public class InputMethodService extends AbstractInputMethodService {
    }

    @Override public void onDestroy() {
        mDestroyed = true;
        super.onDestroy();
        mRootView.getViewTreeObserver().removeOnComputeInternalInsetsListener(
                mInsetsComputer);
+10 −4
Original line number Diff line number Diff line
@@ -137,14 +137,16 @@ public class SplitDecorManager extends WindowlessWindowManager {
            return;
        }

        if (mIcon == null) {
            // TODO: add fade-in animation.
        if (mBackgroundLeash == null) {
            mBackgroundLeash = SurfaceUtils.makeColorLayer(mHostLeash,
                    RESIZING_BACKGROUND_SURFACE_NAME, mSurfaceSession);
            t.setColor(mBackgroundLeash, getResizingBackgroundColor(resizingTask))
                    .setLayer(mBackgroundLeash, SPLIT_DIVIDER_LAYER - 1)
                    .show(mBackgroundLeash);
        }

        if (mIcon == null && resizingTask.topActivityInfo != null) {
            // TODO: add fade-in animation.
            mIcon = mIconProvider.getIcon(resizingTask.topActivityInfo);
            mResizingIconView.setImageDrawable(mIcon);
            mResizingIconView.setVisibility(View.VISIBLE);
@@ -168,12 +170,16 @@ public class SplitDecorManager extends WindowlessWindowManager {
            return;
        }

        if (mBackgroundLeash != null) {
            t.remove(mBackgroundLeash);
            mBackgroundLeash = null;
        }

        if (mIcon != null) {
            mResizingIconView.setVisibility(View.GONE);
            mResizingIconView.setImageDrawable(null);
            t.remove(mBackgroundLeash).hide(mIconLeash);
            t.hide(mIconLeash);
            mIcon = null;
            mBackgroundLeash = null;
        }
    }

+5 −1
Original line number Diff line number Diff line
@@ -388,7 +388,11 @@ public class PackageInstallerService extends IPackageInstaller.Stub implements
                if (age >= MAX_SESSION_AGE_ON_LOW_STORAGE_MILLIS) {
                    // Aggressively close old sessions because we are running low on storage
                    // Their staging dirs will be removed too
                    session.abandon();
                    PackageInstallerSession root = !session.hasParentSessionId()
                            ? session : mSessions.get(session.getParentSessionId());
                    if (!root.isDestroyed()) {
                        root.abandon();
                    }
                } else {
                    // Session is new enough, so it deserves to be kept even on low storage
                    unclaimedStagingDirsOnVolume.remove(session.stageDir);