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

Commit 8133f23e 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

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



Change-Id: I8b32b9c1484369d2be1830c3759063fd909ac469
Signed-off-by: default avatarAutomerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
parents 41dd6224 92f29629
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,