Loading cmds/statsd/src/atoms.proto +3 −0 Original line number Diff line number Diff line Loading @@ -5556,6 +5556,9 @@ message BubbleUIChanged { // Normalized screen position of the bubble stack. The range is between 0 and 1. optional float normalized_x_position = 7; optional float normalized_y_position = 8; // Whether the bubble is unread. If it is unread, a dot is shown in the bubble stack icon. optional bool is_unread = 9; } /** Loading packages/SystemUI/src/com/android/systemui/bubbles/BubbleExpandedView.java +9 −7 Original line number Diff line number Diff line Loading @@ -413,7 +413,7 @@ public class BubbleExpandedView extends LinearLayout implements View.OnClickList ((TextView) mPermissionView.findViewById(R.id.pkgname)).setText(mAppName); ((TextView) mPermissionView.findViewById(R.id.prompt)).setText( getResources().getString(R.string.bubbles_prompt, mAppName)); logBubbleClickEvent(mEntry.notification, logBubbleClickEvent(mEntry, StatsLog.BUBBLE_UICHANGED__ACTION__PERMISSION_DIALOG_SHOWN); } } Loading Loading @@ -509,7 +509,7 @@ public class BubbleExpandedView extends LinearLayout implements View.OnClickList mStackView.collapseStack(() -> { try { n.contentIntent.send(); logBubbleClickEvent(mEntry.notification, logBubbleClickEvent(mEntry, StatsLog.BUBBLE_UICHANGED__ACTION__HEADER_GO_TO_APP); } catch (PendingIntent.CanceledException e) { Log.w(TAG, "Failed to send intent for bubble with key: " Loading @@ -521,7 +521,7 @@ public class BubbleExpandedView extends LinearLayout implements View.OnClickList mEntry.notification.getUid()); mStackView.collapseStack(() -> { mContext.startActivity(intent); logBubbleClickEvent(mEntry.notification, logBubbleClickEvent(mEntry, StatsLog.BUBBLE_UICHANGED__ACTION__HEADER_GO_TO_SETTINGS); }); } else if (id == R.id.no_bubbles_button) { Loading @@ -544,7 +544,7 @@ public class BubbleExpandedView extends LinearLayout implements View.OnClickList mOnBubbleBlockedListener.onBubbleBlocked(mEntry); } mStackView.onExpandedHeightChanged(); logBubbleClickEvent(mEntry.notification, logBubbleClickEvent(mEntry, allowed ? StatsLog.BUBBLE_UICHANGED__ACTION__PERMISSION_OPT_IN : StatsLog.BUBBLE_UICHANGED__ACTION__PERMISSION_OPT_OUT); } catch (RemoteException e) { Loading Loading @@ -707,10 +707,11 @@ public class BubbleExpandedView extends LinearLayout implements View.OnClickList /** * Logs bubble UI click event. * * @param notification the bubble notification that user is interacting with. * @param entry the bubble notification entry that user is interacting with. * @param action the user interaction enum. */ private void logBubbleClickEvent(StatusBarNotification notification, int action) { private void logBubbleClickEvent(NotificationEntry entry, int action) { StatusBarNotification notification = entry.notification; StatsLog.write(StatsLog.BUBBLE_UI_CHANGED, notification.getPackageName(), notification.getNotification().getChannelId(), Loading @@ -719,7 +720,8 @@ public class BubbleExpandedView extends LinearLayout implements View.OnClickList mStackView.getBubbleCount(), action, mStackView.getNormalizedXPosition(), mStackView.getNormalizedYPosition()); mStackView.getNormalizedYPosition(), entry.showInShadeWhenBubble()); } private int getDimenForPackageUser(int resId, String pkg, int userId) { Loading packages/SystemUI/src/com/android/systemui/bubbles/BubbleStackView.java +4 −2 Original line number Diff line number Diff line Loading @@ -962,7 +962,8 @@ public class BubbleStackView extends FrameLayout { getBubbleCount(), action, getNormalizedXPosition(), getNormalizedYPosition()); getNormalizedYPosition(), false /* unread notification */); } else { StatusBarNotification notification = bubble.entry.notification; StatsLog.write(StatsLog.BUBBLE_UI_CHANGED, Loading @@ -973,7 +974,8 @@ public class BubbleStackView extends FrameLayout { getBubbleCount(), action, getNormalizedXPosition(), getNormalizedYPosition()); getNormalizedYPosition(), bubble.entry.showInShadeWhenBubble()); } } Loading Loading
cmds/statsd/src/atoms.proto +3 −0 Original line number Diff line number Diff line Loading @@ -5556,6 +5556,9 @@ message BubbleUIChanged { // Normalized screen position of the bubble stack. The range is between 0 and 1. optional float normalized_x_position = 7; optional float normalized_y_position = 8; // Whether the bubble is unread. If it is unread, a dot is shown in the bubble stack icon. optional bool is_unread = 9; } /** Loading
packages/SystemUI/src/com/android/systemui/bubbles/BubbleExpandedView.java +9 −7 Original line number Diff line number Diff line Loading @@ -413,7 +413,7 @@ public class BubbleExpandedView extends LinearLayout implements View.OnClickList ((TextView) mPermissionView.findViewById(R.id.pkgname)).setText(mAppName); ((TextView) mPermissionView.findViewById(R.id.prompt)).setText( getResources().getString(R.string.bubbles_prompt, mAppName)); logBubbleClickEvent(mEntry.notification, logBubbleClickEvent(mEntry, StatsLog.BUBBLE_UICHANGED__ACTION__PERMISSION_DIALOG_SHOWN); } } Loading Loading @@ -509,7 +509,7 @@ public class BubbleExpandedView extends LinearLayout implements View.OnClickList mStackView.collapseStack(() -> { try { n.contentIntent.send(); logBubbleClickEvent(mEntry.notification, logBubbleClickEvent(mEntry, StatsLog.BUBBLE_UICHANGED__ACTION__HEADER_GO_TO_APP); } catch (PendingIntent.CanceledException e) { Log.w(TAG, "Failed to send intent for bubble with key: " Loading @@ -521,7 +521,7 @@ public class BubbleExpandedView extends LinearLayout implements View.OnClickList mEntry.notification.getUid()); mStackView.collapseStack(() -> { mContext.startActivity(intent); logBubbleClickEvent(mEntry.notification, logBubbleClickEvent(mEntry, StatsLog.BUBBLE_UICHANGED__ACTION__HEADER_GO_TO_SETTINGS); }); } else if (id == R.id.no_bubbles_button) { Loading @@ -544,7 +544,7 @@ public class BubbleExpandedView extends LinearLayout implements View.OnClickList mOnBubbleBlockedListener.onBubbleBlocked(mEntry); } mStackView.onExpandedHeightChanged(); logBubbleClickEvent(mEntry.notification, logBubbleClickEvent(mEntry, allowed ? StatsLog.BUBBLE_UICHANGED__ACTION__PERMISSION_OPT_IN : StatsLog.BUBBLE_UICHANGED__ACTION__PERMISSION_OPT_OUT); } catch (RemoteException e) { Loading Loading @@ -707,10 +707,11 @@ public class BubbleExpandedView extends LinearLayout implements View.OnClickList /** * Logs bubble UI click event. * * @param notification the bubble notification that user is interacting with. * @param entry the bubble notification entry that user is interacting with. * @param action the user interaction enum. */ private void logBubbleClickEvent(StatusBarNotification notification, int action) { private void logBubbleClickEvent(NotificationEntry entry, int action) { StatusBarNotification notification = entry.notification; StatsLog.write(StatsLog.BUBBLE_UI_CHANGED, notification.getPackageName(), notification.getNotification().getChannelId(), Loading @@ -719,7 +720,8 @@ public class BubbleExpandedView extends LinearLayout implements View.OnClickList mStackView.getBubbleCount(), action, mStackView.getNormalizedXPosition(), mStackView.getNormalizedYPosition()); mStackView.getNormalizedYPosition(), entry.showInShadeWhenBubble()); } private int getDimenForPackageUser(int resId, String pkg, int userId) { Loading
packages/SystemUI/src/com/android/systemui/bubbles/BubbleStackView.java +4 −2 Original line number Diff line number Diff line Loading @@ -962,7 +962,8 @@ public class BubbleStackView extends FrameLayout { getBubbleCount(), action, getNormalizedXPosition(), getNormalizedYPosition()); getNormalizedYPosition(), false /* unread notification */); } else { StatusBarNotification notification = bubble.entry.notification; StatsLog.write(StatsLog.BUBBLE_UI_CHANGED, Loading @@ -973,7 +974,8 @@ public class BubbleStackView extends FrameLayout { getBubbleCount(), action, getNormalizedXPosition(), getNormalizedYPosition()); getNormalizedYPosition(), bubble.entry.showInShadeWhenBubble()); } } Loading