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

Commit 90251c75 authored by Huan Song's avatar Huan Song Committed by Android (Google) Code Review
Browse files

Merge "Respect dpi from Emulator" into tm-dev

parents caa918f4 f7eeb100
Loading
Loading
Loading
Loading
+2 −7
Original line number Diff line number Diff line
@@ -995,13 +995,8 @@ status_t SurfaceFlinger::getDynamicDisplayInfo(const sp<IBinder>& displayToken,

        outMode.resolution = ui::Size(width, height);

        if (mEmulatedDisplayDensity) {
            outMode.xDpi = mEmulatedDisplayDensity;
            outMode.yDpi = mEmulatedDisplayDensity;
        } else {
        outMode.xDpi = xDpi;
        outMode.yDpi = yDpi;
        }

        const nsecs_t period = mode->getVsyncPeriod();
        outMode.refreshRate = Fps::fromPeriodNsecs(period).getValue();