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

Commit 523ca2ba authored by Joe Onorato's avatar Joe Onorato Committed by Android (Google) Code Review
Browse files

Merge "Rename ViewRoot to ViewAncestor."

parents f2902588 c6cc0f8c
Loading
Loading
Loading
Loading
+5 −5
Original line number Diff line number Diff line
@@ -70,7 +70,7 @@ import android.view.HardwareRenderer;
import android.view.View;
import android.view.ViewDebug;
import android.view.ViewManager;
import android.view.ViewRoot;
import android.view.ViewAncestor;
import android.view.Window;
import android.view.WindowManager;
import android.view.WindowManagerImpl;
@@ -728,7 +728,7 @@ public final class ActivityThread {
            long dalvikFree = runtime.freeMemory() / 1024;
            long dalvikAllocated = dalvikMax - dalvikFree;
            long viewInstanceCount = ViewDebug.getViewInstanceCount();
            long viewRootInstanceCount = ViewDebug.getViewRootInstanceCount();
            long viewRootInstanceCount = ViewDebug.getViewAncestorInstanceCount();
            long appContextInstanceCount = Debug.countInstancesOfClass(ContextImpl.class);
            long activityInstanceCount = Debug.countInstancesOfClass(Activity.class);
            int globalAssetCount = AssetManager.getGlobalAssetCount();
@@ -843,7 +843,7 @@ public final class ActivityThread {

            pw.println(" ");
            pw.println(" Objects");
            printRow(pw, TWO_COUNT_COLUMNS, "Views:", viewInstanceCount, "ViewRoots:",
            printRow(pw, TWO_COUNT_COLUMNS, "Views:", viewInstanceCount, "ViewAncestors:",
                    viewRootInstanceCount);

            printRow(pw, TWO_COUNT_COLUMNS, "AppContexts:", appContextInstanceCount,
@@ -3918,7 +3918,7 @@ public final class ActivityThread {
        sThreadLocal.set(this);
        mSystemThread = system;
        if (!system) {
            ViewRoot.addFirstDrawHandler(new Runnable() {
            ViewAncestor.addFirstDrawHandler(new Runnable() {
                public void run() {
                    ensureJitEnabled();
                }
@@ -3948,7 +3948,7 @@ public final class ActivityThread {
            }
        }
        
        ViewRoot.addConfigCallback(new ComponentCallbacks() {
        ViewAncestor.addConfigCallback(new ComponentCallbacks() {
            public void onConfigurationChanged(Configuration newConfig) {
                synchronized (mPackages) {
                    // We need to apply this change to the resources
+4 −4
Original line number Diff line number Diff line
@@ -38,7 +38,7 @@ import android.os.RemoteException;
import android.os.ServiceManager;
import android.util.DisplayMetrics;
import android.util.Log;
import android.view.ViewRoot;
import android.view.ViewAncestor;

import java.io.FileOutputStream;
import java.io.IOException;
@@ -632,7 +632,7 @@ public class WallpaperManager {
    public void setWallpaperOffsets(IBinder windowToken, float xOffset, float yOffset) {
        try {
            //Log.v(TAG, "Sending new wallpaper offsets from app...");
            ViewRoot.getWindowSession(mContext.getMainLooper()).setWallpaperPosition(
            ViewAncestor.getWindowSession(mContext.getMainLooper()).setWallpaperPosition(
                    windowToken, xOffset, yOffset, mWallpaperXStep, mWallpaperYStep);
            //Log.v(TAG, "...app returning after sending offsets!");
        } catch (RemoteException e) {
@@ -670,7 +670,7 @@ public class WallpaperManager {
            int x, int y, int z, Bundle extras) {
        try {
            //Log.v(TAG, "Sending new wallpaper offsets from app...");
            ViewRoot.getWindowSession(mContext.getMainLooper()).sendWallpaperCommand(
            ViewAncestor.getWindowSession(mContext.getMainLooper()).sendWallpaperCommand(
                    windowToken, action, x, y, z, extras, false);
            //Log.v(TAG, "...app returning after sending offsets!");
        } catch (RemoteException e) {
@@ -690,7 +690,7 @@ public class WallpaperManager {
     */
    public void clearWallpaperOffsets(IBinder windowToken) {
        try {
            ViewRoot.getWindowSession(mContext.getMainLooper()).setWallpaperPosition(
            ViewAncestor.getWindowSession(mContext.getMainLooper()).setWallpaperPosition(
                    windowToken, -1, -1, -1, -1);
        } catch (RemoteException e) {
            // Ignore.
+2 −2
Original line number Diff line number Diff line
@@ -51,7 +51,7 @@ import android.view.MotionEvent;
import android.view.SurfaceHolder;
import android.view.View;
import android.view.ViewGroup;
import android.view.ViewRoot;
import android.view.ViewAncestor;
import android.view.WindowManager;
import android.view.WindowManagerImpl;
import android.view.WindowManagerPolicy;
@@ -650,7 +650,7 @@ public abstract class WallpaperService extends Service {
            mWindowToken = wrapper.mWindowToken;
            mSurfaceHolder.setSizeFromLayout();
            mInitializing = true;
            mSession = ViewRoot.getWindowSession(getMainLooper());
            mSession = ViewAncestor.getWindowSession(getMainLooper());
            
            mWindow.setSession(mSession);
            
+2 −2
Original line number Diff line number Diff line
@@ -34,7 +34,7 @@ import javax.microedition.khronos.egl.EGLSurface;
import javax.microedition.khronos.opengles.GL;

/**
 * Interface for rendering a ViewRoot using hardware acceleration.
 * Interface for rendering a ViewAncestor using hardware acceleration.
 * 
 * @hide
 */
@@ -209,7 +209,7 @@ public abstract class HardwareRenderer {
    
    /**
     * Initializes the hardware renderer for the specified surface and setup the
     * renderer for drawing, if needed. This is invoked when the ViewRoot has
     * renderer for drawing, if needed. This is invoked when the ViewAncestor has
     * potentially lost the hardware renderer. The hardware renderer should be
     * reinitialized and setup when the render {@link #isRequested()} and
     * {@link #isEnabled()}.
+1 −1
Original line number Diff line number Diff line
@@ -427,7 +427,7 @@ public class SurfaceView extends View {
        if (!mHaveFrame) {
            return;
        }
        ViewRoot viewRoot = (ViewRoot) getRootView().getParent();
        ViewAncestor viewRoot = (ViewAncestor) getRootView().getParent();
        if (viewRoot != null) {
            mTranslator = viewRoot.mTranslator;
        }
Loading