I am dealing with a weird problem.
I am using the following layout for ListView
rows:
<?xml version="1.0" encoding="utf-8"?>
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:jn="http://schemas.android.com/apk/res/com.appeaser.justnoteproject"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="vertical" >
<BUNCH OF VIEWS />
<RelativeLayout
android:id="@+id/rlCon"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_marginBottom="@dimen/margin_note_bottom"
android:layout_marginLeft="@dimen/margin_note_left"
android:layout_marginRight="@dimen/margin_note_right"
android:layout_marginTop="@dimen/margin_note_bottom" >
<BUNCH OF VIEWS />
<View
android:id="@+id/vOverlay"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:background="@drawable/blue_overlay"
android:visibility="gone" />
</RelativeLayout>
</RelativeLayout>
In my list adapter, I toggle vOverlay's
visibility based on a certain condition. But, even after toggling the visibility, vOverlay
is not displayed.
To verify that the code works as intended, I changed the height and width of vOverlay
to 50dp
. When I did this, vOverlay's
visibility worked as intended - except that the size I need is match_parent
.
Could someone explain what I'm doing wrong? How can I get intended results?