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

Commit 8813e7fe authored by Long Ling's avatar Long Ling Committed by Android (Google) Code Review
Browse files

Merge "DMD: update BrightnessObserver dump"

parents 5e87b309 ffcd75f9
Loading
Loading
Loading
Loading
+7 −0
Original line number Diff line number Diff line
@@ -1050,6 +1050,7 @@ public class DisplayModeDirector {

        public void dumpLocked(PrintWriter pw) {
            pw.println("  BrightnessObserver");
            pw.println("    mAmbientLux: " + mAmbientLux);
            pw.println("    mRefreshRateInZone: " + mRefreshRateInZone);

            for (int d: mDisplayBrightnessThresholds) {
@@ -1059,6 +1060,8 @@ public class DisplayModeDirector {
            for (int d: mAmbientBrightnessThresholds) {
                pw.println("    mAmbientBrightnessThreshold: " + d);
            }

            mLightSensorListener.dumpLocked(pw);
        }

        public void onDisplayChanged(int displayId) {
@@ -1222,6 +1225,10 @@ public class DisplayModeDirector {
            final private static int INJECT_EVENTS_INTERVAL_MS = LIGHT_SENSOR_RATE_MS;
            private float mLastSensorData;

            public void dumpLocked(PrintWriter pw) {
                pw.println("    mLastSensorData: " + mLastSensorData);
            }

            @Override
            public void onSensorChanged(SensorEvent event) {
                mLastSensorData = event.values[0];