wanjingy.github.io / hw9 / EventFinder / app / src / main / res / layout / fragment_venue.xml
fragment_venue.xml
Raw
<?xml version="1.0" encoding="utf-8"?>
<FrameLayout xmlns:android="http://schemas.android.com/apk/res/android"
    xmlns:tools="http://schemas.android.com/tools"
    xmlns:app="http://schemas.android.com/apk/res-auto"
    android:layout_width="match_parent"
    android:layout_height="match_parent"
    tools:context=".details.VenueFragment">

    <RelativeLayout
        android:layout_width="match_parent"
        android:layout_height="match_parent">
        <ProgressBar
            android:id="@+id/venueProgressBar"
            android:layout_width="wrap_content"
            android:layout_height="wrap_content"
            android:layout_centerInParent="true"
            android:indeterminate="true"
            android:indeterminateTint="@color/green"
            />
        <androidx.cardview.widget.CardView
            android:id="@+id/noVenue"
            android:layout_width="match_parent"
            android:layout_height="wrap_content"
            android:layout_centerInParent="true"
            android:layout_marginHorizontal="10dp"
            app:cardBackgroundColor="@color/black"
            app:cardCornerRadius="10dp">

            <TextView
                android:layout_width="wrap_content"
                android:layout_height="wrap_content"
                android:layout_gravity="center"
                android:layout_marginVertical="10dp"
                android:text="No venue information found"
                android:textColor="@color/green"
                android:textStyle="bold" />
        </androidx.cardview.widget.CardView>
        <ScrollView
            android:id="@+id/venue"
            android:layout_width="match_parent"
            android:layout_height="match_parent">

            <LinearLayout
                android:layout_width="match_parent"
                android:layout_height="wrap_content"
                android:orientation="vertical"
                android:padding="15dp"
                >
                <androidx.cardview.widget.CardView
                    android:layout_width="match_parent"
                    android:layout_height="wrap_content"
                    app:cardBackgroundColor="@color/black"
                    app:cardCornerRadius="20dp">
                    <LinearLayout
                        android:layout_width="match_parent"
                        android:layout_height="wrap_content"
                        android:orientation="vertical"
                        android:padding="20dp">
                        <GridLayout
                            android:layout_width="match_parent"
                            android:layout_height="match_parent"
                            android:columnCount="2">
                            <TextView
                                android:layout_width="0dp"
                                android:layout_height="wrap_content"
                                android:text="Name"
                                android:textColor="@color/white"
                                android:textSize="18sp"
                                android:textStyle="bold"
                                android:layout_columnWeight="1"
                                android:layout_marginBottom="20dp"
                                />
                            <TextView
                                android:id="@+id/nameContent"
                                android:layout_width="0dp"
                                android:layout_height="wrap_content"
                                android:text="Name"
                                android:textColor="@color/green"
                                android:textSize="18sp"
                                android:textStyle="bold"
                                android:textAlignment="center"
                                android:layout_columnWeight="1"
                                android:ellipsize="marquee"
                                android:marqueeRepeatLimit ="marquee_forever"
                                android:focusable="true"
                                android:focusableInTouchMode="true"
                                android:scrollHorizontally="true"
                                android:singleLine="true"
                                />
                            <TextView
                                android:id="@+id/addressLabel"
                                android:layout_width="0dp"
                                android:layout_height="wrap_content"
                                android:text="Address"
                                android:textColor="@color/white"
                                android:textSize="18sp"
                                android:textStyle="bold"
                                android:layout_columnWeight="1"
                                android:layout_marginBottom="20dp"
                                />
                            <TextView
                                android:id="@+id/addressContent"
                                android:layout_width="0dp"
                                android:layout_height="wrap_content"
                                android:text="Address"
                                android:textColor="@color/green"
                                android:textSize="18sp"
                                android:textStyle="bold"
                                android:textAlignment="center"
                                android:layout_columnWeight="1"
                                android:ellipsize="marquee"
                                android:marqueeRepeatLimit ="marquee_forever"
                                android:focusable="true"
                                android:focusableInTouchMode="true"
                                android:scrollHorizontally="true"
                                android:singleLine="true"
                                />
                            <TextView
                                android:id="@+id/cityLabel"
                                android:layout_width="0dp"
                                android:layout_height="wrap_content"
                                android:text="City/State"
                                android:textColor="@color/white"
                                android:textSize="18sp"
                                android:textStyle="bold"
                                android:layout_columnWeight="1"
                                android:layout_marginBottom="20dp"
                                />
                            <TextView
                                android:id="@+id/cityContent"
                                android:layout_width="0dp"
                                android:layout_height="wrap_content"
                                android:text="City/State"
                                android:textColor="@color/green"
                                android:textSize="18sp"
                                android:textStyle="bold"
                                android:textAlignment="center"
                                android:layout_columnWeight="1"
                                android:ellipsize="marquee"
                                android:marqueeRepeatLimit ="marquee_forever"
                                android:focusable="true"
                                android:focusableInTouchMode="true"
                                android:scrollHorizontally="true"
                                android:singleLine="true"
                                />
                            <TextView
                                android:id="@+id/phoneLabel"
                                android:layout_width="0dp"
                                android:layout_height="wrap_content"
                                android:text="Contact Info"
                                android:textColor="@color/white"
                                android:textSize="18sp"
                                android:textStyle="bold"
                                android:layout_columnWeight="1"
                                android:layout_marginBottom="20dp"
                                />
                            <TextView
                                android:id="@+id/phoneContent"
                                android:layout_width="0dp"
                                android:layout_height="wrap_content"
                                android:text="Contact Info"
                                android:textColor="@color/green"
                                android:textSize="18sp"
                                android:textStyle="bold"
                                android:textAlignment="center"
                                android:layout_columnWeight="1"
                                android:ellipsize="marquee"
                                android:marqueeRepeatLimit ="marquee_forever"
                                android:focusable="true"
                                android:focusableInTouchMode="true"
                                android:scrollHorizontally="true"
                                android:singleLine="true"
                                />
                        </GridLayout>
                        <androidx.cardview.widget.CardView
                            android:id="@+id/mapLayout"
                            android:layout_width="match_parent"
                            android:layout_height="200dp"
                            app:cardCornerRadius="20dp">
                            <fragment
                                android:id="@+id/map"
                                android:name="com.google.android.gms.maps.SupportMapFragment"
                                android:layout_width="match_parent"
                                android:layout_height="match_parent"
                                app:cameraZoom="15"/>
                        </androidx.cardview.widget.CardView>
                    </LinearLayout>
                </androidx.cardview.widget.CardView>
                <androidx.cardview.widget.CardView
                    android:id="@+id/extraInfo"
                    android:layout_width="match_parent"
                    android:layout_height="wrap_content"
                    android:layout_marginTop="20dp"
                    app:cardBackgroundColor="@color/beige"
                    app:cardCornerRadius="20dp">
                    <LinearLayout
                        android:layout_width="match_parent"
                        android:layout_height="wrap_content"
                        android:orientation="vertical"
                        android:padding="20dp">
                        <TextView
                            android:id="@+id/openLabel"
                            android:layout_width="wrap_content"
                            android:layout_height="wrap_content"
                            android:text="Open Hours"
                            android:textSize="18sp"
                            android:textStyle="bold"
                            android:textColor="@color/black"
                            android:layout_marginBottom="20dp"
                            />
                        <TextView
                            android:id="@+id/openContent"
                            android:layout_width="match_parent"
                            android:layout_height="wrap_content"
                            android:text="Open Hours"
                            android:textColor="@color/black"
                            android:layout_marginBottom="20dp"
                            android:ellipsize="end"
                            android:maxLines="3"
                            />
                        <TextView
                            android:id="@+id/generalLabel"
                            android:layout_width="wrap_content"
                            android:layout_height="wrap_content"
                            android:text="General Rules"
                            android:textSize="18sp"
                            android:textStyle="bold"
                            android:textColor="@color/black"
                            android:layout_marginBottom="20dp"
                            />
                        <TextView
                            android:id="@+id/generalContent"
                            android:layout_width="match_parent"
                            android:layout_height="wrap_content"
                            android:text="General Rules"
                            android:textColor="@color/black"
                            android:layout_marginBottom="20dp"
                            android:ellipsize="end"
                            android:maxLines="3"
                            />
                        <TextView
                            android:id="@+id/childLabel"
                            android:layout_width="wrap_content"
                            android:layout_height="wrap_content"
                            android:text="Child Rules"
                            android:textSize="18sp"
                            android:textStyle="bold"
                            android:textColor="@color/black"
                            android:layout_marginBottom="20dp"
                            />
                        <TextView
                            android:id="@+id/childContent"
                            android:layout_width="match_parent"
                            android:layout_height="wrap_content"
                            android:text="Child Rules"
                            android:textColor="@color/black"
                            android:ellipsize="end"
                            android:maxLines="3"
                            />
                    </LinearLayout>
                </androidx.cardview.widget.CardView>
            </LinearLayout>
        </ScrollView>
    </RelativeLayout>

</FrameLayout>