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

Commit 92a2d7b0 authored by TreeHugger Robot's avatar TreeHugger Robot Committed by Automerger Merge Worker
Browse files

Merge "Add debug logs for haptics in NotificationPanelViewController." into...

Merge "Add debug logs for haptics in NotificationPanelViewController." into tm-qpr-dev am: 92f29629 am: 8133f23e

Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/20721950



Change-Id: I3d4639cfb6c98af0c4fd115e53101e2e6213d962
Signed-off-by: default avatarAutomerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
parents 0a7a57d8 8133f23e
Loading
Loading
Loading
Loading
+2 −0
Original line number Diff line number Diff line
@@ -4722,6 +4722,7 @@ public final class NotificationPanelViewController implements Dumpable {
            if (!openingWithTouch || !mHasVibratedOnOpen) {
                mVibratorHelper.vibrate(VibrationEffect.EFFECT_TICK);
                mHasVibratedOnOpen = true;
                mShadeLog.v("Vibrating on opening, mHasVibratedOnOpen=true");
            }
        }
    }
@@ -6122,6 +6123,7 @@ public final class NotificationPanelViewController implements Dumpable {
                    if (isFullyCollapsed()) {
                        // If panel is fully collapsed, reset haptic effect before adding movement.
                        mHasVibratedOnOpen = false;
                        mShadeLog.logHasVibrated(mHasVibratedOnOpen, mExpandedFraction);
                    }
                    addMovement(event);
                    if (!isFullyCollapsed()) {
+9 −0
Original line number Diff line number Diff line
@@ -140,6 +140,15 @@ class ShadeLogger @Inject constructor(@ShadeLog private val buffer: LogBuffer) {
        })
    }

    fun logHasVibrated(hasVibratedOnOpen: Boolean, fraction: Float) {
        log(LogLevel.VERBOSE, {
            bool1 = hasVibratedOnOpen
            double1 = fraction.toDouble()
        }, {
            "hasVibratedOnOpen=$bool1, expansionFraction=$double1"
        })
    }

    fun logQsExpansionChanged(
            message: String,
            qsExpanded: Boolean,