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

Commit 78429586 authored by Yuri Lin's avatar Yuri Lin Committed by Android (Google) Code Review
Browse files

Merge "Add feedback click logging for conversations & bundles" into main

parents 43097916 28d98683
Loading
Loading
Loading
Loading
+37 −0
Original line number Diff line number Diff line
/*
 * Copyright (C) 2025 The Android Open Source Project
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *      http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */

package com.android.systemui.statusbar.notification.row;

import com.android.internal.logging.UiEvent;
import com.android.internal.logging.UiEventLogger;

enum NotificationFeedbackEvent implements UiEventLogger.UiEventEnum {
    @UiEvent(doc = "User clicked on feedback on a notification bundle")
    NOTIFICATION_FEEDBACK_BUNDLE(2280),

    @UiEvent(doc = "User clicked on feedback on a conversation notification")
    NOTIFICATION_FEEDBACK_CONVERSATION(2281);

    private final int mId;
    NotificationFeedbackEvent(int id) {
        mId = id;
    }

    @Override public int getId() {
        return mId;
    }
}
+4 −0
Original line number Diff line number Diff line
@@ -462,6 +462,8 @@ public class NotificationGutsManager implements NotifGutsViewManager, CoreStarta

        NotificationInfo.OnFeedbackClickListener onNasFeedbackClick = (View v, Intent intent) -> {
            guts.resetFalsingCheck();
            mUiEventLogger.log(NotificationFeedbackEvent.NOTIFICATION_FEEDBACK_BUNDLE,
                    sbn.getInstanceId());
            mNotificationActivityStarter.startNotificationGutsIntent(intent, sbn.getUid(), row);
        };

@@ -684,6 +686,8 @@ public class NotificationGutsManager implements NotifGutsViewManager, CoreStarta

        NotificationInfo.OnFeedbackClickListener onNasFeedbackClick = (View v, Intent intent) -> {
            guts.resetFalsingCheck();
            mUiEventLogger.log(NotificationFeedbackEvent.NOTIFICATION_FEEDBACK_CONVERSATION,
                    sbn.getInstanceId());
            mNotificationActivityStarter.startNotificationGutsIntent(intent, sbn.getUid(), row);
        };