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

Commit ef691ab2 authored by TreeHugger Robot's avatar TreeHugger Robot Committed by Android (Google) Code Review
Browse files

Merge "Add attachinfo information to ViewRootImpl dump"

parents e1344c39 ce0f9518
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -7098,7 +7098,7 @@ public class Activity extends ContextThemeWrapper
        if (getWindow() != null &&
                getWindow().peekDecorView() != null &&
                getWindow().peekDecorView().getViewRootImpl() != null) {
            getWindow().peekDecorView().getViewRootImpl().dump(prefix, fd, writer, args);
            getWindow().peekDecorView().getViewRootImpl().dump(prefix, writer);
        }

        mHandler.getLooper().dump(new PrintWriterPrinter(writer), prefix);
+11 −0
Original line number Diff line number Diff line
@@ -154,6 +154,7 @@ import com.android.internal.widget.ScrollBarUtils;
import com.google.android.collect.Lists;
import com.google.android.collect.Maps;
import java.io.PrintWriter;
import java.lang.annotation.Retention;
import java.lang.annotation.RetentionPolicy;
import java.lang.ref.WeakReference;
@@ -29442,6 +29443,16 @@ public class View implements Drawable.Callback, KeyEvent.Callback,
            }
            return mScrollCaptureInternal;
        }
        public void dump(String prefix, PrintWriter writer) {
            String innerPrefix = prefix + "  ";
            writer.println(prefix + "AttachInfo:");
            writer.println(innerPrefix + "mHasWindowFocus=" + mHasWindowFocus);
            writer.println(innerPrefix + "mWindowVisibility=" + mWindowVisibility);
            writer.println(innerPrefix + "mInTouchMode=" + mInTouchMode);
            writer.println(innerPrefix + "mUnbufferedDispatchRequested="
                    + mUnbufferedDispatchRequested);
        }
    }
    /**
+13 −2
Original line number Diff line number Diff line
@@ -200,7 +200,6 @@ import com.android.internal.view.BaseSurfaceHolder;
import com.android.internal.view.RootViewSurfaceTaker;
import com.android.internal.view.SurfaceCallbackHelper;

import java.io.FileDescriptor;
import java.io.IOException;
import java.io.OutputStream;
import java.io.PrintWriter;
@@ -7687,12 +7686,18 @@ public final class ViewRootImpl implements ViewParent,
        mImeFocusController.dumpDebug(proto, IME_FOCUS_CONTROLLER);
    }

    public void dump(String prefix, FileDescriptor fd, PrintWriter writer, String[] args) {
    /**
     * Dump information about this ViewRootImpl
     * @param prefix the prefix that will be prepended to each line of the produced output
     * @param writer the writer that will receive the resulting text
     */
    public void dump(String prefix, PrintWriter writer) {
        String innerPrefix = prefix + "  ";
        writer.println(prefix + "ViewRoot:");
        writer.println(innerPrefix + "mAdded=" + mAdded);
        writer.println(innerPrefix + "mRemoved=" + mRemoved);
        writer.println(innerPrefix + "mStopped=" + mStopped);
        writer.println(innerPrefix + "mPausedForTransition=" + mPausedForTransition);
        writer.println(innerPrefix + "mConsumeBatchedInputScheduled="
                + mConsumeBatchedInputScheduled);
        writer.println(innerPrefix + "mConsumeBatchedInputImmediatelyScheduled="
@@ -7707,6 +7712,12 @@ public final class ViewRootImpl implements ViewParent,
        writer.println(innerPrefix + "mIsAmbientMode="  + mIsAmbientMode);
        writer.println(innerPrefix + "mUnbufferedInputSource="
                + Integer.toHexString(mUnbufferedInputSource));
        if (mAttachInfo != null) {
            writer.print(innerPrefix + "mAttachInfo= ");
            mAttachInfo.dump(innerPrefix, writer);
        } else {
            writer.println(innerPrefix + "mAttachInfo=<null>");
        }

        mFirstInputStage.dump(innerPrefix, writer);

+1 −1
Original line number Diff line number Diff line
@@ -652,7 +652,7 @@ public class NotificationShadeWindowControllerImpl implements NotificationShadeW
        pw.println(TAG + ":");
        pw.println("  mKeyguardDisplayMode=" + mKeyguardDisplayMode);
        pw.println(mCurrentState);
        mNotificationShadeView.getViewRootImpl().dump("  ", fd, pw, args);
        mNotificationShadeView.getViewRootImpl().dump("  ", pw);
    }

    @Override