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

Commit 63273d45 authored by Beverly's avatar Beverly
Browse files

Fix clickable notification row elements

- Don't mark notification guts as clickable. Originally they were marked
as clickable so that the guts wouldn't send touches to trigger the
ExpandableNotificationRow's click, NotificationClicker. This caused
talkback to speak "Double-tap to activate" when announcing the
NotificationGuts even though double-tapping would do nothing.
- Instead, added logic in NotificationClicker to ignore clicks that
occur when the guts are exposed.

Test: manual
Fixes: 140398522
Change-Id: I806051ffd43ed27c38e804fdc43e2c2d3522566c
parent 645fdff0
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -19,8 +19,8 @@
        xmlns:android="http://schemas.android.com/apk/res/android"
        android:layout_width="match_parent"
        android:layout_height="wrap_content"
        android:focusable="true"
        android:id="@+id/app_ops_info"
        android:clickable="true"
        android:clipChildren="false"
        android:clipToPadding="false"
        android:orientation="vertical"
+1 −1
Original line number Diff line number Diff line
@@ -20,7 +20,7 @@
    android:id="@+id/notification_guts"
    android:layout_width="match_parent"
    android:layout_height="wrap_content"
    android:clickable="true"
    android:focusable="true"
    android:clipChildren="false"
    android:clipToPadding="true"
    android:orientation="vertical"
+1 −1
Original line number Diff line number Diff line
@@ -19,8 +19,8 @@
    xmlns:android="http://schemas.android.com/apk/res/android"
    android:layout_width="match_parent"
    android:layout_height="wrap_content"
    android:focusable="true"
    android:id="@+id/notification_guts"
    android:visibility="gone"
    android:clickable="true"
    android:gravity="top|start"
    android:theme="@*android:style/Theme.DeviceDefault.Light"/>
+1 −1
Original line number Diff line number Diff line
@@ -20,7 +20,7 @@
    android:id="@+id/notification_guts"
    android:layout_width="match_parent"
    android:layout_height="wrap_content"
    android:clickable="true"
    android:focusable="true"
    android:clipChildren="false"
    android:clipToPadding="true"
    android:orientation="vertical"
+3 −0
Original line number Diff line number Diff line
@@ -75,6 +75,9 @@ public final class NotificationClicker implements View.OnClickListener {
            // We never want to open the app directly if the user clicks in between
            // the notifications.
            return;
        } else if (row.areGutsExposed()) {
            // ignore click if guts are exposed
            return;
        }

        // Mark notification for one frame.