Merge "Dumps magnification by accessibility controller" into rvc-dev am: 4bdbd1269a am: ca324ea94b
Change-Id: Idbad4054604951ef70ad35619a5a5a0bc68d7fcb
This commit is contained in:
@@ -66,6 +66,7 @@ import com.android.server.policy.WindowManagerPolicy;
|
||||
import com.android.server.wm.WindowManagerInternal.MagnificationCallbacks;
|
||||
import com.android.server.wm.WindowManagerInternal.WindowsForAccessibilityCallback;
|
||||
|
||||
import java.io.PrintWriter;
|
||||
import java.util.ArrayList;
|
||||
import java.util.HashSet;
|
||||
import java.util.List;
|
||||
@@ -341,6 +342,16 @@ final class AccessibilityController {
|
||||
windowState.getTransformationMatrix(sTempFloats, outMatrix);
|
||||
}
|
||||
|
||||
void dump(PrintWriter pw, String prefix) {
|
||||
for (int i = 0; i < mDisplayMagnifiers.size(); i++) {
|
||||
final DisplayMagnifier displayMagnifier = mDisplayMagnifiers.valueAt(i);
|
||||
if (displayMagnifier != null) {
|
||||
displayMagnifier.dump(pw, prefix
|
||||
+ "Magnification display# " + mDisplayMagnifiers.keyAt(i));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* This class encapsulates the functionality related to display magnification.
|
||||
*/
|
||||
@@ -551,6 +562,10 @@ final class AccessibilityController {
|
||||
mMagnifedViewport.drawWindowIfNeededLocked(t);
|
||||
}
|
||||
|
||||
void dump(PrintWriter pw, String prefix) {
|
||||
mMagnifedViewport.dump(pw, prefix);
|
||||
}
|
||||
|
||||
private final class MagnifiedViewport {
|
||||
|
||||
private final SparseArray<WindowState> mTempWindowStates =
|
||||
@@ -820,6 +835,10 @@ final class AccessibilityController {
|
||||
}, false /* traverseTopToBottom */ );
|
||||
}
|
||||
|
||||
void dump(PrintWriter pw, String prefix) {
|
||||
mWindow.dump(pw, prefix);
|
||||
}
|
||||
|
||||
private final class ViewportWindow {
|
||||
private static final String SURFACE_TITLE = "Magnification Overlay";
|
||||
|
||||
@@ -985,6 +1004,14 @@ final class AccessibilityController {
|
||||
mSurface.release();
|
||||
}
|
||||
|
||||
void dump(PrintWriter pw, String prefix) {
|
||||
pw.println(prefix
|
||||
+ " mBounds= " + mBounds
|
||||
+ " mDirtyRect= " + mDirtyRect
|
||||
+ " mWidth= " + mSurfaceControl.getWidth()
|
||||
+ " mHeight= " + mSurfaceControl.getHeight());
|
||||
}
|
||||
|
||||
private final class AnimationController extends Handler {
|
||||
private static final String PROPERTY_NAME_ALPHA = "alpha";
|
||||
|
||||
|
||||
@@ -6111,15 +6111,6 @@ public class WindowManagerService extends IWindowManager.Stub
|
||||
pw.print(" mInputMethodInputTarget in display# "); pw.print(displayId);
|
||||
pw.print(' '); pw.println(inputMethodInputTarget);
|
||||
}
|
||||
if (mAccessibilityController != null) {
|
||||
final Region magnificationRegion = new Region();
|
||||
mAccessibilityController.getMagnificationRegionLocked(displayId,
|
||||
magnificationRegion);
|
||||
pw.print(" mMagnificationRegion in display# ");
|
||||
pw.print(displayId);
|
||||
pw.print(' ');
|
||||
pw.println(magnificationRegion);
|
||||
}
|
||||
});
|
||||
pw.print(" mInTouchMode="); pw.println(mInTouchMode);
|
||||
pw.print(" mLastDisplayFreezeDuration=");
|
||||
@@ -6135,6 +6126,9 @@ public class WindowManagerService extends IWindowManager.Stub
|
||||
|
||||
mInputManagerCallback.dump(pw, " ");
|
||||
mTaskSnapshotController.dump(pw, " ");
|
||||
if (mAccessibilityController != null) {
|
||||
mAccessibilityController.dump(pw, " ");
|
||||
}
|
||||
|
||||
if (dumpAll) {
|
||||
final WindowState imeWindow = mRoot.getCurrentInputMethodWindow();
|
||||
|
||||
@@ -1476,6 +1476,7 @@ class WindowStateAnimator {
|
||||
if (dumpAll) {
|
||||
pw.print(prefix); pw.print("mDrawState="); pw.print(drawStateToString());
|
||||
pw.print(prefix); pw.print(" mLastHidden="); pw.println(mLastHidden);
|
||||
pw.print(prefix); pw.print("mEnterAnimationPending=" + mEnterAnimationPending);
|
||||
pw.print(prefix); pw.print("mSystemDecorRect="); mSystemDecorRect.printShortString(pw);
|
||||
pw.print(" mLastClipRect="); mLastClipRect.printShortString(pw);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user