<?xml version="1.0" encoding="UTF-8"?>
<!--
  ~ Copyright (c) 2015, Nordic Semiconductor
  ~ All rights reserved.
  ~
  ~ Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met:
  ~
  ~ 1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer.
  ~
  ~ 2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the
  ~ documentation and/or other materials provided with the distribution.
  ~
  ~ 3. Neither the name of the copyright holder nor the names of its contributors may be used to endorse or promote products derived from this
  ~ software without specific prior written permission.
  ~
  ~ THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
  ~ LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
  ~ HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  ~ LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
  ~ ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE
  ~ USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  -->
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
	xmlns:app="http://schemas.android.com/apk/res-auto"
	android:layout_width="match_parent"
	android:layout_height="?android:attr/listPreferredItemHeightSmall"
	xmlns:tools="http://schemas.android.com/tools"
	android:paddingBottom="2dp"
	android:paddingEnd="8dp"
	android:paddingStart="8dp"
	android:paddingTop="2dp"
	android:gravity="center_vertical">

	<RelativeLayout
		android:layout_width="0dp"
		android:layout_weight="1"
		android:layout_height="wrap_content">

		<no.nordicsemi.android.nrftoolbox.widget.TrebuchetBoldTextView
			android:id="@+id/name"
			android:layout_width="match_parent"
			android:layout_height="wrap_content"
			android:ellipsize="marquee"
			android:gravity="center_vertical"
			android:textSize="20sp"
			tools:text="Nordic_Prox"
			android:textColor="@android:color/black"
			android:singleLine="true"/>

		<TextView
			android:id="@+id/address"
			android:layout_width="wrap_content"
			android:layout_height="wrap_content"
			android:textSize="12sp"
			tools:text="AA:BB:CC:DD:EE:FF"
			android:layout_below="@+id/name"
			android:lines="1"/>

		<TextView
			android:id="@+id/battery"
			android:layout_width="wrap_content"
			android:layout_height="wrap_content"
			android:layout_below="@+id/name"
			android:textSize="12sp"
			android:gravity="center"
			android:layout_toRightOf="@+id/address"
			android:drawableLeft="@drawable/ic_battery"
			android:layout_marginLeft="4dp"
			tools:visibility="visible"
			tools:text="100%"
			android:visibility="gone"/>

	</RelativeLayout>

	<ProgressBar
		android:id="@+id/progress"
		style="?android:progressBarStyleSmall"
		android:layout_width="wrap_content"
		android:layout_height="wrap_content"
		android:layout_marginRight="16dp"/>

	<android.support.v7.widget.AppCompatImageButton
		android:id="@+id/action_find_silent"
		android:layout_width="wrap_content"
		android:layout_height="wrap_content"
		app:backgroundTint="@color/actionBarColorDark"
		android:src="@drawable/ic_stat_notify_proximity_find"
		tools:visibility="visible"
		android:visibility="gone"/>

	<android.support.v7.widget.AppCompatImageButton
		android:id="@+id/action_disconnect"
		android:layout_width="wrap_content"
		android:layout_height="wrap_content"
		app:backgroundTint="@color/orange"
		android:src="@drawable/ic_action_disconnect"/>

</LinearLayout>
