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

Commit 55e395ab authored by Jeff Brown's avatar Jeff Brown
Browse files

Remove freezeDisplay(), which is no-op.

Change-Id: I981ee49e6e2d41a09feaee4b384392e83f7faf3d
parent 401b1f85
Loading
Loading
Loading
Loading
+0 −16
Original line number Diff line number Diff line
@@ -414,22 +414,6 @@ public class Surface implements Parcelable {
     * set display parameters & screenshots
     */

    /**
     * Freezes the specified display, No updating of the screen will occur
     * until unfreezeDisplay() is called. Everything else works as usual though,
     * in particular transactions.
     * @param display
     * @hide
     */
    public static native   void freezeDisplay(int display);

    /**
     * resume updating the specified display.
     * @param display
     * @hide
     */
    public static native   void unfreezeDisplay(int display);

    /**
     * set the orientation of the given display.
     * @param display
+0 −20
Original line number Diff line number Diff line
@@ -481,24 +481,6 @@ static void Surface_setOrientation(
    }
}

static void Surface_freezeDisplay(
        JNIEnv* env, jobject clazz, jint display)
{
    int err = SurfaceComposerClient::freezeDisplay(display, 0);
    if (err < 0) {
        doThrowIAE(env);
    }
}

static void Surface_unfreezeDisplay(
        JNIEnv* env, jobject clazz, jint display)
{
    int err = SurfaceComposerClient::unfreezeDisplay(display, 0);
    if (err < 0) {
        doThrowIAE(env);
    }
}

class ScreenshotPixelRef : public SkPixelRef {
public:
    ScreenshotPixelRef(SkColorTable* ctable) {
@@ -892,8 +874,6 @@ static JNINativeMethod gSurfaceMethods[] = {
    {"openTransaction",     "()V",  (void*)Surface_openTransaction },
    {"closeTransaction",    "()V",  (void*)Surface_closeTransaction },
    {"setOrientation",      "(III)V", (void*)Surface_setOrientation },
    {"freezeDisplay",       "(I)V", (void*)Surface_freezeDisplay },
    {"unfreezeDisplay",     "(I)V", (void*)Surface_unfreezeDisplay },
    {"screenshot",          "(II)Landroid/graphics/Bitmap;", (void*)Surface_screenshotAll },
    {"screenshot",          "(IIII)Landroid/graphics/Bitmap;", (void*)Surface_screenshot },
    {"setLayer",            "(I)V", (void*)Surface_setLayer },
+0 −7
Original line number Diff line number Diff line
@@ -9415,12 +9415,6 @@ public class WindowManagerService extends IWindowManager.Stub
            mAnimator.mScreenRotationAnimation = new ScreenRotationAnimation(mContext,
                    mFxSession, inTransaction, mCurDisplayWidth, mCurDisplayHeight,
                    mDisplay.getRotation());

            if (!mAnimator.mScreenRotationAnimation.hasScreenshot()) {
                Surface.freezeDisplay(0);
            }
        } else {
            Surface.freezeDisplay(0);
        }
    }

@@ -9463,7 +9457,6 @@ public class WindowManagerService extends IWindowManager.Stub
            }
            updateRotation = true;
        }
        Surface.unfreezeDisplay(0);

        mInputMonitor.thawInputDispatchingLw();