0

In my app, I have used a relative layout with Edittext when I add android:layout_alignParentBottom="true", my edittext will not update and the cursor will not blink(It seem the main thread is doing so much work). When I remove android:layout_alignParentBottom="true" the code work fine

This code is not working well

<?xml version="1.0" encoding="utf-8"?>
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
                android:layout_width="match_parent"
                android:layout_height="match_parent"
               >
        <EditText
                android:layout_alignParentBottom="true"
                android:textColor="@color/black"
                android:layout_width="match_parent"
                android:layout_height="wrap_content"/>
</RelativeLayout>

This work fine

<?xml version="1.0" encoding="utf-8"?>
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
                android:layout_width="match_parent"
                android:layout_height="match_parent"
               >
        <EditText
                android:textColor="@color/black"
                android:layout_width="match_parent"
                android:layout_height="wrap_content"/>
</RelativeLayout>
Youssef Maouche
  • 175
  • 1
  • 2
  • 10
  • We can not reproduce the issue, as the provided info is not sufficient . Please see [How to create a Minimal, Reproducible Example](https://stackoverflow.com/help/minimal-reproducible-example) – Zain Nov 25 '20 at 19:57
  • When you say it will not update, what do you mean? – Si8 Nov 25 '20 at 20:54
  • https://stackoverflow.com/a/57825912/3874721 have a look here, that should be helpful. – Yurii Tsap Nov 25 '20 at 21:01
  • thanks for your reply. Unfortnately I coudn't reproduce the problem and can't share it because its quit big and contain a lot of costume views. The problem appear when start new activity with the upper code. I solved this by updating android studios and create new project and copy past everythings. Thanks a lot. – Youssef Maouche Nov 26 '20 at 09:39

0 Answers0