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

Commit 91bd3003 authored by Brian Attwell's avatar Brian Attwell
Browse files

Move QC's title contentDescription into photo

In Talkback, the contact photo will now read <Contact Name>
instead of "contact photo". The title textview will no longer be
readable by Talkback to avoid redundancy.

I didn't delete the @string/description_contact_photo since
another View uses it.

Bug: 17198755
Change-Id: I25384ba72e6222ac24d5dd20c2bf32326d3dca13
parent b1588c4a
Loading
Loading
Loading
Loading
+1 −2
Original line number Diff line number Diff line
@@ -27,8 +27,7 @@
        android:id="@+id/photo_touch_intercept_overlay"
        android:layout_width="match_parent"
        android:layout_height="match_parent"
        android:background="@drawable/item_background_material_dark"
        android:contentDescription="@string/description_contact_photo" />
        android:background="@drawable/item_background_material_dark" />

    <!-- Overlays/gradients that can be used to make white text/buttons visible -->
    <View
+4 −0
Original line number Diff line number Diff line
@@ -14,6 +14,9 @@
     See the License for the specific language governing permissions and
     limitations under the License.
-->

<!-- The importantForAccessibility is set to "no" since we want the ViewGroup that pretends to be
    this View's parent (contact photo overlay) to provide the content description for Talkback. -->
<TextView
    xmlns:android="http://schemas.android.com/apk/res/android"
    android:layout_width="wrap_content"
@@ -26,4 +29,5 @@
    android:maxLines="@integer/quickcontact_title_lines"
    android:textSize="@dimen/quickcontact_maximum_title_size"
    android:ellipsize="end"
    android:importantForAccessibility="no"
    android:id="@+id/large_title"/>
 No newline at end of file
+1 −0
Original line number Diff line number Diff line
@@ -350,6 +350,7 @@ public class MultiShrinkScroller extends FrameLayout {

    public void setTitle(String title) {
        mLargeTextView.setText(title);
        mPhotoTouchInterceptOverlay.setContentDescription(title);
    }

    public void setUseGradient(boolean useGradient) {