Skip to content

Instantly share code, notes, and snippets.

@frankibem
Created April 8, 2016 00:41
Show Gist options
  • Save frankibem/a4f59cb4993e1cbd4a4d181be7c10f6e to your computer and use it in GitHub Desktop.
Save frankibem/a4f59cb4993e1cbd4a4d181be7c10f6e to your computer and use it in GitHub Desktop.
<?xml version="1.0" encoding="utf-8"?>
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="vertical"
android:paddingBottom="@dimen/activity_vertical_margin"
android:paddingLeft="@dimen/activity_horizontal_margin"
android:paddingRight="@dimen/activity_horizontal_margin"
android:paddingTop="@dimen/activity_vertical_margin"
tools:context="com.test.leaderboard.Leaderboard">
<LinearLayout
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="vertical">
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="center"
android:text="Leaderboard"
android:textColor="@android:color/black"
android:textSize="20sp" />
<ListView
android:id="@+id/listView"
android:layout_width="match_parent"
android:layout_height="0dp"
android:layout_weight="1"
tools:listitem="@layout/leaderboard_item" />
<LinearLayout
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="center"
android:orientation="horizontal">
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="Your score: "
android:textSize="20sp" />
<TextView
android:id="@+id/text_score"
android:layout_width="wrap_content"
android:layout_height="match_parent"
android:textSize="20sp"
tools:text="4000" />
</LinearLayout>
</LinearLayout>
<ProgressBar
android:id="@+id/progress"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_centerInParent="true" />
<TextView
android:id="@+id/text_error"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_centerInParent="true"
android:text="Could not load leaderboard data"
android:textColor="@color/red"
android:visibility="gone" />
</RelativeLayout>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment